BaseParticleRenderer

class BaseParticleRenderer

Bases: ReferenceCount

Pure virtual particle renderer base class

Inheritance diagram

Inheritance diagram of BaseParticleRenderer

enum ParticleRendererAlphaMode
enumerator PR_ALPHA_NONE = 0
enumerator PR_ALPHA_OUT = 1
enumerator PR_ALPHA_IN = 2
enumerator PR_ALPHA_IN_OUT = 3
enumerator PR_ALPHA_USER = 4
enumerator PR_NOT_INITIALIZED_YET = 5
enum ParticleRendererBlendMethod
enumerator PP_NO_BLEND = 0
enumerator PP_BLEND_LINEAR = 1
enumerator PP_BLEND_CUBIC = 2
ParticleRendererAlphaMode get_alpha_mode(void) const
bool get_ignore_scale(void) const

Returns the “ignore scale” flag. See set_ignore_scale().

GeomNode *get_render_node(void) const

Query the geomnode pointer

NodePath get_render_node_path(void) const

Query the geomnode pointer

PN_stdfloat get_user_alpha(void) const

gets alpha for “user” alpha mode

virtual void output(std::ostream &out) const

Write a string representation of this instance to <out>.

void set_alpha_mode(BaseParticleRenderer::ParticleRendererAlphaMode am)
void set_color_blend_mode(ColorBlendAttrib::Mode bm, ColorBlendAttrib::Operand oa = ::ColorBlendAttrib::O_zero, ColorBlendAttrib::Operand ob = ::ColorBlendAttrib::O_zero)

sets the ColorBlendAttrib on the _render_node

void set_ignore_scale(bool ignore_scale)

Sets the “ignore scale” flag. When this is true, particles will be drawn as if they had no scale, regardless of whatever scale might be inherited from above the render node in the scene graph.

This flag is mainly useful to support legacy code that was written for a very early version of Panda, whose sprite particle renderer had a bug that incorrectly ignored the inherited scale.

void set_user_alpha(PN_stdfloat ua)

sets alpha for “user” alpha mode

virtual void write(std::ostream &out, int indent = 0) const

Write a string representation of this instance to <out>.