Name change and const change of Drawable::drawImmediateMode(State&) to

Drawable::drawImplementation(State&) const.   Various updates to the
rest of the OSG to accomodate this.
This commit is contained in:
Robert Osfield
2002-11-06 15:43:11 +00:00
parent e34ecafb1e
commit 3bd400130c
26 changed files with 112 additions and 74 deletions

View File

@@ -164,13 +164,13 @@ namespace osgParticle
bool update(double dt);
/// Perform some pre-rendering tasks. Called automatically by particle systems.
inline void beginRender();
inline void beginRender() const;
/// Render the particle. Called automatically by particle systems.
void render(const osg::Vec3 &xpos, const osg::Vec3 &px, const osg::Vec3 &py, float scale = 1.0f) const;
/// Perform some post-rendering tasks. Called automatically by particle systems.
inline void endRender();
inline void endRender() const;
/// Get the current (interpolated) polygon size. Valid only after the first call to update().
inline float getCurrentSize() const;
@@ -369,7 +369,7 @@ namespace osgParticle
massinv_ = 1 / m;
}
inline void Particle::beginRender()
inline void Particle::beginRender() const
{
switch (shape_)
{
@@ -383,7 +383,7 @@ namespace osgParticle
}
}
inline void Particle::endRender()
inline void Particle::endRender() const
{
switch (shape_)
{

View File

@@ -149,9 +149,9 @@ namespace osgParticle
ParticleSystem &operator=(const ParticleSystem &) { return *this; }
inline virtual bool computeBound() const;
virtual void drawImmediateMode(osg::State &state);
virtual void drawImplementation(osg::State &state) const;
inline void update_bounds(const osg::Vec3 &p, float r);
void single_pass_render(osg::State &state, const osg::Matrix &modelview);
void single_pass_render(osg::State &state, const osg::Matrix &modelview) const;
private:
typedef std::vector<Particle> Particle_vector;
@@ -176,11 +176,11 @@ namespace osgParticle
bool bounds_computed_;
Particle def_ptemp_;
int last_frame_;
mutable int last_frame_;
bool freeze_on_cull_;
int detail_;
int draw_count_;
mutable int draw_count_;
};