ShaderAttrib
from panda3d.core import ShaderAttrib
- class ShaderAttrib
Bases:
RenderAttrib
Inheritance diagram
- F_disable_alpha_write = 1
- F_hardware_instancing = 16
- F_hardware_skinning = 4
- F_shader_point_size = 8
- F_subsume_alpha_test = 2
- __init__(*args, **kwargs)
- autoNormalOn()
C++ Interface: auto_normal_on(ShaderAttrib self)
- autoShader()
C++ Interface: auto_shader(ShaderAttrib self)
- /**
If true, then this ShaderAttrib does not contain an explicit shader -
instead, it requests the automatic generation of a shader.
*/
- auto_normal_on()
C++ Interface: auto_normal_on(ShaderAttrib self)
- auto_shader()
C++ Interface: auto_shader(ShaderAttrib self)
- /**
If true, then this ShaderAttrib does not contain an explicit shader -
instead, it requests the automatic generation of a shader.
*/
- class_slot = 25
- clearAllShaderInputs()
C++ Interface: clear_all_shader_inputs(ShaderAttrib self)
- /**
Clears all the shader inputs on the attrib.
*/
- clearShaderInput()
C++ Interface: clear_shader_input(ShaderAttrib self, const InternalName id) clear_shader_input(ShaderAttrib self, str id)
- clear_all_shader_inputs()
C++ Interface: clear_all_shader_inputs(ShaderAttrib self)
- /**
Clears all the shader inputs on the attrib.
*/
- clear_shader_input()
C++ Interface: clear_shader_input(ShaderAttrib self, const InternalName id) clear_shader_input(ShaderAttrib self, str id)
- getClassSlot()
C++ Interface: get_class_slot()
- getClassType()
C++ Interface: get_class_type()
- getInstanceCount()
C++ Interface: get_instance_count(ShaderAttrib self)
- /**
Returns the number of geometry instances. A value of 0 means not to use
instancing at all. This value is ignored if F_hardware_instancing is set.
*/
- getShader()
C++ Interface: get_shader(ShaderAttrib self)
- /**
Returns the shader object associated with the node. If get_override
returns true, but get_shader returns NULL, that means that this attribute
should disable the shader.
*/
- getShaderInput()
C++ Interface: get_shader_input(ShaderAttrib self, const InternalName id) get_shader_input(ShaderAttrib self, str id)
- getShaderInputBuffer()
C++ Interface: get_shader_input_buffer(ShaderAttrib self, const InternalName id)
- /**
Returns the ShaderInput as a ShaderBuffer. Assertion fails if there is
none, or if it is not a ShaderBuffer.
*/
- getShaderInputMatrix()
C++ Interface: get_shader_input_matrix(ShaderAttrib self, const InternalName id, LMatrix4f matrix)
- /**
Returns the ShaderInput as a matrix. Assertion fails if there is none, or
if it is not a matrix or NodePath.
*/
- getShaderInputNodepath()
C++ Interface: get_shader_input_nodepath(ShaderAttrib self, const InternalName id)
- /**
Returns the ShaderInput as a nodepath. Assertion fails if there is none,
or if it is not a nodepath.
*/
- getShaderInputTexture()
C++ Interface: get_shader_input_texture(ShaderAttrib self, const InternalName id, SamplerState sampler)
- /**
Returns the ShaderInput as a texture. Assertion fails if there is none, or
if it is not a texture.
If sampler is not NULL, the sampler state to use for this texture is
assigned to it.
*/
- getShaderInputVector()
C++ Interface: get_shader_input_vector(ShaderAttrib self, InternalName id)
- /**
Returns the ShaderInput as a vector. Assertion fails if there is none, or
if it is not a vector.
*/
- get_class_slot()
C++ Interface: get_class_slot()
- get_class_type()
C++ Interface: get_class_type()
- get_instance_count()
C++ Interface: get_instance_count(ShaderAttrib self)
- /**
Returns the number of geometry instances. A value of 0 means not to use
instancing at all. This value is ignored if F_hardware_instancing is set.
*/
- get_shader()
C++ Interface: get_shader(ShaderAttrib self)
- /**
Returns the shader object associated with the node. If get_override
returns true, but get_shader returns NULL, that means that this attribute
should disable the shader.
*/
- get_shader_input()
C++ Interface: get_shader_input(ShaderAttrib self, const InternalName id) get_shader_input(ShaderAttrib self, str id)
- get_shader_input_buffer()
C++ Interface: get_shader_input_buffer(ShaderAttrib self, const InternalName id)
- /**
Returns the ShaderInput as a ShaderBuffer. Assertion fails if there is
none, or if it is not a ShaderBuffer.
*/
- get_shader_input_matrix()
C++ Interface: get_shader_input_matrix(ShaderAttrib self, const InternalName id, LMatrix4f matrix)
- /**
Returns the ShaderInput as a matrix. Assertion fails if there is none, or
if it is not a matrix or NodePath.
*/
- get_shader_input_nodepath()
C++ Interface: get_shader_input_nodepath(ShaderAttrib self, const InternalName id)
- /**
Returns the ShaderInput as a nodepath. Assertion fails if there is none,
or if it is not a nodepath.
*/
- get_shader_input_texture()
C++ Interface: get_shader_input_texture(ShaderAttrib self, const InternalName id, SamplerState sampler)
- /**
Returns the ShaderInput as a texture. Assertion fails if there is none, or
if it is not a texture.
If sampler is not NULL, the sampler state to use for this texture is
assigned to it.
*/
- get_shader_input_vector()
C++ Interface: get_shader_input_vector(ShaderAttrib self, InternalName id)
- /**
Returns the ShaderInput as a vector. Assertion fails if there is none, or
if it is not a vector.
*/
- hasShader()
C++ Interface: has_shader(ShaderAttrib self)
- /**
If true, the shader field of this attribute overrides the shader field of
the parent attribute.
*/
- hasShaderInput()
C++ Interface: has_shader_input(ShaderAttrib self, const InternalName id)
- /**
Returns true if there is a ShaderInput of the given name.
*/
- has_shader()
C++ Interface: has_shader(ShaderAttrib self)
- /**
If true, the shader field of this attribute overrides the shader field of
the parent attribute.
*/
- has_shader_input()
C++ Interface: has_shader_input(ShaderAttrib self, const InternalName id)
- /**
Returns true if there is a ShaderInput of the given name.
*/
- instance_count
- make()
C++ Interface: make(const Shader shader, int priority)
- /**
Constructs a new ShaderAttrib object with nothing set.
*/
- 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.
*/
- makeOff()
C++ Interface: make_off()
- /**
Constructs a new ShaderAttrib object that disables the use of shaders (it
does not clear out all shader data, however.)
*/
- 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.
*/
- make_off()
C++ Interface: make_off()
- /**
Constructs a new ShaderAttrib object that disables the use of shaders (it
does not clear out all shader data, however.)
*/
- registerWithReadFactory()
C++ Interface: register_with_read_factory()
- /**
Factory method to generate a Shader object
*/
- register_with_read_factory()
C++ Interface: register_with_read_factory()
- /**
Factory method to generate a Shader object
*/
- setInstanceCount()
C++ Interface: set_instance_count(ShaderAttrib self, int instance_count)
- /**
Sets the geometry instance count. Do not confuse this with instanceTo,
which is used for animation instancing, and has nothing to do with this. A
value of 0 means not to use instancing at all.
This value should not be set if F_hardware_instancing is also set.
*/
- setShaderAuto()
C++ Interface: set_shader_auto(ShaderAttrib self) set_shader_auto(ShaderAttrib self, BitMask shader_switch, int priority) set_shader_auto(ShaderAttrib self, int priority)
- setShaderInput()
C++ Interface: set_shader_input(ShaderAttrib self, const ShaderInput input) set_shader_input(ShaderAttrib self, const InternalName param0, object param1, int priority)
// Shader Inputs
- setShaderInputs()
Returns a new ShaderAttrib with the given shader inputs set. This is a more efficient way to set multiple shader inputs than calling set_shader_input multiple times.
- set_instance_count()
C++ Interface: set_instance_count(ShaderAttrib self, int instance_count)
- /**
Sets the geometry instance count. Do not confuse this with instanceTo,
which is used for animation instancing, and has nothing to do with this. A
value of 0 means not to use instancing at all.
This value should not be set if F_hardware_instancing is also set.
*/
- set_shader_auto()
C++ Interface: set_shader_auto(ShaderAttrib self) set_shader_auto(ShaderAttrib self, BitMask shader_switch, int priority) set_shader_auto(ShaderAttrib self, int priority)
- set_shader_input()
C++ Interface: set_shader_input(ShaderAttrib self, const ShaderInput input) set_shader_input(ShaderAttrib self, const InternalName param0, object param1, int priority)
// Shader Inputs
- set_shader_inputs()
Returns a new ShaderAttrib with the given shader inputs set. This is a more efficient way to set multiple shader inputs than calling set_shader_input multiple times.
- shader