Difference between revisions of "ComposedShader"
From Web3D.org
Abergstrom (Talk | contribs) |
Abergstrom (Talk | contribs) |
||
Line 3: | Line 3: | ||
<pre> | <pre> | ||
− | + | ComposedShader : X3DShaderNode, X3DProgrammableShaderObject { | |
− | + | SFNode [in,out] metadata NULL [X3DMetadataObject] | |
− | + | MFNode [in,out] parts [] [ShaderPart] | |
− | MFNode [in,out] | + | SFBool [out] isSelected |
− | + | SFBool [out] isValid | |
− | + | SFBool [in] activate | |
− | + | SFString [] language "" | |
− | + | ||
+ | # And any number of: | ||
+ | fieldType [] fieldName | ||
+ | fieldType [in] fieldName | ||
+ | fieldType [out] fieldName | ||
+ | fieldType [in,out] fieldName | ||
} | } | ||
</pre> | </pre> | ||
− | |||
+ | The ComposedShader node defines a shader where the individual source files are not individually programmable. All access to the shading capabilities is defined through a single interface that applies to all parts. | ||
− | + | '''EXAMPLE''' OpenGL Shading Language (GLSL) | |
+ | The ''isValid'' field adds an additional semantic indicating whether the current shader parts can be linked together to form a complete valid shader program. | ||
− | The '' | + | The ''activate'' field forces the shader to activate the contained objects. The conditions under which a activate may be required are described in the ''I.5 Event model'' section of the X3D specification. |
* [[Node Reference]] | * [[Node Reference]] |
Revision as of 23:00, 1 February 2006
ComposedShader
ComposedShader : X3DShaderNode, X3DProgrammableShaderObject { SFNode [in,out] metadata NULL [X3DMetadataObject] MFNode [in,out] parts [] [ShaderPart] SFBool [out] isSelected SFBool [out] isValid SFBool [in] activate SFString [] language "" # And any number of: fieldType [] fieldName fieldType [in] fieldName fieldType [out] fieldName fieldType [in,out] fieldName }
The ComposedShader node defines a shader where the individual source files are not individually programmable. All access to the shading capabilities is defined through a single interface that applies to all parts.
EXAMPLE OpenGL Shading Language (GLSL)
The isValid field adds an additional semantic indicating whether the current shader parts can be linked together to form a complete valid shader program.
The activate field forces the shader to activate the contained objects. The conditions under which a activate may be required are described in the I.5 Event model section of the X3D specification.