X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;ds=sidebyside;f=synfig-core%2Ftrunk%2Fsrc%2Fmodules%2Fmod_geometry%2Fcircle.cpp;h=4c38f4514fcbfd394d69bca494b2d166a204e42b;hb=756c0d29ac1742f231e6615f9a577e574e35a4af;hp=5d2ae3903de4fd8b1cf09bd1ff3a2541ccf1558b;hpb=cc54c38609ee9745ad678e5e9b9d7d2912be9c95;p=synfig.git diff --git a/synfig-core/trunk/src/modules/mod_geometry/circle.cpp b/synfig-core/trunk/src/modules/mod_geometry/circle.cpp index 5d2ae39..4c38f45 100644 --- a/synfig-core/trunk/src/modules/mod_geometry/circle.cpp +++ b/synfig-core/trunk/src/modules/mod_geometry/circle.cpp @@ -1,11 +1,12 @@ /* === S Y N F I G ========================================================= */ /*! \file circle.cpp -** \brief Template Header +** \brief Implementation of the "Circle" layer ** ** $Id$ ** ** \legal ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley +** Copyright (c) 2008 Chris Moore ** ** This package is free software; you can redistribute it and/or ** modify it under the terms of the GNU General Public License as @@ -51,8 +52,8 @@ using namespace etl; SYNFIG_LAYER_INIT(Circle); SYNFIG_LAYER_SET_NAME(Circle,"circle"); -SYNFIG_LAYER_SET_LOCAL_NAME(Circle,_("Circle")); -SYNFIG_LAYER_SET_CATEGORY(Circle,_("Geometry")); +SYNFIG_LAYER_SET_LOCAL_NAME(Circle,N_("Circle")); +SYNFIG_LAYER_SET_CATEGORY(Circle,N_("Geometry")); SYNFIG_LAYER_SET_VERSION(Circle,"0.1"); SYNFIG_LAYER_SET_CVS_ID(Circle,"$Id$"); @@ -73,7 +74,9 @@ Circle::Circle(): bool Circle::ImportParameters(const String ¶m, const ValueBase &value) { - IMPORT(color); + IMPORT_PLUS(color, { if (color.get_a() == 0) { if (converted_blend_) { + set_blend_method(Color::BLEND_ALPHA_OVER); + color.set_a(1); } else transparent_color_ = true; } }); IMPORT(radius); IMPORT(feather); IMPORT(invert); @@ -441,7 +444,8 @@ Circle::accelerated_render(Context context,Surface *surface,int quality, const R // Increasing the feather amount by the size of // a pixel will create an anti-aliased appearance - const Real newfeather=feather + (abs(ph)+abs(pw))/4.0; + // don't render feathering at all when quality is 10 + const Real newfeather = (quality == 10) ? 0 : feather + (abs(ph)+abs(pw))/4.0; //int u,v; int left = (int) floor( (pos[0] - x_neg*(radius+newfeather) - tl[0]) / pw );