Back to Reference Guide Index

<gpu_program> XML node

XML Node Summary

<gpu_program
  name=""
  filename=""
  absolute_path="0"
  filename_vs=""
  absolute_path_vs="0"
  filename_ps=""
  absolute_path_ps="0"
  filename_gs=""
  absolute_path_gs="0"
  filename_tcs=""
  absolute_path_tcs="0"
  filename_tes=""
  absolute_path_tes="0"
  filename_cs=""
  absolute_path_cs="0"
  >
  <raw_data />
  <raw_data_vs />
  <raw_data_ps />
  <raw_data_gs />
  <raw_data_tcs />
  <raw_data_tes />
  <raw_data_cs />
</gpu_program>


<gpu_program>

Description

Allows to load and execute real time shaders written in GLSL.


Attributes


Code sample

<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>

Description

Allows to integrate the source code of a shader directly in the XML code without requiring an external file.


<raw_data_vs>

Description

Allows to integrate the source code of a vertex shader directly in the XML code without requiring an external file.


<raw_data_ps>

Description

Allows to integrate the source code of a pixel shader directly in the XML code without requiring an external file.


<raw_data_gs>

Description

Allows to integrate the source code of a geometry shader directly in the XML code without requiring an external file.


<raw_data_tcs>

Description

Allows to integrate the source code of a tessellation control shader directly in the XML code without requiring an external file.


<raw_data_tes>

Description

Allows to integrate the source code of a tessellation evaluation shader directly in the XML code without requiring an external file.


<raw_data_cs>

Description

Allows to integrate the source code of a compute shader directly in the XML code without requiring an external file.



GeeXLab Rootard Guide | Downloads | Contact | Newsletter