5#ifndef NIRT_I_GPU_PROGRAMMING_SERVICES_HPP_INCLUDED
6#define NIRT_I_GPU_PROGRAMMING_SERVICES_HPP_INCLUDED
8#include <nirtcpp/core/engine/EShaderTypes.hpp>
9#include <nirtcpp/core/engine/EMaterialTypes.hpp>
10#include <nirtcpp/core/engine/EPrimitiveTypes.hpp>
11#include <nirtcpp/core/engine/path.hpp>
25class IShaderConstantSetCallBack;
77 const c8* vertexShaderProgram,
78 const c8* vertexShaderEntryPointName,
80 const c8* pixelShaderProgram,
81 const c8* pixelShaderEntryPointName,
83 const c8* geometryShaderProgram,
84 const c8* geometryShaderEntryPointName =
"main",
91 s32 userData = 0) = 0;
95 const c8* vertexShaderProgram,
96 const c8* vertexShaderEntryPointName=
"main",
98 const c8* pixelShaderProgram=0,
99 const c8* pixelShaderEntryPointName=
"main",
106 vertexShaderProgram, vertexShaderEntryPointName,
107 vsCompileTarget, pixelShaderProgram,
108 pixelShaderEntryPointName, psCompileTarget,
109 0,
"main", EGST_GS_4_0,
111 callback, baseMaterial, userData);
119 const c8* vertexShaderProgram,
120 const c8* pixelShaderProgram=0,
126 vertexShaderProgram,
"main",
127 EVST_VS_1_1, pixelShaderProgram,
129 0,
"main", EGST_GS_4_0,
131 callback, baseMaterial, userData);
139 const c8* vertexShaderProgram,
140 const c8* pixelShaderProgram = 0,
141 const c8* geometryShaderProgram = 0,
150 vertexShaderProgram,
"main",
151 EVST_VS_1_1, pixelShaderProgram,
153 geometryShaderProgram,
"main", EGST_GS_4_0,
154 inType, outType, verticesOut,
155 callback, baseMaterial, userData);
201 const io::path& vertexShaderProgramFileName,
202 const c8* vertexShaderEntryPointName,
204 const io::path& pixelShaderProgramFileName,
205 const c8* pixelShaderEntryPointName,
207 const io::path& geometryShaderProgramFileName,
208 const c8* geometryShaderEntryPointName =
"main",
215 s32 userData = 0) = 0;
219 const io::path& vertexShaderProgramFileName,
220 const c8* vertexShaderEntryPointName =
"main",
222 const io::path& pixelShaderProgramFileName =
"",
223 const c8* pixelShaderEntryPointName =
"main",
230 vertexShaderProgramFileName, vertexShaderEntryPointName,
231 vsCompileTarget, pixelShaderProgramFileName,
232 pixelShaderEntryPointName, psCompileTarget,
233 "",
"main", EGST_GS_4_0,
235 callback, baseMaterial, userData);
243 const io::path& vertexShaderProgramFileName,
244 const io::path& pixelShaderProgramFileName =
"",
250 vertexShaderProgramFileName,
"main",
251 EVST_VS_1_1, pixelShaderProgramFileName,
253 "",
"main", EGST_GS_4_0,
255 callback, baseMaterial, userData);
263 const io::path& vertexShaderProgramFileName,
264 const io::path& pixelShaderProgramFileName =
"",
265 const io::path& geometryShaderProgramFileName =
"",
274 vertexShaderProgramFileName,
"main",
275 EVST_VS_1_1, pixelShaderProgramFileName,
277 geometryShaderProgramFileName,
"main", EGST_GS_4_0,
278 inType, outType, verticesOut,
279 callback, baseMaterial, userData);
324 const c8* vertexShaderEntryPointName,
327 const c8* pixelShaderEntryPointName,
330 const c8* geometryShaderEntryPointName =
"main",
337 s32 userData = 0) = 0;
342 const c8* vertexShaderEntryPointName =
"main",
345 const c8* pixelShaderEntryPointName =
"main",
352 vertexShaderProgram, vertexShaderEntryPointName,
353 vsCompileTarget, pixelShaderProgram,
354 pixelShaderEntryPointName, psCompileTarget,
355 0,
"main", EGST_GS_4_0,
357 callback, baseMaterial, userData);
395 const c8* pixelShaderProgram = 0,
398 s32 userData = 0) = 0;
422 s32 userData = 0) = 0;
444 const io::path& pixelShaderProgramFileName,
447 s32 userData = 0) = 0;
Interface providing read access to a file.
Definition IReadFile.hpp:19
Interface making it possible to create and use programs running on the GPU.
Definition IGPUProgrammingServices.hpp:29
virtual s32 addHighLevelShaderMaterialFromFiles(const io::path &vertexShaderProgramFileName, const c8 *vertexShaderEntryPointName, E_VERTEX_SHADER_TYPE vsCompileTarget, const io::path &pixelShaderProgramFileName, const c8 *pixelShaderEntryPointName, E_PIXEL_SHADER_TYPE psCompileTarget, const io::path &geometryShaderProgramFileName, const c8 *geometryShaderEntryPointName="main", E_GEOMETRY_SHADER_TYPE gsCompileTarget=EGST_GS_4_0, scene::E_PRIMITIVE_TYPE inType=scene::EPT_TRIANGLES, scene::E_PRIMITIVE_TYPE outType=scene::EPT_TRIANGLE_STRIP, u32 verticesOut=0, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)=0
Like IGPUProgrammingServices::addShaderMaterial(), but loads from files.
virtual s32 addShaderMaterialFromFiles(const io::path &vertexShaderProgramFileName, const io::path &pixelShaderProgramFileName, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)=0
Like IGPUProgrammingServices::addShaderMaterial(), but loads from files.
s32 addHighLevelShaderMaterialFromFiles(const io::path &vertexShaderProgramFileName, const io::path &pixelShaderProgramFileName="", IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)
convenience function for use with many defaults, without geometry shader
Definition IGPUProgrammingServices.hpp:242
virtual ~IGPUProgrammingServices()
Destructor.
Definition IGPUProgrammingServices.hpp:33
virtual s32 addShaderMaterial(const c8 *vertexShaderProgram=0, const c8 *pixelShaderProgram=0, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)=0
Adds a new ASM shader material renderer to the VideoDriver.
virtual s32 addHighLevelShaderMaterialFromFiles(io::IReadFile *vertexShaderProgram, const c8 *vertexShaderEntryPointName, E_VERTEX_SHADER_TYPE vsCompileTarget, io::IReadFile *pixelShaderProgram, const c8 *pixelShaderEntryPointName, E_PIXEL_SHADER_TYPE psCompileTarget, io::IReadFile *geometryShaderProgram, const c8 *geometryShaderEntryPointName="main", E_GEOMETRY_SHADER_TYPE gsCompileTarget=EGST_GS_4_0, scene::E_PRIMITIVE_TYPE inType=scene::EPT_TRIANGLES, scene::E_PRIMITIVE_TYPE outType=scene::EPT_TRIANGLE_STRIP, u32 verticesOut=0, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)=0
Like IGPUProgrammingServices::addShaderMaterial(), but loads from files.
virtual s32 addShaderMaterialFromFiles(io::IReadFile *vertexShaderProgram, io::IReadFile *pixelShaderProgram, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)=0
Like IGPUProgrammingServices::addShaderMaterial(), but loads from files.
virtual s32 addHighLevelShaderMaterial(const c8 *vertexShaderProgram, const c8 *vertexShaderEntryPointName, E_VERTEX_SHADER_TYPE vsCompileTarget, const c8 *pixelShaderProgram, const c8 *pixelShaderEntryPointName, E_PIXEL_SHADER_TYPE psCompileTarget, const c8 *geometryShaderProgram, const c8 *geometryShaderEntryPointName="main", E_GEOMETRY_SHADER_TYPE gsCompileTarget=EGST_GS_4_0, scene::E_PRIMITIVE_TYPE inType=scene::EPT_TRIANGLES, scene::E_PRIMITIVE_TYPE outType=scene::EPT_TRIANGLE_STRIP, u32 verticesOut=0, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)=0
Adds a new high-level shading material renderer to the VideoDriver.
s32 addHighLevelShaderMaterialFromFiles(io::IReadFile *vertexShaderProgram, const c8 *vertexShaderEntryPointName="main", E_VERTEX_SHADER_TYPE vsCompileTarget=EVST_VS_1_1, io::IReadFile *pixelShaderProgram=0, const c8 *pixelShaderEntryPointName="main", E_PIXEL_SHADER_TYPE psCompileTarget=EPST_PS_1_1, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)
convenience function for use without geometry shaders
Definition IGPUProgrammingServices.hpp:340
s32 addHighLevelShaderMaterial(const c8 *vertexShaderProgram, const c8 *pixelShaderProgram=0, const c8 *geometryShaderProgram=0, scene::E_PRIMITIVE_TYPE inType=scene::EPT_TRIANGLES, scene::E_PRIMITIVE_TYPE outType=scene::EPT_TRIANGLE_STRIP, u32 verticesOut=0, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)
convenience function for use with many defaults, with geometry shader
Definition IGPUProgrammingServices.hpp:138
s32 addHighLevelShaderMaterialFromFiles(const io::path &vertexShaderProgramFileName, const io::path &pixelShaderProgramFileName="", const io::path &geometryShaderProgramFileName="", scene::E_PRIMITIVE_TYPE inType=scene::EPT_TRIANGLES, scene::E_PRIMITIVE_TYPE outType=scene::EPT_TRIANGLE_STRIP, u32 verticesOut=0, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)
convenience function for use with many defaults, with geometry shader
Definition IGPUProgrammingServices.hpp:262
s32 addHighLevelShaderMaterial(const c8 *vertexShaderProgram, const c8 *pixelShaderProgram=0, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)
convenience function for use with many defaults, without geometry shader
Definition IGPUProgrammingServices.hpp:118
s32 addHighLevelShaderMaterialFromFiles(const io::path &vertexShaderProgramFileName, const c8 *vertexShaderEntryPointName="main", E_VERTEX_SHADER_TYPE vsCompileTarget=EVST_VS_1_1, const io::path &pixelShaderProgramFileName="", const c8 *pixelShaderEntryPointName="main", E_PIXEL_SHADER_TYPE psCompileTarget=EPST_PS_1_1, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)
convenience function for use without geometry shaders
Definition IGPUProgrammingServices.hpp:218
s32 addHighLevelShaderMaterial(const c8 *vertexShaderProgram, const c8 *vertexShaderEntryPointName="main", E_VERTEX_SHADER_TYPE vsCompileTarget=EVST_VS_1_1, const c8 *pixelShaderProgram=0, const c8 *pixelShaderEntryPointName="main", E_PIXEL_SHADER_TYPE psCompileTarget=EPST_PS_1_1, IShaderConstantSetCallBack *callback=0, E_MATERIAL_TYPE baseMaterial=video::EMT_SOLID, s32 userData=0)
convenience function for use without geometry shaders
Definition IGPUProgrammingServices.hpp:94
Interface making it possible to set constants for gpu programs every frame.
Definition IShaderConstantSetCallBack.hpp:22
E_PRIMITIVE_TYPE
Enumeration for all primitive types there are.
Definition EPrimitiveTypes.hpp:15
@ EPT_TRIANGLES
Explicitly set all vertices for each triangle.
Definition EPrimitiveTypes.hpp:37
@ EPT_TRIANGLE_STRIP
Definition EPrimitiveTypes.hpp:30
E_GEOMETRY_SHADER_TYPE
Enum for supported geometry shader types.
Definition EShaderTypes.hpp:73
E_VERTEX_SHADER_TYPE
Compile target enumeration for the addHighLevelShaderMaterial() method.
Definition EShaderTypes.hpp:13
E_PIXEL_SHADER_TYPE
Compile target enumeration for the addHighLevelShaderMaterial() method.
Definition EShaderTypes.hpp:39
E_MATERIAL_TYPE
Abstracted and easy to use fixed function/programmable pipeline material modes.
Definition EMaterialTypes.hpp:15
@ EMT_SOLID
Standard solid material.
Definition EMaterialTypes.hpp:19
As of Nirtcpp 1.6, position2d is a synonym for vector2d.
Definition vector3d.hpp:11
signed int s32
32 bit signed variable.
Definition irrTypes.hpp:72
unsigned int u32
32 bit unsigned variable.
Definition irrTypes.hpp:64
char c8
8 bit character variable.
Definition irrTypes.hpp:37