TexGenAttrib
from panda3d.core import TexGenAttrib
- class TexGenAttrib
Bases:
RenderAttrib
Computes texture coordinates for geometry automatically based on vertex position and/or normal. This can be used to implement reflection and/or refraction maps, for instance to make shiny surfaces, as well as other special effects such as projective texturing.
Inheritance diagram
- __init__(*args, **kwargs)
- addStage()
C++ Interface: add_stage(TexGenAttrib self, TextureStage stage, int mode) add_stage(TexGenAttrib self, TextureStage stage, int mode, const LPoint3f constant_value)
- /**
Returns a new TexGenAttrib just like this one, with the indicated
generation mode for the given stage. If this stage already exists, its
mode is replaced.
*/
- /**
Returns a new TexGenAttrib just like this one, with the indicated
generation mode for the given stage. If this stage already exists, its
mode is replaced.
This variant also accepts constant_value, which is only meaningful if mode
is M_constant.
*/
- add_stage()
C++ Interface: add_stage(TexGenAttrib self, TextureStage stage, int mode) add_stage(TexGenAttrib self, TextureStage stage, int mode, const LPoint3f constant_value)
- /**
Returns a new TexGenAttrib just like this one, with the indicated
generation mode for the given stage. If this stage already exists, its
mode is replaced.
*/
- /**
Returns a new TexGenAttrib just like this one, with the indicated
generation mode for the given stage. If this stage already exists, its
mode is replaced.
This variant also accepts constant_value, which is only meaningful if mode
is M_constant.
*/
- class_slot = 29
- getClassSlot()
C++ Interface: get_class_slot()
- getClassType()
C++ Interface: get_class_type()
- getConstantValue()
C++ Interface: get_constant_value(TexGenAttrib self, TextureStage stage)
- /**
Returns the constant value associated with the named texture stage. This
is only meaningful if the mode is M_constant.
*/
- getGeomRendering()
C++ Interface: get_geom_rendering(TexGenAttrib self, int geom_rendering)
- /**
Returns the union of the Geom::GeomRendering bits that will be required
once this TexGenAttrib is applied to a geom which includes the indicated
geom_rendering bits.
*/
- getMode()
C++ Interface: get_mode(TexGenAttrib self, TextureStage stage)
- /**
Returns the generation mode associated with the named texture stage, or
M_off if nothing is associated with the indicated stage.
*/
- get_class_slot()
C++ Interface: get_class_slot()
- get_class_type()
C++ Interface: get_class_type()
- get_constant_value()
C++ Interface: get_constant_value(TexGenAttrib self, TextureStage stage)
- /**
Returns the constant value associated with the named texture stage. This
is only meaningful if the mode is M_constant.
*/
- get_geom_rendering()
C++ Interface: get_geom_rendering(TexGenAttrib self, int geom_rendering)
- /**
Returns the union of the Geom::GeomRendering bits that will be required
once this TexGenAttrib is applied to a geom which includes the indicated
geom_rendering bits.
*/
- get_mode()
C++ Interface: get_mode(TexGenAttrib self, TextureStage stage)
- /**
Returns the generation mode associated with the named texture stage, or
M_off if nothing is associated with the indicated stage.
*/
- hasGenTexcoordStage()
C++ Interface: has_gen_texcoord_stage(TexGenAttrib self, TextureStage stage)
- /**
Returns true if the indicated TextureStage will have texture coordinates
generated for it automatically (and thus there is no need to upload the
texture coordinates encoded in the vertices).
*/
- hasStage()
C++ Interface: has_stage(TexGenAttrib self, TextureStage stage)
- /**
Returns true if there is a mode associated with the indicated stage, or
false otherwise (in which case get_transform(stage) will return M_off).
*/
- has_gen_texcoord_stage()
C++ Interface: has_gen_texcoord_stage(TexGenAttrib self, TextureStage stage)
- /**
Returns true if the indicated TextureStage will have texture coordinates
generated for it automatically (and thus there is no need to upload the
texture coordinates encoded in the vertices).
*/
- has_stage()
C++ Interface: has_stage(TexGenAttrib self, TextureStage stage)
- /**
Returns true if there is a mode associated with the indicated stage, or
false otherwise (in which case get_transform(stage) will return M_off).
*/
- isEmpty()
C++ Interface: is_empty(TexGenAttrib self)
- /**
Returns true if no stages are defined in the TexGenAttrib, false if at
least one is.
*/
- is_empty()
C++ Interface: is_empty(TexGenAttrib self)
- /**
Returns true if no stages are defined in the TexGenAttrib, false if at
least one is.
*/
- make()
C++ Interface: make() make(TextureStage stage, int mode)
- makeDefault()
C++ Interface: make_default()
- /**
Returns a RenderAttrib that corresponds to whatever the standard default
properties for render attributes of this type ought to be.
*/
- make_default()
C++ Interface: make_default()
- /**
Returns a RenderAttrib that corresponds to whatever the standard default
properties for render attributes of this type ought to be.
*/