X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=synfig-core%2Ftrunk%2Fsrc%2Fmodules%2Flyr_std%2Frotate.cpp;h=6c8e9e287098293f9a273b8e9f95cf63c8ff809b;hb=322d3f4965370f9c56c00c79ed9f0de30991ca26;hp=963e8e511205c81cf9efb428a2442ec8b2104a4b;hpb=675aca937d23c7f460edf42ac3ec0ffa06205a2c;p=synfig.git diff --git a/synfig-core/trunk/src/modules/lyr_std/rotate.cpp b/synfig-core/trunk/src/modules/lyr_std/rotate.cpp index 963e8e5..6c8e9e2 100644 --- a/synfig-core/trunk/src/modules/lyr_std/rotate.cpp +++ b/synfig-core/trunk/src/modules/lyr_std/rotate.cpp @@ -1,6 +1,6 @@ /* === S Y N F I G ========================================================= */ /*! \file rotate.cpp -** \brief Template Header +** \brief Implementation of the "Rotate" layer ** ** $Id$ ** @@ -51,8 +51,8 @@ SYNFIG_LAYER_INIT(Rotate); SYNFIG_LAYER_SET_NAME(Rotate,"rotate"); -SYNFIG_LAYER_SET_LOCAL_NAME(Rotate,_("Rotate")); -SYNFIG_LAYER_SET_CATEGORY(Rotate,_("Transform")); +SYNFIG_LAYER_SET_LOCAL_NAME(Rotate,N_("Rotate")); +SYNFIG_LAYER_SET_CATEGORY(Rotate,N_("Transform")); SYNFIG_LAYER_SET_VERSION(Rotate,"0.1"); SYNFIG_LAYER_SET_CVS_ID(Rotate,"$Id$"); @@ -79,7 +79,7 @@ Rotate::set_param(const String & param, const ValueBase &value) { IMPORT(origin); - if(param=="amount" && value.same_as(amount)) + if(param=="amount" && value.same_type_as(amount)) { amount=value.get(amount); sin_val=Angle::sin(amount).get(); @@ -256,7 +256,7 @@ Rotate::accelerated_render(Context context,Surface *surface,int quality, const R tmp=Point(cos_val*(point[0]-origin[0])+sin_val*(point[1]-origin[1]),-sin_val*(point[0]-origin[0])+cos_val*(point[1]-origin[1])) +origin; (*surface)[y][x]=source.cubic_sample((tmp[0]-tl[0])*pw,(tmp[1]-tl[1])*ph); } - if(y&31==0 && cb) + if((y&31)==0 && cb) { if(!stagetwo.amount_complete(y,surface->get_h())) return false; @@ -276,7 +276,7 @@ Rotate::accelerated_render(Context context,Surface *surface,int quality, const R tmp=Point(cos_val*(point[0]-origin[0])+sin_val*(point[1]-origin[1]),-sin_val*(point[0]-origin[0])+cos_val*(point[1]-origin[1])) +origin; (*surface)[y][x]=source.linear_sample((tmp[0]-tl[0])*pw,(tmp[1]-tl[1])*ph); } - if(y&31==0 && cb) + if((y&31)==0 && cb) { if(!stagetwo.amount_complete(y,surface->get_h())) return false; @@ -306,7 +306,7 @@ Rotate::accelerated_render(Context context,Surface *surface,int quality, const R //pen.set_value(source[v][u]); (*surface)[y][x]=source[v][u]; } - if(y&31==0 && cb) + if((y&31)==0 && cb) { if(!stagetwo.amount_complete(y,surface->get_h())) return false;