|
enum | drmtl_opcode {
drmtl_opcode_movf1 = 0x00000001,
drmtl_opcode_movf2 = 0x00000002,
drmtl_opcode_movf3 = 0x00000003,
drmtl_opcode_movf4 = 0x00000004,
drmtl_opcode_movi1 = 0x00000005,
drmtl_opcode_movi2 = 0x00000006,
drmtl_opcode_movi3 = 0x00000007,
drmtl_opcode_movi4 = 0x00000008,
drmtl_opcode_addf1 = 0x00001001,
drmtl_opcode_addf2 = 0x00001002,
drmtl_opcode_addf3 = 0x00001003,
drmtl_opcode_addf4 = 0x00001004,
drmtl_opcode_addi1 = 0x00001005,
drmtl_opcode_addi2 = 0x00001006,
drmtl_opcode_addi3 = 0x00001007,
drmtl_opcode_addi4 = 0x00001008,
drmtl_opcode_subf1 = 0x00001101,
drmtl_opcode_subf2 = 0x00001102,
drmtl_opcode_subf3 = 0x00001103,
drmtl_opcode_subf4 = 0x00001104,
drmtl_opcode_subi1 = 0x00001105,
drmtl_opcode_subi2 = 0x00001106,
drmtl_opcode_subi3 = 0x00001107,
drmtl_opcode_subi4 = 0x00001108,
drmtl_opcode_mulf1 = 0x00001201,
drmtl_opcode_mulf2 = 0x00001202,
drmtl_opcode_mulf3 = 0x00001203,
drmtl_opcode_mulf4 = 0x00001204,
drmtl_opcode_muli1 = 0x00001205,
drmtl_opcode_muli2 = 0x00001206,
drmtl_opcode_muli3 = 0x00001207,
drmtl_opcode_muli4 = 0x00001208,
drmtl_opcode_divf1 = 0x00001301,
drmtl_opcode_divf2 = 0x00001302,
drmtl_opcode_divf3 = 0x00001303,
drmtl_opcode_divf4 = 0x00001304,
drmtl_opcode_divi1 = 0x00001305,
drmtl_opcode_divi2 = 0x00001306,
drmtl_opcode_divi3 = 0x00001307,
drmtl_opcode_divi4 = 0x00001308,
drmtl_opcode_powf1 = 0x00001401,
drmtl_opcode_powf2 = 0x00001402,
drmtl_opcode_powf3 = 0x00001403,
drmtl_opcode_powf4 = 0x00001404,
drmtl_opcode_powi1 = 0x00001405,
drmtl_opcode_powi2 = 0x00001406,
drmtl_opcode_powi3 = 0x00001407,
drmtl_opcode_powi4 = 0x00001408,
drmtl_opcode_tex1 = 0x00002001,
drmtl_opcode_tex2 = 0x00002002,
drmtl_opcode_tex3 = 0x00002003,
drmtl_opcode_texcube = 0x00002004,
drmtl_opcode_var = 0x00003000,
drmtl_opcode_retf1 = 0x00003001,
drmtl_opcode_retf2 = 0x00003002,
drmtl_opcode_retf3 = 0x00003003,
drmtl_opcode_retf4 = 0x00003004,
drmtl_opcode_reti1 = 0x00003005,
drmtl_opcode_reti2 = 0x00003006,
drmtl_opcode_reti3 = 0x00003007,
drmtl_opcode_reti4 = 0x00003008,
drmtl_opcode_movf1 = 0x00000001,
drmtl_opcode_movf2 = 0x00000002,
drmtl_opcode_movf3 = 0x00000003,
drmtl_opcode_movf4 = 0x00000004,
drmtl_opcode_movi1 = 0x00000005,
drmtl_opcode_movi2 = 0x00000006,
drmtl_opcode_movi3 = 0x00000007,
drmtl_opcode_movi4 = 0x00000008,
drmtl_opcode_addf1 = 0x00001001,
drmtl_opcode_addf2 = 0x00001002,
drmtl_opcode_addf3 = 0x00001003,
drmtl_opcode_addf4 = 0x00001004,
drmtl_opcode_addi1 = 0x00001005,
drmtl_opcode_addi2 = 0x00001006,
drmtl_opcode_addi3 = 0x00001007,
drmtl_opcode_addi4 = 0x00001008,
drmtl_opcode_subf1 = 0x00001101,
drmtl_opcode_subf2 = 0x00001102,
drmtl_opcode_subf3 = 0x00001103,
drmtl_opcode_subf4 = 0x00001104,
drmtl_opcode_subi1 = 0x00001105,
drmtl_opcode_subi2 = 0x00001106,
drmtl_opcode_subi3 = 0x00001107,
drmtl_opcode_subi4 = 0x00001108,
drmtl_opcode_mulf1 = 0x00001201,
drmtl_opcode_mulf2 = 0x00001202,
drmtl_opcode_mulf3 = 0x00001203,
drmtl_opcode_mulf4 = 0x00001204,
drmtl_opcode_muli1 = 0x00001205,
drmtl_opcode_muli2 = 0x00001206,
drmtl_opcode_muli3 = 0x00001207,
drmtl_opcode_muli4 = 0x00001208,
drmtl_opcode_divf1 = 0x00001301,
drmtl_opcode_divf2 = 0x00001302,
drmtl_opcode_divf3 = 0x00001303,
drmtl_opcode_divf4 = 0x00001304,
drmtl_opcode_divi1 = 0x00001305,
drmtl_opcode_divi2 = 0x00001306,
drmtl_opcode_divi3 = 0x00001307,
drmtl_opcode_divi4 = 0x00001308,
drmtl_opcode_powf1 = 0x00001401,
drmtl_opcode_powf2 = 0x00001402,
drmtl_opcode_powf3 = 0x00001403,
drmtl_opcode_powf4 = 0x00001404,
drmtl_opcode_powi1 = 0x00001405,
drmtl_opcode_powi2 = 0x00001406,
drmtl_opcode_powi3 = 0x00001407,
drmtl_opcode_powi4 = 0x00001408,
drmtl_opcode_tex1 = 0x00002001,
drmtl_opcode_tex2 = 0x00002002,
drmtl_opcode_tex3 = 0x00002003,
drmtl_opcode_texcube = 0x00002004,
drmtl_opcode_var = 0x00003000,
drmtl_opcode_retf1 = 0x00003001,
drmtl_opcode_retf2 = 0x00003002,
drmtl_opcode_retf3 = 0x00003003,
drmtl_opcode_retf4 = 0x00003004,
drmtl_opcode_reti1 = 0x00003005,
drmtl_opcode_reti2 = 0x00003006,
drmtl_opcode_reti3 = 0x00003007,
drmtl_opcode_reti4 = 0x00003008
} |
| The various run-time opcodes. More...
|
|
enum | drmtl_type {
drmtl_type_float = 1,
drmtl_type_float2 = 2,
drmtl_type_float3 = 3,
drmtl_type_float4 = 4,
drmtl_type_int = 5,
drmtl_type_int2 = 6,
drmtl_type_int3 = 7,
drmtl_type_int4 = 8,
drmtl_type_tex1d = 9,
drmtl_type_tex2d = 10,
drmtl_type_tex3d = 11,
drmtl_type_texcube = 12,
drmtl_type_bool = 13,
drmtl_type_float = 1,
drmtl_type_float2 = 2,
drmtl_type_float3 = 3,
drmtl_type_float4 = 4,
drmtl_type_int = 5,
drmtl_type_int2 = 6,
drmtl_type_int3 = 7,
drmtl_type_int4 = 8,
drmtl_type_tex1d = 9,
drmtl_type_tex2d = 10,
drmtl_type_tex3d = 11,
drmtl_type_texcube = 12,
drmtl_type_bool = 13
} |
| The various data type available to the material. More...
|
|
|
drmtl_instruction | drmtl_addf1_c1 (unsigned int outputIdentifierIndex, float x) |
|
drmtl_instruction | drmtl_addf1_v1 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_addf2_c2 (unsigned int outputIdentifierIndex, float x, float y) |
|
drmtl_instruction | drmtl_addf2_v2 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_addf3_c3 (unsigned int outputIdentifierIndex, float x, float y, float z) |
|
drmtl_instruction | drmtl_addf3_v3 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_addf4_c4 (unsigned int outputIdentifierIndex, float x, float y, float z, float w) |
|
drmtl_instruction | drmtl_addf4_v4 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
bool | drmtl_appendchannel (drmtl_material *pMaterial, drmtl_channel channelHeader) |
|
bool | drmtl_appendidentifier (drmtl_material *pMaterial, drmtl_identifier identifier, unsigned int *indexOut) |
|
bool | drmtl_appendinstruction (drmtl_material *pMaterial, drmtl_instruction instruction) |
| Appends an instruction to the most recently appended channel. More...
|
|
bool | drmtl_appendprivateinput (drmtl_material *pMaterial, drmtl_input input) |
| Appends a private input variable. More...
|
|
bool | drmtl_appendproperty (drmtl_material *pMaterial, drmtl_property prop) |
| Append a property. More...
|
|
bool | drmtl_appendpublicinput (drmtl_material *pMaterial, drmtl_input input) |
| Appends a public input variable. More...
|
|
drmtl_channel | drmtl_channel_float (const char *name) |
| Helper for creating a channel. More...
|
|
drmtl_channel | drmtl_channel_float2 (const char *name) |
|
drmtl_channel | drmtl_channel_float3 (const char *name) |
|
drmtl_channel | drmtl_channel_float4 (const char *name) |
|
drmtl_channel | drmtl_channel_int (const char *name) |
|
drmtl_channel | drmtl_channel_int2 (const char *name) |
|
drmtl_channel | drmtl_channel_int3 (const char *name) |
|
drmtl_channel | drmtl_channel_int4 (const char *name) |
|
bool | drmtl_codegen_glsl_channel (drmtl_material *pMaterial, const char *channelName, char *codeOut, size_t codeOutSizeInBytes, size_t *pBytesWrittenOut) |
| Generates GLSL code for the channel with the given name. More...
|
|
bool | drmtl_codegen_glsl_uniforms (drmtl_material *pMaterial, char *codeOut, size_t codeOutSizeInBytes, size_t *pBytesWritteOut) |
| Generates GLSL code for the uniform variables as defined by the material's public input variables. More...
|
|
bool | drmtl_compile_wavefront_mtl (drmtl_material *pMaterial, const char *mtlData, size_t mtlDataSizeInBytes, const char *texcoordInputName) |
|
drmtl_instruction | drmtl_divf1_c1 (unsigned int outputIdentifierIndex, float x) |
|
drmtl_instruction | drmtl_divf1_v1 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_divf2_c2 (unsigned int outputIdentifierIndex, float x, float y) |
|
drmtl_instruction | drmtl_divf2_v2 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_divf3_c3 (unsigned int outputIdentifierIndex, float x, float y, float z) |
|
drmtl_instruction | drmtl_divf3_v3 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_divf4_c4 (unsigned int outputIdentifierIndex, float x, float y, float z, float w) |
|
drmtl_instruction | drmtl_divf4_v4 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_channel_header * | drmtl_getchannelheaderbyindex (drmtl_material *pMaterial, unsigned int channelIndex) |
|
drmtl_channel_header * | drmtl_getchannelheaderbyname (drmtl_material *pMaterial, const char *channelName) |
|
drmtl_header * | drmtl_getheader (drmtl_material *pMaterial) |
| Retrieve a pointer to the header information. More...
|
|
drmtl_identifier * | drmtl_getidentifier (drmtl_material *pMaterial, unsigned int index) |
|
unsigned int | drmtl_getidentifiercount (drmtl_material *pMaterial) |
| Retrieves the number of identifiers defined by the given material. More...
|
|
drmtl_identifier * | drmtl_getidentifiers (drmtl_material *pMaterial) |
| Retrieves a pointer to the buffer containing the list of identifiers. More...
|
|
drmtl_input * | drmtl_getinputbyindex (drmtl_material *pMaterial, unsigned int index) |
| Retrieves the input variable by it's index. More...
|
|
unsigned int | drmtl_getinputcount (drmtl_material *pMaterial) |
| Retrieves the number of private + public input variables. More...
|
|
drmtl_input * | drmtl_getprivateinputbyindex (drmtl_material *pMaterial, unsigned int index) |
| Retrieves the private input variable by it's index. More...
|
|
unsigned int | drmtl_getprivateinputcount (drmtl_material *pMaterial) |
| Retrieves the number of private input variables. More...
|
|
drmtl_property * | drmtl_getpropertybyindex (drmtl_material *pMaterial, unsigned int index) |
| Retrieves a property by it's index. More...
|
|
drmtl_property * | drmtl_getpropertybyname (drmtl_material *pMaterial, const char *name) |
|
unsigned int | drmtl_getpropertycount (drmtl_material *pMaterial) |
| Retrieves the number of properties. More...
|
|
drmtl_input * | drmtl_getpublicinputbyindex (drmtl_material *pMaterial, unsigned int index) |
| Retrieves the public input variable by it's index. More...
|
|
unsigned int | drmtl_getpublicinputcount (drmtl_material *pMaterial) |
| Retrieves the number of public input variables. More...
|
|
drmtl_identifier | drmtl_identifier_float (const char *name) |
| Helper for creating an identifier. More...
|
|
drmtl_identifier | drmtl_identifier_float2 (const char *name) |
|
drmtl_identifier | drmtl_identifier_float3 (const char *name) |
|
drmtl_identifier | drmtl_identifier_float4 (const char *name) |
|
drmtl_identifier | drmtl_identifier_int (const char *name) |
|
drmtl_identifier | drmtl_identifier_int2 (const char *name) |
|
drmtl_identifier | drmtl_identifier_int3 (const char *name) |
|
drmtl_identifier | drmtl_identifier_int4 (const char *name) |
|
drmtl_identifier | drmtl_identifier_tex2d (const char *name) |
|
bool | drmtl_init (drmtl_material *pMaterial) |
|
bool | drmtl_initfromexisting (drmtl_material *pMaterial, const void *pRawData, unsigned int dataSizeInBytes) |
|
bool | drmtl_initfromexisting_nocopy (drmtl_material *pMaterial, const void *pRawData, unsigned int dataSizeInBytes) |
|
drmtl_input | drmtl_input_float (unsigned int identifierIndex, float x) |
| Helper for creating an input variable. More...
|
|
drmtl_input | drmtl_input_float2 (unsigned int identifierIndex, float x, float y) |
|
drmtl_input | drmtl_input_float3 (unsigned int identifierIndex, float x, float y, float z) |
|
drmtl_input | drmtl_input_float4 (unsigned int identifierIndex, float x, float y, float z, float w) |
|
drmtl_input | drmtl_input_int (unsigned int identifierIndex, int x) |
|
drmtl_input | drmtl_input_int2 (unsigned int identifierIndex, int x, int y) |
|
drmtl_input | drmtl_input_int3 (unsigned int identifierIndex, int x, int y, int z) |
|
drmtl_input | drmtl_input_int4 (unsigned int identifierIndex, int x, int y, int z, int w) |
|
drmtl_input | drmtl_input_tex (unsigned int identifierIndex, const char *path) |
|
drmtl_instruction | drmtl_movf1_c1 (unsigned int outputIdentifierIndex, float x) |
|
drmtl_instruction | drmtl_movf1_v1 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
| Helper for creating an instruction. These are heavily simplified and more complex setups are possible using lower level APIs. More...
|
|
drmtl_instruction | drmtl_movf2_c2 (unsigned int outputIdentifierIndex, float x, float y) |
|
drmtl_instruction | drmtl_movf2_v2 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_movf3_c3 (unsigned int outputIdentifierIndex, float x, float y, float z) |
|
drmtl_instruction | drmtl_movf3_v3 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_movf4_c4 (unsigned int outputIdentifierIndex, float x, float y, float z, float w) |
|
drmtl_instruction | drmtl_movf4_v4 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_mulf1_c1 (unsigned int outputIdentifierIndex, float x) |
|
drmtl_instruction | drmtl_mulf1_v1 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_mulf2_c2 (unsigned int outputIdentifierIndex, float x, float y) |
|
drmtl_instruction | drmtl_mulf2_v2 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_mulf3_c3 (unsigned int outputIdentifierIndex, float x, float y, float z) |
|
drmtl_instruction | drmtl_mulf3_v3 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_mulf4_c4 (unsigned int outputIdentifierIndex, float x, float y, float z, float w) |
|
drmtl_instruction | drmtl_mulf4_v1c3 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex, float y, float z, float w) |
|
drmtl_instruction | drmtl_mulf4_v1v1v1v1 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndexX, unsigned int inputIdentifierIndexY, unsigned int inputIdentifierIndexZ, unsigned int inputIdentifierIndexW) |
|
drmtl_instruction | drmtl_mulf4_v2c2 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex, float z, float w) |
|
drmtl_instruction | drmtl_mulf4_v3c1 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex, float w) |
|
drmtl_instruction | drmtl_mulf4_v3v1 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndexXYZ, unsigned int inputIdentifierIndexW) |
|
drmtl_instruction | drmtl_mulf4_v4 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_property | drmtl_property_bool (const char *name, bool value) |
|
drmtl_property | drmtl_property_float (const char *name, float x) |
| Helper for creating a property. More...
|
|
drmtl_property | drmtl_property_float2 (const char *name, float x, float y) |
|
drmtl_property | drmtl_property_float3 (const char *name, float x, float y, float z) |
|
drmtl_property | drmtl_property_float4 (const char *name, float x, float y, float z, float w) |
|
drmtl_property | drmtl_property_int (const char *name, int x) |
|
drmtl_property | drmtl_property_int2 (const char *name, int x, int y) |
|
drmtl_property | drmtl_property_int3 (const char *name, int x, int y, int z) |
|
drmtl_property | drmtl_property_int4 (const char *name, int x, int y, int z, int w) |
|
drmtl_instruction | drmtl_retf1 (unsigned int identifierIndex) |
|
drmtl_instruction | drmtl_retf1_c1 (float x) |
|
drmtl_instruction | drmtl_retf2 (unsigned int identifierIndex) |
|
drmtl_instruction | drmtl_retf2_c2 (float x, float y) |
|
drmtl_instruction | drmtl_retf3 (unsigned int identifierIndex) |
|
drmtl_instruction | drmtl_retf3_c3 (float x, float y, float z) |
|
drmtl_instruction | drmtl_retf4 (unsigned int identifierIndex) |
|
drmtl_instruction | drmtl_retf4_c4 (float x, float y, float z, float w) |
|
drmtl_instruction | drmtl_reti1 (unsigned int identifierIndex) |
|
drmtl_instruction | drmtl_reti1_c1 (int x) |
|
drmtl_instruction | drmtl_reti2 (unsigned int identifierIndex) |
|
drmtl_instruction | drmtl_reti2_c2 (int x, int y) |
|
drmtl_instruction | drmtl_reti3 (unsigned int identifierIndex) |
|
drmtl_instruction | drmtl_reti3_c3 (int x, int y, int z) |
|
drmtl_instruction | drmtl_reti4 (unsigned int identifierIndex) |
|
drmtl_instruction | drmtl_reti4_c4 (int x, int y, int z, int w) |
|
drmtl_instruction | drmtl_subf1_c1 (unsigned int outputIdentifierIndex, float x) |
|
drmtl_instruction | drmtl_subf1_v1 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_subf2_c2 (unsigned int outputIdentifierIndex, float x, float y) |
|
drmtl_instruction | drmtl_subf2_v2 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_subf3_c3 (unsigned int outputIdentifierIndex, float x, float y, float z) |
|
drmtl_instruction | drmtl_subf3_v3 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_subf4_c4 (unsigned int outputIdentifierIndex, float x, float y, float z, float w) |
|
drmtl_instruction | drmtl_subf4_v4 (unsigned int outputIdentifierIndex, unsigned int inputIdentifierIndex) |
|
drmtl_instruction | drmtl_tex2 (unsigned int outputIdentifierIndex, unsigned int textureIdentifierIndex, unsigned int texcoordIdentifierIndex) |
|
void | drmtl_uninit (drmtl_material *pMaterial) |
|
drmtl_instruction | drmtl_var (unsigned int identifierIndex) |
|