 Reference Guide XML Nodes
» Back to homepage
» Back to Developer's Guide Index
<gpu_program> XML Node
<gpu_program
name=""
filename=""
filename_vs=""
filename_ps=""
filename_gs=""
filename_tcs=""
filename_tes=""
filename_cs=""
>
<raw_data />
<raw_data_vs />
<raw_data_ps />
<raw_data_gs />
<raw_data_tcs />
<raw_data_tes />
<raw_data_cs />
</gpu_program>
<gpu_program>
Allows to load and execute real time shaders written in GLSL.
gpu_program element has 8 attributes and 7 sub-element(s)
- name [STRING]: name of this XML node.
- filename [STRING]: location of the shader file relative to the main XML script. Currently the vertex and pixel shaders must be in the same file.
- filename_vs [STRING]: location of a vertex shader file relative to the main XML script. Currently the vertex and pixel shaders must be in the same file.
- filename_ps [STRING]: location of a pixel shader file relative to the main XML script. Currently the vertex and pixel shaders must be in the same file.
- filename_gs [STRING]: location of a geometry shader file relative to the main XML script. Currently the vertex and pixel shaders must be in the same file.
- filename_tcs [STRING]: location of a tessellation control shader file relative to the main XML script. Currently the vertex and pixel shaders must be in the same file.
- filename_tes [STRING]: location of a tessellation evaluation shader file relative to the main XML script. Currently the vertex and pixel shaders must be in the same file.
- filename_cs [STRING]: location of a compute shader file relative to the main XML script. Currently the vertex and pixel shaders must be in the same file.
:
<glsl_hacker>
<gpu_program name="simpleShader" >
<raw_data><![CDATA[
[Vertex_Shader]
void main(void)
{
gl_Position = ftransform();
}
[Pixel_Shader]
void main()
{
gl_FragColor = vec4(1.0, 0.5, 0.5, 1.0);
}
]]></raw_data>
</gpu_program>
<gpu_program name="shader_v2" >
<raw_data_vs><![CDATA[
void main(void)
{
gl_Position = ftransform();
}
]]></raw_data_vs>
<raw_data_ps><![CDATA[
void main()
{
gl_FragColor = vec4(1.0, 0.5, 0.5, 1.0);
}
]]></raw_data_ps>
</gpu_program>
</glsl_hacker>
<raw_data>
Allows to integrate the source code of a shader directly in the XML code without requiring an external file.
raw_data element has 0 attributes and 0 sub-element(s)
<raw_data_vs>
Allows to integrate the source code of a vertex shader directly in the XML code without requiring an external file.
raw_data_vs element has 0 attributes and 0 sub-element(s)
<raw_data_ps>
Allows to integrate the source code of a pixel shader directly in the XML code without requiring an external file.
raw_data_ps element has 0 attributes and 0 sub-element(s)
<raw_data_gs>
Allows to integrate the source code of a geometry shader directly in the XML code without requiring an external file.
raw_data_gs element has 0 attributes and 0 sub-element(s)
<raw_data_tcs>
Allows to integrate the source code of a tessellation control shader directly in the XML code without requiring an external file.
raw_data_tcs element has 0 attributes and 0 sub-element(s)
<raw_data_tes>
Allows to integrate the source code of a tessellation evaluation shader directly in the XML code without requiring an external file.
raw_data_tes element has 0 attributes and 0 sub-element(s)
<raw_data_cs>
Allows to integrate the source code of a compute shader directly in the XML code without requiring an external file.
raw_data_cs element has 0 attributes and 0 sub-element(s)
|