25#if !D3D_COMPILER_VERSION
26#define ID3D11ShaderReflection ID3D10ShaderReflection
27#define ID3D11ShaderReflectionVtbl ID3D10ShaderReflectionVtbl
28#define ID3D11ShaderReflectionConstantBuffer ID3D10ShaderReflectionConstantBuffer
29#define ID3D11ShaderReflectionConstantBufferVtbl ID3D10ShaderReflectionConstantBufferVtbl
30#define ID3D11ShaderReflectionType ID3D10ShaderReflectionType
31#define ID3D11ShaderReflectionTypeVtbl ID3D10ShaderReflectionTypeVtbl
32#define ID3D11ShaderReflectionVariable ID3D10ShaderReflectionVariable
33#define ID3D11ShaderReflectionVariableVtbl ID3D10ShaderReflectionVariableVtbl
34#define IID_ID3D11ShaderReflection IID_ID3D10ShaderReflection
35#define D3D11_SHADER_BUFFER_DESC D3D10_SHADER_BUFFER_DESC
36#define D3D11_SHADER_DESC D3D10_SHADER_DESC
37#define D3D11_SHADER_INPUT_BIND_DESC D3D10_SHADER_INPUT_BIND_DESC
38#define D3D11_SHADER_TYPE_DESC D3D10_SHADER_TYPE_DESC
39#define D3D11_SHADER_VARIABLE_DESC D3D10_SHADER_VARIABLE_DESC
40#define D3D11_SIGNATURE_PARAMETER_DESC D3D10_SIGNATURE_PARAMETER_DESC
51#define D3DCOMPILER_SHADER_TARGET_VERSION_MASK 0xffff
52#define D3DCOMPILER_SHADER_TARGET_SHADERTYPE_MASK 0xffff0000
53#define D3DCOMPILER_SHADER_TARGET_SHADERTYPE_SHIFT 16
55#define D3DCOMPILER_SHDR_SHADER_TYPE_CS 0x4353
211 ERR(
"Failed to allocate name memory.\n");
225 ERR(
"Failed to allocate value memory.\n");
255 TRACE(
"reflection type %p.\n",
t);
259 for (
i = 0;
i <
t->desc.Members; ++
i)
272 TRACE(
"Free signature %p\n", sig);
293 for (
i = 0;
i <
cb->variable_count; ++
i)
325 if (
ref->constant_buffers)
329 for (
i = 0;
i <
ref->constant_buffer_count; ++
i)
357 IUnknown_AddRef(iface);
400 FIXME(
"iface %p, desc %p partial stub!\n", iface,
desc);
404 WARN(
"Invalid argument specified\n");
413 desc->InputParameters = reflection->
isgn ? reflection->
isgn->element_count : 0;
414 desc->OutputParameters = reflection->
osgn ? reflection->
osgn->element_count : 0;
436#if D3D_COMPILER_VERSION
438 desc->PatchConstantParameters = reflection->
pcsg ? reflection->
pcsg->element_count : 0;
439 desc->cGSInstanceCount = 0;
444 desc->cBarrierInstructions = 0;
445 desc->cInterlockedInstructions = 0;
446 desc->cTextureStoreInstructions = 0;
459 if (
index >=
This->constant_buffer_count)
461 WARN(
"Invalid argument specified\n");
465 return &
This->constant_buffers[
index].ID3D11ShaderReflectionConstantBuffer_iface;
478 WARN(
"Invalid argument specified\n");
482 for (
i = 0;
i <
This->constant_buffer_count; ++
i)
488 TRACE(
"Returning ID3D11ShaderReflectionConstantBuffer %p.\n",
d);
489 return &
d->ID3D11ShaderReflectionConstantBuffer_iface;
493 WARN(
"Invalid name specified\n");
507 WARN(
"Invalid argument specified\n");
527 WARN(
"Invalid argument specified\n");
545 WARN(
"Invalid argument specified\n");
554#if D3D_COMPILER_VERSION
564 WARN(
"Invalid argument specified\n");
583 WARN(
"Invalid name specified\n");
587 for (
i = 0;
i <
This->constant_buffer_count; ++
i)
591 for (
k = 0;
k <
cb->variable_count; ++
k)
597 TRACE(
"Returning ID3D11ShaderReflectionVariable %p.\n",
v);
598 return &
v->ID3D11ShaderReflectionVariable_iface;
603 WARN(
"Invalid name specified\n");
618 WARN(
"Invalid argument specified\n");
628 TRACE(
"Returning D3D11_SHADER_INPUT_BIND_DESC %p.\n",
d);
635 WARN(
"Invalid name specified\n");
645 TRACE(
"iface %p\n", iface);
647 return This->mov_instruction_count;
653 FIXME(
"iface %p stub!\n", iface);
663 TRACE(
"iface %p\n", iface);
665 return This->conversion_instruction_count;
671 FIXME(
"iface %p stub!\n", iface);
679 FIXME(
"iface %p stub!\n", iface);
687 FIXME(
"iface %p stub!\n", iface);
695 FIXME(
"iface %p stub!\n", iface);
703 FIXME(
"iface %p, level %p stub!\n", iface,
level);
713 TRACE(
"iface %p, sizex %p, sizey %p, sizez %p.\n", iface, sizex, sizey, sizez);
715 if (!sizex || !sizey || !sizez)
717 WARN(
"Invalid argument specified.\n");
725 return *sizex * *sizey * *sizez;
731 FIXME(
"iface %p stub!\n", iface);
750#if D3D_COMPILER_VERSION
751 d3dcompiler_shader_reflection_GetPatchConstantParameterDesc,
752 d3dcompiler_shader_reflection_GetVariableByName,
753 d3dcompiler_shader_reflection_GetResourceBindingDescByName,
754 d3dcompiler_shader_reflection_GetMovInstructionCount,
755 d3dcompiler_shader_reflection_GetMovcInstructionCount,
756 d3dcompiler_shader_reflection_GetConversionInstructionCount,
757 d3dcompiler_shader_reflection_GetBitwiseInstructionCount,
758 d3dcompiler_shader_reflection_GetGSInputPrimitive,
759 d3dcompiler_shader_reflection_IsSampleFrequencyShader,
760 d3dcompiler_shader_reflection_GetNumInterfaceSlots,
761 d3dcompiler_shader_reflection_GetMinFeatureLevel,
762 d3dcompiler_shader_reflection_GetThreadGroupSize,
763 d3dcompiler_shader_reflection_GetRequiresFlags,
779 TRACE(
"iface %p, desc %p\n", iface,
desc);
783 WARN(
"Null constant buffer specified\n");
789 WARN(
"Invalid argument specified\n");
795 desc->Variables =
This->variable_count;
811 WARN(
"Invalid index specified\n");
815 return &
This->variables[
index].ID3D11ShaderReflectionVariable_iface;
828 WARN(
"Invalid argument specified\n");
832 for (
i = 0;
i <
This->variable_count; ++
i)
838 TRACE(
"Returning ID3D11ShaderReflectionVariable %p.\n",
v);
839 return &
v->ID3D11ShaderReflectionVariable_iface;
843 WARN(
"Invalid name specified\n");
868 TRACE(
"iface %p, desc %p\n", iface,
desc);
872 WARN(
"Null variable specified\n");
878 WARN(
"Invalid argument specified\n");
888#if D3D_COMPILER_VERSION
904 TRACE(
"iface %p\n", iface);
906 return &
This->type->ID3D11ShaderReflectionType_iface;
909#if D3D_COMPILER_VERSION
915 TRACE(
"iface %p\n", iface);
917 return &
This->constant_buffer->ID3D11ShaderReflectionConstantBuffer_iface;
923 FIXME(
"iface %p, index %u stub!\n", iface,
index);
934#if D3D_COMPILER_VERSION
935 d3dcompiler_shader_reflection_variable_GetBuffer,
936 d3dcompiler_shader_reflection_variable_GetInterfaceSlot,
952 TRACE(
"iface %p, desc %p\n", iface,
desc);
956 WARN(
"Null type specified\n");
962 WARN(
"Invalid argument specified\n");
980 WARN(
"Invalid index specified\n");
981 return &
null_type.ID3D11ShaderReflectionType_iface;
984 return &
This->members[
index].type->ID3D11ShaderReflectionType_iface;
997 WARN(
"Invalid argument specified\n");
998 return &
null_type.ID3D11ShaderReflectionType_iface;
1001 for (
i = 0;
i <
This->desc.Members; ++
i)
1008 return &
member->
type->ID3D11ShaderReflectionType_iface;
1012 WARN(
"Invalid name specified\n");
1014 return &
null_type.ID3D11ShaderReflectionType_iface;
1026 WARN(
"Null type specified\n");
1032 WARN(
"Invalid index specified\n");
1039#if D3D_COMPILER_VERSION
1045 TRACE(
"iface %p, type %p\n", iface,
type);
1049 WARN(
"Null type specified\n");
1062 FIXME(
"iface %p stub!\n", iface);
1070 FIXME(
"iface %p stub!\n", iface);
1078 FIXME(
"iface %p stub!\n", iface);
1086 FIXME(
"iface %p, index %u stub!\n", iface,
index);
1094 FIXME(
"iface %p, type %p stub!\n", iface,
type);
1102 FIXME(
"iface %p, base %p stub!\n", iface,
base);
1115#if D3D_COMPILER_VERSION
1116 d3dcompiler_shader_reflection_type_IsEqual,
1117 d3dcompiler_shader_reflection_type_GetSubType,
1118 d3dcompiler_shader_reflection_type_GetBaseClass,
1119 d3dcompiler_shader_reflection_type_GetNumInterfaces,
1120 d3dcompiler_shader_reflection_type_GetInterfaceByIndex,
1121 d3dcompiler_shader_reflection_type_IsOfType,
1122 d3dcompiler_shader_reflection_type_ImplementsInterface,
1129 size_t size = data_size >> 2;
1134 TRACE(
"InstructionCount: %u.\n",
r->instruction_count);
1137 TRACE(
"TempRegisterCount: %u.\n",
r->temp_register_count);
1140 TRACE(
"DefCount: %u.\n",
r->def_count);
1143 TRACE(
"DclCount: %u.\n",
r->dcl_count);
1146 TRACE(
"FloatInstructionCount: %u.\n",
r->float_instruction_count);
1149 TRACE(
"IntInstructionCount: %u.\n",
r->int_instruction_count);
1152 TRACE(
"UintInstructionCount: %u.\n",
r->uint_instruction_count);
1155 TRACE(
"StaticFlowControlCount: %u.\n",
r->static_flow_control_count);
1158 TRACE(
"DynamicFlowControlCount: %u.\n",
r->dynamic_flow_control_count);
1161 TRACE(
"MacroInstructionCount: %u.\n",
r->macro_instruction_count);
1164 TRACE(
"TempArrayCount: %u.\n",
r->temp_array_count);
1167 TRACE(
"ArrayInstructionCount: %u.\n",
r->array_instruction_count);
1170 TRACE(
"CutInstructionCount: %u.\n",
r->cut_instruction_count);
1173 TRACE(
"EmitInstructionCount: %u.\n",
r->emit_instruction_count);
1176 TRACE(
"TextureNormalInstructions: %u.\n",
r->texture_normal_instructions);
1179 TRACE(
"TextureLoadInstructions: %u.\n",
r->texture_load_instructions);
1182 TRACE(
"TextureCompInstructions: %u.\n",
r->texture_comp_instructions);
1185 TRACE(
"TextureBiasInstructions: %u.\n",
r->texture_bias_instructions);
1188 TRACE(
"TextureGradientInstructions: %u.\n",
r->texture_gradient_instructions);
1191 TRACE(
"MovInstructionCount: %u.\n",
r->mov_instruction_count);
1196 TRACE(
"ConversionInstructionCount: %u.\n",
r->conversion_instruction_count);
1201 TRACE(
"InputPrimitive: %x.\n",
r->input_primitive);
1204 TRACE(
"GSOutputTopology: %x.\n",
r->gs_output_topology);
1207 TRACE(
"GSMaxOutputVertexCount: %u.\n",
r->gs_max_output_vertex_count);
1222 TRACE(
"cControlPoints: %u.\n",
r->c_control_points);
1225 TRACE(
"HSOutputPrimitive: %x.\n",
r->hs_output_primitive);
1228 TRACE(
"HSPartitioning: %x.\n",
r->hs_partitioning);
1231 TRACE(
"TessellatorDomain: %x.\n",
r->tessellator_domain);
1251 ERR(
"Failed to copy name.\n");
1262 ERR(
"Failed to get member type\n");
1299 TRACE(
"Elements %u, Members %u\n",
desc->Elements,
desc->Members);
1302 TRACE(
"Member Offset %u.\n", member_offset);
1309 const char *ptr2 =
data + member_offset;
1311 members =
calloc(
desc->Members,
sizeof(*members));
1314 ERR(
"Failed to allocate type memory.\n");
1318 for (
i = 0;
i <
desc->Members; ++
i)
1323 FIXME(
"Failed to parse type members.\n");
1329#if D3D_COMPILER_VERSION
1335 ERR(
"Failed to copy name.\n");
1344 type->members = members;
1349 for (
i = 0;
i <
desc->Members; ++
i)
1366 TRACE(
"Returning existing type.\n");
1376 type->reflection = reflection;
1381 ERR(
"Failed to parse type info, hr %#lx.\n",
hr);
1388 ERR(
"Failed to insert type entry.\n");
1397 const char *
data,
size_t data_size,
const char *
ptr)
1403 variables =
calloc(
cb->variable_count,
sizeof(*variables));
1406 ERR(
"Failed to allocate variables memory.\n");
1410 for (
i = 0;
i <
cb->variable_count;
i++)
1416 v->constant_buffer =
cb;
1421 ERR(
"Failed to copy name.\n");
1428 TRACE(
"Variable offset: %u\n",
v->start_offset);
1431 TRACE(
"Variable size: %u\n",
v->size);
1434 TRACE(
"Variable flags: %u\n",
v->flags);
1441 ERR(
"Failed to get type.\n");
1447 TRACE(
"Variable default value offset: %x.\n",
offset);
1450 ERR(
"Failed to copy name.\n");
1459 cb->variables = variables;
1464 for (
i = 0;
i <
cb->variable_count;
i++)
1475 uint32_t offset, cbuffer_offset, resource_offset, creator_offset;
1476 unsigned int i, string_data_offset, string_data_size;
1478 char *string_data =
NULL, *creator =
NULL;
1479 size_t size = data_size >> 2;
1482#if D3D_COMPILER_VERSION < 47
1490 TRACE(
"Constant buffer count: %u.\n",
r->constant_buffer_count);
1493 TRACE(
"Constant buffer offset: %#x.\n", cbuffer_offset);
1496 TRACE(
"Bound resource count: %u.\n",
r->bound_resource_count);
1499 TRACE(
"Bound resource offset: %#x.\n", resource_offset);
1502 TRACE(
"Target: %#x.\n",
r->target);
1505#if D3D_COMPILER_VERSION < 47
1517 TRACE(
"Flags: %u.\n",
r->flags);
1520 TRACE(
"Creator at offset %#x.\n", creator_offset);
1524 ERR(
"Failed to copy name.\n");
1530 if (target_version >= 0x500)
1535 if (
r->bound_resource_count)
1538 string_data_offset = resource_offset +
r->bound_resource_count * 8 *
sizeof(
uint32_t);
1539 string_data_size = (cbuffer_offset ? cbuffer_offset : creator_offset) - string_data_offset;
1541 string_data =
malloc(string_data_size);
1544 ERR(
"Failed to allocate string data memory.\n");
1548 memcpy(string_data,
data + string_data_offset, string_data_size);
1550 bound_resources =
calloc(
r->bound_resource_count,
sizeof(*bound_resources));
1551 if (!bound_resources)
1553 ERR(
"Failed to allocate resources memory.\n");
1559 for (
i = 0;
i <
r->bound_resource_count;
i++)
1568 TRACE(
"Input bind Type: %#x.\n",
desc->Type);
1571 TRACE(
"Input bind ReturnType: %#x.\n",
desc->ReturnType);
1574 TRACE(
"Input bind Dimension: %#x.\n",
desc->Dimension);
1577 TRACE(
"Input bind NumSamples: %u.\n",
desc->NumSamples);
1580 TRACE(
"Input bind BindPoint: %u.\n",
desc->BindPoint);
1583 TRACE(
"Input bind BindCount: %u.\n",
desc->BindCount);
1588 if (target_version >= 0x501)
1591 TRACE(
"Input bind Space %u.\n",
desc->Space);
1593 TRACE(
"Input bind uID %u.\n",
desc->uID);
1602 if (
r->constant_buffer_count)
1604 constant_buffers =
calloc(
r->constant_buffer_count,
sizeof(*constant_buffers));
1605 if (!constant_buffers)
1607 ERR(
"Failed to allocate constant buffer memory.\n");
1613 for (
i = 0;
i <
r->constant_buffer_count;
i++)
1623 ERR(
"Failed to copy name.\n");
1630 TRACE(
"Variable count: %u.\n",
cb->variable_count);
1638 FIXME(
"Failed to parse variables.\n");
1643 TRACE(
"Cbuffer size: %u.\n",
cb->size);
1646 TRACE(
"Cbuffer flags: %u.\n",
cb->flags);
1649 TRACE(
"Cbuffer type: %#x.\n",
cb->type);
1653 r->creator = creator;
1654 r->resource_string = string_data;
1655 r->bound_resources = bound_resources;
1656 r->constant_buffers = constant_buffers;
1661 for (
i = 0;
i <
r->constant_buffer_count; ++
i)
1665 free(constant_buffers);
1666 free(bound_resources);
1679 unsigned int string_data_offset;
1680 unsigned int string_data_size;
1710 ERR(
"Failed to allocate signature memory.\n");
1716 string_data_size =
section->data.size - string_data_offset;
1718 string_data =
malloc(string_data_size);
1721 ERR(
"Failed to allocate string data memory.\n");
1725 memcpy(string_data, (
const char *)
section->data.code + string_data_offset, string_data_size);
1731#if D3D_COMPILER_VERSION >= 46
1735#if D3D_COMPILER_VERSION
1743 d[
i].SemanticName = string_data + (name_offset - string_data_offset);
1749 d[
i].ReadWriteMask = (
mask >> 8) & 0xff;
1752 if (!
stricmp(
d[
i].SemanticName,
"sv_depth"))
1754 else if (!
stricmp(
d[
i].SemanticName,
"sv_coverage"))
1756 else if (!
stricmp(
d[
i].SemanticName,
"sv_depthgreaterequal"))
1758 else if (!
stricmp(
d[
i].SemanticName,
"sv_depthlessequal"))
1760 else if (!
stricmp(
d[
i].SemanticName,
"sv_target"))
1765 s->element_count =
count;
1766 s->string_data = string_data;
1771#define SM4_OPCODE_MASK 0xff
1772#define SM4_INSTRUCTION_LENGTH_SHIFT 24
1773#define SM4_INSTRUCTION_LENGTH_MASK (0x1fu << SM4_INSTRUCTION_LENGTH_SHIFT)
1789 TRACE(
"Shader version: %u\n",
r->version);
1811 opcode_token = *u_ptr;
1818 WARN(
"End of byte-code, failed to read length token.\n");
1825 WARN(
"Invalid instruction length %u, size %u.\n",
len,
size);
1832 WARN(
"Invalid dcl_thread_group opcode length %u.\n",
len);
1835 r->thread_group_size_x = u_ptr[1];
1836 r->thread_group_size_y = u_ptr[2];
1837 r->thread_group_size_z = u_ptr[3];
1838 TRACE(
"Found dcl_thread_group %u, %u, %u.\n",
1839 r->thread_group_size_x,
r->thread_group_size_y,
r->thread_group_size_z);
1860 WARN(
"Failed to parse reflection, ret %d.\n",
ret);
1874 WARN(
"Failed to parse RDEF section.\n");
1881 if (!reflection->
isgn)
1883 ERR(
"Failed to allocate ISGN memory.\n");
1891 WARN(
"Failed to parse section ISGN.\n");
1899 if (!reflection->
osgn)
1901 ERR(
"Failed to allocate OSGN memory.\n");
1909 WARN(
"Failed to parse section OSGN.\n");
1916 if (!reflection->
pcsg)
1918 ERR(
"Failed to allocate PCSG memory.\n");
1926 WARN(
"Failed to parse section PCSG.\n");
1936 WARN(
"Failed to parse SHDR section.\n");
1945 WARN(
"Failed to parse section STAT.\n");
1968#if !D3D_COMPILER_VERSION
1974 TRACE(
"data %p, data_size %Iu, reflector %p.\n",
data, data_size, reflector);
1976 if (!(
object =
calloc(1,
sizeof(*
object))))
1978 ERR(
"Failed to allocate D3D10 shader reflection object memory.\n");
1984 object->refcount = 1;
1989 WARN(
"Failed to initialize shader reflection.\n");
1996 TRACE(
"Created ID3D10ShaderReflection %p.\n",
object);
2009 if (!
data || data_size < 32)
2011 WARN(
"Invalid argument supplied.\n");
2015 if (
temp[6] != data_size)
2017 WARN(
"Wrong size supplied.\n");
2018#if D3D_COMPILER_VERSION >= 46
2029#if D3D_COMPILER_VERSION >= 46
2036 object =
calloc(1,
sizeof(*
object));
2041 object->refcount = 1;
2042 object->interface_version =
IsEqualGUID(
riid, &IID_ID3D12ShaderReflection)
2048 WARN(
"Failed to initialize shader reflection\n");
2054 TRACE(
"Created ID3D11ShaderReflection %p\n",
object);
COMPILER_DEPENDENT_UINT64 UINT64
#define InterlockedIncrement
#define InterlockedDecrement
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
#define STDMETHODCALLTYPE
#define D3DERR_INVALIDCALL
#define D3D_COMPILER_VERSION
D3D_TESSELLATOR_OUTPUT_PRIMITIVE
D3D_TESSELLATOR_PARTITIONING
@ D3D_NAME_DEPTH_GREATER_EQUAL
@ D3D_NAME_DEPTH_LESS_EQUAL
@ D3D_MIN_PRECISION_DEFAULT
HRESULT WINAPI D3DReflect(const void *data, SIZE_T data_size, REFIID riid, void **reflector)
const char * debug_d3dcompiler_shader_variable_type(D3D_SHADER_VARIABLE_TYPE t)
const char * debug_d3dcompiler_shader_variable_class(D3D_SHADER_VARIABLE_CLASS c)
size_t const element_size
static struct d3dcompiler_shader_reflection_type * get_reflection_type(struct d3dcompiler_shader_reflection *reflection, const char *data, uint32_t offset)
static struct d3dcompiler_shader_reflection_variable * impl_from_ID3D11ShaderReflectionVariable(ID3D11ShaderReflectionVariable *iface)
#define ID3D11ShaderReflectionConstantBufferVtbl
#define D3DCOMPILER_SHADER_TARGET_SHADERTYPE_SHIFT
#define D3DCOMPILER_SHADER_TARGET_SHADERTYPE_MASK
#define ID3D11ShaderReflectionVtbl
static HRESULT STDMETHODCALLTYPE d3dcompiler_shader_reflection_constant_buffer_GetDesc(ID3D11ShaderReflectionConstantBuffer *iface, D3D11_SHADER_BUFFER_DESC *desc)
#define ID3D11ShaderReflectionVariableVtbl
#define D3DCOMPILER_SHADER_TARGET_VERSION_MASK
static const struct ID3D11ShaderReflectionVariableVtbl d3dcompiler_shader_reflection_variable_vtbl
static void d3dcompiler_shader_reflection_type_destroy(struct wine_rb_entry *entry, void *context)
static struct ID3D11ShaderReflectionConstantBuffer *STDMETHODCALLTYPE d3dcompiler_shader_reflection_GetConstantBufferByName(ID3D11ShaderReflection *iface, const char *name)
D3DCOMPILER_SIGNATURE_ELEMENT_SIZE
@ D3DCOMPILER_SIGNATURE_ELEMENT_SIZE7
@ D3DCOMPILER_SIGNATURE_ELEMENT_SIZE6
static const struct ID3D11ShaderReflectionVtbl d3dcompiler_shader_reflection_vtbl
static ID3D11ShaderReflectionType *STDMETHODCALLTYPE d3dcompiler_shader_reflection_type_GetMemberTypeByIndex(ID3D11ShaderReflectionType *iface, UINT index)
#define ID3D11ShaderReflectionType
#define ID3D11ShaderReflectionTypeVtbl
static ULONG STDMETHODCALLTYPE d3dcompiler_shader_reflection_AddRef(ID3D11ShaderReflection *iface)
static HRESULT STDMETHODCALLTYPE d3dcompiler_shader_reflection_type_GetDesc(ID3D11ShaderReflectionType *iface, D3D11_SHADER_TYPE_DESC *desc)
static void free_signature(struct d3dcompiler_shader_signature *sig)
#define ID3D11ShaderReflectionConstantBuffer
static HRESULT d3dcompiler_parse_type(struct d3dcompiler_shader_reflection_type *type, const char *data, uint32_t offset)
static void free_type_member(struct d3dcompiler_shader_reflection_type_member *member)
@ D3DCOMPILER_SHADER_TYPE_CS
#define ID3D11ShaderReflection
#define ID3D11ShaderReflectionVariable
static const struct ID3D11ShaderReflectionConstantBufferVtbl d3dcompiler_shader_reflection_constant_buffer_vtbl
static const char *STDMETHODCALLTYPE d3dcompiler_shader_reflection_type_GetMemberTypeName(ID3D11ShaderReflectionType *iface, UINT index)
static ID3D11ShaderReflectionType *STDMETHODCALLTYPE d3dcompiler_shader_reflection_type_GetMemberTypeByName(ID3D11ShaderReflectionType *iface, const char *name)
static HRESULT STDMETHODCALLTYPE d3dcompiler_shader_reflection_GetResourceBindingDesc(ID3D11ShaderReflection *iface, UINT index, D3D11_SHADER_INPUT_BIND_DESC *desc)
static struct d3dcompiler_shader_reflection_constant_buffer * impl_from_ID3D11ShaderReflectionConstantBuffer(ID3D11ShaderReflectionConstantBuffer *iface)
static HRESULT STDMETHODCALLTYPE d3dcompiler_shader_reflection_GetInputParameterDesc(ID3D11ShaderReflection *iface, UINT index, D3D11_SIGNATURE_PARAMETER_DESC *desc)
static HRESULT d3dcompiler_parse_stat(struct d3dcompiler_shader_reflection *r, const char *data, size_t data_size)
D3DCOMPILER_REFLECTION_VERSION
@ D3DCOMPILER_REFLECTION_VERSION_D3D10
@ D3DCOMPILER_REFLECTION_VERSION_D3D11
@ D3DCOMPILER_REFLECTION_VERSION_D3D12
#define IID_ID3D11ShaderReflection
static HRESULT d3dcompiler_parse_variables(struct d3dcompiler_shader_reflection_constant_buffer *cb, const char *data, size_t data_size, const char *ptr)
static BOOL copy_value(const char *ptr, void **value, uint32_t size)
static HRESULT STDMETHODCALLTYPE d3dcompiler_shader_reflection_GetOutputParameterDesc(ID3D11ShaderReflection *iface, UINT index, D3D11_SIGNATURE_PARAMETER_DESC *desc)
static HRESULT d3dcompiler_parse_rdef(struct d3dcompiler_shader_reflection *r, const char *data, size_t data_size)
static HRESULT d3dcompiler_parse_type_members(struct d3dcompiler_shader_reflection *ref, struct d3dcompiler_shader_reflection_type_member *member, const char *data, const char **ptr)
#define SM4_INSTRUCTION_LENGTH_SHIFT
#define SM4_INSTRUCTION_LENGTH_MASK
static HRESULT d3dcompiler_parse_shdr(struct d3dcompiler_shader_reflection *r, const char *data, size_t data_size)
static HRESULT STDMETHODCALLTYPE d3dcompiler_shader_reflection_QueryInterface(ID3D11ShaderReflection *iface, REFIID riid, void **object)
static void free_constant_buffer(struct d3dcompiler_shader_reflection_constant_buffer *cb)
static ULONG STDMETHODCALLTYPE d3dcompiler_shader_reflection_Release(ID3D11ShaderReflection *iface)
static int d3dcompiler_shader_reflection_type_compare(const void *key, const struct wine_rb_entry *entry)
static ID3D11ShaderReflectionType *STDMETHODCALLTYPE d3dcompiler_shader_reflection_variable_GetType(ID3D11ShaderReflectionVariable *iface)
static HRESULT d3dcompiler_shader_reflection_init(struct d3dcompiler_shader_reflection *reflection, const void *data, SIZE_T data_size)
static void reflection_cleanup(struct d3dcompiler_shader_reflection *ref)
static struct d3dcompiler_shader_reflection * impl_from_ID3D11ShaderReflection(ID3D11ShaderReflection *iface)
static struct d3dcompiler_shader_reflection_type * impl_from_ID3D11ShaderReflectionType(ID3D11ShaderReflectionType *iface)
HRESULT WINAPI D3D10ReflectShader(const void *data, SIZE_T data_size, ID3D10ShaderReflection **reflector)
static ID3D11ShaderReflectionVariable *STDMETHODCALLTYPE d3dcompiler_shader_reflection_constant_buffer_GetVariableByIndex(ID3D11ShaderReflectionConstantBuffer *iface, UINT index)
static HRESULT STDMETHODCALLTYPE d3dcompiler_shader_reflection_variable_GetDesc(ID3D11ShaderReflectionVariable *iface, D3D11_SHADER_VARIABLE_DESC *desc)
static struct d3dcompiler_shader_reflection_variable null_variable
static const struct ID3D11ShaderReflectionTypeVtbl d3dcompiler_shader_reflection_type_vtbl
static struct d3dcompiler_shader_reflection_constant_buffer null_constant_buffer
static void free_variable(struct d3dcompiler_shader_reflection_variable *var)
static BOOL copy_name(const char *ptr, char **name)
@ SM5_OP_DCL_THREAD_GROUP
static struct d3dcompiler_shader_reflection_type null_type
static HRESULT STDMETHODCALLTYPE d3dcompiler_shader_reflection_GetDesc(ID3D11ShaderReflection *iface, D3D11_SHADER_DESC *desc)
static HRESULT d3dcompiler_parse_signature(struct d3dcompiler_shader_signature *s, const struct vkd3d_shader_dxbc_section_desc *section)
#define D3DCOMPILER_SHDR_SHADER_TYPE_CS
static ID3D11ShaderReflectionVariable *STDMETHODCALLTYPE d3dcompiler_shader_reflection_constant_buffer_GetVariableByName(ID3D11ShaderReflectionConstantBuffer *iface, const char *name)
static struct ID3D11ShaderReflectionConstantBuffer *STDMETHODCALLTYPE d3dcompiler_shader_reflection_GetConstantBufferByIndex(ID3D11ShaderReflection *iface, UINT index)
void skip_u32_unknown(const char **ptr, unsigned int count)
static uint32_t read_u32(const char **ptr)
#define stricmp(_String1, _String2)
_ACRTIMP int __cdecl strcmp(const char *, const char *)
static char * strdup(const char *buf)
GLuint GLuint GLsizei count
GLuint GLuint GLsizei GLenum type
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
GLdouble GLdouble GLdouble r
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define memcpy(s1, s2, n)
D3D11_SHADER_VARIABLE_DESC desc
#define IsEqualGUID(rguid1, rguid2)
static __inline const char * debugstr_fourcc(unsigned int cc)
#define WINE_RB_ENTRY_VALUE
ID3D11ShaderReflectionConstantBuffer ID3D11ShaderReflectionConstantBuffer_iface
struct d3dcompiler_shader_reflection * reflection
struct d3dcompiler_shader_reflection_variable * variables
struct d3dcompiler_shader_reflection_type * type
struct wine_rb_entry entry
ID3D11ShaderReflectionType ID3D11ShaderReflectionType_iface
D3D11_SHADER_TYPE_DESC desc
struct d3dcompiler_shader_reflection * reflection
struct d3dcompiler_shader_reflection_type_member * members
struct d3dcompiler_shader_reflection_constant_buffer * constant_buffer
ID3D11ShaderReflectionVariable ID3D11ShaderReflectionVariable_iface
struct d3dcompiler_shader_reflection_type * type
UINT texture_gradient_instructions
UINT texture_load_instructions
UINT array_instruction_count
struct d3dcompiler_shader_signature * osgn
UINT texture_normal_instructions
D3D_TESSELLATOR_OUTPUT_PRIMITIVE hs_output_primitive
UINT macro_instruction_count
struct d3dcompiler_shader_signature * pcsg
D3D12_SHADER_INPUT_BIND_DESC * bound_resources
enum D3DCOMPILER_REFLECTION_VERSION interface_version
UINT conversion_instruction_count
UINT int_instruction_count
UINT constant_buffer_count
D3D_PRIMITIVE_TOPOLOGY gs_output_topology
UINT emit_instruction_count
ID3D11ShaderReflection ID3D11ShaderReflection_iface
UINT cut_instruction_count
UINT bound_resource_count
UINT uint_instruction_count
D3D_TESSELLATOR_PARTITIONING hs_partitioning
UINT texture_comp_instructions
D3D_PRIMITIVE input_primitive
UINT float_instruction_count
struct d3dcompiler_shader_reflection_constant_buffer * constant_buffers
struct d3dcompiler_shader_signature * isgn
D3D_TESSELLATOR_DOMAIN tessellator_domain
UINT gs_max_output_vertex_count
UINT texture_bias_instructions
UINT mov_instruction_count
UINT static_flow_control_count
UINT dynamic_flow_control_count
struct wine_rb_tree types
unsigned int element_count
D3D11_SIGNATURE_PARAMETER_DESC * elements
struct vkd3d_shader_dxbc_section_desc * sections
#define CONTAINING_RECORD(address, type, field)
VKD3D_SHADER_API void vkd3d_shader_free_dxbc(struct vkd3d_shader_dxbc_desc *dxbc)
VKD3D_SHADER_API int vkd3d_shader_parse_dxbc(const struct vkd3d_shader_code *dxbc, uint32_t flags, struct vkd3d_shader_dxbc_desc *desc, char **messages)