projects
/
synfig.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix the 'plant' layer.
[synfig.git]
/
synfig-core
/
trunk
/
src
/
modules
/
mod_particle
/
plant.cpp
diff --git
a/synfig-core/trunk/src/modules/mod_particle/plant.cpp
b/synfig-core/trunk/src/modules/mod_particle/plant.cpp
index
035f494
..
66d78b8
100644
(file)
--- a/
synfig-core/trunk/src/modules/mod_particle/plant.cpp
+++ b/
synfig-core/trunk/src/modules/mod_particle/plant.cpp
@@
-2,7
+2,7
@@
/*! \file plant.cpp
** \brief Template
**
/*! \file plant.cpp
** \brief Template
**
-** $Id
: plant.cpp,v 1.2 2005/01/13 06:48:39 darco Exp
$
+** $Id$
**
** \legal
** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
**
** \legal
** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
@@
-65,9
+65,9
@@
using namespace etl;
SYNFIG_LAYER_INIT(Plant);
SYNFIG_LAYER_SET_NAME(Plant,"plant");
SYNFIG_LAYER_SET_LOCAL_NAME(Plant,_("Plant"));
SYNFIG_LAYER_INIT(Plant);
SYNFIG_LAYER_SET_NAME(Plant,"plant");
SYNFIG_LAYER_SET_LOCAL_NAME(Plant,_("Plant"));
-SYNFIG_LAYER_SET_CATEGORY(Plant,_("
Particle Systems
"));
+SYNFIG_LAYER_SET_CATEGORY(Plant,_("
Other
"));
SYNFIG_LAYER_SET_VERSION(Plant,"0.1");
SYNFIG_LAYER_SET_VERSION(Plant,"0.1");
-SYNFIG_LAYER_SET_CVS_ID(Plant,"$Id
: plant.cpp,v 1.2 2005/01/13 06:48:39 darco Exp
$");
+SYNFIG_LAYER_SET_CVS_ID(Plant,"$Id$");
/* === P R O C E D U R E S ================================================= */
/* === P R O C E D U R E S ================================================= */
@@
-251,7
+251,7
@@
Plant::set_param(const String & param, const ValueBase &value)
return true;
}
return true;
}
- if(param=="seed" && value.same_as(int()))
+ if(param=="seed" && value.same_
type_
as(int()))
{
random.set_seed(value.get(int()));
needs_sync_=true;
{
random.set_seed(value.get(int()));
needs_sync_=true;
@@
-356,7
+356,7
@@
Plant::get_param_vocab()const
);
ret.push_back(ParamDesc("size_as_alpha")
);
ret.push_back(ParamDesc("size_as_alpha")
- .set_local_name(_("Size
As
Alpha"))
+ .set_local_name(_("Size
As
Alpha"))
);
ret.push_back(ParamDesc("step")
);
ret.push_back(ParamDesc("step")
@@
-413,7
+413,7
@@
Plant::accelerated_render(Context context,Surface *surface,int quality, const Re
std::vector<Particle>::reverse_iterator iter;
const float size_factor(1);
std::vector<Particle>::reverse_iterator iter;
const float size_factor(1);
- float radius(size_factor*size*sqrt(1.0f/(abs(pw)*abs(ph))));
+ float radius(size_factor*size*sqrt(1.0f/(abs(pw)*abs(ph))))
, temp_radius
;
if(radius>1.0f)
{
if(radius>1.0f)
{
@@
-421,7
+421,8
@@
Plant::accelerated_render(Context context,Surface *surface,int quality, const Re
int x1,y1,x2,y2;
for(iter=particle_list.rbegin();iter!=particle_list.rend();++iter)
{
int x1,y1,x2,y2;
for(iter=particle_list.rbegin();iter!=particle_list.rend();++iter)
{
- float radius(radius);
+ temp_radius = radius;
+ float radius(temp_radius);
Color color(iter->color);
if(size_as_alpha)
{
Color color(iter->color);
if(size_as_alpha)
{
@@
-469,7
+470,8
@@
Plant::accelerated_render(Context context,Surface *surface,int quality, const Re
float a,b,c,d;
for(iter=particle_list.rbegin();iter!=particle_list.rend();++iter)
{
float a,b,c,d;
for(iter=particle_list.rbegin();iter!=particle_list.rend();++iter)
{
- float radius(radius);
+ temp_radius = radius;
+ float radius(temp_radius);
Color color(iter->color);
if(size_as_alpha)
{
Color color(iter->color);
if(size_as_alpha)
{