ReactOS 0.4.17-dev-934-g091855f
effect.c File Reference
#include "d3d10_private.h"
#include <vkd3d_shader.h>
#include <float.h>
#include <stdint.h>
Include dependency graph for effect.c:

Go to the source code of this file.

Classes

struct  preshader_instr
 
struct  preshader_op_info
 
struct  d3d10_ctab_var
 
struct  d3d10_reg_table
 
struct  d3d10_effect_preshader
 
struct  d3d10_preshader_parse_context
 
struct  d3d10_effect_prop_dependency
 
struct  d3d10_effect_state_property_info
 
struct  d3d10_effect_state_storage_info
 
struct  d3d10_effect_so_decl
 
struct  numeric_type
 

Macros

#define MAKE_TAG(ch0, ch1, ch2, ch3)
 
#define TAG_FX10   MAKE_TAG('F', 'X', '1', '0')
 
#define TAG_FXLC   MAKE_TAG('F', 'X', 'L', 'C')
 
#define TAG_CLI4   MAKE_TAG('C', 'L', 'I', '4')
 
#define TAG_CTAB   MAKE_TAG('C', 'T', 'A', 'B')
 
#define WINE_D3D10_TO_STR(x)   case x: return #x
 

Typedefs

typedef void(* pres_op_func) (float **args, unsigned int n, const struct preshader_instr *instr)
 

Enumerations

enum  d3d10_effect_container_type {
  D3D10_C_NONE , D3D10_C_PASS , D3D10_C_RASTERIZER , D3D10_C_DEPTHSTENCIL ,
  D3D10_C_BLEND , D3D10_C_SAMPLER
}
 
enum  d3d10_reg_table_type {
  D3D10_REG_TABLE_CONSTANTS = 1 , D3D10_REG_TABLE_CB = 2 , D3D10_REG_TABLE_RESULT = 4 , D3D10_REG_TABLE_TEMP = 7 ,
  D3D10_REG_TABLE_COUNT
}
 

Functions

 WINE_DEFAULT_DEBUG_CHANNEL (d3d10)
 
static struct d3d10_effect * impl_from_ID3D10EffectPool (ID3D10EffectPool *iface)
 
static struct d3d10_effect * unsafe_impl_from_ID3D10EffectPool (ID3D10EffectPool *iface)
 
static void d3d10_effect_variable_destroy (struct d3d10_effect_variable *v)
 
static struct d3d10_effect_type * get_fx10_type (struct d3d10_effect *effect, const char *data, size_t data_size, uint32_t offset)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectVariable (ID3D10EffectVariable *iface)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectShaderVariable (ID3D10EffectShaderVariable *iface)
 
static struct d3d10_effect_variable * d3d10_array_get_element (struct d3d10_effect_variable *v, unsigned int index)
 
static struct d3d10_effect_variable * d3d10_get_state_variable (struct d3d10_effect_variable *v, unsigned int index, const struct d3d10_effect_var_array *array)
 
static enum d3d10_effect_container_type get_var_container_type (const struct d3d10_effect_variable *v)
 
static void pres_mov (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_neg (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_rcp (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_frc (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_exp (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_log (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_rsq (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_sin (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_cos (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_asin (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_acos (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_atan (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_sqrt (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_ineg (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_not (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_itof (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_utof (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_ftou (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_ftob (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_floor (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_ceil (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_min (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_max (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_add (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_mul (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_atan2 (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_div (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_iadd (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_imul (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_bilt (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_bige (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_bieq (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_bine (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_buge (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_bult (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_udiv (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_imin (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_imax (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_umin (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_umax (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_and (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_or (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_xor (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_ishl (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_ishr (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_ushr (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_movc (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_dot (float **args, unsigned int n, const struct preshader_instr *instr)
 
static void pres_dotswiz (float **args, unsigned int n, const struct preshader_instr *instr)
 
static int __cdecl preshader_op_compare (const void *a, const void *b)
 
static const struct preshader_op_info * d3d10_effect_get_op_info (int opcode)
 
static HRESULT d3d10_reg_table_allocate (struct d3d10_reg_table *table, unsigned int count)
 
static void d3d10_effect_preshader_clear (struct d3d10_effect_preshader *p)
 
static float * d3d10_effect_preshader_get_reg_ptr (const struct d3d10_effect_preshader *p, enum d3d10_reg_table_type regt, unsigned int offset)
 
static HRESULT d3d10_effect_preshader_eval (struct d3d10_effect_preshader *p)
 
static void d3d10_effect_clear_prop_dependencies (struct d3d10_effect_prop_dependencies *d)
 
static const char * debug_d3d10_shader_variable_class (D3D10_SHADER_VARIABLE_CLASS c)
 
static const char * debug_d3d10_shader_variable_type (D3D10_SHADER_VARIABLE_TYPE t)
 
static HRESULT d3d10_effect_variable_get_raw_value (struct d3d10_effect_variable *v, void *data, unsigned int offset, unsigned int count)
 
static BOOL read_float_value (uint32_t value, D3D_SHADER_VARIABLE_TYPE in_type, float *out_data, unsigned int out_idx)
 
static BOOL read_int32_value (uint32_t value, D3D_SHADER_VARIABLE_TYPE in_type, int *out_data, unsigned int out_idx)
 
static BOOL read_int8_value (uint32_t value, D3D_SHADER_VARIABLE_TYPE in_type, INT8 *out_data, unsigned int out_idx)
 
static BOOL d3d10_effect_read_numeric_value (uint32_t value, D3D_SHADER_VARIABLE_TYPE in_type, D3D_SHADER_VARIABLE_TYPE out_type, void *out_data, unsigned int out_idx)
 
static void d3d10_effect_update_dependent_props (struct d3d10_effect_prop_dependencies *deps, void *container)
 
static BOOL d3d_array_reserve (void **elements, SIZE_T *capacity, SIZE_T count, SIZE_T size)
 
static BOOL require_space (size_t offset, size_t count, size_t size, size_t data_size)
 
static BOOL fx10_get_string (const char *data, size_t data_size, uint32_t offset, const char **s, size_t *l)
 
static BOOL fx10_copy_string (const char *data, size_t data_size, DWORD offset, char **s)
 
static BOOL copy_name (const char *ptr, char **name)
 
static struct d3d10_effect_variable * d3d10_effect_get_buffer_by_name (struct d3d10_effect *effect, const char *name)
 
static struct d3d10_effect_variable * d3d10_effect_get_variable_by_name (const struct d3d10_effect *effect, const char *name)
 
static HRESULT get_fx10_shader_resources (struct d3d10_effect_variable *v)
 
static void d3d10_effect_cleanup_so_decl (struct d3d10_effect_so_decl *so_decl)
 
static HRESULT d3d10_effect_parse_stream_output_declaration (const char *decl, struct d3d10_effect_so_decl *so_decl)
 
static HRESULT parse_fx10_shader (const char *data, size_t data_size, uint32_t offset, struct d3d10_effect_variable *v)
 
static D3D10_SHADER_VARIABLE_CLASS d3d10_variable_class (uint32_t c, BOOL is_column_major)
 
static D3D10_SHADER_VARIABLE_TYPE d3d10_variable_type (uint32_t t, BOOL is_object, uint32_t *flags)
 
static HRESULT parse_fx10_type (const char *data, size_t data_size, uint32_t offset, struct d3d10_effect_type *t)
 
static void set_variable_vtbl (struct d3d10_effect_variable *v)
 
static HRESULT copy_variableinfo_from_type (struct d3d10_effect_variable *v)
 
static HRESULT parse_fx10_variable_head (const char *data, size_t data_size, const char **ptr, struct d3d10_effect_variable *v)
 
static HRESULT parse_fx10_annotation (const char *data, size_t data_size, const char **ptr, struct d3d10_effect_variable *a)
 
static HRESULT parse_fx10_annotations (const char *data, size_t data_size, const char **ptr, struct d3d10_effect *effect, struct d3d10_effect_annotations *annotations)
 
static HRESULT parse_fx10_anonymous_shader (struct d3d10_effect *e, D3D_SHADER_VARIABLE_TYPE basetype, struct d3d10_effect_anonymous_shader *s)
 
static const struct d3d10_effect_state_storage_info * get_storage_info (D3D_SHADER_VARIABLE_TYPE id)
 
static BOOL read_value_list (const char *data, size_t data_size, uint32_t offset, D3D_SHADER_VARIABLE_TYPE out_type, unsigned int out_base, unsigned int out_size, void *out_data)
 
static BOOL is_object_property (const struct d3d10_effect_state_property_info *property_info)
 
static BOOL is_object_property_type_matching (const struct d3d10_effect_state_property_info *property_info, const struct d3d10_effect_variable *v)
 
static HRESULT parse_fx10_preshader_instr (struct d3d10_preshader_parse_context *context, unsigned int *offset, const char **ptr, unsigned int data_size)
 
static HRESULT parse_fx10_fxlc (void *ctx, const char *data, unsigned int data_size)
 
static HRESULT parse_fx10_cli4 (void *ctx, const char *data, unsigned int data_size)
 
static HRESULT parse_fx10_ctab (void *ctx, const char *data, unsigned int data_size)
 
static HRESULT fxlvm_chunk_handler (const struct vkd3d_shader_dxbc_section_desc *section, struct d3d10_preshader_parse_context *ctx)
 
static HRESULT parse_fx10_preshader (const char *data, size_t data_size, struct d3d10_effect *effect, struct d3d10_effect_preshader *preshader)
 
static HRESULT d3d10_effect_add_prop_dependency (struct d3d10_effect_prop_dependencies *d, const struct d3d10_effect_prop_dependency *dep)
 
static HRESULT parse_fx10_property_assignment (const char *data, size_t data_size, const char **ptr, enum d3d10_effect_container_type container_type, struct d3d10_effect *effect, void *container, struct d3d10_effect_prop_dependencies *d)
 
static HRESULT parse_fx10_pass (const char *data, size_t data_size, const char **ptr, struct d3d10_effect_pass *p)
 
static HRESULT parse_fx10_technique (const char *data, size_t data_size, const char **ptr, struct d3d10_effect_technique *t)
 
static void parse_fx10_set_default_numeric_value (const char **ptr, struct d3d10_effect_variable *v)
 
static void parse_fx10_default_value (const char **ptr, struct d3d10_effect_variable *var)
 
static void d3d10_effect_variable_update_buffer_offsets (struct d3d10_effect_variable *v, unsigned int offset)
 
static HRESULT parse_fx10_numeric_variable (const char *data, size_t data_size, const char **ptr, BOOL local, struct d3d10_effect_variable *v)
 
static HRESULT create_state_object (struct d3d10_effect_variable *v)
 
static HRESULT parse_fx10_object_variable (const char *data, size_t data_size, const char **ptr, BOOL shared_type_desc, struct d3d10_effect_variable *v)
 
static HRESULT create_buffer_object (struct d3d10_effect_variable *v)
 
static HRESULT parse_fx10_buffer (const char *data, size_t data_size, const char **ptr, BOOL local, struct d3d10_effect_variable *l)
 
static void d3d10_effect_type_member_destroy (struct d3d10_effect_type_member *typem)
 
static void d3d10_effect_type_destroy (struct wine_rb_entry *entry, void *context)
 
static BOOL d3d10_effect_types_match (const struct d3d10_effect_type *t1, const struct d3d10_effect_type *t2)
 
static HRESULT d3d10_effect_validate_shared_variable (const struct d3d10_effect *effect, const struct d3d10_effect_variable *v)
 
static HRESULT parse_fx10_body (struct d3d10_effect *e, const char *data, size_t data_size)
 
static HRESULT parse_fx10 (struct d3d10_effect *e, const char *data, size_t data_size)
 
HRESULT d3d10_effect_parse (struct d3d10_effect *effect, const void *data, SIZE_T data_size)
 
static void d3d10_effect_shader_variable_destroy (struct d3d10_effect_shader_variable *s, D3D10_SHADER_VARIABLE_TYPE type)
 
static void d3d10_effect_annotations_destroy (struct d3d10_effect_annotations *a)
 
static void d3d10_effect_pass_destroy (struct d3d10_effect_pass *p)
 
static void d3d10_effect_technique_destroy (struct d3d10_effect_technique *t)
 
static void d3d10_effect_local_buffer_destroy (struct d3d10_effect_variable *l)
 
static struct d3d10_effect * impl_from_ID3D10Effect (ID3D10Effect *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_QueryInterface (ID3D10Effect *iface, REFIID riid, void **object)
 
static ULONG STDMETHODCALLTYPE d3d10_effect_AddRef (ID3D10Effect *iface)
 
static ULONG STDMETHODCALLTYPE d3d10_effect_Release (ID3D10Effect *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_IsValid (ID3D10Effect *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_IsPool (ID3D10Effect *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_GetDevice (ID3D10Effect *iface, ID3D10Device **device)
 
static void d3d10_effect_get_desc (const struct d3d10_effect *effect, D3D10_EFFECT_DESC *desc)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_GetDesc (ID3D10Effect *iface, D3D10_EFFECT_DESC *desc)
 
static struct d3d10_effect_variable * d3d10_effect_get_buffer_by_index (struct d3d10_effect *effect, unsigned int index)
 
static BOOL is_var_shared (const struct d3d10_effect_variable *v)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_GetConstantBufferByIndex (ID3D10Effect *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_GetConstantBufferByName (ID3D10Effect *iface, const char *name)
 
static struct d3d10_effect_variable * d3d10_effect_get_variable_by_index (const struct d3d10_effect *effect, unsigned int index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_GetVariableByIndex (ID3D10Effect *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_GetVariableByName (ID3D10Effect *iface, const char *name)
 
static struct d3d10_effect_variable * d3d10_effect_get_variable_by_semantic (const struct d3d10_effect *effect, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_GetVariableBySemantic (ID3D10Effect *iface, const char *semantic)
 
static struct ID3D10EffectTechnique *STDMETHODCALLTYPE d3d10_effect_GetTechniqueByIndex (ID3D10Effect *iface, UINT index)
 
static struct ID3D10EffectTechnique *STDMETHODCALLTYPE d3d10_effect_GetTechniqueByName (ID3D10Effect *iface, const char *name)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_Optimize (ID3D10Effect *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_IsOptimized (ID3D10Effect *iface)
 
static struct d3d10_effect_technique * impl_from_ID3D10EffectTechnique (ID3D10EffectTechnique *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_technique_IsValid (ID3D10EffectTechnique *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_technique_GetDesc (ID3D10EffectTechnique *iface, D3D10_TECHNIQUE_DESC *desc)
 
static ID3D10EffectVariable * d3d10_annotation_get_by_index (const struct d3d10_effect_annotations *annotations, unsigned int index)
 
static ID3D10EffectVariable * d3d10_annotation_get_by_name (const struct d3d10_effect_annotations *annotations, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_technique_GetAnnotationByIndex (ID3D10EffectTechnique *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_technique_GetAnnotationByName (ID3D10EffectTechnique *iface, const char *name)
 
static struct ID3D10EffectPass *STDMETHODCALLTYPE d3d10_effect_technique_GetPassByIndex (ID3D10EffectTechnique *iface, UINT index)
 
static struct ID3D10EffectPass *STDMETHODCALLTYPE d3d10_effect_technique_GetPassByName (ID3D10EffectTechnique *iface, const char *name)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_technique_ComputeStateBlockMask (ID3D10EffectTechnique *iface, D3D10_STATE_BLOCK_MASK *mask)
 
static struct d3d10_effect_pass * impl_from_ID3D10EffectPass (ID3D10EffectPass *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_pass_IsValid (ID3D10EffectPass *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetDesc (ID3D10EffectPass *iface, D3D10_PASS_DESC *desc)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetVertexShaderDesc (ID3D10EffectPass *iface, D3D10_PASS_SHADER_DESC *desc)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetGeometryShaderDesc (ID3D10EffectPass *iface, D3D10_PASS_SHADER_DESC *desc)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetPixelShaderDesc (ID3D10EffectPass *iface, D3D10_PASS_SHADER_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_pass_GetAnnotationByIndex (ID3D10EffectPass *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_pass_GetAnnotationByName (ID3D10EffectPass *iface, const char *name)
 
static void update_buffer (ID3D10Device *device, struct d3d10_effect_variable *v)
 
static void set_sampler (ID3D10Device *device, D3D10_SHADER_VARIABLE_TYPE shader_type, struct d3d10_effect_variable *v, unsigned int bind_point)
 
static void apply_shader_resources (ID3D10Device *device, struct d3d10_effect_variable *v)
 
static void d3d10_effect_pass_set_shader (struct d3d10_effect_pass *pass, const struct d3d10_effect_pass_shader_desc *shader_desc)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_Apply (ID3D10EffectPass *iface, UINT flags)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_ComputeStateBlockMask (ID3D10EffectPass *iface, D3D10_STATE_BLOCK_MASK *mask)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_variable_IsValid (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_variable_GetType (ID3D10EffectVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_GetDesc (ID3D10EffectVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetAnnotationByIndex (ID3D10EffectVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetAnnotationByName (ID3D10EffectVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetMemberByIndex (ID3D10EffectVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetMemberByName (ID3D10EffectVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetMemberBySemantic (ID3D10EffectVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetElement (ID3D10EffectVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_variable_GetParentConstantBuffer (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsScalar (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsVector (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsMatrix (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsString (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsShaderResource (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsRenderTargetView (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsDepthStencilView (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_variable_AsConstantBuffer (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsShader (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsBlend (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsDepthStencil (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsRasterizer (ID3D10EffectVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsSampler (ID3D10EffectVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_SetRawValue (ID3D10EffectVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_GetRawValue (ID3D10EffectVariable *iface, void *data, UINT offset, UINT count)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectConstantBuffer (ID3D10EffectConstantBuffer *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_constant_buffer_IsValid (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetType (ID3D10EffectConstantBuffer *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetDesc (ID3D10EffectConstantBuffer *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetAnnotationByIndex (ID3D10EffectConstantBuffer *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetAnnotationByName (ID3D10EffectConstantBuffer *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetMemberByIndex (ID3D10EffectConstantBuffer *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetMemberByName (ID3D10EffectConstantBuffer *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetMemberBySemantic (ID3D10EffectConstantBuffer *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetElement (ID3D10EffectConstantBuffer *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetParentConstantBuffer (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsScalar (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsVector (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsMatrix (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsString (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsShaderResource (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsRenderTargetView (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsDepthStencilView (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsConstantBuffer (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsShader (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsBlend (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsDepthStencil (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsRasterizer (ID3D10EffectConstantBuffer *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsSampler (ID3D10EffectConstantBuffer *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_SetRawValue (ID3D10EffectConstantBuffer *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetRawValue (ID3D10EffectConstantBuffer *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_SetConstantBuffer (ID3D10EffectConstantBuffer *iface, ID3D10Buffer *buffer)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetConstantBuffer (ID3D10EffectConstantBuffer *iface, ID3D10Buffer **buffer)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_SetTextureBuffer (ID3D10EffectConstantBuffer *iface, ID3D10ShaderResourceView *view)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetTextureBuffer (ID3D10EffectConstantBuffer *iface, ID3D10ShaderResourceView **view)
 
static BOOL get_value_as_bool (void *src_data, D3D10_SHADER_VARIABLE_TYPE src_type)
 
static int get_value_as_int (void *src_data, D3D10_SHADER_VARIABLE_TYPE src_type)
 
static float get_value_as_float (void *src_data, D3D10_SHADER_VARIABLE_TYPE src_type)
 
static void get_vector_as_type (BYTE *dst_data, D3D_SHADER_VARIABLE_TYPE dst_type, BYTE *src_data, D3D_SHADER_VARIABLE_TYPE src_type, unsigned int count)
 
static void write_variable_to_buffer (struct d3d10_effect_variable *variable, void *src, D3D_SHADER_VARIABLE_TYPE src_type)
 
static void write_variable_array_to_buffer (struct d3d10_effect_variable *variable, void *src, D3D_SHADER_VARIABLE_TYPE src_type, unsigned int offset, unsigned int count)
 
static void read_variable_from_buffer (struct d3d10_effect_variable *variable, void *dst, D3D_SHADER_VARIABLE_TYPE dst_type)
 
static void read_variable_array_from_buffer (struct d3d10_effect_variable *variable, void *dst, D3D_SHADER_VARIABLE_TYPE dst_type, unsigned int offset, unsigned int count)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectScalarVariable (ID3D10EffectScalarVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_scalar_variable_IsValid (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetType (ID3D10EffectScalarVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetDesc (ID3D10EffectScalarVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetAnnotationByIndex (ID3D10EffectScalarVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetAnnotationByName (ID3D10EffectScalarVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetMemberByIndex (ID3D10EffectScalarVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetMemberByName (ID3D10EffectScalarVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetMemberBySemantic (ID3D10EffectScalarVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetElement (ID3D10EffectScalarVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetParentConstantBuffer (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsScalar (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsVector (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsMatrix (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsString (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsShaderResource (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsRenderTargetView (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsDepthStencilView (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsConstantBuffer (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsShader (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsBlend (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsDepthStencil (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsRasterizer (ID3D10EffectScalarVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsSampler (ID3D10EffectScalarVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetRawValue (ID3D10EffectScalarVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetRawValue (ID3D10EffectScalarVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetFloat (ID3D10EffectScalarVariable *iface, float value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetFloat (ID3D10EffectScalarVariable *iface, float *value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetFloatArray (ID3D10EffectScalarVariable *iface, float *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetFloatArray (ID3D10EffectScalarVariable *iface, float *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetInt (ID3D10EffectScalarVariable *iface, int value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetInt (ID3D10EffectScalarVariable *iface, int *value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetIntArray (ID3D10EffectScalarVariable *iface, int *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetIntArray (ID3D10EffectScalarVariable *iface, int *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetBool (ID3D10EffectScalarVariable *iface, BOOL value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetBool (ID3D10EffectScalarVariable *iface, BOOL *value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetBoolArray (ID3D10EffectScalarVariable *iface, BOOL *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetBoolArray (ID3D10EffectScalarVariable *iface, BOOL *values, UINT offset, UINT count)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectVectorVariable (ID3D10EffectVectorVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_vector_variable_IsValid (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetType (ID3D10EffectVectorVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetDesc (ID3D10EffectVectorVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetAnnotationByIndex (ID3D10EffectVectorVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetAnnotationByName (ID3D10EffectVectorVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetMemberByIndex (ID3D10EffectVectorVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetMemberByName (ID3D10EffectVectorVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetMemberBySemantic (ID3D10EffectVectorVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetElement (ID3D10EffectVectorVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetParentConstantBuffer (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsScalar (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsVector (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsMatrix (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsString (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsShaderResource (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsRenderTargetView (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsDepthStencilView (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsConstantBuffer (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsShader (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsBlend (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsDepthStencil (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsRasterizer (ID3D10EffectVectorVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsSampler (ID3D10EffectVectorVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetRawValue (ID3D10EffectVectorVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetRawValue (ID3D10EffectVectorVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetBoolVector (ID3D10EffectVectorVariable *iface, BOOL *value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetIntVector (ID3D10EffectVectorVariable *iface, int *value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetFloatVector (ID3D10EffectVectorVariable *iface, float *value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetBoolVector (ID3D10EffectVectorVariable *iface, BOOL *value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetIntVector (ID3D10EffectVectorVariable *iface, int *value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetFloatVector (ID3D10EffectVectorVariable *iface, float *value)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetBoolVectorArray (ID3D10EffectVectorVariable *iface, BOOL *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetIntVectorArray (ID3D10EffectVectorVariable *iface, int *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetFloatVectorArray (ID3D10EffectVectorVariable *iface, float *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetBoolVectorArray (ID3D10EffectVectorVariable *iface, BOOL *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetIntVectorArray (ID3D10EffectVectorVariable *iface, int *values, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetFloatVectorArray (ID3D10EffectVectorVariable *iface, float *values, UINT offset, UINT count)
 
static void write_matrix_to_buffer (struct d3d10_effect_variable *variable, void *dst_void, struct d3d10_matrix *src, BOOL transpose)
 
static void write_matrix_variable_to_buffer (struct d3d10_effect_variable *variable, void *src_data, BOOL transpose)
 
static void write_matrix_variable_array_to_buffer (struct d3d10_effect_variable *variable, void *src_data, unsigned int offset, unsigned int count, BOOL transpose)
 
static void read_matrix_from_buffer (struct d3d10_effect_variable *variable, void *src_void, struct d3d10_matrix *dst, BOOL transpose)
 
static void read_matrix_variable_from_buffer (struct d3d10_effect_variable *variable, void *dst, BOOL transpose)
 
static void read_matrix_variable_array_from_buffer (struct d3d10_effect_variable *variable, void *dst_data, UINT offset, UINT count, BOOL transpose)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectMatrixVariable (ID3D10EffectMatrixVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_matrix_variable_IsValid (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetType (ID3D10EffectMatrixVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetDesc (ID3D10EffectMatrixVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetAnnotationByIndex (ID3D10EffectMatrixVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetAnnotationByName (ID3D10EffectMatrixVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMemberByIndex (ID3D10EffectMatrixVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMemberByName (ID3D10EffectMatrixVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMemberBySemantic (ID3D10EffectMatrixVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetElement (ID3D10EffectMatrixVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetParentConstantBuffer (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsScalar (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsVector (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsMatrix (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsString (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsShaderResource (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsRenderTargetView (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsDepthStencilView (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsConstantBuffer (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsShader (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsBlend (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsDepthStencil (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsRasterizer (ID3D10EffectMatrixVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsSampler (ID3D10EffectMatrixVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetRawValue (ID3D10EffectMatrixVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetRawValue (ID3D10EffectMatrixVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetMatrix (ID3D10EffectMatrixVariable *iface, float *data)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMatrix (ID3D10EffectMatrixVariable *iface, float *data)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetMatrixArray (ID3D10EffectMatrixVariable *iface, float *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMatrixArray (ID3D10EffectMatrixVariable *iface, float *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetMatrixTranspose (ID3D10EffectMatrixVariable *iface, float *data)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMatrixTranspose (ID3D10EffectMatrixVariable *iface, float *data)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetMatrixTransposeArray (ID3D10EffectMatrixVariable *iface, float *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMatrixTransposeArray (ID3D10EffectMatrixVariable *iface, float *data, UINT offset, UINT count)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectStringVariable (ID3D10EffectStringVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_string_variable_IsValid (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_string_variable_GetType (ID3D10EffectStringVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_GetDesc (ID3D10EffectStringVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetAnnotationByIndex (ID3D10EffectStringVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetAnnotationByName (ID3D10EffectStringVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetMemberByIndex (ID3D10EffectStringVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetMemberByName (ID3D10EffectStringVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetMemberBySemantic (ID3D10EffectStringVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetElement (ID3D10EffectStringVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_string_variable_GetParentConstantBuffer (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsScalar (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsVector (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsMatrix (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsString (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsShaderResource (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsRenderTargetView (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsDepthStencilView (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_string_variable_AsConstantBuffer (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsShader (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsBlend (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsDepthStencil (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsRasterizer (ID3D10EffectStringVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsSampler (ID3D10EffectStringVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_SetRawValue (ID3D10EffectStringVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_GetRawValue (ID3D10EffectStringVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_GetString (ID3D10EffectStringVariable *iface, const char **str)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_GetStringArray (ID3D10EffectStringVariable *iface, const char **strs, UINT offset, UINT count)
 
static void set_shader_resource_variable (ID3D10ShaderResourceView **src, ID3D10ShaderResourceView **dst)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectShaderResourceVariable (ID3D10EffectShaderResourceVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_IsValid (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetType (ID3D10EffectShaderResourceVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetDesc (ID3D10EffectShaderResourceVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetAnnotationByIndex (ID3D10EffectShaderResourceVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetAnnotationByName (ID3D10EffectShaderResourceVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetMemberByIndex (ID3D10EffectShaderResourceVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetMemberByName (ID3D10EffectShaderResourceVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetMemberBySemantic (ID3D10EffectShaderResourceVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetElement (ID3D10EffectShaderResourceVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetParentConstantBuffer (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsScalar (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsVector (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsMatrix (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsString (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsShaderResource (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsRenderTargetView (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsDepthStencilView (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsConstantBuffer (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsShader (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsBlend (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsDepthStencil (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsRasterizer (ID3D10EffectShaderResourceVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsSampler (ID3D10EffectShaderResourceVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_SetRawValue (ID3D10EffectShaderResourceVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetRawValue (ID3D10EffectShaderResourceVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_SetResource (ID3D10EffectShaderResourceVariable *iface, ID3D10ShaderResourceView *resource)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetResource (ID3D10EffectShaderResourceVariable *iface, ID3D10ShaderResourceView **resource)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_SetResourceArray (ID3D10EffectShaderResourceVariable *iface, ID3D10ShaderResourceView **resources, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetResourceArray (ID3D10EffectShaderResourceVariable *iface, ID3D10ShaderResourceView **resources, UINT offset, UINT count)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectRenderTargetViewVariable (ID3D10EffectRenderTargetViewVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_IsValid (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetType (ID3D10EffectRenderTargetViewVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetDesc (ID3D10EffectRenderTargetViewVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetAnnotationByIndex (ID3D10EffectRenderTargetViewVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetAnnotationByName (ID3D10EffectRenderTargetViewVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetMemberByIndex (ID3D10EffectRenderTargetViewVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetMemberByName (ID3D10EffectRenderTargetViewVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetMemberBySemantic (ID3D10EffectRenderTargetViewVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetElement (ID3D10EffectRenderTargetViewVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetParentConstantBuffer (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsScalar (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsVector (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsMatrix (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsString (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsShaderResource (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsRenderTargetView (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsDepthStencilView (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsConstantBuffer (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsShader (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsBlend (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsDepthStencil (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsRasterizer (ID3D10EffectRenderTargetViewVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsSampler (ID3D10EffectRenderTargetViewVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_SetRawValue (ID3D10EffectRenderTargetViewVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetRawValue (ID3D10EffectRenderTargetViewVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_SetRenderTarget (ID3D10EffectRenderTargetViewVariable *iface, ID3D10RenderTargetView *view)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetRenderTarget (ID3D10EffectRenderTargetViewVariable *iface, ID3D10RenderTargetView **view)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_SetRenderTargetArray (ID3D10EffectRenderTargetViewVariable *iface, ID3D10RenderTargetView **views, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetRenderTargetArray (ID3D10EffectRenderTargetViewVariable *iface, ID3D10RenderTargetView **views, UINT offset, UINT count)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectDepthStencilViewVariable (ID3D10EffectDepthStencilViewVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_IsValid (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetType (ID3D10EffectDepthStencilViewVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetDesc (ID3D10EffectDepthStencilViewVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetAnnotationByIndex (ID3D10EffectDepthStencilViewVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetAnnotationByName (ID3D10EffectDepthStencilViewVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetMemberByIndex (ID3D10EffectDepthStencilViewVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetMemberByName (ID3D10EffectDepthStencilViewVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetMemberBySemantic (ID3D10EffectDepthStencilViewVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetElement (ID3D10EffectDepthStencilViewVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetParentConstantBuffer (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsScalar (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsVector (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsMatrix (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsString (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsShaderResource (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsRenderTargetView (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsDepthStencilView (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsConstantBuffer (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsShader (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsBlend (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsDepthStencil (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsRasterizer (ID3D10EffectDepthStencilViewVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsSampler (ID3D10EffectDepthStencilViewVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_SetRawValue (ID3D10EffectDepthStencilViewVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetRawValue (ID3D10EffectDepthStencilViewVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_SetDepthStencil (ID3D10EffectDepthStencilViewVariable *iface, ID3D10DepthStencilView *view)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetDepthStencil (ID3D10EffectDepthStencilViewVariable *iface, ID3D10DepthStencilView **view)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_SetDepthStencilArray (ID3D10EffectDepthStencilViewVariable *iface, ID3D10DepthStencilView **views, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetDepthStencilArray (ID3D10EffectDepthStencilViewVariable *iface, ID3D10DepthStencilView **views, UINT offset, UINT count)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_shader_variable_IsValid (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetType (ID3D10EffectShaderVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetDesc (ID3D10EffectShaderVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetAnnotationByIndex (ID3D10EffectShaderVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetAnnotationByName (ID3D10EffectShaderVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetMemberByIndex (ID3D10EffectShaderVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetMemberByName (ID3D10EffectShaderVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetMemberBySemantic (ID3D10EffectShaderVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetElement (ID3D10EffectShaderVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetParentConstantBuffer (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsScalar (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsVector (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsMatrix (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsString (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsShaderResource (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsRenderTargetView (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsDepthStencilView (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsConstantBuffer (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsShader (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsBlend (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsDepthStencil (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsRasterizer (ID3D10EffectShaderVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsSampler (ID3D10EffectShaderVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_SetRawValue (ID3D10EffectShaderVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetRawValue (ID3D10EffectShaderVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT d3d10_get_shader_variable (struct d3d10_effect_variable *v, UINT shader_index, struct d3d10_effect_shader_variable **s, D3D10_SHADER_VARIABLE_TYPE *basetype)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetShaderDesc (ID3D10EffectShaderVariable *iface, UINT index, D3D10_EFFECT_SHADER_DESC *desc)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetVertexShader (ID3D10EffectShaderVariable *iface, UINT index, ID3D10VertexShader **shader)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetGeometryShader (ID3D10EffectShaderVariable *iface, UINT index, ID3D10GeometryShader **shader)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetPixelShader (ID3D10EffectShaderVariable *iface, UINT index, ID3D10PixelShader **shader)
 
static HRESULT d3d10_get_shader_variable_signature (struct d3d10_effect_variable *v, UINT shader_index, UINT element_index, BOOL output, D3D10_SIGNATURE_PARAMETER_DESC *desc)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetInputSignatureElementDesc (ID3D10EffectShaderVariable *iface, UINT shader_index, UINT element_index, D3D10_SIGNATURE_PARAMETER_DESC *desc)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetOutputSignatureElementDesc (ID3D10EffectShaderVariable *iface, UINT shader_index, UINT element_index, D3D10_SIGNATURE_PARAMETER_DESC *desc)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectBlendVariable (ID3D10EffectBlendVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_blend_variable_IsValid (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetType (ID3D10EffectBlendVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_GetDesc (ID3D10EffectBlendVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetAnnotationByIndex (ID3D10EffectBlendVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetAnnotationByName (ID3D10EffectBlendVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetMemberByIndex (ID3D10EffectBlendVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetMemberByName (ID3D10EffectBlendVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetMemberBySemantic (ID3D10EffectBlendVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetElement (ID3D10EffectBlendVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetParentConstantBuffer (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsScalar (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsVector (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsMatrix (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsString (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsShaderResource (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsRenderTargetView (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsDepthStencilView (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsConstantBuffer (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsShader (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsBlend (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsDepthStencil (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsRasterizer (ID3D10EffectBlendVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsSampler (ID3D10EffectBlendVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_SetRawValue (ID3D10EffectBlendVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_GetRawValue (ID3D10EffectBlendVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_GetBlendState (ID3D10EffectBlendVariable *iface, UINT index, ID3D10BlendState **blend_state)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_GetBackingStore (ID3D10EffectBlendVariable *iface, UINT index, D3D10_BLEND_DESC *desc)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectDepthStencilVariable (ID3D10EffectDepthStencilVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_IsValid (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetType (ID3D10EffectDepthStencilVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetDesc (ID3D10EffectDepthStencilVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetAnnotationByIndex (ID3D10EffectDepthStencilVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetAnnotationByName (ID3D10EffectDepthStencilVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetMemberByIndex (ID3D10EffectDepthStencilVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetMemberByName (ID3D10EffectDepthStencilVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetMemberBySemantic (ID3D10EffectDepthStencilVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetElement (ID3D10EffectDepthStencilVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetParentConstantBuffer (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsScalar (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsVector (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsMatrix (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsString (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsShaderResource (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsRenderTargetView (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsDepthStencilView (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsConstantBuffer (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsShader (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsBlend (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsDepthStencil (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsRasterizer (ID3D10EffectDepthStencilVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsSampler (ID3D10EffectDepthStencilVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_SetRawValue (ID3D10EffectDepthStencilVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetRawValue (ID3D10EffectDepthStencilVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetDepthStencilState (ID3D10EffectDepthStencilVariable *iface, UINT index, ID3D10DepthStencilState **depth_stencil_state)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetBackingStore (ID3D10EffectDepthStencilVariable *iface, UINT index, D3D10_DEPTH_STENCIL_DESC *desc)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectRasterizerVariable (ID3D10EffectRasterizerVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_IsValid (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetType (ID3D10EffectRasterizerVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetDesc (ID3D10EffectRasterizerVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetAnnotationByIndex (ID3D10EffectRasterizerVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetAnnotationByName (ID3D10EffectRasterizerVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetMemberByIndex (ID3D10EffectRasterizerVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetMemberByName (ID3D10EffectRasterizerVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetMemberBySemantic (ID3D10EffectRasterizerVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetElement (ID3D10EffectRasterizerVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetParentConstantBuffer (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsScalar (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsVector (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsMatrix (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsString (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsShaderResource (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsRenderTargetView (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsDepthStencilView (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsConstantBuffer (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsShader (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsBlend (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsDepthStencil (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsRasterizer (ID3D10EffectRasterizerVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsSampler (ID3D10EffectRasterizerVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_SetRawValue (ID3D10EffectRasterizerVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetRawValue (ID3D10EffectRasterizerVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetRasterizerState (ID3D10EffectRasterizerVariable *iface, UINT index, ID3D10RasterizerState **rasterizer_state)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetBackingStore (ID3D10EffectRasterizerVariable *iface, UINT index, D3D10_RASTERIZER_DESC *desc)
 
static struct d3d10_effect_variable * impl_from_ID3D10EffectSamplerVariable (ID3D10EffectSamplerVariable *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_sampler_variable_IsValid (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetType (ID3D10EffectSamplerVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetDesc (ID3D10EffectSamplerVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetAnnotationByIndex (ID3D10EffectSamplerVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetAnnotationByName (ID3D10EffectSamplerVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetMemberByIndex (ID3D10EffectSamplerVariable *iface, UINT index)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetMemberByName (ID3D10EffectSamplerVariable *iface, const char *name)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetMemberBySemantic (ID3D10EffectSamplerVariable *iface, const char *semantic)
 
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetElement (ID3D10EffectSamplerVariable *iface, UINT index)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetParentConstantBuffer (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsScalar (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsVector (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsMatrix (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsString (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsShaderResource (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsRenderTargetView (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsDepthStencilView (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsConstantBuffer (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsShader (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsBlend (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsDepthStencil (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsRasterizer (ID3D10EffectSamplerVariable *iface)
 
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsSampler (ID3D10EffectSamplerVariable *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_SetRawValue (ID3D10EffectSamplerVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetRawValue (ID3D10EffectSamplerVariable *iface, void *data, UINT offset, UINT count)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetSampler (ID3D10EffectSamplerVariable *iface, UINT index, ID3D10SamplerState **sampler)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetBackingStore (ID3D10EffectSamplerVariable *iface, UINT index, D3D10_SAMPLER_DESC *desc)
 
static struct d3d10_effect_type * impl_from_ID3D10EffectType (ID3D10EffectType *iface)
 
static BOOL STDMETHODCALLTYPE d3d10_effect_type_IsValid (ID3D10EffectType *iface)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_type_GetDesc (ID3D10EffectType *iface, D3D10_EFFECT_TYPE_DESC *desc)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_type_GetMemberTypeByIndex (ID3D10EffectType *iface, UINT index)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_type_GetMemberTypeByName (ID3D10EffectType *iface, const char *name)
 
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_type_GetMemberTypeBySemantic (ID3D10EffectType *iface, const char *semantic)
 
static const char *STDMETHODCALLTYPE d3d10_effect_type_GetMemberName (ID3D10EffectType *iface, UINT index)
 
static const char *STDMETHODCALLTYPE d3d10_effect_type_GetMemberSemantic (ID3D10EffectType *iface, UINT index)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_pool_QueryInterface (ID3D10EffectPool *iface, REFIID riid, void **object)
 
static ULONG STDMETHODCALLTYPE d3d10_effect_pool_AddRef (ID3D10EffectPool *iface)
 
static ULONG STDMETHODCALLTYPE d3d10_effect_pool_Release (ID3D10EffectPool *iface)
 
static ID3D10Effect *STDMETHODCALLTYPE d3d10_effect_pool_AsEffect (ID3D10EffectPool *iface)
 
static int d3d10_effect_type_compare (const void *key, const struct wine_rb_entry *entry)
 
static HRESULT d3d10_create_effect (void *data, SIZE_T data_size, ID3D10Device *device, struct d3d10_effect *pool, unsigned int flags, struct d3d10_effect **effect)
 
HRESULT WINAPI D3D10CreateEffectFromMemory (void *data, SIZE_T data_size, UINT flags, ID3D10Device *device, ID3D10EffectPool *effect_pool, ID3D10Effect **effect)
 
static HRESULT STDMETHODCALLTYPE d3d10_effect_pool_effect_QueryInterface (ID3D10Effect *iface, REFIID riid, void **object)
 
HRESULT WINAPI D3D10CreateEffectPoolFromMemory (void *data, SIZE_T data_size, UINT fx_flags, ID3D10Device *device, ID3D10EffectPool **effect_pool)
 

Variables

const struct ID3D10EffectPoolVtbl d3d10_effect_pool_vtbl
 
static const struct ID3D10EffectVtbl d3d10_effect_pool_effect_vtbl
 
static const struct ID3D10EffectTechniqueVtbl d3d10_effect_technique_vtbl
 
static const struct ID3D10EffectPassVtbl d3d10_effect_pass_vtbl
 
static const struct ID3D10EffectVariableVtbl d3d10_effect_variable_vtbl
 
static const struct ID3D10EffectConstantBufferVtbl d3d10_effect_constant_buffer_vtbl
 
static const struct ID3D10EffectScalarVariableVtbl d3d10_effect_scalar_variable_vtbl
 
static const struct ID3D10EffectVectorVariableVtbl d3d10_effect_vector_variable_vtbl
 
static const struct ID3D10EffectMatrixVariableVtbl d3d10_effect_matrix_variable_vtbl
 
static const struct ID3D10EffectStringVariableVtbl d3d10_effect_string_variable_vtbl
 
static const struct ID3D10EffectShaderResourceVariableVtbl d3d10_effect_shader_resource_variable_vtbl
 
static const struct ID3D10EffectRenderTargetViewVariableVtbl d3d10_effect_render_target_view_variable_vtbl
 
static const struct ID3D10EffectDepthStencilViewVariableVtbl d3d10_effect_depth_stencil_view_variable_vtbl
 
static const struct ID3D10EffectShaderVariableVtbl d3d10_effect_shader_variable_vtbl
 
static const struct ID3D10EffectBlendVariableVtbl d3d10_effect_blend_variable_vtbl
 
static const struct ID3D10EffectDepthStencilVariableVtbl d3d10_effect_depth_stencil_variable_vtbl
 
static const struct ID3D10EffectRasterizerVariableVtbl d3d10_effect_rasterizer_variable_vtbl
 
static const struct ID3D10EffectSamplerVariableVtbl d3d10_effect_sampler_variable_vtbl
 
static const struct ID3D10EffectTypeVtbl d3d10_effect_type_vtbl
 
static struct d3d10_effect_technique null_technique = {{&d3d10_effect_technique_vtbl}}
 
static struct d3d10_effect_pass null_pass = {{&d3d10_effect_pass_vtbl}}
 
static struct d3d10_effect_type null_type = {{&d3d10_effect_type_vtbl}}
 
static struct d3d10_effect_variable null_local_buffer
 
static struct d3d10_effect_variable null_variable
 
static struct d3d10_effect_variable null_scalar_variable
 
static struct d3d10_effect_variable null_vector_variable
 
static struct d3d10_effect_variable null_matrix_variable
 
static struct d3d10_effect_variable null_string_variable
 
static struct d3d10_effect_variable null_render_target_view_variable
 
static struct d3d10_effect_variable null_depth_stencil_view_variable
 
static struct d3d10_effect_variable null_shader_variable
 
static struct d3d10_effect_variable null_blend_variable
 
static struct d3d10_effect_variable null_depth_stencil_variable
 
static struct d3d10_effect_variable null_rasterizer_variable
 
static struct d3d10_effect_variable null_sampler_variable
 
static ID3D10ShaderResourceView * null_srvs [D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT]
 
static struct d3d10_effect_variable null_shader_resource_variable
 
static char anonymous_name [] = "$Anonymous"
 
static char anonymous_vertexshader_name [] = "vertexshader"
 
static char anonymous_pixelshader_name [] = "pixelshader"
 
static char anonymous_geometryshader_name [] = "geometryshader"
 
static struct d3d10_effect_type anonymous_vs_type
 
static struct d3d10_effect_type anonymous_ps_type
 
static struct d3d10_effect_type anonymous_gs_type
 
static struct d3d10_effect_variable anonymous_vs
 
static struct d3d10_effect_variable anonymous_ps
 
static struct d3d10_effect_variable anonymous_gs
 
static const struct preshader_op_info preshader_ops []
 
static const struct d3d10_effect_state_property_info property_infos []
 
static const D3D10_RASTERIZER_DESC default_rasterizer_desc
 
static const D3D10_DEPTH_STENCIL_DESC default_depth_stencil_desc
 
static const D3D10_BLEND_DESC default_blend_desc
 
static const D3D10_SAMPLER_DESC default_sampler_desc
 
static const struct d3d10_effect_state_storage_info d3d10_effect_state_storage_info []
 
static const struct ID3D10EffectVtbl d3d10_effect_vtbl
 

Macro Definition Documentation

◆ MAKE_TAG

#define MAKE_TAG (   ch0,
  ch1,
  ch2,
  ch3 
)
Value:
((DWORD)(ch0) | ((DWORD)(ch1) << 8) | \
((DWORD)(ch2) << 16) | ((DWORD)(ch3) << 24 ))
unsigned long DWORD
Definition: ntddk_ex.h:95
#define DWORD
Definition: nt_native.h:44

Definition at line 29 of file effect.c.

◆ TAG_CLI4

#define TAG_CLI4   MAKE_TAG('C', 'L', 'I', '4')

Definition at line 34 of file effect.c.

◆ TAG_CTAB

#define TAG_CTAB   MAKE_TAG('C', 'T', 'A', 'B')

Definition at line 35 of file effect.c.

◆ TAG_FX10

#define TAG_FX10   MAKE_TAG('F', 'X', '1', '0')

Definition at line 32 of file effect.c.

◆ TAG_FXLC

#define TAG_FXLC   MAKE_TAG('F', 'X', 'L', 'C')

Definition at line 33 of file effect.c.

◆ WINE_D3D10_TO_STR

#define WINE_D3D10_TO_STR (   x)    case x: return #x

Definition at line 1143 of file effect.c.

Typedef Documentation

◆ pres_op_func

typedef void(* pres_op_func) (float **args, unsigned int n, const struct preshader_instr *instr)

Definition at line 194 of file effect.c.

Enumeration Type Documentation

◆ d3d10_effect_container_type

Enumerator
D3D10_C_NONE 
D3D10_C_PASS 
D3D10_C_RASTERIZER 
D3D10_C_DEPTHSTENCIL 
D3D10_C_BLEND 
D3D10_C_SAMPLER 

Definition at line 164 of file effect.c.

165{
172};
@ D3D10_C_NONE
Definition: effect.c:166
@ D3D10_C_PASS
Definition: effect.c:167
@ D3D10_C_SAMPLER
Definition: effect.c:171
@ D3D10_C_DEPTHSTENCIL
Definition: effect.c:169
@ D3D10_C_RASTERIZER
Definition: effect.c:168
@ D3D10_C_BLEND
Definition: effect.c:170

◆ d3d10_reg_table_type

Enumerator
D3D10_REG_TABLE_CONSTANTS 
D3D10_REG_TABLE_CB 
D3D10_REG_TABLE_RESULT 
D3D10_REG_TABLE_TEMP 
D3D10_REG_TABLE_COUNT 

Definition at line 844 of file effect.c.

845{
851};
@ D3D10_REG_TABLE_TEMP
Definition: effect.c:849
@ D3D10_REG_TABLE_RESULT
Definition: effect.c:848
@ D3D10_REG_TABLE_CB
Definition: effect.c:847
@ D3D10_REG_TABLE_CONSTANTS
Definition: effect.c:846
@ D3D10_REG_TABLE_COUNT
Definition: effect.c:850

Function Documentation

◆ apply_shader_resources()

static void apply_shader_resources ( ID3D10Device *  device,
struct d3d10_effect_variable *  v 
)
static

Definition at line 5351 of file effect.c.

5352{
5353 struct d3d10_effect_shader_variable *sv = &v->u.shader;
5355 struct d3d10_effect_variable *rsrc_v;
5357 unsigned int i, j;
5358
5359 for (i = 0; i < sv->resource_count; ++i)
5360 {
5361 sr = &sv->resources[i];
5362 rsrc_v = sr->variable;
5363
5364 switch (sr->in_type)
5365 {
5366 case D3D10_SIT_CBUFFER:
5367 update_buffer(device, rsrc_v);
5368 switch (v->type->basetype)
5369 {
5371 ID3D10Device_VSSetConstantBuffers(device, sr->bind_point, 1,
5372 &rsrc_v->u.buffer.buffer);
5373 break;
5374
5376 ID3D10Device_PSSetConstantBuffers(device, sr->bind_point, 1,
5377 &rsrc_v->u.buffer.buffer);
5378 break;
5379
5381 ID3D10Device_GSSetConstantBuffers(device, sr->bind_point, 1,
5382 &rsrc_v->u.buffer.buffer);
5383 break;
5384
5385 default:
5386 WARN("Incorrect shader type to bind constant buffer.\n");
5387 break;
5388 }
5389 break;
5390
5391 case D3D10_SIT_TEXTURE:
5392
5393 if (rsrc_v->type->basetype == D3D10_SVT_SAMPLER)
5394 {
5395 TRACE("Using texture associated with sampler %s.\n", debugstr_a(rsrc_v->name));
5396 rsrc_v = rsrc_v->u.state.desc.sampler.texture;
5397 }
5398
5399 /* fallthrough */
5400 case D3D10_SIT_TBUFFER:
5401
5402 if (sr->in_type == D3D10_SIT_TBUFFER)
5403 {
5404 update_buffer(device, rsrc_v);
5405 srv = &rsrc_v->u.buffer.resource_view;
5406 }
5407 else
5408 srv = rsrc_v->u.resource.srv;
5409
5410 switch (v->type->basetype)
5411 {
5413 ID3D10Device_VSSetShaderResources(device, sr->bind_point, sr->bind_count, srv);
5414 break;
5415
5417 ID3D10Device_PSSetShaderResources(device, sr->bind_point, sr->bind_count, srv);
5418 break;
5419
5421 ID3D10Device_GSSetShaderResources(device, sr->bind_point, sr->bind_count, srv);
5422 break;
5423
5424 default:
5425 WARN("Incorrect shader type to bind shader resource view.\n");
5426 break;
5427 }
5428 break;
5429
5430 case D3D10_SIT_SAMPLER:
5431 if (!rsrc_v->type->element_count)
5432 {
5433 set_sampler(device, v->type->basetype, rsrc_v, sr->bind_point);
5434 break;
5435 }
5436
5437 for (j = 0; j < sr->bind_count; ++j)
5438 set_sampler(device, v->type->basetype, &rsrc_v->elements[j], sr->bind_point + j);
5439 break;
5440
5441 default:
5442 WARN("Unhandled shader resource %#x.\n", sr->in_type);
5443 break;
5444 }
5445 }
5446}
#define WARN(fmt,...)
Definition: precomp.h:61
@ D3D10_SVT_GEOMETRYSHADER
Definition: d3dcommon.idl:247
@ D3D10_SVT_PIXELSHADER
Definition: d3dcommon.idl:241
@ D3D10_SVT_SAMPLER
Definition: d3dcommon.idl:236
@ D3D10_SVT_VERTEXSHADER
Definition: d3dcommon.idl:242
@ D3D10_SIT_TBUFFER
Definition: d3dcommon.idl:709
@ D3D10_SIT_TEXTURE
Definition: d3dcommon.idl:710
@ D3D10_SIT_CBUFFER
Definition: d3dcommon.idl:708
@ D3D10_SIT_SAMPLER
Definition: d3dcommon.idl:711
static void set_sampler(ID3D10Device *device, D3D10_SHADER_VARIABLE_TYPE shader_type, struct d3d10_effect_variable *v, unsigned int bind_point)
Definition: effect.c:5328
static void update_buffer(ID3D10Device *device, struct d3d10_effect_variable *v)
Definition: effect.c:5315
const GLdouble * v
Definition: gl.h:2040
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
Definition: glfuncs.h:248
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 GLint GLint j
Definition: glfuncs.h:250
#define debugstr_a
Definition: kernel32.h:31
#define TRACE(s)
Definition: solgame.cpp:4
struct d3d10_effect_variable * variable
Definition: d3d10_private.h:71
D3D10_SHADER_INPUT_TYPE in_type
Definition: d3d10_private.h:67
union d3d10_effect_shader_variable::@255 shader
struct d3d10_effect_shader_resource * resources
Definition: d3d10_private.h:96
struct d3d10_effect_resource_variable resource
struct d3d10_effect_variable * elements
union d3d10_effect_variable::@258 u
struct d3d10_effect_type * type
struct d3d10_effect_variable * buffer
struct d3d10_effect_state_object_variable state
Definition: devices.h:37

Referenced by d3d10_effect_pass_set_shader().

◆ copy_name()

static BOOL copy_name ( const char *  ptr,
char **  name 
)
static

Definition at line 1496 of file effect.c.

1497{
1498 if (!ptr || !*ptr) return TRUE;
1499
1500 if (!(*name = strdup(ptr)))
1501 {
1502 ERR("Failed to allocate name memory.\n");
1503 return FALSE;
1504 }
1505
1506 return TRUE;
1507}
#define ERR(fmt,...)
Definition: precomp.h:57
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
static char * strdup(const char *buf)
Definition: string.h:83
static PVOID ptr
Definition: dispmode.c:27
Definition: name.c:39

Referenced by copy_variableinfo_from_type(), parse_fx10_anonymous_shader(), parse_fx10_buffer(), and parse_fx10_type().

◆ copy_variableinfo_from_type()

static HRESULT copy_variableinfo_from_type ( struct d3d10_effect_variable *  v)
static

Definition at line 2248 of file effect.c.

2249{
2250 unsigned int i;
2251 HRESULT hr;
2252
2253 if (v->type->member_count)
2254 {
2255 if (!(v->members = calloc(v->type->member_count, sizeof(*v->members))))
2256 {
2257 ERR("Failed to allocate members memory.\n");
2258 return E_OUTOFMEMORY;
2259 }
2260
2261 for (i = 0; i < v->type->member_count; ++i)
2262 {
2263 struct d3d10_effect_variable *var = &v->members[i];
2264 struct d3d10_effect_type_member *typem = &v->type->members[i];
2265
2266 var->buffer = v->buffer;
2267 var->effect = v->effect;
2268 var->type = typem->type;
2270
2271 if (!copy_name(typem->name, &var->name))
2272 {
2273 ERR("Failed to copy name.\n");
2274 return E_OUTOFMEMORY;
2275 }
2276 TRACE("Variable name: %s.\n", debugstr_a(var->name));
2277
2278 if (!copy_name(typem->semantic, &var->semantic))
2279 {
2280 ERR("Failed to copy name.\n");
2281 return E_OUTOFMEMORY;
2282 }
2283 TRACE("Variable semantic: %s.\n", debugstr_a(var->semantic));
2284
2285 var->buffer_offset = v->buffer_offset + typem->buffer_offset;
2286 TRACE("Variable buffer offset: %u.\n", var->buffer_offset);
2287
2289 if (FAILED(hr)) return hr;
2290 }
2291 }
2292
2293 if (v->type->element_count)
2294 {
2295 unsigned int bufferoffset = v->buffer_offset;
2296
2297 if (!(v->elements = calloc(v->type->element_count, sizeof(*v->elements))))
2298 {
2299 ERR("Failed to allocate elements memory.\n");
2300 return E_OUTOFMEMORY;
2301 }
2302
2303 for (i = 0; i < v->type->element_count; ++i)
2304 {
2305 struct d3d10_effect_variable *var = &v->elements[i];
2306
2307 var->buffer = v->buffer;
2308 var->effect = v->effect;
2309 var->type = v->type->elementtype;
2311
2312 if (!copy_name(v->name, &var->name))
2313 {
2314 ERR("Failed to copy name.\n");
2315 return E_OUTOFMEMORY;
2316 }
2317 TRACE("Variable name: %s.\n", debugstr_a(var->name));
2318
2319 if (!copy_name(v->semantic, &var->semantic))
2320 {
2321 ERR("Failed to copy name.\n");
2322 return E_OUTOFMEMORY;
2323 }
2324 TRACE("Variable semantic: %s.\n", debugstr_a(var->semantic));
2325
2326 if (i != 0)
2327 {
2328 bufferoffset += v->type->stride;
2329 }
2330 var->buffer_offset = bufferoffset;
2331 TRACE("Variable buffer offset: %u.\n", var->buffer_offset);
2332
2334 if (FAILED(hr)) return hr;
2335 }
2336 }
2337
2338 return S_OK;
2339}
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
HRESULT hr
Definition: delayimp.cpp:582
static void set_variable_vtbl(struct d3d10_effect_variable *v)
Definition: effect.c:2161
static HRESULT copy_variableinfo_from_type(struct d3d10_effect_variable *v)
Definition: effect.c:2248
static BOOL copy_name(const char *ptr, char **name)
Definition: effect.c:1496
#define S_OK
Definition: intsafe.h:52
#define FAILED(hr)
Definition: intsafe.h:51
const char * var
Definition: shader.c:5879
#define calloc
Definition: rosglue.h:14
struct d3d10_effect_type * type

Referenced by copy_variableinfo_from_type(), and parse_fx10_variable_head().

◆ create_buffer_object()

static HRESULT create_buffer_object ( struct d3d10_effect_variable *  v)
static

Definition at line 3753 of file effect.c.

3754{
3755 D3D10_BUFFER_DESC buffer_desc;
3756 D3D10_SUBRESOURCE_DATA subresource_data;
3758 ID3D10Device *device = v->effect->device;
3759 HRESULT hr;
3760
3761 buffer_desc.ByteWidth = v->data_size;
3762 buffer_desc.Usage = D3D10_USAGE_DEFAULT;
3763 buffer_desc.CPUAccessFlags = 0;
3764 buffer_desc.MiscFlags = 0;
3765 if (v->type->basetype == D3D10_SVT_CBUFFER)
3767 else
3769
3770 subresource_data.pSysMem = v->u.buffer.local_buffer;
3771 subresource_data.SysMemPitch = 0;
3772 subresource_data.SysMemSlicePitch = 0;
3773
3774 if (FAILED(hr = ID3D10Device_CreateBuffer(device, &buffer_desc, &subresource_data, &v->u.buffer.buffer)))
3775 return hr;
3776
3777 if (v->type->basetype == D3D10_SVT_TBUFFER)
3778 {
3781 srv_desc.Buffer.ElementOffset = 0;
3782 srv_desc.Buffer.ElementWidth = v->type->size_unpacked / 16;
3783 if (v->type->size_unpacked % 16)
3784 WARN("Unexpected texture buffer size not a multiple of 16.\n");
3785
3786 if (FAILED(hr = ID3D10Device_CreateShaderResourceView(device, (ID3D10Resource *)v->u.buffer.buffer,
3787 &srv_desc, &v->u.buffer.resource_view)))
3788 return hr;
3789 }
3790 else
3791 v->u.buffer.resource_view = NULL;
3792
3793 return S_OK;
3794}
@ D3D10_USAGE_DEFAULT
Definition: d3d10.idl:461
@ D3D10_BIND_SHADER_RESOURCE
Definition: d3d10.idl:471
@ D3D10_BIND_CONSTANT_BUFFER
Definition: d3d10.idl:470
@ D3D10_SVT_TBUFFER
Definition: d3dcommon.idl:253
@ D3D10_SVT_CBUFFER
Definition: d3dcommon.idl:252
@ D3D_SRV_DIMENSION_BUFFER
Definition: d3dcommon.idl:550
#define NULL
Definition: types.h:112
@ DXGI_FORMAT_R32G32B32A32_UINT
Definition: dxgiformat.idl:26
D3D10_USAGE Usage
Definition: d3d10.idl:479
UINT CPUAccessFlags
Definition: d3d10.idl:481
UINT ElementOffset
Definition: d3d10.idl:733
UINT ElementWidth
Definition: d3d10.idl:737
D3D10_SRV_DIMENSION ViewDimension
Definition: d3d10.idl:786
D3D10_BUFFER_SRV Buffer
Definition: d3d10.idl:788
const void * pSysMem
Definition: d3d10.idl:810

Referenced by parse_fx10_buffer().

◆ create_state_object()

static HRESULT create_state_object ( struct d3d10_effect_variable *  v)
static

Definition at line 3525 of file effect.c.

3526{
3527 ID3D10Device *device = v->effect->device;
3528 HRESULT hr;
3529
3530 switch (v->type->basetype)
3531 {
3533 if (FAILED(hr = ID3D10Device_CreateDepthStencilState(device,
3534 &v->u.state.desc.depth_stencil, &v->u.state.object.depth_stencil)))
3535 return hr;
3536 break;
3537
3538 case D3D10_SVT_BLEND:
3539 if (FAILED(hr = ID3D10Device_CreateBlendState(device,
3540 &v->u.state.desc.blend, &v->u.state.object.blend)))
3541 return hr;
3542 break;
3543
3545 if (FAILED(hr = ID3D10Device_CreateRasterizerState(device,
3546 &v->u.state.desc.rasterizer, &v->u.state.object.rasterizer)))
3547 return hr;
3548 break;
3549
3550 case D3D10_SVT_SAMPLER:
3551 if (FAILED(hr = ID3D10Device_CreateSamplerState(device,
3552 &v->u.state.desc.sampler.desc, &v->u.state.object.sampler)))
3553 return hr;
3554 break;
3555
3556 default:
3557 ERR("Unhandled variable type %s.\n", debug_d3d10_shader_variable_type(v->type->basetype));
3558 return E_FAIL;
3559 }
3560
3561 return S_OK;
3562}
@ D3D10_SVT_BLEND
Definition: d3dcommon.idl:250
@ D3D10_SVT_RASTERIZER
Definition: d3dcommon.idl:248
@ D3D10_SVT_DEPTHSTENCIL
Definition: d3dcommon.idl:249
#define E_FAIL
Definition: ddrawi.h:102
static const char * debug_d3d10_shader_variable_type(D3D10_SHADER_VARIABLE_TYPE t)
Definition: effect.c:1161

Referenced by parse_fx10_object_variable().

◆ d3d10_annotation_get_by_index()

static ID3D10EffectVariable * d3d10_annotation_get_by_index ( const struct d3d10_effect_annotations *  annotations,
unsigned int  index 
)
static

Definition at line 5029 of file effect.c.

5031{
5032 struct d3d10_effect_variable *a;
5033
5034 if (index >= annotations->count)
5035 {
5036 WARN("Invalid index specified\n");
5037 return &null_variable.ID3D10EffectVariable_iface;
5038 }
5039
5040 a = &annotations->elements[index];
5041
5042 TRACE("Returning annotation %p, name %s.\n", a, debugstr_a(a->name));
5043
5044 return &a->ID3D10EffectVariable_iface;
5045}
#define index(s, c)
Definition: various.h:29
static struct d3d10_effect_variable null_variable
Definition: effect.c:77
GLuint index
Definition: glext.h:6031
GLboolean GLboolean GLboolean GLboolean a
Definition: glext.h:6204
#define a
Definition: ke_i.h:78
struct d3d10_effect_annotations annotations

Referenced by d3d10_effect_pass_GetAnnotationByIndex(), d3d10_effect_technique_GetAnnotationByIndex(), and d3d10_effect_variable_GetAnnotationByIndex().

◆ d3d10_annotation_get_by_name()

static ID3D10EffectVariable * d3d10_annotation_get_by_name ( const struct d3d10_effect_annotations *  annotations,
const char *  name 
)
static

Definition at line 5047 of file effect.c.

5049{
5050 unsigned int i;
5051
5052 for (i = 0; i < annotations->count; ++i)
5053 {
5054 struct d3d10_effect_variable *a = &annotations->elements[i];
5055 if (a->name && !strcmp(a->name, name))
5056 {
5057 TRACE("Returning annotation %p.\n", a);
5058 return &a->ID3D10EffectVariable_iface;
5059 }
5060 }
5061
5062 WARN("Invalid name specified.\n");
5063
5064 return &null_variable.ID3D10EffectVariable_iface;
5065}
_ACRTIMP int __cdecl strcmp(const char *, const char *)
Definition: string.c:3324

Referenced by d3d10_effect_pass_GetAnnotationByName(), d3d10_effect_technique_GetAnnotationByName(), and d3d10_effect_variable_GetAnnotationByName().

◆ d3d10_array_get_element()

static struct d3d10_effect_variable * d3d10_array_get_element ( struct d3d10_effect_variable *  v,
unsigned int  index 
)
static

Definition at line 143 of file effect.c.

145{
146 if (!v->type->element_count) return v;
147 return &v->elements[index];
148}

Referenced by d3d10_effect_pass_GetDesc(), d3d10_effect_pass_set_shader(), d3d10_get_shader_variable(), d3d10_get_state_variable(), parse_fx10_default_value(), and parse_fx10_object_variable().

◆ d3d10_create_effect()

static HRESULT d3d10_create_effect ( void *  data,
SIZE_T  data_size,
ID3D10Device *  device,
struct d3d10_effect *  pool,
unsigned int  flags,
struct d3d10_effect **  effect 
)
static

Definition at line 10097 of file effect.c.

10099{
10100 struct d3d10_effect *object;
10101 HRESULT hr;
10102
10103 if (!device)
10104 return D3DERR_INVALIDCALL;
10105
10106 if (!(object = calloc(1, sizeof(*object))))
10107 return E_OUTOFMEMORY;
10108
10110 object->ID3D10Effect_iface.lpVtbl = flags & D3D10_EFFECT_IS_POOL ?
10112 object->ID3D10EffectPool_iface.lpVtbl = &d3d10_effect_pool_vtbl;
10113 object->refcount = 1;
10114 ID3D10Device_AddRef(device);
10115 object->device = device;
10116 object->pool = pool;
10117 object->flags = flags;
10118 if (pool) IUnknown_AddRef(&pool->ID3D10Effect_iface);
10119
10120 hr = d3d10_effect_parse(object, data, data_size);
10121 if (FAILED(hr))
10122 {
10123 ERR("Failed to parse effect\n");
10124 IUnknown_Release(&object->ID3D10Effect_iface);
10125 return hr;
10126 }
10127
10128 *effect = object;
10129
10130 return S_OK;
10131}
@ D3D10_EFFECT_IS_POOL
#define D3DERR_INVALIDCALL
Definition: d3d10_private.h:42
static const struct ID3D10EffectVtbl d3d10_effect_vtbl
Definition: effect.c:4965
const struct ID3D10EffectPoolVtbl d3d10_effect_pool_vtbl
Definition: effect.c:42
static int d3d10_effect_type_compare(const void *key, const struct wine_rb_entry *entry)
Definition: effect.c:10089
static const struct ID3D10EffectVtbl d3d10_effect_pool_effect_vtbl
Definition: effect.c:50
HRESULT d3d10_effect_parse(struct d3d10_effect *effect, const void *data, SIZE_T data_size)
Definition: effect.c:4308
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
GLbitfield flags
Definition: glext.h:7161
#define wine_rb_init
Definition: rbtree.h:406
struct d3d10_effect * pool
ID3D10Device * device

Referenced by D3D10CreateEffectFromMemory(), and D3D10CreateEffectPoolFromMemory().

◆ d3d10_effect_add_prop_dependency()

static HRESULT d3d10_effect_add_prop_dependency ( struct d3d10_effect_prop_dependencies *  d,
const struct d3d10_effect_prop_dependency *  dep 
)
static

Definition at line 2924 of file effect.c.

2926{
2927 if (!d3d_array_reserve((void **)&d->entries, &d->capacity, d->count + 1, sizeof(*d->entries)))
2928 return E_OUTOFMEMORY;
2929
2930 d->entries[d->count++] = *dep;
2931
2932 return S_OK;
2933}
static BOOL d3d_array_reserve(void **elements, SIZE_T *capacity, SIZE_T count, SIZE_T size)
Definition: effect.c:1413
#define d
Definition: ke_i.h:81

Referenced by parse_fx10_property_assignment().

◆ d3d10_effect_AddRef()

static ULONG STDMETHODCALLTYPE d3d10_effect_AddRef ( ID3D10Effect *  iface)
static

Definition at line 4550 of file effect.c.

4551{
4552 struct d3d10_effect *This = impl_from_ID3D10Effect(iface);
4554
4555 TRACE("%p increasing refcount to %lu.\n", This, refcount);
4556
4557 return refcount;
4558}
#define InterlockedIncrement
Definition: armddk.h:53
static struct d3d10_effect * impl_from_ID3D10Effect(ID3D10Effect *iface)
Definition: effect.c:4527
uint32_t ULONG
Definition: typedefs.h:59

Referenced by d3d10_effect_pool_AddRef().

◆ d3d10_effect_annotations_destroy()

static void d3d10_effect_annotations_destroy ( struct d3d10_effect_annotations *  a)
static

Definition at line 4374 of file effect.c.

4375{
4376 unsigned int i;
4377
4378 if (!a->elements) return;
4379
4380 for (i = 0; i < a->count; ++i)
4381 d3d10_effect_variable_destroy(&a->elements[i]);
4382 free(a->elements);
4383 a->elements = NULL;
4384 a->count = 0;
4385}
#define free
Definition: debug_ros.c:5
static void d3d10_effect_variable_destroy(struct d3d10_effect_variable *v)
Definition: effect.c:4387

Referenced by d3d10_effect_local_buffer_destroy(), d3d10_effect_pass_destroy(), d3d10_effect_technique_destroy(), and d3d10_effect_variable_destroy().

◆ d3d10_effect_blend_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsBlend ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 9024 of file effect.c.

9026{
9028}
static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsBlend(ID3D10EffectVariable *iface)
Definition: effect.c:5840

◆ d3d10_effect_blend_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsConstantBuffer ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 9012 of file effect.c.

9014{
9016}
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_variable_AsConstantBuffer(ID3D10EffectVariable *iface)
Definition: effect.c:5814

◆ d3d10_effect_blend_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsDepthStencil ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 9030 of file effect.c.

9032{
9034}
static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsDepthStencil(ID3D10EffectVariable *iface)
Definition: effect.c:5852

◆ d3d10_effect_blend_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsDepthStencilView ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 9006 of file effect.c.

9008{
9010}
static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsDepthStencilView(ID3D10EffectVariable *iface)
Definition: effect.c:5801

◆ d3d10_effect_blend_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsMatrix ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 8982 of file effect.c.

8984{
8986}
static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsMatrix(ID3D10EffectVariable *iface)
Definition: effect.c:5749

◆ d3d10_effect_blend_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsRasterizer ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 9036 of file effect.c.

9038{
9040}
static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsRasterizer(ID3D10EffectVariable *iface)
Definition: effect.c:5865

◆ d3d10_effect_blend_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsRenderTargetView ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 9000 of file effect.c.

9002{
9004}
static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsRenderTargetView(ID3D10EffectVariable *iface)
Definition: effect.c:5788

◆ d3d10_effect_blend_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsSampler ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 9042 of file effect.c.

9044{
9046}
static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsSampler(ID3D10EffectVariable *iface)
Definition: effect.c:5878

◆ d3d10_effect_blend_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsScalar ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 8970 of file effect.c.

8972{
8974}
static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsScalar(ID3D10EffectVariable *iface)
Definition: effect.c:5723

◆ d3d10_effect_blend_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsShader ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 9018 of file effect.c.

9020{
9022}
static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsShader(ID3D10EffectVariable *iface)
Definition: effect.c:5827

◆ d3d10_effect_blend_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsShaderResource ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 8994 of file effect.c.

8996{
8998}
static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsShaderResource(ID3D10EffectVariable *iface)
Definition: effect.c:5775

◆ d3d10_effect_blend_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsString ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 8988 of file effect.c.

8990{
8992}
static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsString(ID3D10EffectVariable *iface)
Definition: effect.c:5762

◆ d3d10_effect_blend_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_AsVector ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 8976 of file effect.c.

8978{
8980}
static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsVector(ID3D10EffectVariable *iface)
Definition: effect.c:5736

◆ d3d10_effect_blend_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetAnnotationByIndex ( ID3D10EffectBlendVariable *  iface,
UINT  index 
)
static

Definition at line 8928 of file effect.c.

8930{
8932}
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetAnnotationByIndex(ID3D10EffectVariable *iface, UINT index)
Definition: effect.c:5591

◆ d3d10_effect_blend_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetAnnotationByName ( ID3D10EffectBlendVariable *  iface,
const char *  name 
)
static

Definition at line 8934 of file effect.c.

8936{
8938}
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetAnnotationByName(ID3D10EffectVariable *iface, const char *name)
Definition: effect.c:5601

◆ d3d10_effect_blend_variable_GetBackingStore()

static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_GetBackingStore ( ID3D10EffectBlendVariable *  iface,
UINT  index,
D3D10_BLEND_DESC *  desc 
)
static

Definition at line 9084 of file effect.c.

9086{
9088
9089 TRACE("iface %p, index %u, desc %p.\n", iface, index, desc);
9090
9091 if (!iface->lpVtbl->IsValid(iface))
9092 {
9093 WARN("Invalid variable.\n");
9094 return E_FAIL;
9095 }
9096
9097 if (!(v = d3d10_get_state_variable(v, index, &v->effect->blend_states)))
9098 return E_FAIL;
9099
9100 *desc = v->u.state.desc.blend;
9101
9102 return S_OK;
9103}
static struct d3d10_effect_variable * d3d10_get_state_variable(struct d3d10_effect_variable *v, unsigned int index, const struct d3d10_effect_var_array *array)
Definition: effect.c:150
static struct d3d10_effect_variable * impl_from_ID3D10EffectBlendVariable(ID3D10EffectBlendVariable *iface)
Definition: effect.c:8901
D3D11_SHADER_VARIABLE_DESC desc
Definition: reflection.c:1683

◆ d3d10_effect_blend_variable_GetBlendState()

static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_GetBlendState ( ID3D10EffectBlendVariable *  iface,
UINT  index,
ID3D10BlendState **  blend_state 
)
static

Definition at line 9062 of file effect.c.

9064{
9066
9067 TRACE("iface %p, index %u, blend_state %p.\n", iface, index, blend_state);
9068
9069 if (!iface->lpVtbl->IsValid(iface))
9070 {
9071 WARN("Invalid variable.\n");
9072 return E_FAIL;
9073 }
9074
9075 if (!(v = d3d10_get_state_variable(v, index, &v->effect->blend_states)))
9076 return E_FAIL;
9077
9078 if ((*blend_state = v->u.state.object.blend))
9079 ID3D10BlendState_AddRef(*blend_state);
9080
9081 return S_OK;
9082}

◆ d3d10_effect_blend_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_GetDesc ( ID3D10EffectBlendVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 8922 of file effect.c.

8924{
8926}
static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_GetDesc(ID3D10EffectVariable *iface, D3D10_EFFECT_VARIABLE_DESC *desc)
Definition: effect.c:5558

◆ d3d10_effect_blend_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetElement ( ID3D10EffectBlendVariable *  iface,
UINT  index 
)
static

Definition at line 8958 of file effect.c.

8960{
8962}
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetElement(ID3D10EffectVariable *iface, UINT index)
Definition: effect.c:5692

◆ d3d10_effect_blend_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetMemberByIndex ( ID3D10EffectBlendVariable *  iface,
UINT  index 
)
static

Definition at line 8940 of file effect.c.

8942{
8944}
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetMemberByIndex(ID3D10EffectVariable *iface, UINT index)
Definition: effect.c:5611

◆ d3d10_effect_blend_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetMemberByName ( ID3D10EffectBlendVariable *  iface,
const char *  name 
)
static

Definition at line 8946 of file effect.c.

8948{
8950}
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetMemberByName(ID3D10EffectVariable *iface, const char *name)
Definition: effect.c:5632

◆ d3d10_effect_blend_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetMemberBySemantic ( ID3D10EffectBlendVariable *  iface,
const char *  semantic 
)
static

Definition at line 8952 of file effect.c.

8954{
8956}
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetMemberBySemantic(ID3D10EffectVariable *iface, const char *semantic)
Definition: effect.c:5662

◆ d3d10_effect_blend_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetParentConstantBuffer ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 8964 of file effect.c.

8966{
8968}
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_variable_GetParentConstantBuffer(ID3D10EffectVariable *iface)
Definition: effect.c:5713

◆ d3d10_effect_blend_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_GetRawValue ( ID3D10EffectBlendVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 9054 of file effect.c.

9056{
9058}
static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_GetRawValue(ID3D10EffectVariable *iface, void *data, UINT offset, UINT count)
Definition: effect.c:5926
GLuint GLuint GLsizei count
Definition: gl.h:1545
GLintptr offset
Definition: glext.h:5920

◆ d3d10_effect_blend_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_blend_variable_GetType ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 8916 of file effect.c.

8918{
8920}
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_variable_GetType(ID3D10EffectVariable *iface)
Definition: effect.c:5549

◆ d3d10_effect_blend_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_blend_variable_IsValid ( ID3D10EffectBlendVariable *  iface)
static

Definition at line 8907 of file effect.c.

8908{
8910
8911 TRACE("iface %p\n", iface);
8912
8913 return v != &null_blend_variable;
8914}
static struct d3d10_effect_variable null_blend_variable
Definition: effect.c:93

◆ d3d10_effect_blend_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_blend_variable_SetRawValue ( ID3D10EffectBlendVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 9048 of file effect.c.

9050{
9052}
static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_SetRawValue(ID3D10EffectVariable *iface, void *data, UINT offset, UINT count)
Definition: effect.c:5891

◆ d3d10_effect_cleanup_so_decl()

static void d3d10_effect_cleanup_so_decl ( struct d3d10_effect_so_decl *  so_decl)
static

Definition at line 1617 of file effect.c.

1618{
1619 free(so_decl->entries);
1620 free(so_decl->decl);
1621 memset(so_decl, 0, sizeof(*so_decl));
1622}
#define memset(x, y, z)
Definition: compat.h:39
D3D10_SO_DECLARATION_ENTRY * entries
Definition: effect.c:1610

Referenced by d3d10_effect_parse_stream_output_declaration(), and parse_fx10_shader().

◆ d3d10_effect_clear_prop_dependencies()

static void d3d10_effect_clear_prop_dependencies ( struct d3d10_effect_prop_dependencies *  d)
static

Definition at line 976 of file effect.c.

977{
978 unsigned int i;
979
980 for (i = 0; i < d->count; ++i)
981 {
982 struct d3d10_effect_prop_dependency *dep = &d->entries[i];
983 switch (dep->operation)
984 {
987 break;
990 break;
991 }
992 }
993 free(d->entries);
994 memset(d, 0, sizeof(*d));
995}
@ D3D10_EOO_VALUE_EXPRESSION
Definition: d3d10_private.h:56
@ D3D10_EOO_INDEX_EXPRESSION
Definition: d3d10_private.h:55
static void d3d10_effect_preshader_clear(struct d3d10_effect_preshader *p)
Definition: effect.c:901
struct d3d10_effect_prop_dependency::@261::@265 value_expr
unsigned int operation
Definition: effect.c:873
struct d3d10_effect_prop_dependency::@261::@264 index_expr

Referenced by d3d10_effect_pass_destroy(), and d3d10_effect_variable_destroy().

◆ d3d10_effect_constant_buffer_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsBlend ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6094 of file effect.c.

6095{
6097}

◆ d3d10_effect_constant_buffer_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsConstantBuffer ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6082 of file effect.c.

◆ d3d10_effect_constant_buffer_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsDepthStencil ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6099 of file effect.c.

6101{
6103}

◆ d3d10_effect_constant_buffer_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsDepthStencilView ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6076 of file effect.c.

◆ d3d10_effect_constant_buffer_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsMatrix ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6052 of file effect.c.

6054{
6056}

◆ d3d10_effect_constant_buffer_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsRasterizer ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6105 of file effect.c.

6107{
6109}

◆ d3d10_effect_constant_buffer_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsRenderTargetView ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6070 of file effect.c.

◆ d3d10_effect_constant_buffer_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsSampler ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6111 of file effect.c.

6113{
6115}

◆ d3d10_effect_constant_buffer_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsScalar ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6040 of file effect.c.

6042{
6044}

◆ d3d10_effect_constant_buffer_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsShader ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6088 of file effect.c.

6090{
6092}

◆ d3d10_effect_constant_buffer_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsShaderResource ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6064 of file effect.c.

◆ d3d10_effect_constant_buffer_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsString ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6058 of file effect.c.

6060{
6062}

◆ d3d10_effect_constant_buffer_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsVector ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6046 of file effect.c.

6048{
6050}

◆ d3d10_effect_constant_buffer_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetAnnotationByIndex ( ID3D10EffectConstantBuffer *  iface,
UINT  index 
)
static

Definition at line 5998 of file effect.c.

◆ d3d10_effect_constant_buffer_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetAnnotationByName ( ID3D10EffectConstantBuffer *  iface,
const char *  name 
)
static

Definition at line 6004 of file effect.c.

◆ d3d10_effect_constant_buffer_GetConstantBuffer()

static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetConstantBuffer ( ID3D10EffectConstantBuffer *  iface,
ID3D10Buffer **  buffer 
)
static

Definition at line 6138 of file effect.c.

6140{
6142
6143 TRACE("iface %p, buffer %p.\n", iface, buffer);
6144
6145 if (!iface->lpVtbl->IsValid(iface))
6146 {
6147 WARN("Null variable specified.\n");
6148 return E_FAIL;
6149 }
6150
6151 if (v->type->basetype != D3D10_SVT_CBUFFER)
6152 {
6153 WARN("Wrong variable type %s.\n", debug_d3d10_shader_variable_type(v->type->basetype));
6154 return D3DERR_INVALIDCALL;
6155 }
6156
6157 *buffer = v->u.buffer.buffer;
6158 ID3D10Buffer_AddRef(*buffer);
6159
6160 return S_OK;
6161}
static struct d3d10_effect_variable * impl_from_ID3D10EffectConstantBuffer(ID3D10EffectConstantBuffer *iface)
Definition: effect.c:5973
GLuint buffer
Definition: glext.h:5915

◆ d3d10_effect_constant_buffer_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetDesc ( ID3D10EffectConstantBuffer *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 5992 of file effect.c.

5994{
5996}

◆ d3d10_effect_constant_buffer_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetElement ( ID3D10EffectConstantBuffer *  iface,
UINT  index 
)
static

Definition at line 6028 of file effect.c.

6030{
6032}

◆ d3d10_effect_constant_buffer_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetMemberByIndex ( ID3D10EffectConstantBuffer *  iface,
UINT  index 
)
static

Definition at line 6010 of file effect.c.

◆ d3d10_effect_constant_buffer_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetMemberByName ( ID3D10EffectConstantBuffer *  iface,
const char *  name 
)
static

Definition at line 6016 of file effect.c.

◆ d3d10_effect_constant_buffer_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetMemberBySemantic ( ID3D10EffectConstantBuffer *  iface,
const char *  semantic 
)
static

Definition at line 6022 of file effect.c.

6024{
6026}

◆ d3d10_effect_constant_buffer_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetParentConstantBuffer ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 6034 of file effect.c.

◆ d3d10_effect_constant_buffer_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetRawValue ( ID3D10EffectConstantBuffer *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 6123 of file effect.c.

◆ d3d10_effect_constant_buffer_GetTextureBuffer()

static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetTextureBuffer ( ID3D10EffectConstantBuffer *  iface,
ID3D10ShaderResourceView **  view 
)
static

Definition at line 6171 of file effect.c.

6173{
6175
6176 FIXME("iface %p, view %p stub!\n", iface, view);
6177
6178 if (!iface->lpVtbl->IsValid(iface))
6179 {
6180 WARN("Null variable specified.\n");
6181 return E_FAIL;
6182 }
6183
6184 if (v->type->basetype != D3D10_SVT_TBUFFER)
6185 {
6186 WARN("Wrong variable type %s.\n", debug_d3d10_shader_variable_type(v->type->basetype));
6187 return D3DERR_INVALIDCALL;
6188 }
6189
6190 return E_NOTIMPL;
6191}
#define FIXME(fmt,...)
Definition: precomp.h:53
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ d3d10_effect_constant_buffer_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetType ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 5987 of file effect.c.

5988{
5990}

◆ d3d10_effect_constant_buffer_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_constant_buffer_IsValid ( ID3D10EffectConstantBuffer *  iface)
static

Definition at line 5978 of file effect.c.

5979{
5981
5982 TRACE("iface %p.\n", iface);
5983
5984 return v != &null_local_buffer;
5985}
static struct d3d10_effect_variable null_local_buffer
Definition: effect.c:75

◆ d3d10_effect_constant_buffer_SetConstantBuffer()

static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_SetConstantBuffer ( ID3D10EffectConstantBuffer *  iface,
ID3D10Buffer *  buffer 
)
static

Definition at line 6130 of file effect.c.

6132{
6133 FIXME("iface %p, buffer %p stub!\n", iface, buffer);
6134
6135 return E_NOTIMPL;
6136}

◆ d3d10_effect_constant_buffer_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_SetRawValue ( ID3D10EffectConstantBuffer *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 6117 of file effect.c.

◆ d3d10_effect_constant_buffer_SetTextureBuffer()

static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_SetTextureBuffer ( ID3D10EffectConstantBuffer *  iface,
ID3D10ShaderResourceView *  view 
)
static

Definition at line 6163 of file effect.c.

6165{
6166 FIXME("iface %p, view %p stub!\n", iface, view);
6167
6168 return E_NOTIMPL;
6169}

◆ d3d10_effect_depth_stencil_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsBlend ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9263 of file effect.c.

9265{
9267}

◆ d3d10_effect_depth_stencil_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsConstantBuffer ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9251 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsDepthStencil ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9269 of file effect.c.

9271{
9273}

◆ d3d10_effect_depth_stencil_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsDepthStencilView ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9245 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsMatrix ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9221 of file effect.c.

9223{
9225}

◆ d3d10_effect_depth_stencil_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsRasterizer ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9275 of file effect.c.

9277{
9279}

◆ d3d10_effect_depth_stencil_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsRenderTargetView ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9239 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsSampler ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9281 of file effect.c.

9283{
9285}

◆ d3d10_effect_depth_stencil_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsScalar ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9209 of file effect.c.

9211{
9213}

◆ d3d10_effect_depth_stencil_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsShader ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9257 of file effect.c.

9259{
9261}

◆ d3d10_effect_depth_stencil_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsShaderResource ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9233 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsString ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9227 of file effect.c.

9229{
9231}

◆ d3d10_effect_depth_stencil_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_AsVector ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9215 of file effect.c.

9217{
9219}

◆ d3d10_effect_depth_stencil_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetAnnotationByIndex ( ID3D10EffectDepthStencilVariable *  iface,
UINT  index 
)
static

Definition at line 9167 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetAnnotationByName ( ID3D10EffectDepthStencilVariable *  iface,
const char *  name 
)
static

Definition at line 9173 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_GetBackingStore()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetBackingStore ( ID3D10EffectDepthStencilVariable *  iface,
UINT  index,
D3D10_DEPTH_STENCIL_DESC *  desc 
)
static

Definition at line 9323 of file effect.c.

9325{
9327
9328 TRACE("iface %p, index %u, desc %p.\n", iface, index, desc);
9329
9330 if (!iface->lpVtbl->IsValid(iface))
9331 {
9332 WARN("Invalid variable.\n");
9333 return E_FAIL;
9334 }
9335
9336 if (!(v = d3d10_get_state_variable(v, index, &v->effect->ds_states)))
9337 return E_FAIL;
9338
9339 d3d10_effect_update_dependent_props(&v->u.state.dependencies, &v->u.state.desc);
9340
9341 *desc = v->u.state.desc.depth_stencil;
9342
9343 return S_OK;
9344}
static struct d3d10_effect_variable * impl_from_ID3D10EffectDepthStencilVariable(ID3D10EffectDepthStencilVariable *iface)
Definition: effect.c:9140
static void d3d10_effect_update_dependent_props(struct d3d10_effect_prop_dependencies *deps, void *container)
Definition: effect.c:1306

◆ d3d10_effect_depth_stencil_variable_GetDepthStencilState()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetDepthStencilState ( ID3D10EffectDepthStencilVariable *  iface,
UINT  index,
ID3D10DepthStencilState **  depth_stencil_state 
)
static

Definition at line 9301 of file effect.c.

9303{
9305
9306 TRACE("iface %p, index %u, depth_stencil_state %p.\n", iface, index, depth_stencil_state);
9307
9308 if (!iface->lpVtbl->IsValid(iface))
9309 {
9310 WARN("Invalid variable.\n");
9311 return E_FAIL;
9312 }
9313
9314 if (!(v = d3d10_get_state_variable(v, index, &v->effect->ds_states)))
9315 return E_FAIL;
9316
9317 if ((*depth_stencil_state = v->u.state.object.depth_stencil))
9318 ID3D10DepthStencilState_AddRef(*depth_stencil_state);
9319
9320 return S_OK;
9321}

◆ d3d10_effect_depth_stencil_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetDesc ( ID3D10EffectDepthStencilVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 9161 of file effect.c.

9163{
9165}

◆ d3d10_effect_depth_stencil_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetElement ( ID3D10EffectDepthStencilVariable *  iface,
UINT  index 
)
static

Definition at line 9197 of file effect.c.

9199{
9201}

◆ d3d10_effect_depth_stencil_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetMemberByIndex ( ID3D10EffectDepthStencilVariable *  iface,
UINT  index 
)
static

Definition at line 9179 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetMemberByName ( ID3D10EffectDepthStencilVariable *  iface,
const char *  name 
)
static

Definition at line 9185 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetMemberBySemantic ( ID3D10EffectDepthStencilVariable *  iface,
const char *  semantic 
)
static

Definition at line 9191 of file effect.c.

9193{
9195}

◆ d3d10_effect_depth_stencil_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetParentConstantBuffer ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9203 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetRawValue ( ID3D10EffectDepthStencilVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 9293 of file effect.c.

◆ d3d10_effect_depth_stencil_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_GetType ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9155 of file effect.c.

9157{
9159}

◆ d3d10_effect_depth_stencil_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_IsValid ( ID3D10EffectDepthStencilVariable *  iface)
static

Definition at line 9146 of file effect.c.

9147{
9149
9150 TRACE("iface %p\n", iface);
9151
9152 return v != &null_depth_stencil_variable;
9153}
static struct d3d10_effect_variable null_depth_stencil_variable
Definition: effect.c:95

◆ d3d10_effect_depth_stencil_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_variable_SetRawValue ( ID3D10EffectDepthStencilVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 9287 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsBlend ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8395 of file effect.c.

8397{
8399}

◆ d3d10_effect_depth_stencil_view_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsConstantBuffer ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8383 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsDepthStencil ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8401 of file effect.c.

8403{
8405}

◆ d3d10_effect_depth_stencil_view_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsDepthStencilView ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8377 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsMatrix ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8353 of file effect.c.

8355{
8357}

◆ d3d10_effect_depth_stencil_view_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsRasterizer ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8407 of file effect.c.

8409{
8411}

◆ d3d10_effect_depth_stencil_view_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsRenderTargetView ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8371 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsSampler ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8413 of file effect.c.

8415{
8417}

◆ d3d10_effect_depth_stencil_view_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsScalar ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8341 of file effect.c.

8343{
8345}

◆ d3d10_effect_depth_stencil_view_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsShader ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8389 of file effect.c.

8391{
8393}

◆ d3d10_effect_depth_stencil_view_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsShaderResource ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8365 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsString ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8359 of file effect.c.

8361{
8363}

◆ d3d10_effect_depth_stencil_view_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_AsVector ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8347 of file effect.c.

8349{
8351}

◆ d3d10_effect_depth_stencil_view_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetAnnotationByIndex ( ID3D10EffectDepthStencilViewVariable *  iface,
UINT  index 
)
static

Definition at line 8299 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetAnnotationByName ( ID3D10EffectDepthStencilViewVariable *  iface,
const char *  name 
)
static

Definition at line 8305 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_GetDepthStencil()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetDepthStencil ( ID3D10EffectDepthStencilViewVariable *  iface,
ID3D10DepthStencilView **  view 
)
static

Definition at line 8441 of file effect.c.

8443{
8444 FIXME("iface %p, view %p stub!\n", iface, view);
8445
8446 return E_NOTIMPL;
8447}

◆ d3d10_effect_depth_stencil_view_variable_GetDepthStencilArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetDepthStencilArray ( ID3D10EffectDepthStencilViewVariable *  iface,
ID3D10DepthStencilView **  views,
UINT  offset,
UINT  count 
)
static

Definition at line 8457 of file effect.c.

8459{
8460 FIXME("iface %p, views %p, offset %u, count %u stub!\n", iface, views, offset, count);
8461
8462 return E_NOTIMPL;
8463}

◆ d3d10_effect_depth_stencil_view_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetDesc ( ID3D10EffectDepthStencilViewVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 8293 of file effect.c.

8295{
8297}

◆ d3d10_effect_depth_stencil_view_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetElement ( ID3D10EffectDepthStencilViewVariable *  iface,
UINT  index 
)
static

Definition at line 8329 of file effect.c.

8331{
8333}

◆ d3d10_effect_depth_stencil_view_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetMemberByIndex ( ID3D10EffectDepthStencilViewVariable *  iface,
UINT  index 
)
static

Definition at line 8311 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetMemberByName ( ID3D10EffectDepthStencilViewVariable *  iface,
const char *  name 
)
static

Definition at line 8317 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetMemberBySemantic ( ID3D10EffectDepthStencilViewVariable *  iface,
const char *  semantic 
)
static

Definition at line 8323 of file effect.c.

8325{
8327}

◆ d3d10_effect_depth_stencil_view_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetParentConstantBuffer ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8335 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetRawValue ( ID3D10EffectDepthStencilViewVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 8425 of file effect.c.

◆ d3d10_effect_depth_stencil_view_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_GetType ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8287 of file effect.c.

8289{
8291}

◆ d3d10_effect_depth_stencil_view_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_IsValid ( ID3D10EffectDepthStencilViewVariable *  iface)
static

Definition at line 8277 of file effect.c.

8279{
8281
8282 TRACE("iface %p\n", iface);
8283
8285}
static struct d3d10_effect_variable null_depth_stencil_view_variable
Definition: effect.c:89
static struct d3d10_effect_variable * impl_from_ID3D10EffectDepthStencilViewVariable(ID3D10EffectDepthStencilViewVariable *iface)
Definition: effect.c:8271

◆ d3d10_effect_depth_stencil_view_variable_SetDepthStencil()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_SetDepthStencil ( ID3D10EffectDepthStencilViewVariable *  iface,
ID3D10DepthStencilView *  view 
)
static

Definition at line 8433 of file effect.c.

8435{
8436 FIXME("iface %p, view %p stub!\n", iface, view);
8437
8438 return E_NOTIMPL;
8439}

◆ d3d10_effect_depth_stencil_view_variable_SetDepthStencilArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_SetDepthStencilArray ( ID3D10EffectDepthStencilViewVariable *  iface,
ID3D10DepthStencilView **  views,
UINT  offset,
UINT  count 
)
static

Definition at line 8449 of file effect.c.

8451{
8452 FIXME("iface %p, views %p, offset %u, count %u stub!\n", iface, views, offset, count);
8453
8454 return E_NOTIMPL;
8455}

◆ d3d10_effect_depth_stencil_view_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_depth_stencil_view_variable_SetRawValue ( ID3D10EffectDepthStencilViewVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 8419 of file effect.c.

◆ d3d10_effect_get_buffer_by_index()

static struct d3d10_effect_variable * d3d10_effect_get_buffer_by_index ( struct d3d10_effect *  effect,
unsigned int  index 
)
static

Definition at line 4688 of file effect.c.

4690{
4691 if (index < effect->local_buffer_count)
4692 return &effect->local_buffers[index];
4693 index -= effect->local_buffer_count;
4694
4695 return effect->pool ? d3d10_effect_get_buffer_by_index(effect->pool, index) : NULL;
4696}
static struct d3d10_effect_variable * d3d10_effect_get_buffer_by_index(struct d3d10_effect *effect, unsigned int index)
Definition: effect.c:4688
unsigned int local_buffer_count
struct d3d10_effect_variable * local_buffers

Referenced by d3d10_effect_get_buffer_by_index(), and d3d10_effect_GetConstantBufferByIndex().

◆ d3d10_effect_get_buffer_by_name()

static struct d3d10_effect_variable * d3d10_effect_get_buffer_by_name ( struct d3d10_effect *  effect,
const char *  name 
)
static

Definition at line 1509 of file effect.c.

1511{
1512 unsigned int i;
1513
1514 for (i = 0; i < effect->local_buffer_count; ++i)
1515 {
1516 struct d3d10_effect_variable *l = &effect->local_buffers[i];
1517 if (l->name && !strcmp(l->name, name))
1518 return l;
1519 }
1520
1521 return effect->pool ? d3d10_effect_get_buffer_by_name(effect->pool, name) : NULL;
1522}
r l[0]
Definition: byte_order.h:168
static struct d3d10_effect_variable * d3d10_effect_get_buffer_by_name(struct d3d10_effect *effect, const char *name)
Definition: effect.c:1509
struct d3d10_effect * effect

Referenced by d3d10_effect_get_buffer_by_name(), d3d10_effect_GetConstantBufferByName(), d3d10_effect_validate_shared_variable(), and get_fx10_shader_resources().

◆ d3d10_effect_get_desc()

static void d3d10_effect_get_desc ( const struct d3d10_effect *  effect,
D3D10_EFFECT_DESC *  desc 
)
static

Definition at line 4657 of file effect.c.

4658{
4659 desc->IsChildEffect = !!effect->pool;
4660 desc->ConstantBuffers = effect->local_buffer_count;
4661 desc->SharedConstantBuffers = 0;
4662 desc->GlobalVariables = effect->object_count + effect->numeric_variable_count;
4663 desc->SharedGlobalVariables = 0;
4664 desc->Techniques = effect->technique_count;
4665}
unsigned int numeric_variable_count
unsigned int object_count
unsigned int technique_count

Referenced by d3d10_effect_GetDesc().

◆ d3d10_effect_get_op_info()

static const struct preshader_op_info * d3d10_effect_get_op_info ( int  opcode)
static

Definition at line 821 of file effect.c.

822{
823 return bsearch(&opcode, preshader_ops, ARRAY_SIZE(preshader_ops), sizeof(*preshader_ops),
825}
#define ARRAY_SIZE(A)
Definition: main.h:20
static const struct preshader_op_info preshader_ops[]
Definition: effect.c:761
static int __cdecl preshader_op_compare(const void *a, const void *b)
Definition: effect.c:814
#define bsearch

Referenced by d3d10_effect_preshader_eval(), and parse_fx10_preshader_instr().

◆ d3d10_effect_get_variable_by_index()

static struct d3d10_effect_variable * d3d10_effect_get_variable_by_index ( const struct d3d10_effect *  effect,
unsigned int  index 
)
static

Definition at line 4742 of file effect.c.

4744{
4745 unsigned int i;
4746
4747 for (i = 0; i < effect->local_buffer_count; ++i)
4748 {
4749 struct d3d10_effect_variable *v = &effect->local_buffers[i];
4750 if (index < v->type->member_count)
4751 return &v->members[index];
4752 index -= v->type->member_count;
4753 }
4754
4755 if (index < effect->object_count)
4756 return &effect->object_variables[index];
4757 index -= effect->object_count;
4758
4760}
static struct d3d10_effect_variable * d3d10_effect_get_variable_by_index(const struct d3d10_effect *effect, unsigned int index)
Definition: effect.c:4742
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
long object_count
Definition: nc_alloc.cpp:37

Referenced by d3d10_effect_get_variable_by_index(), and d3d10_effect_GetVariableByIndex().

◆ d3d10_effect_get_variable_by_name()

static struct d3d10_effect_variable * d3d10_effect_get_variable_by_name ( const struct d3d10_effect *  effect,
const char *  name 
)
static

Definition at line 1524 of file effect.c.

1526{
1527 struct d3d10_effect_variable *v;
1528 unsigned int i, j;
1529
1530 for (i = 0; i < effect->local_buffer_count; ++i)
1531 {
1532 for (j = 0; j < effect->local_buffers[i].type->member_count; ++j)
1533 {
1534 v = &effect->local_buffers[i].members[j];
1535 if (v->name && !strcmp(v->name, name))
1536 return v;
1537 }
1538 }
1539
1540 for (i = 0; i < effect->object_count; ++i)
1541 {
1542 struct d3d10_effect_variable *v = &effect->object_variables[i];
1543 if (v->name && !strcmp(v->name, name))
1544 return v;
1545 }
1546
1547 return effect->pool ? d3d10_effect_get_variable_by_name(effect->pool, name) : NULL;
1548}
static struct d3d10_effect_variable * d3d10_effect_get_variable_by_name(const struct d3d10_effect *effect, const char *name)
Definition: effect.c:1524

Referenced by d3d10_effect_get_variable_by_name(), d3d10_effect_GetVariableByName(), d3d10_effect_validate_shared_variable(), get_fx10_shader_resources(), parse_fx10_ctab(), and parse_fx10_property_assignment().

◆ d3d10_effect_get_variable_by_semantic()

static struct d3d10_effect_variable * d3d10_effect_get_variable_by_semantic ( const struct d3d10_effect *  effect,
const char *  semantic 
)
static

Definition at line 4805 of file effect.c.

4807{
4808 unsigned int i;
4809
4810 for (i = 0; i < effect->local_buffer_count; ++i)
4811 {
4812 struct d3d10_effect_variable *l = &effect->local_buffers[i];
4813 unsigned int j;
4814
4815 for (j = 0; j < l->type->member_count; ++j)
4816 {
4817 struct d3d10_effect_variable *v = &l->members[j];
4818
4819 if (v->semantic && !stricmp(v->semantic, semantic))
4820 return v;
4821 }
4822 }
4823
4824 for (i = 0; i < effect->object_count; ++i)
4825 {
4826 struct d3d10_effect_variable *v = &effect->object_variables[i];
4827
4828 if (v->semantic && !stricmp(v->semantic, semantic))
4829 return v;
4830 }
4831
4833}
static struct d3d10_effect_variable * d3d10_effect_get_variable_by_semantic(const struct d3d10_effect *effect, const char *semantic)
Definition: effect.c:4805
#define stricmp(_String1, _String2)
Definition: compat.h:24

Referenced by d3d10_effect_get_variable_by_semantic(), and d3d10_effect_GetVariableBySemantic().

◆ d3d10_effect_GetConstantBufferByIndex()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_GetConstantBufferByIndex ( ID3D10Effect *  iface,
UINT  index 
)
static

Definition at line 4703 of file effect.c.

4705{
4706 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4707 struct d3d10_effect_variable *v;
4708
4709 TRACE("iface %p, index %u\n", iface, index);
4710
4712 {
4713 TRACE("Returning %sbuffer %p, name %s.\n", is_var_shared(v) ? "shared " : "", v,
4714 debugstr_a(v->name));
4715 return (ID3D10EffectConstantBuffer *)&v->ID3D10EffectVariable_iface;
4716 }
4717
4718 WARN("Invalid index specified\n");
4719
4720 return (ID3D10EffectConstantBuffer *)&null_local_buffer.ID3D10EffectVariable_iface;
4721}
static BOOL is_var_shared(const struct d3d10_effect_variable *v)
Definition: effect.c:4698

◆ d3d10_effect_GetConstantBufferByName()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_GetConstantBufferByName ( ID3D10Effect *  iface,
const char *  name 
)
static

Definition at line 4723 of file effect.c.

4725{
4726 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4727 struct d3d10_effect_variable *v;
4728
4729 TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
4730
4732 {
4733 TRACE("Returning %sbuffer %p.\n", is_var_shared(v) ? "shared " : "", v);
4734 return (ID3D10EffectConstantBuffer *)&v->ID3D10EffectVariable_iface;
4735 }
4736
4737 WARN("Invalid name specified\n");
4738
4739 return (ID3D10EffectConstantBuffer *)&null_local_buffer.ID3D10EffectVariable_iface;
4740}

◆ d3d10_effect_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_GetDesc ( ID3D10Effect *  iface,
D3D10_EFFECT_DESC *  desc 
)
static

Definition at line 4667 of file effect.c.

4668{
4669 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4670 D3D10_EFFECT_DESC pool_desc = { 0 };
4671
4672 TRACE("iface %p, desc %p.\n", iface, desc);
4673
4674 if (!desc)
4675 return E_INVALIDARG;
4676
4677 if (effect->pool)
4678 d3d10_effect_get_desc(effect->pool, &pool_desc);
4679
4680 d3d10_effect_get_desc(effect, desc);
4681
4682 desc->SharedConstantBuffers = pool_desc.ConstantBuffers;
4683 desc->SharedGlobalVariables = pool_desc.GlobalVariables;
4684
4685 return S_OK;
4686}
#define E_INVALIDARG
Definition: ddrawi.h:101
static void d3d10_effect_get_desc(const struct d3d10_effect *effect, D3D10_EFFECT_DESC *desc)
Definition: effect.c:4657

◆ d3d10_effect_GetDevice()

static HRESULT STDMETHODCALLTYPE d3d10_effect_GetDevice ( ID3D10Effect *  iface,
ID3D10Device **  device 
)
static

Definition at line 4645 of file effect.c.

4646{
4647 struct d3d10_effect *This = impl_from_ID3D10Effect(iface);
4648
4649 TRACE("iface %p, device %p\n", iface, device);
4650
4651 ID3D10Device_AddRef(This->device);
4652 *device = This->device;
4653
4654 return S_OK;
4655}

◆ d3d10_effect_GetTechniqueByIndex()

static struct ID3D10EffectTechnique *STDMETHODCALLTYPE d3d10_effect_GetTechniqueByIndex ( ID3D10Effect *  iface,
UINT  index 
)
static

Definition at line 4860 of file effect.c.

4862{
4863 struct d3d10_effect *This = impl_from_ID3D10Effect(iface);
4864 struct d3d10_effect_technique *t;
4865
4866 TRACE("iface %p, index %u\n", iface, index);
4867
4868 if (index >= This->technique_count)
4869 {
4870 WARN("Invalid index specified\n");
4871 return &null_technique.ID3D10EffectTechnique_iface;
4872 }
4873
4874 t = &This->techniques[index];
4875
4876 TRACE("Returning technique %p, %s.\n", t, debugstr_a(t->name));
4877
4878 return &t->ID3D10EffectTechnique_iface;
4879}
static struct d3d10_effect_technique null_technique
Definition: effect.c:72
GLdouble GLdouble t
Definition: gl.h:2047

◆ d3d10_effect_GetTechniqueByName()

static struct ID3D10EffectTechnique *STDMETHODCALLTYPE d3d10_effect_GetTechniqueByName ( ID3D10Effect *  iface,
const char *  name 
)
static

Definition at line 4881 of file effect.c.

4883{
4884 struct d3d10_effect *This = impl_from_ID3D10Effect(iface);
4885 unsigned int i;
4886
4887 TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
4888
4889 if (!name)
4890 {
4891 WARN("Invalid name specified\n");
4892 return &null_technique.ID3D10EffectTechnique_iface;
4893 }
4894
4895 for (i = 0; i < This->technique_count; ++i)
4896 {
4897 struct d3d10_effect_technique *t = &This->techniques[i];
4898 if (t->name && !strcmp(t->name, name))
4899 {
4900 TRACE("Returning technique %p\n", t);
4901 return &t->ID3D10EffectTechnique_iface;
4902 }
4903 }
4904
4905 WARN("Invalid name specified\n");
4906
4907 return &null_technique.ID3D10EffectTechnique_iface;
4908}

◆ d3d10_effect_GetVariableByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_GetVariableByIndex ( ID3D10Effect *  iface,
UINT  index 
)
static

Definition at line 4762 of file effect.c.

4763{
4764 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4765 struct d3d10_effect_variable *v;
4766
4767 TRACE("iface %p, index %u\n", iface, index);
4768
4770 {
4771 TRACE("Returning %svariable %s.\n", is_var_shared(v) ? "shared " : "", debugstr_a(v->name));
4772 return &v->ID3D10EffectVariable_iface;
4773 }
4774
4775 WARN("Invalid index specified\n");
4776
4777 return &null_variable.ID3D10EffectVariable_iface;
4778}

◆ d3d10_effect_GetVariableByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_GetVariableByName ( ID3D10Effect *  iface,
const char *  name 
)
static

Definition at line 4780 of file effect.c.

4782{
4783 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4784 struct d3d10_effect_variable *v;
4785
4786 TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
4787
4788 if (!name)
4789 {
4790 WARN("Invalid name specified\n");
4791 return &null_variable.ID3D10EffectVariable_iface;
4792 }
4793
4795 {
4796 TRACE("Returning %svariable %p.\n", is_var_shared(v) ? "shared " : "", v);
4797 return &v->ID3D10EffectVariable_iface;
4798 }
4799
4800 WARN("Invalid name specified\n");
4801
4802 return &null_variable.ID3D10EffectVariable_iface;
4803}

◆ d3d10_effect_GetVariableBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_GetVariableBySemantic ( ID3D10Effect *  iface,
const char *  semantic 
)
static

Definition at line 4835 of file effect.c.

4837{
4838 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4839 struct d3d10_effect_variable *v;
4840
4841 TRACE("iface %p, semantic %s\n", iface, debugstr_a(semantic));
4842
4843 if (!semantic)
4844 {
4845 WARN("Invalid semantic specified\n");
4846 return &null_variable.ID3D10EffectVariable_iface;
4847 }
4848
4850 {
4851 TRACE("Returning %svariable %s.\n", is_var_shared(v) ? "shared " : "", debugstr_a(v->name));
4852 return &v->ID3D10EffectVariable_iface;
4853 }
4854
4855 WARN("Invalid semantic specified\n");
4856
4857 return &null_variable.ID3D10EffectVariable_iface;
4858}

◆ d3d10_effect_IsOptimized()

static BOOL STDMETHODCALLTYPE d3d10_effect_IsOptimized ( ID3D10Effect *  iface)
static

Definition at line 4956 of file effect.c.

4957{
4958 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4959
4960 TRACE("iface %p.\n", iface);
4961
4962 return !!(effect->flags & D3D10_EFFECT_OPTIMIZED);
4963}
@ D3D10_EFFECT_OPTIMIZED
uint32_t flags

◆ d3d10_effect_IsPool()

static BOOL STDMETHODCALLTYPE d3d10_effect_IsPool ( ID3D10Effect *  iface)
static

Definition at line 4636 of file effect.c.

4637{
4638 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4639
4640 TRACE("iface %p.\n", iface);
4641
4642 return effect->ID3D10Effect_iface.lpVtbl == &d3d10_effect_pool_effect_vtbl;
4643}
ID3D10Effect ID3D10Effect_iface

◆ d3d10_effect_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_IsValid ( ID3D10Effect *  iface)
static

Definition at line 4629 of file effect.c.

4630{
4631 FIXME("iface %p stub!\n", iface);
4632
4633 return FALSE;
4634}

◆ d3d10_effect_local_buffer_destroy()

static void d3d10_effect_local_buffer_destroy ( struct d3d10_effect_variable *  l)
static

Definition at line 4497 of file effect.c.

4498{
4499 unsigned int i;
4500
4501 TRACE("local buffer %p.\n", l);
4502
4503 free(l->name);
4504 if (l->members)
4505 {
4506 for (i = 0; i < l->type->member_count; ++i)
4507 {
4508 d3d10_effect_variable_destroy(&l->members[i]);
4509 }
4510 free(l->members);
4511 }
4512
4513 if (l->type)
4514 d3d10_effect_type_destroy(&l->type->entry, NULL);
4515
4516 d3d10_effect_annotations_destroy(&l->annotations);
4517 free(l->u.buffer.local_buffer);
4518
4519 if (l->u.buffer.buffer)
4520 ID3D10Buffer_Release(l->u.buffer.buffer);
4521 if (l->u.buffer.resource_view)
4522 ID3D10ShaderResourceView_Release(l->u.buffer.resource_view);
4523}
static void d3d10_effect_type_destroy(struct wine_rb_entry *entry, void *context)
Definition: effect.c:4011
static void d3d10_effect_annotations_destroy(struct d3d10_effect_annotations *a)
Definition: effect.c:4374

Referenced by d3d10_effect_Release().

◆ d3d10_effect_matrix_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsBlend ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7373 of file effect.c.

7375{
7377}

◆ d3d10_effect_matrix_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsConstantBuffer ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7361 of file effect.c.

◆ d3d10_effect_matrix_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsDepthStencil ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7379 of file effect.c.

7381{
7383}

◆ d3d10_effect_matrix_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsDepthStencilView ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7355 of file effect.c.

◆ d3d10_effect_matrix_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsMatrix ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7331 of file effect.c.

7333{
7335}

◆ d3d10_effect_matrix_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsRasterizer ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7385 of file effect.c.

7387{
7389}

◆ d3d10_effect_matrix_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsRenderTargetView ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7349 of file effect.c.

◆ d3d10_effect_matrix_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsSampler ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7391 of file effect.c.

7393{
7395}

◆ d3d10_effect_matrix_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsScalar ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7319 of file effect.c.

7321{
7323}

◆ d3d10_effect_matrix_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsShader ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7367 of file effect.c.

7369{
7371}

◆ d3d10_effect_matrix_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsShaderResource ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7343 of file effect.c.

◆ d3d10_effect_matrix_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsString ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7337 of file effect.c.

7339{
7341}

◆ d3d10_effect_matrix_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_AsVector ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7325 of file effect.c.

7327{
7329}

◆ d3d10_effect_matrix_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetAnnotationByIndex ( ID3D10EffectMatrixVariable *  iface,
UINT  index 
)
static

Definition at line 7277 of file effect.c.

◆ d3d10_effect_matrix_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetAnnotationByName ( ID3D10EffectMatrixVariable *  iface,
const char *  name 
)
static

Definition at line 7283 of file effect.c.

◆ d3d10_effect_matrix_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetDesc ( ID3D10EffectMatrixVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 7271 of file effect.c.

7273{
7275}

◆ d3d10_effect_matrix_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetElement ( ID3D10EffectMatrixVariable *  iface,
UINT  index 
)
static

Definition at line 7307 of file effect.c.

7309{
7311}

◆ d3d10_effect_matrix_variable_GetMatrix()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMatrix ( ID3D10EffectMatrixVariable *  iface,
float *  data 
)
static

Definition at line 7422 of file effect.c.

7424{
7426
7427 TRACE("iface %p, data %p.\n", iface, data);
7429
7430 return S_OK;
7431}
static void read_matrix_variable_from_buffer(struct d3d10_effect_variable *variable, void *dst, BOOL transpose)
Definition: effect.c:7205
static struct d3d10_effect_variable * impl_from_ID3D10EffectMatrixVariable(ID3D10EffectMatrixVariable *iface)
Definition: effect.c:7251

◆ d3d10_effect_matrix_variable_GetMatrixArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMatrixArray ( ID3D10EffectMatrixVariable *  iface,
float *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7444 of file effect.c.

7446{
7448
7449 TRACE("iface %p, data %p, offset %u, count %u.\n", iface, data, offset, count);
7451
7452 return S_OK;
7453}
static void read_matrix_variable_array_from_buffer(struct d3d10_effect_variable *variable, void *dst_data, UINT offset, UINT count, BOOL transpose)
Definition: effect.c:7212

◆ d3d10_effect_matrix_variable_GetMatrixTranspose()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMatrixTranspose ( ID3D10EffectMatrixVariable *  iface,
float *  data 
)
static

Definition at line 7466 of file effect.c.

7468{
7470
7471 TRACE("iface %p, data %p.\n", iface, data);
7473
7474 return S_OK;
7475}

◆ d3d10_effect_matrix_variable_GetMatrixTransposeArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMatrixTransposeArray ( ID3D10EffectMatrixVariable *  iface,
float *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7488 of file effect.c.

7490{
7492
7493 TRACE("iface %p, data %p, offset %u, count %u.\n", iface, data, offset, count);
7495
7496 return S_OK;
7497}

◆ d3d10_effect_matrix_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMemberByIndex ( ID3D10EffectMatrixVariable *  iface,
UINT  index 
)
static

Definition at line 7289 of file effect.c.

◆ d3d10_effect_matrix_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMemberByName ( ID3D10EffectMatrixVariable *  iface,
const char *  name 
)
static

Definition at line 7295 of file effect.c.

◆ d3d10_effect_matrix_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetMemberBySemantic ( ID3D10EffectMatrixVariable *  iface,
const char *  semantic 
)
static

Definition at line 7301 of file effect.c.

7303{
7305}

◆ d3d10_effect_matrix_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetParentConstantBuffer ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7313 of file effect.c.

◆ d3d10_effect_matrix_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetRawValue ( ID3D10EffectMatrixVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7403 of file effect.c.

◆ d3d10_effect_matrix_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_matrix_variable_GetType ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7265 of file effect.c.

7267{
7269}

◆ d3d10_effect_matrix_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_matrix_variable_IsValid ( ID3D10EffectMatrixVariable *  iface)
static

Definition at line 7256 of file effect.c.

7257{
7259
7260 TRACE("iface %p\n", iface);
7261
7262 return v != &null_matrix_variable;
7263}
static struct d3d10_effect_variable null_matrix_variable
Definition: effect.c:83

◆ d3d10_effect_matrix_variable_SetMatrix()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetMatrix ( ID3D10EffectMatrixVariable *  iface,
float *  data 
)
static

Definition at line 7411 of file effect.c.

7413{
7415
7416 TRACE("iface %p, data %p.\n", iface, data);
7418
7419 return S_OK;
7420}
static void write_matrix_variable_to_buffer(struct d3d10_effect_variable *variable, void *src_data, BOOL transpose)
Definition: effect.c:7127

◆ d3d10_effect_matrix_variable_SetMatrixArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetMatrixArray ( ID3D10EffectMatrixVariable *  iface,
float *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7433 of file effect.c.

7435{
7437
7438 TRACE("iface %p, data %p, offset %u, count %u.\n", iface, data, offset, count);
7440
7441 return S_OK;
7442}
static void write_matrix_variable_array_to_buffer(struct d3d10_effect_variable *variable, void *src_data, unsigned int offset, unsigned int count, BOOL transpose)
Definition: effect.c:7136

◆ d3d10_effect_matrix_variable_SetMatrixTranspose()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetMatrixTranspose ( ID3D10EffectMatrixVariable *  iface,
float *  data 
)
static

Definition at line 7455 of file effect.c.

7457{
7459
7460 TRACE("iface %p, data %p.\n", iface, data);
7462
7463 return S_OK;
7464}

◆ d3d10_effect_matrix_variable_SetMatrixTransposeArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetMatrixTransposeArray ( ID3D10EffectMatrixVariable *  iface,
float *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7477 of file effect.c.

7479{
7481
7482 TRACE("iface %p, data %p, offset %u, count %u.\n", iface, data, offset, count);
7484
7485 return S_OK;
7486}

◆ d3d10_effect_matrix_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_matrix_variable_SetRawValue ( ID3D10EffectMatrixVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7397 of file effect.c.

◆ d3d10_effect_Optimize()

static HRESULT STDMETHODCALLTYPE d3d10_effect_Optimize ( ID3D10Effect *  iface)
static

Definition at line 4910 of file effect.c.

4911{
4912 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4913 struct d3d10_effect_variable *v;
4914 unsigned int i, j;
4915
4916 FIXME("iface %p semi-stub!\n", iface);
4917
4918 if (effect->flags & D3D10_EFFECT_OPTIMIZED)
4919 return S_OK;
4920
4921 for (i = 0; i < effect->shaders.count; ++i)
4922 {
4923 v = effect->shaders.v[i];
4924
4925 if (v->u.shader.reflection)
4926 {
4927 v->u.shader.reflection->lpVtbl->Release(v->u.shader.reflection);
4928 v->u.shader.reflection = NULL;
4929 }
4930 if (v->u.shader.bytecode)
4931 {
4932 ID3D10Blob_Release(v->u.shader.bytecode);
4933 v->u.shader.bytecode = NULL;
4934 }
4935 free(v->u.shader.stream_output_declaration);
4936 v->u.shader.stream_output_declaration = NULL;
4937 }
4938
4939 for (i = 0; i < effect->technique_count; ++i)
4940 {
4941 for (j = 0; j < effect->techniques[i].pass_count; ++j)
4942 {
4943 free(effect->techniques[i].passes[j].name);
4944 effect->techniques[i].passes[j].name = NULL;
4945 }
4946
4947 free(effect->techniques[i].name);
4948 effect->techniques[i].name = NULL;
4949 }
4950
4952
4953 return S_OK;
4954}
ULONG Release()

◆ d3d10_effect_parse()

HRESULT d3d10_effect_parse ( struct d3d10_effect *  effect,
const void *  data,
SIZE_T  data_size 
)

Definition at line 4308 of file effect.c.

4309{
4310 const struct vkd3d_shader_code dxbc = {.code = data, .size = data_size};
4312 struct vkd3d_shader_dxbc_desc dxbc_desc;
4313 HRESULT hr = S_OK;
4314 unsigned int i;
4315 int ret;
4316
4317 if ((ret = vkd3d_shader_parse_dxbc(&dxbc, 0, &dxbc_desc, NULL)) < 0)
4318 {
4319 WARN("Failed to parse DXBC, ret %d.\n", ret);
4320 return E_FAIL;
4321 }
4322
4323 for (i = 0; i < dxbc_desc.section_count; ++i)
4324 {
4325 section = &dxbc_desc.sections[i];
4326
4327 TRACE("Section %u: tag %s, data {%p, %#Ix}.\n",
4328 i, debugstr_fourcc(section->tag),
4329 section->data.code, section->data.size);
4330
4331 if (section->tag != TAG_FX10)
4332 {
4333 FIXME("Unhandled chunk %s.\n", debugstr_fourcc(section->tag));
4334 continue;
4335 }
4336
4337 if (FAILED(hr = parse_fx10(effect, section->data.code, section->data.size)))
4338 break;
4339 }
4340
4341 vkd3d_shader_free_dxbc(&dxbc_desc);
4342
4343 return hr;
4344}
static HRESULT parse_fx10(struct d3d10_effect *e, const char *data, size_t data_size)
Definition: effect.c:4230
#define TAG_FX10
Definition: effect.c:32
return ret
Definition: mutex.c:147
static __inline const char * debugstr_fourcc(unsigned int cc)
Definition: debug.h:397
Definition: parser.c:56
const void * code
Definition: vkd3d_shader.h:413
VKD3D_SHADER_API void vkd3d_shader_free_dxbc(struct vkd3d_shader_dxbc_desc *dxbc)
Definition: dxbc.c:290
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)
Definition: dxbc.c:320

Referenced by d3d10_create_effect().

◆ d3d10_effect_parse_stream_output_declaration()

static HRESULT d3d10_effect_parse_stream_output_declaration ( const char *  decl,
struct d3d10_effect_so_decl *  so_decl 
)
static

Definition at line 1624 of file effect.c.

1626{
1627 static const char * xyzw = "xyzw";
1628 static const char * rgba = "rgba";
1629 char *p, *ptr, *end, *next, *mask, *m, *slot;
1631 unsigned int len;
1632
1633 memset(so_decl, 0, sizeof(*so_decl));
1634
1635 if (!(so_decl->decl = strdup(decl)))
1636 return E_OUTOFMEMORY;
1637
1638 p = so_decl->decl;
1639
1640 while (p && *p)
1641 {
1642 memset(&e, 0, sizeof(e));
1643
1644 end = strchr(p, ';');
1645 next = end ? end + 1 : p + strlen(p);
1646
1647 len = next - p;
1648 if (end) len--;
1649
1650 /* Remove leading and trailing spaces. */
1651 while (len && isspace(*p)) { len--; p++; }
1652 while (len && isspace(p[len - 1])) len--;
1653
1654 p[len] = 0;
1655
1656 /* Output slot */
1657 if ((slot = strchr(p, ':')))
1658 {
1659 *slot = 0;
1660
1661 ptr = p;
1662 while (*ptr)
1663 {
1664 if (!isdigit(*ptr))
1665 {
1666 WARN("Invalid output slot %s.\n", debugstr_a(p));
1667 goto failed;
1668 }
1669 ptr++;
1670 }
1671
1672 e.OutputSlot = atoi(p);
1673 p = slot + 1;
1674 }
1675
1676 /* Mask */
1677 if ((mask = strchr(p, '.')))
1678 {
1679 *mask = 0; mask++;
1680
1681 if ((m = strstr(xyzw, mask)))
1682 e.StartComponent = m - xyzw;
1683 else if ((m = strstr(rgba, mask)))
1684 e.StartComponent = m - rgba;
1685 else
1686 {
1687 WARN("Invalid component mask %s.\n", debugstr_a(mask));
1688 goto failed;
1689 }
1690
1691 e.ComponentCount = strlen(mask);
1692 }
1693 else
1694 {
1695 e.StartComponent = 0;
1696 e.ComponentCount = 4;
1697 }
1698
1699 /* Semantic index and name */
1700 len = strlen(p);
1701 while (isdigit(p[len - 1]))
1702 len--;
1703
1704 if (p[len])
1705 {
1706 e.SemanticIndex = atoi(&p[len]);
1707 p[len] = 0;
1708 }
1709
1710 e.SemanticName = stricmp(p, "$SKIP") ? p : NULL;
1711
1712 if (!d3d_array_reserve((void **)&so_decl->entries, &so_decl->capacity, so_decl->count + 1,
1713 sizeof(*so_decl->entries)))
1714 goto failed;
1715
1716 so_decl->entries[so_decl->count++] = e;
1717
1718 if (e.OutputSlot == 0)
1719 so_decl->stride += e.ComponentCount * sizeof(float);
1720
1721 p = next;
1722 }
1723
1724 return S_OK;
1725
1726failed:
1728
1729 return E_FAIL;
1730}
#define isspace(c)
Definition: acclib.h:69
#define isdigit(c)
Definition: acclib.h:68
static void d3d10_effect_cleanup_so_decl(struct d3d10_effect_so_decl *so_decl)
Definition: effect.c:1617
_ACRTIMP int __cdecl atoi(const char *)
Definition: string.c:1720
_ACRTIMP char *__cdecl strchr(const char *, int)
Definition: string.c:3291
_ACRTIMP size_t __cdecl strlen(const char *)
Definition: string.c:1597
_ACRTIMP char *__cdecl strstr(const char *, const char *)
Definition: string.c:3420
GLuint GLuint end
Definition: gl.h:1545
GLenum GLint GLuint mask
Definition: glext.h:6028
GLfloat GLfloat p
Definition: glext.h:8902
GLenum GLsizei len
Definition: glext.h:6722
const GLfloat * m
Definition: glext.h:10848
#define e
Definition: ke_i.h:82
static float(__cdecl *square_half_float)(float x
static unsigned __int64 next
Definition: rand_nt.c:6
Definition: d3d10.idl:816
Definition: vfat.h:185
unsigned int stride
Definition: effect.c:1613
struct _slot slot
Definition: vfat.h:196

Referenced by parse_fx10_shader().

◆ d3d10_effect_pass_Apply()

static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_Apply ( ID3D10EffectPass *  iface,
UINT  flags 
)
static

Definition at line 5474 of file effect.c.

5475{
5477 ID3D10Device *device = pass->technique->effect->device;
5478
5479 TRACE("iface %p, flags %#x\n", iface, flags);
5480
5481 if (flags) FIXME("Ignoring flags (%#x)\n", flags);
5482
5484
5485 if (pass->vs.shader != &null_shader_variable)
5487 if (pass->gs.shader != &null_shader_variable)
5489 if (pass->ps.shader != &null_shader_variable)
5491 if (pass->rasterizer)
5492 ID3D10Device_RSSetState(device, pass->rasterizer->u.state.object.rasterizer);
5493 if (pass->depth_stencil)
5494 ID3D10Device_OMSetDepthStencilState(device, pass->depth_stencil->u.state.object.depth_stencil,
5495 pass->stencil_ref);
5496 if (pass->blend)
5497 ID3D10Device_OMSetBlendState(device, pass->blend->u.state.object.blend,
5498 pass->blend_factor, pass->sample_mask);
5499
5500 return S_OK;
5501}
static void d3d10_effect_pass_set_shader(struct d3d10_effect_pass *pass, const struct d3d10_effect_pass_shader_desc *shader_desc)
Definition: effect.c:5448
static struct d3d10_effect_variable null_shader_variable
Definition: effect.c:91
static struct d3d10_effect_pass * impl_from_ID3D10EffectPass(ID3D10EffectPass *iface)
Definition: effect.c:5155
pass
Definition: typegen.h:25

◆ d3d10_effect_pass_ComputeStateBlockMask()

static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_ComputeStateBlockMask ( ID3D10EffectPass *  iface,
D3D10_STATE_BLOCK_MASK *  mask 
)
static

Definition at line 5503 of file effect.c.

5505{
5507
5508 FIXME("iface %p, mask %p semi-stub!\n", iface, mask);
5509
5510 if (pass->vs.shader != &null_shader_variable)
5512 if (pass->ps.shader != &null_shader_variable)
5514 if (pass->gs.shader != &null_shader_variable)
5516 if (pass->rasterizer)
5518 if (pass->depth_stencil)
5520 if (pass->blend)
5522
5523 return S_OK;
5524}
HRESULT WINAPI D3D10StateBlockMaskEnableCapture(D3D10_STATE_BLOCK_MASK *mask, D3D10_DEVICE_STATE_TYPES state_type, UINT start_idx, UINT count)
Definition: stateblock.c:771
@ D3D10_DST_VS
Definition: d3d10effect.idl:54
@ D3D10_DST_OM_BLEND_STATE
Definition: d3d10effect.idl:53
@ D3D10_DST_PS
Definition: d3d10effect.idl:62
@ D3D10_DST_GS
Definition: d3d10effect.idl:58
@ D3D10_DST_OM_DEPTH_STENCIL_STATE
Definition: d3d10effect.idl:52
@ D3D10_DST_RS_RASTERIZER_STATE
Definition: d3d10effect.idl:72

◆ d3d10_effect_pass_destroy()

static void d3d10_effect_pass_destroy ( struct d3d10_effect_pass *  p)
static

Definition at line 4469 of file effect.c.

4470{
4471 TRACE("pass %p\n", p);
4472
4473 free(p->name);
4474 d3d10_effect_annotations_destroy(&p->annotations);
4476}
static void d3d10_effect_clear_prop_dependencies(struct d3d10_effect_prop_dependencies *d)
Definition: effect.c:976

Referenced by d3d10_effect_technique_destroy().

◆ d3d10_effect_pass_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_pass_GetAnnotationByIndex ( ID3D10EffectPass *  iface,
UINT  index 
)
static

Definition at line 5295 of file effect.c.

5297{
5299
5300 TRACE("iface %p, index %u\n", iface, index);
5301
5302 return d3d10_annotation_get_by_index(&pass->annotations, index);
5303}
static ID3D10EffectVariable * d3d10_annotation_get_by_index(const struct d3d10_effect_annotations *annotations, unsigned int index)
Definition: effect.c:5029

◆ d3d10_effect_pass_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_pass_GetAnnotationByName ( ID3D10EffectPass *  iface,
const char *  name 
)
static

Definition at line 5305 of file effect.c.

5307{
5309
5310 TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
5311
5312 return d3d10_annotation_get_by_name(&pass->annotations, name);
5313}
static ID3D10EffectVariable * d3d10_annotation_get_by_name(const struct d3d10_effect_annotations *annotations, const char *name)
Definition: effect.c:5047

◆ d3d10_effect_pass_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetDesc ( ID3D10EffectPass *  iface,
D3D10_PASS_DESC *  desc 
)
static

Definition at line 5169 of file effect.c.

5171{
5173 struct d3d10_effect_variable *vs;
5174 ID3D10Blob *input_signature;
5175
5176 TRACE("iface %p, desc %p.\n", iface, desc);
5177
5178 if (pass == &null_pass)
5179 {
5180 WARN("Null pass specified\n");
5181 return E_FAIL;
5182 }
5183
5184 if (!desc)
5185 {
5186 WARN("Invalid argument specified\n");
5187 return E_INVALIDARG;
5188 }
5189
5191
5192 vs = d3d10_array_get_element(pass->vs.shader, pass->vs.index);
5193 input_signature = vs->u.shader.input_signature;
5194
5195 desc->Name = pass->name;
5196 desc->Annotations = pass->annotations.count;
5197 if (input_signature)
5198 {
5199 desc->pIAInputSignature = ID3D10Blob_GetBufferPointer(input_signature);
5200 desc->IAInputSignatureSize = ID3D10Blob_GetBufferSize(input_signature);
5201 }
5202 else
5203 {
5204 desc->pIAInputSignature = NULL;
5205 desc->IAInputSignatureSize = 0;
5206 }
5207 desc->StencilRef = pass->stencil_ref;
5208 desc->SampleMask = pass->sample_mask;
5209 memcpy(desc->BlendFactor, pass->blend_factor, 4 * sizeof(float));
5210
5211 return S_OK;
5212}
static struct d3d10_effect_pass null_pass
Definition: effect.c:73
static struct d3d10_effect_variable * d3d10_array_get_element(struct d3d10_effect_variable *v, unsigned int index)
Definition: effect.c:143
#define memcpy(s1, s2, n)
Definition: mkisofs.h:878
static vector_t * vs
Definition: server.c:146

◆ d3d10_effect_pass_GetGeometryShaderDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetGeometryShaderDesc ( ID3D10EffectPass *  iface,
D3D10_PASS_SHADER_DESC *  desc 
)
static

Definition at line 5241 of file effect.c.

5243{
5245
5246 TRACE("iface %p, desc %p.\n", iface, desc);
5247
5248 if (pass == &null_pass)
5249 {
5250 WARN("Null pass specified.\n");
5251 return E_FAIL;
5252 }
5253
5254 if (!desc)
5255 {
5256 WARN("Invalid argument specified.\n");
5257 return E_INVALIDARG;
5258 }
5259
5261
5262 desc->pShaderVariable = (ID3D10EffectShaderVariable *)&pass->gs.shader->ID3D10EffectVariable_iface;
5263 desc->ShaderIndex = pass->gs.index;
5264
5265 return S_OK;
5266}

◆ d3d10_effect_pass_GetPixelShaderDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetPixelShaderDesc ( ID3D10EffectPass *  iface,
D3D10_PASS_SHADER_DESC *  desc 
)
static

Definition at line 5268 of file effect.c.

5270{
5272
5273 TRACE("iface %p, desc %p.\n", iface, desc);
5274
5275 if (pass == &null_pass)
5276 {
5277 WARN("Null pass specified.\n");
5278 return E_FAIL;
5279 }
5280
5281 if (!desc)
5282 {
5283 WARN("Invalid argument specified.\n");
5284 return E_INVALIDARG;
5285 }
5286
5288
5289 desc->pShaderVariable = (ID3D10EffectShaderVariable *)&pass->ps.shader->ID3D10EffectVariable_iface;
5290 desc->ShaderIndex = pass->ps.index;
5291
5292 return S_OK;
5293}

◆ d3d10_effect_pass_GetVertexShaderDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetVertexShaderDesc ( ID3D10EffectPass *  iface,
D3D10_PASS_SHADER_DESC *  desc 
)
static

Definition at line 5214 of file effect.c.

5216{
5218
5219 TRACE("iface %p, desc %p.\n", iface, desc);
5220
5221 if (pass == &null_pass)
5222 {
5223 WARN("Null pass specified.\n");
5224 return E_FAIL;
5225 }
5226
5227 if (!desc)
5228 {
5229 WARN("Invalid argument specified.\n");
5230 return E_INVALIDARG;
5231 }
5232
5234
5235 desc->pShaderVariable = (ID3D10EffectShaderVariable *)&pass->vs.shader->ID3D10EffectVariable_iface;
5236 desc->ShaderIndex = pass->vs.index;
5237
5238 return S_OK;
5239}

◆ d3d10_effect_pass_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_pass_IsValid ( ID3D10EffectPass *  iface)
static

Definition at line 5160 of file effect.c.

5161{
5163
5164 TRACE("iface %p\n", iface);
5165
5166 return This != &null_pass;
5167}

◆ d3d10_effect_pass_set_shader()

static void d3d10_effect_pass_set_shader ( struct d3d10_effect_pass *  pass,
const struct d3d10_effect_pass_shader_desc *  shader_desc 
)
static

Definition at line 5448 of file effect.c.

5450{
5451 ID3D10Device *device = pass->technique->effect->device;
5452 struct d3d10_effect_variable *v;
5453
5454 v = d3d10_array_get_element(shader_desc->shader, shader_desc->index);
5455
5456 switch (v->type->basetype)
5457 {
5459 ID3D10Device_VSSetShader(device, v->u.shader.shader.vs);
5460 break;
5462 ID3D10Device_PSSetShader(device, v->u.shader.shader.ps);
5463 break;
5465 ID3D10Device_GSSetShader(device, v->u.shader.shader.gs);
5466 break;
5467 default:
5468 WARN("Unexpected shader type %u.\n", v->type->basetype);
5469 }
5470
5472}
static void apply_shader_resources(ID3D10Device *device, struct d3d10_effect_variable *v)
Definition: effect.c:5351
struct d3d10_effect_variable * shader

Referenced by d3d10_effect_pass_Apply().

◆ d3d10_effect_pool_AddRef()

static ULONG STDMETHODCALLTYPE d3d10_effect_pool_AddRef ( ID3D10EffectPool *  iface)
static

Definition at line 10057 of file effect.c.

10058{
10059 struct d3d10_effect *effect = impl_from_ID3D10EffectPool(iface);
10060 return d3d10_effect_AddRef(&effect->ID3D10Effect_iface);
10061}
static struct d3d10_effect * impl_from_ID3D10EffectPool(ID3D10EffectPool *iface)
Definition: effect.c:37
static ULONG STDMETHODCALLTYPE d3d10_effect_AddRef(ID3D10Effect *iface)
Definition: effect.c:4550

◆ d3d10_effect_pool_AsEffect()

static ID3D10Effect *STDMETHODCALLTYPE d3d10_effect_pool_AsEffect ( ID3D10EffectPool *  iface)
static

Definition at line 10069 of file effect.c.

10070{
10071 struct d3d10_effect *effect = impl_from_ID3D10EffectPool(iface);
10072
10073 TRACE("%p.\n", iface);
10074
10075 return &effect->ID3D10Effect_iface;
10076}

◆ d3d10_effect_pool_effect_QueryInterface()

static HRESULT STDMETHODCALLTYPE d3d10_effect_pool_effect_QueryInterface ( ID3D10Effect *  iface,
REFIID  riid,
void **  object 
)
static

Definition at line 10164 of file effect.c.

10166{
10167 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
10168
10169 TRACE("iface %p, riid %s, obj %p.\n", iface, debugstr_guid(riid), object);
10170
10171 return IUnknown_QueryInterface(&effect->ID3D10EffectPool_iface, riid, object);
10172}
REFIID riid
Definition: atlbase.h:39
#define debugstr_guid
Definition: kernel32.h:35
ID3D10EffectPool ID3D10EffectPool_iface

◆ d3d10_effect_pool_QueryInterface()

static HRESULT STDMETHODCALLTYPE d3d10_effect_pool_QueryInterface ( ID3D10EffectPool *  iface,
REFIID  riid,
void **  object 
)
static

Definition at line 10038 of file effect.c.

10040{
10041 TRACE("iface %p, riid %s, object %p.\n", iface, debugstr_guid(riid), object);
10042
10043 if (IsEqualGUID(riid, &IID_ID3D10EffectPool) ||
10045 {
10046 IUnknown_AddRef(iface);
10047 *object = iface;
10048 return S_OK;
10049 }
10050
10051 WARN("%s not implemented, returning E_NOINTERFACE\n", debugstr_guid(riid));
10052
10053 *object = NULL;
10054 return E_NOINTERFACE;
10055}
const GUID IID_IUnknown
#define IsEqualGUID(rguid1, rguid2)
Definition: guiddef.h:147
#define E_NOINTERFACE
Definition: winerror.h:3479

◆ d3d10_effect_pool_Release()

static ULONG STDMETHODCALLTYPE d3d10_effect_pool_Release ( ID3D10EffectPool *  iface)
static

Definition at line 10063 of file effect.c.

10064{
10065 struct d3d10_effect *effect = impl_from_ID3D10EffectPool(iface);
10067}
static ULONG STDMETHODCALLTYPE d3d10_effect_Release(ID3D10Effect *iface)
Definition: effect.c:4560

◆ d3d10_effect_preshader_clear()

static void d3d10_effect_preshader_clear ( struct d3d10_effect_preshader *  p)
static

Definition at line 901 of file effect.c.

902{
903 unsigned int i;
904
905 for (i = 0; i < ARRAY_SIZE(p->reg_tables); ++i)
906 free(p->reg_tables[i].f);
907 if (p->code)
908 ID3D10Blob_Release(p->code);
909 free(p->vars);
910 memset(p, 0, sizeof(*p));
911}

Referenced by d3d10_effect_clear_prop_dependencies().

◆ d3d10_effect_preshader_eval()

static HRESULT d3d10_effect_preshader_eval ( struct d3d10_effect_preshader *  p)
static

Definition at line 928 of file effect.c.

929{
930 unsigned int i, j, regt, offset, instr_count, arg_count;
931 const DWORD *ip = ID3D10Blob_GetBufferPointer(p->code);
932 struct preshader_instr ins;
933 float *dst, *args[9];
934
936 memset(dst, 0, sizeof(float) * p->reg_tables[D3D10_REG_TABLE_RESULT].count);
937
938 /* Update constant buffer */
940 for (i = 0; i < p->vars_count; ++i)
941 {
942 struct d3d10_ctab_var *v = &p->vars[i];
943 memcpy(dst + v->offset, v->v->buffer->u.buffer.local_buffer + v->v->buffer_offset,
944 v->length * sizeof(*dst));
945 }
946
947 instr_count = *ip++;
948
949 for (i = 0; i < instr_count; ++i)
950 {
951 *(DWORD *)&ins = *ip++;
952 arg_count = 1 + *ip++;
953
954 if (arg_count > ARRAY_SIZE(args))
955 {
956 FIXME("Unexpected argument count %u.\n", arg_count);
957 return E_FAIL;
958 }
959
960 /* Arguments are followed by the return value. */
961 for (j = 0; j < arg_count; ++j)
962 {
963 ip++; /* TODO: argument register flags are currently ignored */
964 regt = *ip++;
965 offset = *ip++;
966
968 }
969
970 d3d10_effect_get_op_info(ins.opcode)->func(args, arg_count, &ins);
971 }
972
973 return S_OK;
974}
static const struct preshader_op_info * d3d10_effect_get_op_info(int opcode)
Definition: effect.c:821
static float * d3d10_effect_preshader_get_reg_ptr(const struct d3d10_effect_preshader *p, enum d3d10_reg_table_type regt, unsigned int offset)
Definition: effect.c:913
GLenum GLenum dst
Definition: glext.h:6340
Definition: match.c:390
Definition: dhcpd.h:62

Referenced by d3d10_effect_update_dependent_props().

◆ d3d10_effect_preshader_get_reg_ptr()

static float * d3d10_effect_preshader_get_reg_ptr ( const struct d3d10_effect_preshader *  p,
enum d3d10_reg_table_type  regt,
unsigned int  offset 
)
static

Definition at line 913 of file effect.c.

915{
916 switch (regt)
917 {
922 return p->reg_tables[regt].f + offset;
923 default:
924 return NULL;
925 }
926}

Referenced by d3d10_effect_preshader_eval().

◆ d3d10_effect_QueryInterface()

static HRESULT STDMETHODCALLTYPE d3d10_effect_QueryInterface ( ID3D10Effect *  iface,
REFIID  riid,
void **  object 
)
static

Definition at line 4532 of file effect.c.

4533{
4534 TRACE("iface %p, riid %s, object %p\n", iface, debugstr_guid(riid), object);
4535
4536 if (IsEqualGUID(riid, &IID_ID3D10Effect)
4538 {
4539 IUnknown_AddRef(iface);
4540 *object = iface;
4541 return S_OK;
4542 }
4543
4544 WARN("%s not implemented, returning E_NOINTERFACE\n", debugstr_guid(riid));
4545
4546 *object = NULL;
4547 return E_NOINTERFACE;
4548}

◆ d3d10_effect_rasterizer_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsBlend ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9504 of file effect.c.

9506{
9508}

◆ d3d10_effect_rasterizer_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsConstantBuffer ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9492 of file effect.c.

◆ d3d10_effect_rasterizer_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsDepthStencil ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9510 of file effect.c.

9512{
9514}

◆ d3d10_effect_rasterizer_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsDepthStencilView ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9486 of file effect.c.

◆ d3d10_effect_rasterizer_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsMatrix ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9462 of file effect.c.

9464{
9466}

◆ d3d10_effect_rasterizer_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsRasterizer ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9516 of file effect.c.

9518{
9520}

◆ d3d10_effect_rasterizer_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsRenderTargetView ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9480 of file effect.c.

◆ d3d10_effect_rasterizer_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsSampler ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9522 of file effect.c.

9524{
9526}

◆ d3d10_effect_rasterizer_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsScalar ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9450 of file effect.c.

9452{
9454}

◆ d3d10_effect_rasterizer_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsShader ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9498 of file effect.c.

9500{
9502}

◆ d3d10_effect_rasterizer_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsShaderResource ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9474 of file effect.c.

◆ d3d10_effect_rasterizer_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsString ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9468 of file effect.c.

9470{
9472}

◆ d3d10_effect_rasterizer_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_AsVector ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9456 of file effect.c.

9458{
9460}

◆ d3d10_effect_rasterizer_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetAnnotationByIndex ( ID3D10EffectRasterizerVariable *  iface,
UINT  index 
)
static

Definition at line 9408 of file effect.c.

◆ d3d10_effect_rasterizer_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetAnnotationByName ( ID3D10EffectRasterizerVariable *  iface,
const char *  name 
)
static

Definition at line 9414 of file effect.c.

◆ d3d10_effect_rasterizer_variable_GetBackingStore()

static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetBackingStore ( ID3D10EffectRasterizerVariable *  iface,
UINT  index,
D3D10_RASTERIZER_DESC *  desc 
)
static

Definition at line 9564 of file effect.c.

9566{
9568
9569 TRACE("iface %p, index %u, desc %p.\n", iface, index, desc);
9570
9571 if (!iface->lpVtbl->IsValid(iface))
9572 {
9573 WARN("Invalid variable.\n");
9574 return E_FAIL;
9575 }
9576
9577 if (!(v = d3d10_get_state_variable(v, index, &v->effect->rs_states)))
9578 return E_FAIL;
9579
9580 *desc = v->u.state.desc.rasterizer;
9581
9582 return S_OK;
9583}
static struct d3d10_effect_variable * impl_from_ID3D10EffectRasterizerVariable(ID3D10EffectRasterizerVariable *iface)
Definition: effect.c:9381

◆ d3d10_effect_rasterizer_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetDesc ( ID3D10EffectRasterizerVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 9402 of file effect.c.

9404{
9406}

◆ d3d10_effect_rasterizer_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetElement ( ID3D10EffectRasterizerVariable *  iface,
UINT  index 
)
static

Definition at line 9438 of file effect.c.

9440{
9442}

◆ d3d10_effect_rasterizer_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetMemberByIndex ( ID3D10EffectRasterizerVariable *  iface,
UINT  index 
)
static

Definition at line 9420 of file effect.c.

◆ d3d10_effect_rasterizer_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetMemberByName ( ID3D10EffectRasterizerVariable *  iface,
const char *  name 
)
static

Definition at line 9426 of file effect.c.

◆ d3d10_effect_rasterizer_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetMemberBySemantic ( ID3D10EffectRasterizerVariable *  iface,
const char *  semantic 
)
static

Definition at line 9432 of file effect.c.

9434{
9436}

◆ d3d10_effect_rasterizer_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetParentConstantBuffer ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9444 of file effect.c.

◆ d3d10_effect_rasterizer_variable_GetRasterizerState()

static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetRasterizerState ( ID3D10EffectRasterizerVariable *  iface,
UINT  index,
ID3D10RasterizerState **  rasterizer_state 
)
static

Definition at line 9542 of file effect.c.

9544{
9546
9547 TRACE("iface %p, index %u, rasterizer_state %p.\n", iface, index, rasterizer_state);
9548
9549 if (!iface->lpVtbl->IsValid(iface))
9550 {
9551 WARN("Invalid variable.\n");
9552 return E_FAIL;
9553 }
9554
9555 if (!(v = d3d10_get_state_variable(v, index, &v->effect->rs_states)))
9556 return E_FAIL;
9557
9558 if ((*rasterizer_state = v->u.state.object.rasterizer))
9559 ID3D10RasterizerState_AddRef(*rasterizer_state);
9560
9561 return S_OK;
9562}

◆ d3d10_effect_rasterizer_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetRawValue ( ID3D10EffectRasterizerVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 9534 of file effect.c.

◆ d3d10_effect_rasterizer_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_GetType ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9396 of file effect.c.

9398{
9400}

◆ d3d10_effect_rasterizer_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_IsValid ( ID3D10EffectRasterizerVariable *  iface)
static

Definition at line 9387 of file effect.c.

9388{
9390
9391 TRACE("iface %p\n", iface);
9392
9393 return v != &null_rasterizer_variable;
9394}
static struct d3d10_effect_variable null_rasterizer_variable
Definition: effect.c:97

◆ d3d10_effect_rasterizer_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_rasterizer_variable_SetRawValue ( ID3D10EffectRasterizerVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 9528 of file effect.c.

◆ d3d10_effect_read_numeric_value()

static BOOL d3d10_effect_read_numeric_value ( uint32_t  value,
D3D_SHADER_VARIABLE_TYPE  in_type,
D3D_SHADER_VARIABLE_TYPE  out_type,
void *  out_data,
unsigned int  out_idx 
)
static

Definition at line 1287 of file effect.c.

1289{
1290 switch (out_type)
1291 {
1292 case D3D10_SVT_FLOAT:
1293 return read_float_value(value, in_type, out_data, out_idx);
1294 case D3D10_SVT_INT:
1295 case D3D10_SVT_UINT:
1296 case D3D10_SVT_BOOL:
1297 return read_int32_value(value, in_type, out_data, out_idx);
1298 case D3D10_SVT_UINT8:
1299 return read_int8_value(value, in_type, out_data, out_idx);
1300 default:
1301 FIXME("Unsupported property type %u.\n", out_type);
1302 return FALSE;
1303 }
1304}
@ D3D10_SVT_BOOL
Definition: d3dcommon.idl:227
@ D3D10_SVT_UINT
Definition: d3dcommon.idl:245
@ D3D10_SVT_UINT8
Definition: d3dcommon.idl:246
@ D3D10_SVT_FLOAT
Definition: d3dcommon.idl:229
@ D3D10_SVT_INT
Definition: d3dcommon.idl:228
static BOOL read_int8_value(uint32_t value, D3D_SHADER_VARIABLE_TYPE in_type, INT8 *out_data, unsigned int out_idx)
Definition: effect.c:1271
static BOOL read_float_value(uint32_t value, D3D_SHADER_VARIABLE_TYPE in_type, float *out_data, unsigned int out_idx)
Definition: effect.c:1227
static BOOL read_int32_value(uint32_t value, D3D_SHADER_VARIABLE_TYPE in_type, int *out_data, unsigned int out_idx)
Definition: effect.c:1250
Definition: pdh_main.c:64

Referenced by d3d10_effect_update_dependent_props(), and read_value_list().

◆ d3d10_effect_Release()

static ULONG STDMETHODCALLTYPE d3d10_effect_Release ( ID3D10Effect *  iface)
static

Definition at line 4560 of file effect.c.

4561{
4562 struct d3d10_effect *effect = impl_from_ID3D10Effect(iface);
4564
4565 TRACE("%p decreasing refcount to %lu.\n", iface, refcount);
4566
4567 if (!refcount)
4568 {
4569 unsigned int i;
4570
4571 if (effect->techniques)
4572 {
4573 for (i = 0; i < effect->technique_count; ++i)
4574 {
4576 }
4577 free(effect->techniques);
4578 }
4579
4580 if (effect->object_variables)
4581 {
4582 for (i = 0; i < effect->object_count; ++i)
4583 {
4585 }
4586 free(effect->object_variables);
4587 }
4588
4589 if (effect->local_buffers)
4590 {
4591 for (i = 0; i < effect->local_buffer_count; ++i)
4592 {
4594 }
4595 free(effect->local_buffers);
4596 }
4597
4598 if (effect->anonymous_shaders)
4599 {
4600 for (i = 0; i < effect->anonymous_shader_count; ++i)
4601 {
4603 free(effect->anonymous_shaders[i].type.name);
4604 }
4605 free(effect->anonymous_shaders);
4606 }
4607
4608 free(effect->shaders.v);
4609 free(effect->samplers.v);
4610 free(effect->rtvs.v);
4611 free(effect->dsvs.v);
4612 free(effect->blend_states.v);
4613 free(effect->ds_states.v);
4614 free(effect->rs_states.v);
4615
4617
4618 if (effect->pool)
4619 IUnknown_Release(&effect->pool->ID3D10Effect_iface);
4620 ID3D10Device_Release(effect->device);
4621 free(effect);
4622 }
4623
4624 return refcount;
4625}
#define InterlockedDecrement
Definition: armddk.h:52
static void d3d10_effect_technique_destroy(struct d3d10_effect_technique *t)
Definition: effect.c:4478
static void d3d10_effect_local_buffer_destroy(struct d3d10_effect_variable *l)
Definition: effect.c:4497
#define wine_rb_destroy
Definition: rbtree.h:408
struct d3d10_effect_var_array shaders
struct d3d10_effect_variable * object_variables
struct d3d10_effect_anonymous_shader * anonymous_shaders
struct d3d10_effect_var_array dsvs
struct d3d10_effect_var_array blend_states
struct d3d10_effect_var_array rtvs
struct d3d10_effect_var_array ds_states
struct d3d10_effect_technique * techniques
struct d3d10_effect_var_array rs_states
struct wine_rb_tree types
struct d3d10_effect_var_array samplers
unsigned int anonymous_shader_count

Referenced by d3d10_effect_pool_Release().

◆ d3d10_effect_render_target_view_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsBlend ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8163 of file effect.c.

8165{
8167}

◆ d3d10_effect_render_target_view_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsConstantBuffer ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8151 of file effect.c.

◆ d3d10_effect_render_target_view_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsDepthStencil ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8169 of file effect.c.

8171{
8173}

◆ d3d10_effect_render_target_view_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsDepthStencilView ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8145 of file effect.c.

◆ d3d10_effect_render_target_view_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsMatrix ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8121 of file effect.c.

8123{
8125}

◆ d3d10_effect_render_target_view_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsRasterizer ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8175 of file effect.c.

8177{
8179}

◆ d3d10_effect_render_target_view_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsRenderTargetView ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8139 of file effect.c.

◆ d3d10_effect_render_target_view_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsSampler ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8181 of file effect.c.

8183{
8185}

◆ d3d10_effect_render_target_view_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsScalar ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8109 of file effect.c.

8111{
8113}

◆ d3d10_effect_render_target_view_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsShader ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8157 of file effect.c.

8159{
8161}

◆ d3d10_effect_render_target_view_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsShaderResource ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8133 of file effect.c.

◆ d3d10_effect_render_target_view_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsString ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8127 of file effect.c.

8129{
8131}

◆ d3d10_effect_render_target_view_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_AsVector ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8115 of file effect.c.

8117{
8119}

◆ d3d10_effect_render_target_view_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetAnnotationByIndex ( ID3D10EffectRenderTargetViewVariable *  iface,
UINT  index 
)
static

Definition at line 8067 of file effect.c.

◆ d3d10_effect_render_target_view_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetAnnotationByName ( ID3D10EffectRenderTargetViewVariable *  iface,
const char *  name 
)
static

Definition at line 8073 of file effect.c.

◆ d3d10_effect_render_target_view_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetDesc ( ID3D10EffectRenderTargetViewVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 8061 of file effect.c.

8063{
8065}

◆ d3d10_effect_render_target_view_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetElement ( ID3D10EffectRenderTargetViewVariable *  iface,
UINT  index 
)
static

Definition at line 8097 of file effect.c.

8099{
8101}

◆ d3d10_effect_render_target_view_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetMemberByIndex ( ID3D10EffectRenderTargetViewVariable *  iface,
UINT  index 
)
static

Definition at line 8079 of file effect.c.

◆ d3d10_effect_render_target_view_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetMemberByName ( ID3D10EffectRenderTargetViewVariable *  iface,
const char *  name 
)
static

Definition at line 8085 of file effect.c.

◆ d3d10_effect_render_target_view_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetMemberBySemantic ( ID3D10EffectRenderTargetViewVariable *  iface,
const char *  semantic 
)
static

Definition at line 8091 of file effect.c.

8093{
8095}

◆ d3d10_effect_render_target_view_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetParentConstantBuffer ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8103 of file effect.c.

◆ d3d10_effect_render_target_view_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetRawValue ( ID3D10EffectRenderTargetViewVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 8193 of file effect.c.

◆ d3d10_effect_render_target_view_variable_GetRenderTarget()

static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetRenderTarget ( ID3D10EffectRenderTargetViewVariable *  iface,
ID3D10RenderTargetView **  view 
)
static

Definition at line 8209 of file effect.c.

8211{
8212 FIXME("iface %p, view %p stub!\n", iface, view);
8213
8214 return E_NOTIMPL;
8215}

◆ d3d10_effect_render_target_view_variable_GetRenderTargetArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetRenderTargetArray ( ID3D10EffectRenderTargetViewVariable *  iface,
ID3D10RenderTargetView **  views,
UINT  offset,
UINT  count 
)
static

Definition at line 8225 of file effect.c.

8227{
8228 FIXME("iface %p, views %p, offset %u, count %u stub!\n", iface, views, offset, count);
8229
8230 return E_NOTIMPL;
8231}

◆ d3d10_effect_render_target_view_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_GetType ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8055 of file effect.c.

8057{
8059}

◆ d3d10_effect_render_target_view_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_IsValid ( ID3D10EffectRenderTargetViewVariable *  iface)
static

Definition at line 8045 of file effect.c.

8047{
8049
8050 TRACE("iface %p\n", iface);
8051
8053}
static struct d3d10_effect_variable * impl_from_ID3D10EffectRenderTargetViewVariable(ID3D10EffectRenderTargetViewVariable *iface)
Definition: effect.c:8039
static struct d3d10_effect_variable null_render_target_view_variable
Definition: effect.c:87

◆ d3d10_effect_render_target_view_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_SetRawValue ( ID3D10EffectRenderTargetViewVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 8187 of file effect.c.

◆ d3d10_effect_render_target_view_variable_SetRenderTarget()

static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_SetRenderTarget ( ID3D10EffectRenderTargetViewVariable *  iface,
ID3D10RenderTargetView *  view 
)
static

Definition at line 8201 of file effect.c.

8203{
8204 FIXME("iface %p, view %p stub!\n", iface, view);
8205
8206 return E_NOTIMPL;
8207}

◆ d3d10_effect_render_target_view_variable_SetRenderTargetArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_render_target_view_variable_SetRenderTargetArray ( ID3D10EffectRenderTargetViewVariable *  iface,
ID3D10RenderTargetView **  views,
UINT  offset,
UINT  count 
)
static

Definition at line 8217 of file effect.c.

8219{
8220 FIXME("iface %p, views %p, offset %u, count %u stub!\n", iface, views, offset, count);
8221
8222 return E_NOTIMPL;
8223}

◆ d3d10_effect_sampler_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsBlend ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9743 of file effect.c.

9745{
9747}

◆ d3d10_effect_sampler_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsConstantBuffer ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9731 of file effect.c.

◆ d3d10_effect_sampler_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsDepthStencil ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9749 of file effect.c.

9751{
9753}

◆ d3d10_effect_sampler_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsDepthStencilView ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9725 of file effect.c.

◆ d3d10_effect_sampler_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsMatrix ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9701 of file effect.c.

9703{
9705}

◆ d3d10_effect_sampler_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsRasterizer ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9755 of file effect.c.

9757{
9759}

◆ d3d10_effect_sampler_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsRenderTargetView ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9719 of file effect.c.

◆ d3d10_effect_sampler_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsSampler ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9761 of file effect.c.

9763{
9765}

◆ d3d10_effect_sampler_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsScalar ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9689 of file effect.c.

9691{
9693}

◆ d3d10_effect_sampler_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsShader ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9737 of file effect.c.

9739{
9741}

◆ d3d10_effect_sampler_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsShaderResource ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9713 of file effect.c.

◆ d3d10_effect_sampler_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsString ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9707 of file effect.c.

9709{
9711}

◆ d3d10_effect_sampler_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_AsVector ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9695 of file effect.c.

9697{
9699}

◆ d3d10_effect_sampler_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetAnnotationByIndex ( ID3D10EffectSamplerVariable *  iface,
UINT  index 
)
static

Definition at line 9647 of file effect.c.

◆ d3d10_effect_sampler_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetAnnotationByName ( ID3D10EffectSamplerVariable *  iface,
const char *  name 
)
static

Definition at line 9653 of file effect.c.

◆ d3d10_effect_sampler_variable_GetBackingStore()

static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetBackingStore ( ID3D10EffectSamplerVariable *  iface,
UINT  index,
D3D10_SAMPLER_DESC *  desc 
)
static

Definition at line 9803 of file effect.c.

9805{
9807
9808 TRACE("iface %p, index %u, desc %p.\n", iface, index, desc);
9809
9810 if (!iface->lpVtbl->IsValid(iface))
9811 {
9812 WARN("Invalid variable.\n");
9813 return E_FAIL;
9814 }
9815
9816 if (!(v = d3d10_get_state_variable(v, index, &v->effect->samplers)))
9817 return E_FAIL;
9818
9819 *desc = v->u.state.desc.sampler.desc;
9820
9821 return S_OK;
9822}
static struct d3d10_effect_variable * impl_from_ID3D10EffectSamplerVariable(ID3D10EffectSamplerVariable *iface)
Definition: effect.c:9620

◆ d3d10_effect_sampler_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetDesc ( ID3D10EffectSamplerVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 9641 of file effect.c.

9643{
9645}

◆ d3d10_effect_sampler_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetElement ( ID3D10EffectSamplerVariable *  iface,
UINT  index 
)
static

Definition at line 9677 of file effect.c.

9679{
9681}

◆ d3d10_effect_sampler_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetMemberByIndex ( ID3D10EffectSamplerVariable *  iface,
UINT  index 
)
static

Definition at line 9659 of file effect.c.

◆ d3d10_effect_sampler_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetMemberByName ( ID3D10EffectSamplerVariable *  iface,
const char *  name 
)
static

Definition at line 9665 of file effect.c.

◆ d3d10_effect_sampler_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetMemberBySemantic ( ID3D10EffectSamplerVariable *  iface,
const char *  semantic 
)
static

Definition at line 9671 of file effect.c.

9673{
9675}

◆ d3d10_effect_sampler_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetParentConstantBuffer ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9683 of file effect.c.

◆ d3d10_effect_sampler_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetRawValue ( ID3D10EffectSamplerVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 9773 of file effect.c.

◆ d3d10_effect_sampler_variable_GetSampler()

static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetSampler ( ID3D10EffectSamplerVariable *  iface,
UINT  index,
ID3D10SamplerState **  sampler 
)
static

Definition at line 9781 of file effect.c.

9783{
9785
9786 TRACE("iface %p, index %u, sampler %p.\n", iface, index, sampler);
9787
9788 if (!iface->lpVtbl->IsValid(iface))
9789 {
9790 WARN("Invalid variable.\n");
9791 return E_FAIL;
9792 }
9793
9794 if (!(v = d3d10_get_state_variable(v, index, &v->effect->samplers)))
9795 return E_FAIL;
9796
9797 if ((*sampler = v->u.state.object.sampler))
9798 ID3D10SamplerState_AddRef(*sampler);
9799
9800 return S_OK;
9801}
GLuint sampler
Definition: glext.h:7283

◆ d3d10_effect_sampler_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetType ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9635 of file effect.c.

9637{
9639}

◆ d3d10_effect_sampler_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_sampler_variable_IsValid ( ID3D10EffectSamplerVariable *  iface)
static

Definition at line 9626 of file effect.c.

9627{
9629
9630 TRACE("iface %p\n", iface);
9631
9632 return v != &null_sampler_variable;
9633}
static struct d3d10_effect_variable null_sampler_variable
Definition: effect.c:99

◆ d3d10_effect_sampler_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_SetRawValue ( ID3D10EffectSamplerVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 9767 of file effect.c.

◆ d3d10_effect_scalar_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsBlend ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6546 of file effect.c.

6548{
6550}

◆ d3d10_effect_scalar_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsConstantBuffer ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6534 of file effect.c.

◆ d3d10_effect_scalar_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsDepthStencil ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6552 of file effect.c.

6554{
6556}

◆ d3d10_effect_scalar_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsDepthStencilView ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6528 of file effect.c.

◆ d3d10_effect_scalar_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsMatrix ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6504 of file effect.c.

6506{
6508}

◆ d3d10_effect_scalar_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsRasterizer ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6558 of file effect.c.

6560{
6562}

◆ d3d10_effect_scalar_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsRenderTargetView ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6522 of file effect.c.

◆ d3d10_effect_scalar_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsSampler ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6564 of file effect.c.

6566{
6568}

◆ d3d10_effect_scalar_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsScalar ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6492 of file effect.c.

6494{
6496}

◆ d3d10_effect_scalar_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsShader ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6540 of file effect.c.

6542{
6544}

◆ d3d10_effect_scalar_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsShaderResource ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6516 of file effect.c.

◆ d3d10_effect_scalar_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsString ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6510 of file effect.c.

6512{
6514}

◆ d3d10_effect_scalar_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_AsVector ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6498 of file effect.c.

6500{
6502}

◆ d3d10_effect_scalar_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetAnnotationByIndex ( ID3D10EffectScalarVariable *  iface,
UINT  index 
)
static

Definition at line 6450 of file effect.c.

◆ d3d10_effect_scalar_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetAnnotationByName ( ID3D10EffectScalarVariable *  iface,
const char *  name 
)
static

Definition at line 6456 of file effect.c.

◆ d3d10_effect_scalar_variable_GetBool()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetBool ( ID3D10EffectScalarVariable *  iface,
BOOL *  value 
)
static

Definition at line 6684 of file effect.c.

6686{
6688
6689 TRACE("iface %p, value %p.\n", iface, value);
6691
6692 return S_OK;
6693}
static struct d3d10_effect_variable * impl_from_ID3D10EffectScalarVariable(ID3D10EffectScalarVariable *iface)
Definition: effect.c:6424
static void read_variable_from_buffer(struct d3d10_effect_variable *variable, void *dst, D3D_SHADER_VARIABLE_TYPE dst_type)
Definition: effect.c:6374

◆ d3d10_effect_scalar_variable_GetBoolArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetBoolArray ( ID3D10EffectScalarVariable *  iface,
BOOL *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 6706 of file effect.c.

6708{
6710
6711 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
6713
6714 return S_OK;
6715}
static void read_variable_array_from_buffer(struct d3d10_effect_variable *variable, void *dst, D3D_SHADER_VARIABLE_TYPE dst_type, unsigned int offset, unsigned int count)
Definition: effect.c:6383
GLboolean GLenum GLenum GLvoid * values
Definition: glext.h:5666

◆ d3d10_effect_scalar_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetDesc ( ID3D10EffectScalarVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 6444 of file effect.c.

6446{
6448}

◆ d3d10_effect_scalar_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetElement ( ID3D10EffectScalarVariable *  iface,
UINT  index 
)
static

Definition at line 6480 of file effect.c.

6482{
6484}

◆ d3d10_effect_scalar_variable_GetFloat()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetFloat ( ID3D10EffectScalarVariable *  iface,
float *  value 
)
static

Definition at line 6595 of file effect.c.

6597{
6599
6600 TRACE("iface %p, value %p.\n", iface, value);
6602
6603 return S_OK;
6604}

◆ d3d10_effect_scalar_variable_GetFloatArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetFloatArray ( ID3D10EffectScalarVariable *  iface,
float *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 6618 of file effect.c.

6620{
6622
6623 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
6625
6626 return S_OK;
6627}

◆ d3d10_effect_scalar_variable_GetInt()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetInt ( ID3D10EffectScalarVariable *  iface,
int *  value 
)
static

Definition at line 6640 of file effect.c.

6642{
6644
6645 TRACE("iface %p, value %p.\n", iface, value);
6647
6648 return S_OK;
6649}

◆ d3d10_effect_scalar_variable_GetIntArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetIntArray ( ID3D10EffectScalarVariable *  iface,
int *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 6662 of file effect.c.

6664{
6666
6667 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
6669
6670 return S_OK;
6671}

◆ d3d10_effect_scalar_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetMemberByIndex ( ID3D10EffectScalarVariable *  iface,
UINT  index 
)
static

Definition at line 6462 of file effect.c.

◆ d3d10_effect_scalar_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetMemberByName ( ID3D10EffectScalarVariable *  iface,
const char *  name 
)
static

Definition at line 6468 of file effect.c.

◆ d3d10_effect_scalar_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetMemberBySemantic ( ID3D10EffectScalarVariable *  iface,
const char *  semantic 
)
static

Definition at line 6474 of file effect.c.

6476{
6478}

◆ d3d10_effect_scalar_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetParentConstantBuffer ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6486 of file effect.c.

◆ d3d10_effect_scalar_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetRawValue ( ID3D10EffectScalarVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 6576 of file effect.c.

◆ d3d10_effect_scalar_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_scalar_variable_GetType ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6438 of file effect.c.

6440{
6442}

◆ d3d10_effect_scalar_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_scalar_variable_IsValid ( ID3D10EffectScalarVariable *  iface)
static

Definition at line 6429 of file effect.c.

6430{
6432
6433 TRACE("iface %p\n", iface);
6434
6435 return v != &null_scalar_variable;
6436}
static struct d3d10_effect_variable null_scalar_variable
Definition: effect.c:79

◆ d3d10_effect_scalar_variable_SetBool()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetBool ( ID3D10EffectScalarVariable *  iface,
BOOL  value 
)
static

Definition at line 6673 of file effect.c.

6675{
6677
6678 TRACE("iface %p, value %d.\n", iface, value);
6680
6681 return S_OK;
6682}
static void write_variable_to_buffer(struct d3d10_effect_variable *variable, void *src, D3D_SHADER_VARIABLE_TYPE src_type)
Definition: effect.c:6322

◆ d3d10_effect_scalar_variable_SetBoolArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetBoolArray ( ID3D10EffectScalarVariable *  iface,
BOOL *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 6695 of file effect.c.

6697{
6699
6700 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
6702
6703 return S_OK;
6704}
static void write_variable_array_to_buffer(struct d3d10_effect_variable *variable, void *src, D3D_SHADER_VARIABLE_TYPE src_type, unsigned int offset, unsigned int count)
Definition: effect.c:6333

◆ d3d10_effect_scalar_variable_SetFloat()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetFloat ( ID3D10EffectScalarVariable *  iface,
float  value 
)
static

Definition at line 6584 of file effect.c.

6586{
6588
6589 TRACE("iface %p, value %.8e.\n", iface, value);
6591
6592 return S_OK;
6593}

◆ d3d10_effect_scalar_variable_SetFloatArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetFloatArray ( ID3D10EffectScalarVariable *  iface,
float *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 6607 of file effect.c.

6609{
6611
6612 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
6614
6615 return S_OK;
6616}

◆ d3d10_effect_scalar_variable_SetInt()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetInt ( ID3D10EffectScalarVariable *  iface,
int  value 
)
static

Definition at line 6629 of file effect.c.

6631{
6633
6634 TRACE("iface %p, value %d.\n", iface, value);
6636
6637 return S_OK;
6638}

◆ d3d10_effect_scalar_variable_SetIntArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetIntArray ( ID3D10EffectScalarVariable *  iface,
int *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 6651 of file effect.c.

6653{
6655
6656 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
6658
6659 return S_OK;
6660}

◆ d3d10_effect_scalar_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_scalar_variable_SetRawValue ( ID3D10EffectScalarVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 6570 of file effect.c.

◆ d3d10_effect_shader_resource_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsBlend ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7900 of file effect.c.

7902{
7904}

◆ d3d10_effect_shader_resource_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsConstantBuffer ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7888 of file effect.c.

◆ d3d10_effect_shader_resource_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsDepthStencil ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7906 of file effect.c.

7908{
7910}

◆ d3d10_effect_shader_resource_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsDepthStencilView ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7882 of file effect.c.

◆ d3d10_effect_shader_resource_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsMatrix ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7858 of file effect.c.

7860{
7862}

◆ d3d10_effect_shader_resource_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsRasterizer ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7912 of file effect.c.

7914{
7916}

◆ d3d10_effect_shader_resource_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsRenderTargetView ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7876 of file effect.c.

◆ d3d10_effect_shader_resource_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsSampler ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7918 of file effect.c.

7920{
7922}

◆ d3d10_effect_shader_resource_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsScalar ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7846 of file effect.c.

7848{
7850}

◆ d3d10_effect_shader_resource_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsShader ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7894 of file effect.c.

7896{
7898}

◆ d3d10_effect_shader_resource_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsShaderResource ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7870 of file effect.c.

◆ d3d10_effect_shader_resource_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsString ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7864 of file effect.c.

7866{
7868}

◆ d3d10_effect_shader_resource_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_AsVector ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7852 of file effect.c.

7854{
7856}

◆ d3d10_effect_shader_resource_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetAnnotationByIndex ( ID3D10EffectShaderResourceVariable *  iface,
UINT  index 
)
static

Definition at line 7804 of file effect.c.

◆ d3d10_effect_shader_resource_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetAnnotationByName ( ID3D10EffectShaderResourceVariable *  iface,
const char *  name 
)
static

Definition at line 7810 of file effect.c.

◆ d3d10_effect_shader_resource_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetDesc ( ID3D10EffectShaderResourceVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 7798 of file effect.c.

7800{
7802}

◆ d3d10_effect_shader_resource_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetElement ( ID3D10EffectShaderResourceVariable *  iface,
UINT  index 
)
static

Definition at line 7834 of file effect.c.

7836{
7838}

◆ d3d10_effect_shader_resource_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetMemberByIndex ( ID3D10EffectShaderResourceVariable *  iface,
UINT  index 
)
static

Definition at line 7816 of file effect.c.

◆ d3d10_effect_shader_resource_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetMemberByName ( ID3D10EffectShaderResourceVariable *  iface,
const char *  name 
)
static

Definition at line 7822 of file effect.c.

◆ d3d10_effect_shader_resource_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetMemberBySemantic ( ID3D10EffectShaderResourceVariable *  iface,
const char *  semantic 
)
static

Definition at line 7828 of file effect.c.

7830{
7832}

◆ d3d10_effect_shader_resource_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetParentConstantBuffer ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7840 of file effect.c.

◆ d3d10_effect_shader_resource_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetRawValue ( ID3D10EffectShaderResourceVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7930 of file effect.c.

◆ d3d10_effect_shader_resource_variable_GetResource()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetResource ( ID3D10EffectShaderResourceVariable *  iface,
ID3D10ShaderResourceView **  resource 
)
static

Definition at line 7953 of file effect.c.

7955{
7956 FIXME("iface %p, resource %p stub!\n", iface, resource);
7957
7958 return E_NOTIMPL;
7959}

◆ d3d10_effect_shader_resource_variable_GetResourceArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetResourceArray ( ID3D10EffectShaderResourceVariable *  iface,
ID3D10ShaderResourceView **  resources,
UINT  offset,
UINT  count 
)
static

Definition at line 7993 of file effect.c.

7995{
7996 FIXME("iface %p, resources %p, offset %u, count %u stub!\n", iface, resources, offset, count);
7997
7998 return E_NOTIMPL;
7999}
FxCmResList * resources

◆ d3d10_effect_shader_resource_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_GetType ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7792 of file effect.c.

7794{
7796}

◆ d3d10_effect_shader_resource_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_IsValid ( ID3D10EffectShaderResourceVariable *  iface)
static

Definition at line 7783 of file effect.c.

7784{
7786
7787 TRACE("iface %p.\n", iface);
7788
7790}
static struct d3d10_effect_variable null_shader_resource_variable
Definition: effect.c:104
static struct d3d10_effect_variable * impl_from_ID3D10EffectShaderResourceVariable(ID3D10EffectShaderResourceVariable *iface)
Definition: effect.c:7777

Referenced by d3d10_effect_shader_resource_variable_SetResource().

◆ d3d10_effect_shader_resource_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_SetRawValue ( ID3D10EffectShaderResourceVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7924 of file effect.c.

◆ d3d10_effect_shader_resource_variable_SetResource()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_SetResource ( ID3D10EffectShaderResourceVariable *  iface,
ID3D10ShaderResourceView *  resource 
)
static

Definition at line 7938 of file effect.c.

7940{
7942
7943 TRACE("iface %p, resource %p.\n", iface, resource);
7944
7946 return E_FAIL;
7947
7948 set_shader_resource_variable(&resource, v->u.resource.srv);
7949
7950 return S_OK;
7951}
static BOOL STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_IsValid(ID3D10EffectShaderResourceVariable *iface)
Definition: effect.c:7783
static void set_shader_resource_variable(ID3D10ShaderResourceView **src, ID3D10ShaderResourceView **dst)
Definition: effect.c:7762

Referenced by d3d10_effect_shader_resource_variable_SetResourceArray().

◆ d3d10_effect_shader_resource_variable_SetResourceArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_SetResourceArray ( ID3D10EffectShaderResourceVariable *  iface,
ID3D10ShaderResourceView **  resources,
UINT  offset,
UINT  count 
)
static

Definition at line 7961 of file effect.c.

7963{
7965 ID3D10ShaderResourceView **rsrc_view;
7966 unsigned int i;
7967
7968 TRACE("iface %p, resources %p, offset %u, count %u.\n", iface, resources, offset, count);
7969
7970 if (!v->type->element_count)
7972
7973 if (offset >= v->type->element_count)
7974 {
7975 WARN("Offset %u larger than element count %u, ignoring.\n", offset, v->type->element_count);
7976 return S_OK;
7977 }
7978
7979 if (count > v->type->element_count - offset)
7980 {
7981 WARN("Offset %u, count %u overruns the variable (element count %u), fixing up.\n",
7982 offset, count, v->type->element_count);
7983 count = v->type->element_count - offset;
7984 }
7985
7986 rsrc_view = &v->u.resource.srv[offset];
7987 for (i = 0; i < count; ++i)
7988 set_shader_resource_variable(&resources[i], &rsrc_view[i]);
7989
7990 return S_OK;
7991}
static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_resource_variable_SetResource(ID3D10EffectShaderResourceVariable *iface, ID3D10ShaderResourceView *resource)
Definition: effect.c:7938

◆ d3d10_effect_shader_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsBlend ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8620 of file effect.c.

8622{
8624}

◆ d3d10_effect_shader_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsConstantBuffer ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8608 of file effect.c.

◆ d3d10_effect_shader_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsDepthStencil ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8626 of file effect.c.

8628{
8630}

◆ d3d10_effect_shader_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsDepthStencilView ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8602 of file effect.c.

◆ d3d10_effect_shader_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsMatrix ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8578 of file effect.c.

8580{
8582}

◆ d3d10_effect_shader_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsRasterizer ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8632 of file effect.c.

8634{
8636}

◆ d3d10_effect_shader_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsRenderTargetView ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8596 of file effect.c.

◆ d3d10_effect_shader_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsSampler ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8638 of file effect.c.

8640{
8642}

◆ d3d10_effect_shader_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsScalar ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8566 of file effect.c.

8568{
8570}

◆ d3d10_effect_shader_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsShader ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8614 of file effect.c.

8616{
8618}

◆ d3d10_effect_shader_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsShaderResource ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8590 of file effect.c.

◆ d3d10_effect_shader_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsString ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8584 of file effect.c.

8586{
8588}

◆ d3d10_effect_shader_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_AsVector ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8572 of file effect.c.

8574{
8576}

◆ d3d10_effect_shader_variable_destroy()

static void d3d10_effect_shader_variable_destroy ( struct d3d10_effect_shader_variable *  s,
D3D10_SHADER_VARIABLE_TYPE  type 
)
static

Definition at line 4346 of file effect.c.

4348{
4349 if (s->reflection)
4350 s->reflection->lpVtbl->Release(s->reflection);
4351 if (s->input_signature)
4352 ID3D10Blob_Release(s->input_signature);
4353 if (s->bytecode)
4354 ID3D10Blob_Release(s->bytecode);
4355
4356 switch (type)
4357 {
4361 if (s->shader.object)
4362 IUnknown_Release(s->shader.object);
4363 break;
4364
4365 default:
4366 FIXME("Unhandled shader type %s.\n", debug_d3d10_shader_variable_type(type));
4367 break;
4368 }
4369
4370 if (s->resource_count)
4371 free(s->resources);
4372}
GLdouble s
Definition: gl.h:2039

Referenced by d3d10_effect_variable_destroy().

◆ d3d10_effect_shader_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetAnnotationByIndex ( ID3D10EffectShaderVariable *  iface,
UINT  index 
)
static

Definition at line 8524 of file effect.c.

◆ d3d10_effect_shader_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetAnnotationByName ( ID3D10EffectShaderVariable *  iface,
const char *  name 
)
static

Definition at line 8530 of file effect.c.

◆ d3d10_effect_shader_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetDesc ( ID3D10EffectShaderVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 8518 of file effect.c.

8520{
8522}

◆ d3d10_effect_shader_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetElement ( ID3D10EffectShaderVariable *  iface,
UINT  index 
)
static

Definition at line 8554 of file effect.c.

8556{
8558}

◆ d3d10_effect_shader_variable_GetGeometryShader()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetGeometryShader ( ID3D10EffectShaderVariable *  iface,
UINT  index,
ID3D10GeometryShader **  shader 
)
static

Definition at line 8753 of file effect.c.

8755{
8759 HRESULT hr;
8760
8761 TRACE("iface %p, index %u, shader %p.\n", iface, index, shader);
8762
8763 *shader = NULL;
8764
8765 if (FAILED(hr = d3d10_get_shader_variable(v, index, &s, &basetype)))
8766 return hr;
8767
8768 if (basetype != D3D10_SVT_GEOMETRYSHADER)
8769 {
8770 WARN("Shader is not a geometry shader.\n");
8771 return D3DERR_INVALIDCALL;
8772 }
8773
8774 if ((*shader = s->shader.gs))
8775 ID3D10GeometryShader_AddRef(*shader);
8776
8777 return S_OK;
8778}
D3D_SHADER_VARIABLE_TYPE D3D10_SHADER_VARIABLE_TYPE
Definition: d3d10shader.idl:60
static HRESULT d3d10_get_shader_variable(struct d3d10_effect_variable *v, UINT shader_index, struct d3d10_effect_shader_variable **s, D3D10_SHADER_VARIABLE_TYPE *basetype)
Definition: effect.c:8658
static struct d3d10_effect_variable * impl_from_ID3D10EffectShaderVariable(ID3D10EffectShaderVariable *iface)
Definition: effect.c:138
GLuint shader
Definition: glext.h:6030

◆ d3d10_effect_shader_variable_GetInputSignatureElementDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetInputSignatureElementDesc ( ID3D10EffectShaderVariable *  iface,
UINT  shader_index,
UINT  element_index,
D3D10_SIGNATURE_PARAMETER_DESC *  desc 
)
static

Definition at line 8825 of file effect.c.

8828{
8830
8831 TRACE("iface %p, shader_index %u, element_index %u, desc %p\n",
8832 iface, shader_index, element_index, desc);
8833
8834 if (!iface->lpVtbl->IsValid(iface))
8835 {
8836 WARN("Null variable specified\n");
8837 return E_FAIL;
8838 }
8839
8840 return d3d10_get_shader_variable_signature(v, shader_index, element_index, FALSE, desc);
8841}
static HRESULT d3d10_get_shader_variable_signature(struct d3d10_effect_variable *v, UINT shader_index, UINT element_index, BOOL output, D3D10_SIGNATURE_PARAMETER_DESC *desc)
Definition: effect.c:8807

◆ d3d10_effect_shader_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetMemberByIndex ( ID3D10EffectShaderVariable *  iface,
UINT  index 
)
static

Definition at line 8536 of file effect.c.

◆ d3d10_effect_shader_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetMemberByName ( ID3D10EffectShaderVariable *  iface,
const char *  name 
)
static

Definition at line 8542 of file effect.c.

◆ d3d10_effect_shader_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetMemberBySemantic ( ID3D10EffectShaderVariable *  iface,
const char *  semantic 
)
static

Definition at line 8548 of file effect.c.

8550{
8552}

◆ d3d10_effect_shader_variable_GetOutputSignatureElementDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetOutputSignatureElementDesc ( ID3D10EffectShaderVariable *  iface,
UINT  shader_index,
UINT  element_index,
D3D10_SIGNATURE_PARAMETER_DESC *  desc 
)
static

Definition at line 8843 of file effect.c.

8846{
8848
8849 TRACE("iface %p, shader_index %u, element_index %u, desc %p\n",
8850 iface, shader_index, element_index, desc);
8851
8852 if (!iface->lpVtbl->IsValid(iface))
8853 {
8854 WARN("Null variable specified\n");
8855 return E_FAIL;
8856 }
8857
8858 return d3d10_get_shader_variable_signature(v, shader_index, element_index, TRUE, desc);
8859}

◆ d3d10_effect_shader_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetParentConstantBuffer ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8560 of file effect.c.

◆ d3d10_effect_shader_variable_GetPixelShader()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetPixelShader ( ID3D10EffectShaderVariable *  iface,
UINT  index,
ID3D10PixelShader **  shader 
)
static

Definition at line 8780 of file effect.c.

8782{
8786 HRESULT hr;
8787
8788 TRACE("iface %p, index %u, shader %p.\n", iface, index, shader);
8789
8790 *shader = NULL;
8791
8792 if (FAILED(hr = d3d10_get_shader_variable(v, index, &s, &basetype)))
8793 return hr;
8794
8795 if (basetype != D3D10_SVT_PIXELSHADER)
8796 {
8797 WARN("Shader is not a pixel shader.\n");
8798 return D3DERR_INVALIDCALL;
8799 }
8800
8801 if ((*shader = s->shader.ps))
8802 ID3D10PixelShader_AddRef(*shader);
8803
8804 return S_OK;
8805}

◆ d3d10_effect_shader_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetRawValue ( ID3D10EffectShaderVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 8650 of file effect.c.

◆ d3d10_effect_shader_variable_GetShaderDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetShaderDesc ( ID3D10EffectShaderVariable *  iface,
UINT  index,
D3D10_EFFECT_SHADER_DESC *  desc 
)
static

Definition at line 8691 of file effect.c.

8693{
8696 D3D10_SHADER_DESC shader_desc;
8697 HRESULT hr;
8698
8699 TRACE("iface %p, index %u, desc %p.\n", iface, index, desc);
8700
8702 return hr;
8703
8704 memset(desc, 0, sizeof(*desc));
8705 if (s->input_signature)
8706 desc->pInputSignature = ID3D10Blob_GetBufferPointer(s->input_signature);
8707 desc->SODecl = s->stream_output_declaration;
8708 desc->IsInline = s->isinline;
8709 if (s->bytecode)
8710 {
8711 desc->pBytecode = ID3D10Blob_GetBufferPointer(s->bytecode);
8712 desc->BytecodeLength = ID3D10Blob_GetBufferSize(s->bytecode);
8713 }
8714 if (s->reflection)
8715 {
8716 if (SUCCEEDED(hr = s->reflection->lpVtbl->GetDesc(s->reflection, &shader_desc)))
8717 {
8718 desc->NumInputSignatureEntries = shader_desc.InputParameters;
8719 desc->NumOutputSignatureEntries = shader_desc.OutputParameters;
8720 }
8721 }
8722
8723 return hr;
8724}
#define SUCCEEDED(hr)
Definition: intsafe.h:50

◆ d3d10_effect_shader_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_shader_variable_GetType ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8512 of file effect.c.

8514{
8516}

◆ d3d10_effect_shader_variable_GetVertexShader()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_GetVertexShader ( ID3D10EffectShaderVariable *  iface,
UINT  index,
ID3D10VertexShader **  shader 
)
static

Definition at line 8726 of file effect.c.

8728{
8732 HRESULT hr;
8733
8734 TRACE("iface %p, index %u, shader %p.\n", iface, index, shader);
8735
8736 *shader = NULL;
8737
8738 if (FAILED(hr = d3d10_get_shader_variable(v, index, &s, &basetype)))
8739 return hr;
8740
8741 if (basetype != D3D10_SVT_VERTEXSHADER)
8742 {
8743 WARN("Shader is not a vertex shader.\n");
8744 return D3DERR_INVALIDCALL;
8745 }
8746
8747 if ((*shader = s->shader.vs))
8748 ID3D10VertexShader_AddRef(*shader);
8749
8750 return S_OK;
8751}

◆ d3d10_effect_shader_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_shader_variable_IsValid ( ID3D10EffectShaderVariable *  iface)
static

Definition at line 8503 of file effect.c.

8504{
8506
8507 TRACE("iface %p\n", iface);
8508
8509 return v != &null_shader_variable;
8510}

◆ d3d10_effect_shader_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_shader_variable_SetRawValue ( ID3D10EffectShaderVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 8644 of file effect.c.

◆ d3d10_effect_string_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsBlend ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7663 of file effect.c.

7665{
7667}

◆ d3d10_effect_string_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_string_variable_AsConstantBuffer ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7651 of file effect.c.

◆ d3d10_effect_string_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsDepthStencil ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7669 of file effect.c.

7671{
7673}

◆ d3d10_effect_string_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsDepthStencilView ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7645 of file effect.c.

◆ d3d10_effect_string_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsMatrix ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7621 of file effect.c.

7623{
7625}

◆ d3d10_effect_string_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsRasterizer ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7675 of file effect.c.

7677{
7679}

◆ d3d10_effect_string_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsRenderTargetView ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7639 of file effect.c.

◆ d3d10_effect_string_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsSampler ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7681 of file effect.c.

7683{
7685}

◆ d3d10_effect_string_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsScalar ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7609 of file effect.c.

7611{
7613}

◆ d3d10_effect_string_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsShader ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7657 of file effect.c.

7659{
7661}

◆ d3d10_effect_string_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsShaderResource ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7633 of file effect.c.

◆ d3d10_effect_string_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsString ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7627 of file effect.c.

7629{
7631}

◆ d3d10_effect_string_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_AsVector ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7615 of file effect.c.

7617{
7619}

◆ d3d10_effect_string_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetAnnotationByIndex ( ID3D10EffectStringVariable *  iface,
UINT  index 
)
static

Definition at line 7567 of file effect.c.

◆ d3d10_effect_string_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetAnnotationByName ( ID3D10EffectStringVariable *  iface,
const char *  name 
)
static

Definition at line 7573 of file effect.c.

◆ d3d10_effect_string_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_GetDesc ( ID3D10EffectStringVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 7561 of file effect.c.

7563{
7565}

◆ d3d10_effect_string_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetElement ( ID3D10EffectStringVariable *  iface,
UINT  index 
)
static

Definition at line 7597 of file effect.c.

7599{
7601}

◆ d3d10_effect_string_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetMemberByIndex ( ID3D10EffectStringVariable *  iface,
UINT  index 
)
static

Definition at line 7579 of file effect.c.

◆ d3d10_effect_string_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetMemberByName ( ID3D10EffectStringVariable *  iface,
const char *  name 
)
static

Definition at line 7585 of file effect.c.

◆ d3d10_effect_string_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_string_variable_GetMemberBySemantic ( ID3D10EffectStringVariable *  iface,
const char *  semantic 
)
static

Definition at line 7591 of file effect.c.

7593{
7595}

◆ d3d10_effect_string_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_string_variable_GetParentConstantBuffer ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7603 of file effect.c.

◆ d3d10_effect_string_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_GetRawValue ( ID3D10EffectStringVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7693 of file effect.c.

◆ d3d10_effect_string_variable_GetString()

static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_GetString ( ID3D10EffectStringVariable *  iface,
const char **  str 
)
static

Definition at line 7701 of file effect.c.

7703{
7705 char *value = (char *)var->u.buffer.local_buffer;
7706
7707 TRACE("iface %p, str %p.\n", iface, str);
7708
7709 if (!value)
7710 return E_FAIL;
7711
7712 if (!str)
7713 return E_INVALIDARG;
7714
7715 *str = value;
7716
7717 return S_OK;
7718}
static struct d3d10_effect_variable * impl_from_ID3D10EffectStringVariable(ID3D10EffectStringVariable *iface)
Definition: effect.c:7541
const WCHAR * str

◆ d3d10_effect_string_variable_GetStringArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_GetStringArray ( ID3D10EffectStringVariable *  iface,
const char **  strs,
UINT  offset,
UINT  count 
)
static

Definition at line 7720 of file effect.c.

7722{
7723 FIXME("iface %p, strs %p, offset %u, count %u stub!\n", iface, strs, offset, count);
7724
7725 return E_NOTIMPL;
7726}

◆ d3d10_effect_string_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_string_variable_GetType ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7555 of file effect.c.

7557{
7559}

◆ d3d10_effect_string_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_string_variable_IsValid ( ID3D10EffectStringVariable *  iface)
static

Definition at line 7546 of file effect.c.

7547{
7549
7550 TRACE("iface %p\n", iface);
7551
7552 return v != &null_string_variable;
7553}
static struct d3d10_effect_variable null_string_variable
Definition: effect.c:85

◆ d3d10_effect_string_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_string_variable_SetRawValue ( ID3D10EffectStringVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 7687 of file effect.c.

◆ d3d10_effect_technique_ComputeStateBlockMask()

static HRESULT STDMETHODCALLTYPE d3d10_effect_technique_ComputeStateBlockMask ( ID3D10EffectTechnique *  iface,
D3D10_STATE_BLOCK_MASK *  mask 
)
static

Definition at line 5133 of file effect.c.

5135{
5136 FIXME("iface %p,mask %p stub!\n", iface, mask);
5137
5138 return E_NOTIMPL;
5139}

◆ d3d10_effect_technique_destroy()

static void d3d10_effect_technique_destroy ( struct d3d10_effect_technique *  t)
static

Definition at line 4478 of file effect.c.

4479{
4480 unsigned int i;
4481
4482 TRACE("technique %p\n", t);
4483
4484 free(t->name);
4485 if (t->passes)
4486 {
4487 for (i = 0; i < t->pass_count; ++i)
4488 {
4489 d3d10_effect_pass_destroy(&t->passes[i]);
4490 }
4491 free(t->passes);
4492 }
4493
4494 d3d10_effect_annotations_destroy(&t->annotations);
4495}
static void d3d10_effect_pass_destroy(struct d3d10_effect_pass *p)
Definition: effect.c:4469

Referenced by d3d10_effect_Release().

◆ d3d10_effect_technique_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_technique_GetAnnotationByIndex ( ID3D10EffectTechnique *  iface,
UINT  index 
)
static

Definition at line 5067 of file effect.c.

5069{
5071
5072 TRACE("iface %p, index %u\n", iface, index);
5073
5075}
static struct d3d10_effect_technique * impl_from_ID3D10EffectTechnique(ID3D10EffectTechnique *iface)
Definition: effect.c:4989
struct d3d10_effect_annotations annotations

◆ d3d10_effect_technique_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_technique_GetAnnotationByName ( ID3D10EffectTechnique *  iface,
const char *  name 
)
static

Definition at line 5077 of file effect.c.

5079{
5081
5082 TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
5083
5085}

◆ d3d10_effect_technique_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_technique_GetDesc ( ID3D10EffectTechnique *  iface,
D3D10_TECHNIQUE_DESC *  desc 
)
static

Definition at line 5003 of file effect.c.

5005{
5007
5008 TRACE("iface %p, desc %p\n", iface, desc);
5009
5010 if (tech == &null_technique)
5011 {
5012 WARN("Null technique specified\n");
5013 return E_FAIL;
5014 }
5015
5016 if (!desc)
5017 {
5018 WARN("Invalid argument specified\n");
5019 return E_INVALIDARG;
5020 }
5021
5022 desc->Name = tech->name;
5023 desc->Passes = tech->pass_count;
5024 desc->Annotations = tech->annotations.count;
5025
5026 return S_OK;
5027}

◆ d3d10_effect_technique_GetPassByIndex()

static struct ID3D10EffectPass *STDMETHODCALLTYPE d3d10_effect_technique_GetPassByIndex ( ID3D10EffectTechnique *  iface,
UINT  index 
)
static

Definition at line 5087 of file effect.c.

5089{
5091 struct d3d10_effect_pass *p;
5092
5093 TRACE("iface %p, index %u\n", iface, index);
5094
5095 if (index >= This->pass_count)
5096 {
5097 WARN("Invalid index specified\n");
5098 return &null_pass.ID3D10EffectPass_iface;
5099 }
5100
5101 p = &This->passes[index];
5102
5103 TRACE("Returning pass %p, %s.\n", p, debugstr_a(p->name));
5104
5105 return &p->ID3D10EffectPass_iface;
5106}

◆ d3d10_effect_technique_GetPassByName()

static struct ID3D10EffectPass *STDMETHODCALLTYPE d3d10_effect_technique_GetPassByName ( ID3D10EffectTechnique *  iface,
const char *  name 
)
static

Definition at line 5108 of file effect.c.

5110{
5112 unsigned int i;
5113
5114 TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
5115
5116 /* Do not check for name==NULL, W7/DX10 crashes in that case. */
5117
5118 for (i = 0; i < This->pass_count; ++i)
5119 {
5120 struct d3d10_effect_pass *p = &This->passes[i];
5121 if (p->name && !strcmp(p->name, name))
5122 {
5123 TRACE("Returning pass %p\n", p);
5124 return &p->ID3D10EffectPass_iface;
5125 }
5126 }
5127
5128 WARN("Invalid name specified\n");
5129
5130 return &null_pass.ID3D10EffectPass_iface;
5131}

◆ d3d10_effect_technique_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_technique_IsValid ( ID3D10EffectTechnique *  iface)
static

Definition at line 4994 of file effect.c.

4995{
4997
4998 TRACE("iface %p\n", iface);
4999
5000 return This != &null_technique;
5001}

◆ d3d10_effect_type_compare()

static int d3d10_effect_type_compare ( const void *  key,
const struct wine_rb_entry *  entry 
)
static

Definition at line 10089 of file effect.c.

10090{
10091 const struct d3d10_effect_type *t = WINE_RB_ENTRY_VALUE(entry, const struct d3d10_effect_type, entry);
10092 const DWORD *id = key;
10093
10094 return *id - t->id;
10095}
uint32_t entry
Definition: isohybrid.c:63
#define WINE_RB_ENTRY_VALUE
Definition: rbtree.h:414
Definition: copy.c:22

Referenced by d3d10_create_effect().

◆ d3d10_effect_type_destroy()

static void d3d10_effect_type_destroy ( struct wine_rb_entry *  entry,
void *  context 
)
static

Definition at line 4011 of file effect.c.

4012{
4014
4015 TRACE("effect type %p.\n", t);
4016
4017 if (t->elementtype)
4018 {
4019 free(t->elementtype->name);
4020 free(t->elementtype);
4021 }
4022
4023 if (t->members)
4024 {
4025 unsigned int i;
4026
4027 for (i = 0; i < t->member_count; ++i)
4028 {
4030 }
4031 free(t->members);
4032 }
4033
4034 free(t->name);
4035 free(t);
4036}
static void d3d10_effect_type_member_destroy(struct d3d10_effect_type_member *typem)
Definition: effect.c:4002

Referenced by d3d10_effect_local_buffer_destroy(), and d3d10_effect_Release().

◆ d3d10_effect_type_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_type_GetDesc ( ID3D10EffectType *  iface,
D3D10_EFFECT_TYPE_DESC *  desc 
)
static

Definition at line 9873 of file effect.c.

9874{
9876
9877 TRACE("iface %p, desc %p\n", iface, desc);
9878
9879 if (This == &null_type)
9880 {
9881 WARN("Null type specified\n");
9882 return E_FAIL;
9883 }
9884
9885 if (!desc)
9886 {
9887 WARN("Invalid argument specified\n");
9888 return E_INVALIDARG;
9889 }
9890
9891 desc->TypeName = This->name;
9892 desc->Class = This->type_class;
9893 desc->Type = This->basetype;
9894 desc->Elements = This->element_count;
9895 desc->Members = This->member_count;
9896 desc->Rows = This->row_count;
9897 desc->Columns = This->column_count;
9898 desc->PackedSize = This->size_packed;
9899 desc->UnpackedSize = This->size_unpacked;
9900 desc->Stride = This->stride;
9901
9902 return S_OK;
9903}
static struct d3d10_effect_type null_type
Definition: effect.c:74
static struct d3d10_effect_type * impl_from_ID3D10EffectType(ID3D10EffectType *iface)
Definition: effect.c:9859

◆ d3d10_effect_type_GetMemberName()

static const char *STDMETHODCALLTYPE d3d10_effect_type_GetMemberName ( ID3D10EffectType *  iface,
UINT  index 
)
static

Definition at line 9986 of file effect.c.

9987{
9989 struct d3d10_effect_type_member *typem;
9990
9991 TRACE("iface %p, index %u\n", iface, index);
9992
9993 if (index >= This->member_count)
9994 {
9995 WARN("Invalid index specified\n");
9996 return NULL;
9997 }
9998
9999 typem = &This->members[index];
10000
10001 TRACE("Returning name %s\n", debugstr_a(typem->name));
10002
10003 return typem->name;
10004}

◆ d3d10_effect_type_GetMemberSemantic()

static const char *STDMETHODCALLTYPE d3d10_effect_type_GetMemberSemantic ( ID3D10EffectType *  iface,
UINT  index 
)
static

Definition at line 10006 of file effect.c.

10007{
10009 struct d3d10_effect_type_member *typem;
10010
10011 TRACE("iface %p, index %u\n", iface, index);
10012
10013 if (index >= This->member_count)
10014 {
10015 WARN("Invalid index specified\n");
10016 return NULL;
10017 }
10018
10019 typem = &This->members[index];
10020
10021 TRACE("Returning semantic %s\n", debugstr_a(typem->semantic));
10022
10023 return typem->semantic;
10024}

◆ d3d10_effect_type_GetMemberTypeByIndex()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_type_GetMemberTypeByIndex ( ID3D10EffectType *  iface,
UINT  index 
)
static

Definition at line 9905 of file effect.c.

9907{
9909 struct d3d10_effect_type *t;
9910
9911 TRACE("iface %p, index %u\n", iface, index);
9912
9913 if (index >= This->member_count)
9914 {
9915 WARN("Invalid index specified\n");
9916 return &null_type.ID3D10EffectType_iface;
9917 }
9918
9919 t = (&This->members[index])->type;
9920
9921 TRACE("Returning member %p, %s\n", t, debugstr_a(t->name));
9922
9923 return &t->ID3D10EffectType_iface;
9924}

◆ d3d10_effect_type_GetMemberTypeByName()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_type_GetMemberTypeByName ( ID3D10EffectType *  iface,
const char *  name 
)
static

Definition at line 9926 of file effect.c.

9928{
9930 unsigned int i;
9931
9932 TRACE("iface %p, name %s\n", iface, debugstr_a(name));
9933
9934 if (!name)
9935 {
9936 WARN("Invalid name specified\n");
9937 return &null_type.ID3D10EffectType_iface;
9938 }
9939
9940 for (i = 0; i < This->member_count; ++i)
9941 {
9942 struct d3d10_effect_type_member *typem = &This->members[i];
9943
9944 if (typem->name && !strcmp(typem->name, name))
9945 {
9946 TRACE("Returning type %p.\n", typem->type);
9947 return &typem->type->ID3D10EffectType_iface;
9948 }
9949 }
9950
9951 WARN("Invalid name specified\n");
9952
9953 return &null_type.ID3D10EffectType_iface;
9954}

◆ d3d10_effect_type_GetMemberTypeBySemantic()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_type_GetMemberTypeBySemantic ( ID3D10EffectType *  iface,
const char *  semantic 
)
static

Definition at line 9956 of file effect.c.

9958{
9960 unsigned int i;
9961
9962 TRACE("iface %p, semantic %s\n", iface, debugstr_a(semantic));
9963
9964 if (!semantic)
9965 {
9966 WARN("Invalid semantic specified\n");
9967 return &null_type.ID3D10EffectType_iface;
9968 }
9969
9970 for (i = 0; i < This->member_count; ++i)
9971 {
9972 struct d3d10_effect_type_member *typem = &This->members[i];
9973
9974 if (typem->semantic && !stricmp(typem->semantic, semantic))
9975 {
9976 TRACE("Returning type %p.\n", typem->type);
9977 return &typem->type->ID3D10EffectType_iface;
9978 }
9979 }
9980
9981 WARN("Invalid semantic specified\n");
9982
9983 return &null_type.ID3D10EffectType_iface;
9984}

◆ d3d10_effect_type_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_type_IsValid ( ID3D10EffectType *  iface)
static

Definition at line 9864 of file effect.c.

9865{
9867
9868 TRACE("iface %p\n", iface);
9869
9870 return This != &null_type;
9871}

◆ d3d10_effect_type_member_destroy()

static void d3d10_effect_type_member_destroy ( struct d3d10_effect_type_member *  typem)
static

Definition at line 4002 of file effect.c.

4003{
4004 TRACE("effect type member %p.\n", typem);
4005
4006 /* Do not release typem->type, it will be covered by d3d10_effect_type_destroy(). */
4007 free(typem->semantic);
4008 free(typem->name);
4009}

Referenced by d3d10_effect_type_destroy().

◆ d3d10_effect_types_match()

static BOOL d3d10_effect_types_match ( const struct d3d10_effect_type *  t1,
const struct d3d10_effect_type *  t2 
)
static

Definition at line 4038 of file effect.c.

4040{
4041 unsigned int i;
4042
4043 if (strcmp(t1->name, t2->name)) return FALSE;
4044 if (t1->basetype != t2->basetype) return FALSE;
4045 if (t1->type_class != t2->type_class) return FALSE;
4046 if (t1->element_count != t2->element_count) return FALSE;
4048 if (t1->member_count != t2->member_count) return FALSE;
4049 if (t1->column_count != t2->column_count) return FALSE;
4050 if (t1->row_count != t2->row_count) return FALSE;
4051
4052 for (i = 0; i < t1->member_count; ++i)
4053 {
4054 if (strcmp(t1->members[i].name, t2->members[i].name)) return FALSE;
4055 if (t1->members[i].buffer_offset != t2->members[i].buffer_offset) return FALSE;
4056 if (!d3d10_effect_types_match(t1->members[i].type, t2->members[i].type)) return FALSE;
4057 }
4058
4059 return TRUE;
4060}
static BOOL d3d10_effect_types_match(const struct d3d10_effect_type *t1, const struct d3d10_effect_type *t2)
Definition: effect.c:4038
D3D10_SHADER_VARIABLE_CLASS type_class
struct d3d10_effect_type * elementtype
unsigned int member_count
D3D10_SHADER_VARIABLE_TYPE basetype
unsigned int element_count
unsigned int row_count
struct d3d10_effect_type_member * members
unsigned int column_count

Referenced by d3d10_effect_types_match(), and d3d10_effect_validate_shared_variable().

◆ d3d10_effect_update_dependent_props()

static void d3d10_effect_update_dependent_props ( struct d3d10_effect_prop_dependencies *  deps,
void *  container 
)
static

Definition at line 1306 of file effect.c.

1308{
1311 unsigned int i, j, count, variable_idx;
1312 struct d3d10_effect_variable *v;
1313 struct d3d10_reg_table *table;
1314 unsigned int *dst_index;
1316 HRESULT hr;
1317 void *dst;
1318
1319 for (i = 0; i < deps->count; ++i)
1320 {
1321 d = &deps->entries[i];
1322
1324
1325 dst = (char *)container + property_info->offset;
1326 dst_index = (unsigned int *)((char *)container + property_info->index_offset);
1327
1328 switch (d->operation)
1329 {
1330 case D3D10_EOO_VAR:
1332
1333 v = d->var.v;
1334
1335 count = v->type->type_class == D3D10_SVC_VECTOR ? 4 : 1;
1336
1337 for (j = 0; j < count; ++j)
1338 {
1339 d3d10_effect_variable_get_raw_value(v, &value, d->var.offset + j * sizeof(value), sizeof(value));
1340 d3d10_effect_read_numeric_value(value, v->type->basetype, property_info->type, dst, j);
1341 }
1342
1343 break;
1344
1346
1347 v = d->index_expr.v;
1348
1349 if (FAILED(hr = d3d10_effect_preshader_eval(&d->index_expr.index)))
1350 {
1351 WARN("Failed to evaluate index expression, hr %#lx.\n", hr);
1352 return;
1353 }
1354
1355 variable_idx = *d->index_expr.index.reg_tables[D3D10_REG_TABLE_RESULT].dword;
1356
1357 if (variable_idx >= v->type->element_count)
1358 {
1359 WARN("Expression evaluated to invalid index value %u, array %s of size %u.\n",
1360 variable_idx, debugstr_a(v->name), v->type->element_count);
1361 variable_idx = 0;
1362 }
1363
1364 /* Ignoring destination index here, there are no object typed array properties. */
1365 switch (property_info->type)
1366 {
1370 *(void **)dst = v;
1371 *dst_index = variable_idx;
1372 break;
1373 default:
1374 *(void **)dst = &v->elements[variable_idx];
1375 }
1376 break;
1377
1379
1380 if ((property_info->type != D3D10_SVT_UINT)
1381 && (property_info->type != D3D10_SVT_FLOAT)
1382 && (property_info->type != D3D10_SVT_BOOL))
1383 {
1384 FIXME("Unimplemented for property %s.\n", property_info->name);
1385 return;
1386 }
1387
1388 if (FAILED(hr = d3d10_effect_preshader_eval(&d->value_expr.value)))
1389 {
1390 WARN("Failed to evaluate value expression, hr %#lx.\n", hr);
1391 return;
1392 }
1393
1394 table = &d->value_expr.value.reg_tables[D3D10_REG_TABLE_RESULT];
1395
1396 if (property_info->size != table->count)
1397 {
1398 WARN("Unexpected value expression output size %u, property size %u.\n",
1399 table->count, property_info->size);
1400 return;
1401 }
1402
1403 memcpy(dst, table->f, property_info->size * sizeof(float));
1404
1405 break;
1406
1407 default:
1408 FIXME("Unsupported property update for %u.\n", d->operation);
1409 }
1410 }
1411}
@ D3D10_EOO_VAR
Definition: d3d10_private.h:52
@ D3D10_EOO_CONST_INDEX
Definition: d3d10_private.h:53
@ D3D10_SVC_VECTOR
Definition: d3dcommon.idl:143
UINT32 uint32_t
Definition: types.h:75
static BOOL d3d10_effect_read_numeric_value(uint32_t value, D3D_SHADER_VARIABLE_TYPE in_type, D3D_SHADER_VARIABLE_TYPE out_type, void *out_data, unsigned int out_idx)
Definition: effect.c:1287
static HRESULT d3d10_effect_variable_get_raw_value(struct d3d10_effect_variable *v, void *data, unsigned int offset, unsigned int count)
Definition: effect.c:1202
static const struct d3d10_effect_state_property_info property_infos[]
Definition: effect.c:1008
static HRESULT d3d10_effect_preshader_eval(struct d3d10_effect_preshader *p)
Definition: effect.c:928
struct d3d10_effect_prop_dependency * entries
char * value
Definition: wpp.c:53
const WCHAR * name
Definition: jsdisp.idl:28

Referenced by d3d10_effect_depth_stencil_variable_GetBackingStore(), d3d10_effect_pass_Apply(), d3d10_effect_pass_GetDesc(), d3d10_effect_pass_GetGeometryShaderDesc(), d3d10_effect_pass_GetPixelShaderDesc(), and d3d10_effect_pass_GetVertexShaderDesc().

◆ d3d10_effect_validate_shared_variable()

static HRESULT d3d10_effect_validate_shared_variable ( const struct d3d10_effect *  effect,
const struct d3d10_effect_variable *  v 
)
static

Definition at line 4062 of file effect.c.

4064{
4065 struct d3d10_effect_variable *sv;
4066
4067 switch (v->type->basetype)
4068 {
4069 case D3D10_SVT_CBUFFER:
4070 case D3D10_SVT_TBUFFER:
4071 sv = d3d10_effect_get_buffer_by_name(effect->pool, v->name);
4072 break;
4073 default:
4074 sv = d3d10_effect_get_variable_by_name(effect->pool, v->name);
4075 }
4076
4077 if (!sv)
4078 {
4079 WARN("Variable %s wasn't found in the pool.\n", debugstr_a(v->name));
4080 return E_INVALIDARG;
4081 }
4082
4083 if (!d3d10_effect_types_match(sv->type, v->type))
4084 {
4085 WARN("Variable %s type does not match pool type.\n", debugstr_a(v->name));
4086 return E_INVALIDARG;
4087 }
4088
4089 return S_OK;
4090}

Referenced by parse_fx10_body().

◆ d3d10_effect_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsBlend ( ID3D10EffectVariable *  iface)
static

◆ d3d10_effect_variable_AsConstantBuffer()

◆ d3d10_effect_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsDepthStencil ( ID3D10EffectVariable *  iface)
static

◆ d3d10_effect_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsDepthStencilView ( ID3D10EffectVariable *  iface)
static

◆ d3d10_effect_variable_AsMatrix()

◆ d3d10_effect_variable_AsRasterizer()

◆ d3d10_effect_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsRenderTargetView ( ID3D10EffectVariable *  iface)
static

◆ d3d10_effect_variable_AsSampler()

◆ d3d10_effect_variable_AsScalar()

◆ d3d10_effect_variable_AsShader()

◆ d3d10_effect_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsShaderResource ( ID3D10EffectVariable *  iface)
static

◆ d3d10_effect_variable_AsString()

◆ d3d10_effect_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_variable_AsVector ( ID3D10EffectVariable *  iface)
static

◆ d3d10_effect_variable_destroy()

static void d3d10_effect_variable_destroy ( struct d3d10_effect_variable *  v)
static

Definition at line 4387 of file effect.c.

4388{
4389 unsigned int i, elem_count;
4390
4391 TRACE("variable %p.\n", v);
4392
4393 free(v->name);
4394 free(v->semantic);
4395 d3d10_effect_annotations_destroy(&v->annotations);
4396
4397 if (v->members)
4398 {
4399 for (i = 0; i < v->type->member_count; ++i)
4400 {
4401 d3d10_effect_variable_destroy(&v->members[i]);
4402 }
4403 free(v->members);
4404 }
4405
4406 if (v->elements)
4407 {
4408 for (i = 0; i < v->type->element_count; ++i)
4409 {
4410 d3d10_effect_variable_destroy(&v->elements[i]);
4411 }
4412 free(v->elements);
4413 }
4414
4415 if (v->type)
4416 {
4417 switch (v->type->basetype)
4418 {
4422 d3d10_effect_shader_variable_destroy(&v->u.shader, v->type->basetype);
4423 break;
4424
4426 case D3D10_SVT_BLEND:
4428 case D3D10_SVT_SAMPLER:
4429 if (v->u.state.object.object)
4430 IUnknown_Release(v->u.state.object.object);
4431 d3d10_effect_clear_prop_dependencies(&v->u.state.dependencies);
4432 break;
4433
4442 if (!v->u.resource.parent)
4443 break;
4444
4445 if (!v->type->element_count)
4446 elem_count = 1;
4447 else
4448 elem_count = v->type->element_count;
4449
4450 for (i = 0; i < elem_count; ++i)
4451 {
4452 if (v->u.resource.srv[i])
4453 ID3D10ShaderResourceView_Release(v->u.resource.srv[i]);
4454 }
4455
4456 free(v->u.resource.srv);
4457 break;
4458
4459 case D3D10_SVT_STRING:
4460 free(v->u.buffer.local_buffer);
4461 break;
4462
4463 default:
4464 break;
4465 }
4466 }
4467}
@ D3D10_SVT_TEXTURE2D
Definition: d3dcommon.idl:233
@ D3D10_SVT_TEXTURE3D
Definition: d3dcommon.idl:234
@ D3D10_SVT_TEXTURE2DMSARRAY
Definition: d3dcommon.idl:259
@ D3D10_SVT_TEXTURE2DARRAY
Definition: d3dcommon.idl:255
@ D3D10_SVT_STRING
Definition: d3dcommon.idl:230
@ D3D10_SVT_TEXTURE1DARRAY
Definition: d3dcommon.idl:254
@ D3D10_SVT_TEXTURECUBE
Definition: d3dcommon.idl:235
@ D3D10_SVT_TEXTURE1D
Definition: d3dcommon.idl:232
@ D3D10_SVT_TEXTURE2DMS
Definition: d3dcommon.idl:258
static void d3d10_effect_shader_variable_destroy(struct d3d10_effect_shader_variable *s, D3D10_SHADER_VARIABLE_TYPE type)
Definition: effect.c:4346

Referenced by d3d10_effect_annotations_destroy(), d3d10_effect_local_buffer_destroy(), d3d10_effect_Release(), d3d10_effect_variable_destroy(), and parse_fx10_body().

◆ d3d10_effect_variable_get_raw_value()

static HRESULT d3d10_effect_variable_get_raw_value ( struct d3d10_effect_variable *  v,
void *  data,
unsigned int  offset,
unsigned int  count 
)
static

Definition at line 1202 of file effect.c.

1204{
1205 BOOL is_buffer;
1206
1207 is_buffer = v->type->basetype == D3D10_SVT_CBUFFER || v->type->basetype == D3D10_SVT_TBUFFER;
1208
1209 if (v->type->type_class == D3D10_SVC_OBJECT && !is_buffer)
1210 {
1211 WARN("Not supported on object variables of type %s.\n",
1212 debug_d3d10_shader_variable_type(v->type->basetype));
1213 return D3DERR_INVALIDCALL;
1214 }
1215
1216 if (!is_buffer)
1217 {
1218 offset += v->buffer_offset;
1219 v = v->buffer;
1220 }
1221
1222 memcpy(data, v->u.buffer.local_buffer + offset, count);
1223
1224 return S_OK;
1225}
@ D3D10_SVC_OBJECT
Definition: d3dcommon.idl:146
unsigned int BOOL
Definition: ntddk_ex.h:94

Referenced by d3d10_effect_update_dependent_props(), and d3d10_effect_variable_GetRawValue().

◆ d3d10_effect_variable_GetAnnotationByIndex()

◆ d3d10_effect_variable_GetAnnotationByName()

◆ d3d10_effect_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_GetDesc ( ID3D10EffectVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 5558 of file effect.c.

5560{
5562
5563 TRACE("iface %p, desc %p\n", iface, desc);
5564
5565 if (!iface->lpVtbl->IsValid(iface))
5566 {
5567 WARN("Null variable specified\n");
5568 return E_FAIL;
5569 }
5570
5571 if (!desc)
5572 {
5573 WARN("Invalid argument specified\n");
5574 return E_INVALIDARG;
5575 }
5576
5577 /* FIXME: This isn't correct. Anonymous shaders let desc->ExplicitBindPoint untouched, but normal shaders set it! */
5578 memset(desc, 0, sizeof(*desc));
5579 desc->Name = v->name;
5580 desc->Semantic = v->semantic;
5581 desc->Flags = v->flag;
5582 desc->Annotations = v->annotations.count;
5583 desc->BufferOffset = v->buffer_offset;
5584
5586 desc->ExplicitBindPoint = v->explicit_bind_point;
5587
5588 return S_OK;
5589}
const unsigned int D3D10_EFFECT_VARIABLE_EXPLICIT_BIND_POINT
Definition: d3d10effect.idl:46

Referenced by d3d10_effect_blend_variable_GetDesc(), d3d10_effect_constant_buffer_GetDesc(), d3d10_effect_depth_stencil_variable_GetDesc(), d3d10_effect_depth_stencil_view_variable_GetDesc(), d3d10_effect_matrix_variable_GetDesc(), d3d10_effect_rasterizer_variable_GetDesc(), d3d10_effect_render_target_view_variable_GetDesc(), d3d10_effect_sampler_variable_GetDesc(), d3d10_effect_scalar_variable_GetDesc(), d3d10_effect_shader_resource_variable_GetDesc(), d3d10_effect_shader_variable_GetDesc(), d3d10_effect_string_variable_GetDesc(), and d3d10_effect_vector_variable_GetDesc().

◆ d3d10_effect_variable_GetElement()

◆ d3d10_effect_variable_GetMemberByIndex()

◆ d3d10_effect_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetMemberByName ( ID3D10EffectVariable *  iface,
const char *  name 
)
static

Definition at line 5632 of file effect.c.

5634{
5636 unsigned int i;
5637
5638 TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
5639
5640 if (!name)
5641 {
5642 WARN("Invalid name specified\n");
5643 return &null_variable.ID3D10EffectVariable_iface;
5644 }
5645
5646 for (i = 0; i < This->type->member_count; ++i)
5647 {
5648 struct d3d10_effect_variable *m = &This->members[i];
5649
5650 if (m->name && !strcmp(m->name, name))
5651 {
5652 TRACE("Returning member %p\n", m);
5653 return &m->ID3D10EffectVariable_iface;
5654 }
5655 }
5656
5657 WARN("Invalid name specified\n");
5658
5659 return &null_variable.ID3D10EffectVariable_iface;
5660}

Referenced by d3d10_effect_blend_variable_GetMemberByName(), d3d10_effect_constant_buffer_GetMemberByName(), d3d10_effect_depth_stencil_variable_GetMemberByName(), d3d10_effect_depth_stencil_view_variable_GetMemberByName(), d3d10_effect_matrix_variable_GetMemberByName(), d3d10_effect_rasterizer_variable_GetMemberByName(), d3d10_effect_render_target_view_variable_GetMemberByName(), d3d10_effect_sampler_variable_GetMemberByName(), d3d10_effect_scalar_variable_GetMemberByName(), d3d10_effect_shader_resource_variable_GetMemberByName(), d3d10_effect_shader_variable_GetMemberByName(), d3d10_effect_string_variable_GetMemberByName(), and d3d10_effect_vector_variable_GetMemberByName().

◆ d3d10_effect_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_variable_GetMemberBySemantic ( ID3D10EffectVariable *  iface,
const char *  semantic 
)
static

Definition at line 5662 of file effect.c.

5664{
5666 unsigned int i;
5667
5668 TRACE("iface %p, semantic %s.\n", iface, debugstr_a(semantic));
5669
5670 if (!semantic)
5671 {
5672 WARN("Invalid semantic specified\n");
5673 return &null_variable.ID3D10EffectVariable_iface;
5674 }
5675
5676 for (i = 0; i < This->type->member_count; ++i)
5677 {
5678 struct d3d10_effect_variable *m = &This->members[i];
5679
5680 if (m->semantic && !stricmp(m->semantic, semantic))
5681 {
5682 TRACE("Returning member %p\n", m);
5683 return &m->ID3D10EffectVariable_iface;
5684 }
5685 }
5686
5687 WARN("Invalid semantic specified\n");
5688
5689 return &null_variable.ID3D10EffectVariable_iface;
5690}

Referenced by d3d10_effect_blend_variable_GetMemberBySemantic(), d3d10_effect_constant_buffer_GetMemberBySemantic(), d3d10_effect_depth_stencil_variable_GetMemberBySemantic(), d3d10_effect_depth_stencil_view_variable_GetMemberBySemantic(), d3d10_effect_matrix_variable_GetMemberBySemantic(), d3d10_effect_rasterizer_variable_GetMemberBySemantic(), d3d10_effect_render_target_view_variable_GetMemberBySemantic(), d3d10_effect_sampler_variable_GetMemberBySemantic(), d3d10_effect_scalar_variable_GetMemberBySemantic(), d3d10_effect_shader_resource_variable_GetMemberBySemantic(), d3d10_effect_shader_variable_GetMemberBySemantic(), d3d10_effect_string_variable_GetMemberBySemantic(), and d3d10_effect_vector_variable_GetMemberBySemantic().

◆ d3d10_effect_variable_GetParentConstantBuffer()

◆ d3d10_effect_variable_GetRawValue()

◆ d3d10_effect_variable_GetType()

◆ d3d10_effect_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_variable_IsValid ( ID3D10EffectVariable *  iface)
static

Definition at line 5542 of file effect.c.

5543{
5544 TRACE("iface %p\n", iface);
5545
5547}

◆ d3d10_effect_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_variable_SetRawValue ( ID3D10EffectVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 5891 of file effect.c.

5893{
5895 BOOL is_buffer;
5896
5897 TRACE("iface %p, data %p, offset %u, count %u.\n", iface, data, offset, count);
5898
5899 if (!iface->lpVtbl->IsValid(iface))
5900 {
5901 WARN("Invalid variable.\n");
5902 return E_FAIL;
5903 }
5904
5905 is_buffer = v->type->basetype == D3D10_SVT_CBUFFER || v->type->basetype == D3D10_SVT_TBUFFER;
5906
5907 if (v->type->type_class == D3D10_SVC_OBJECT && !is_buffer)
5908 {
5909 WARN("Not supported on object variables of type %s.\n",
5910 debug_d3d10_shader_variable_type(v->type->basetype));
5911 return D3DERR_INVALIDCALL;
5912 }
5913
5914 if (!is_buffer)
5915 {
5916 offset += v->buffer_offset;
5917 v = v->buffer;
5918 }
5919
5920 memcpy(v->u.buffer.local_buffer + offset, data, count);
5921 v->u.buffer.changed = TRUE;
5922
5923 return S_OK;
5924}

Referenced by d3d10_effect_blend_variable_SetRawValue(), d3d10_effect_constant_buffer_SetRawValue(), d3d10_effect_depth_stencil_variable_SetRawValue(), d3d10_effect_depth_stencil_view_variable_SetRawValue(), d3d10_effect_matrix_variable_SetRawValue(), d3d10_effect_rasterizer_variable_SetRawValue(), d3d10_effect_render_target_view_variable_SetRawValue(), d3d10_effect_sampler_variable_SetRawValue(), d3d10_effect_scalar_variable_SetRawValue(), d3d10_effect_shader_resource_variable_SetRawValue(), d3d10_effect_shader_variable_SetRawValue(), d3d10_effect_string_variable_SetRawValue(), and d3d10_effect_vector_variable_SetRawValue().

◆ d3d10_effect_variable_update_buffer_offsets()

static void d3d10_effect_variable_update_buffer_offsets ( struct d3d10_effect_variable *  v,
unsigned int  offset 
)
static

Definition at line 3444 of file effect.c.

3446{
3447 unsigned int i;
3448
3449 for (i = 0; i < v->type->member_count; ++i)
3451
3452 for (i = 0; i < v->type->element_count; ++i)
3454
3455 v->buffer_offset += offset;
3456}
static void d3d10_effect_variable_update_buffer_offsets(struct d3d10_effect_variable *v, unsigned int offset)
Definition: effect.c:3444

Referenced by d3d10_effect_variable_update_buffer_offsets(), and parse_fx10_numeric_variable().

◆ d3d10_effect_vector_variable_AsBlend()

static struct ID3D10EffectBlendVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsBlend ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6884 of file effect.c.

6886{
6888}

◆ d3d10_effect_vector_variable_AsConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsConstantBuffer ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6872 of file effect.c.

◆ d3d10_effect_vector_variable_AsDepthStencil()

static struct ID3D10EffectDepthStencilVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsDepthStencil ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6890 of file effect.c.

6892{
6894}

◆ d3d10_effect_vector_variable_AsDepthStencilView()

static struct ID3D10EffectDepthStencilViewVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsDepthStencilView ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6866 of file effect.c.

◆ d3d10_effect_vector_variable_AsMatrix()

static struct ID3D10EffectMatrixVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsMatrix ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6842 of file effect.c.

6844{
6846}

◆ d3d10_effect_vector_variable_AsRasterizer()

static struct ID3D10EffectRasterizerVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsRasterizer ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6896 of file effect.c.

6898{
6900}

◆ d3d10_effect_vector_variable_AsRenderTargetView()

static struct ID3D10EffectRenderTargetViewVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsRenderTargetView ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6860 of file effect.c.

◆ d3d10_effect_vector_variable_AsSampler()

static struct ID3D10EffectSamplerVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsSampler ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6902 of file effect.c.

6904{
6906}

◆ d3d10_effect_vector_variable_AsScalar()

static struct ID3D10EffectScalarVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsScalar ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6830 of file effect.c.

6832{
6834}

◆ d3d10_effect_vector_variable_AsShader()

static struct ID3D10EffectShaderVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsShader ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6878 of file effect.c.

6880{
6882}

◆ d3d10_effect_vector_variable_AsShaderResource()

static struct ID3D10EffectShaderResourceVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsShaderResource ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6854 of file effect.c.

◆ d3d10_effect_vector_variable_AsString()

static struct ID3D10EffectStringVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsString ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6848 of file effect.c.

6850{
6852}

◆ d3d10_effect_vector_variable_AsVector()

static struct ID3D10EffectVectorVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_AsVector ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6836 of file effect.c.

6838{
6840}

◆ d3d10_effect_vector_variable_GetAnnotationByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetAnnotationByIndex ( ID3D10EffectVectorVariable *  iface,
UINT  index 
)
static

Definition at line 6788 of file effect.c.

◆ d3d10_effect_vector_variable_GetAnnotationByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetAnnotationByName ( ID3D10EffectVectorVariable *  iface,
const char *  name 
)
static

Definition at line 6794 of file effect.c.

◆ d3d10_effect_vector_variable_GetBoolVector()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetBoolVector ( ID3D10EffectVectorVariable *  iface,
BOOL *  value 
)
static

Definition at line 6955 of file effect.c.

6957{
6959
6960 TRACE("iface %p, value %p.\n", iface, value);
6962
6963 return S_OK;
6964}
static struct d3d10_effect_variable * impl_from_ID3D10EffectVectorVariable(ID3D10EffectVectorVariable *iface)
Definition: effect.c:6762

◆ d3d10_effect_vector_variable_GetBoolVectorArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetBoolVectorArray ( ID3D10EffectVectorVariable *  iface,
BOOL *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 7021 of file effect.c.

7023{
7025
7026 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
7028
7029 return S_OK;
7030}

◆ d3d10_effect_vector_variable_GetDesc()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetDesc ( ID3D10EffectVectorVariable *  iface,
D3D10_EFFECT_VARIABLE_DESC *  desc 
)
static

Definition at line 6782 of file effect.c.

6784{
6786}

◆ d3d10_effect_vector_variable_GetElement()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetElement ( ID3D10EffectVectorVariable *  iface,
UINT  index 
)
static

Definition at line 6818 of file effect.c.

6820{
6822}

◆ d3d10_effect_vector_variable_GetFloatVector()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetFloatVector ( ID3D10EffectVectorVariable *  iface,
float *  value 
)
static

Definition at line 6977 of file effect.c.

6979{
6981
6982 TRACE("iface %p, value %p.\n", iface, value);
6984
6985 return S_OK;
6986}

◆ d3d10_effect_vector_variable_GetFloatVectorArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetFloatVectorArray ( ID3D10EffectVectorVariable *  iface,
float *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 7043 of file effect.c.

7045{
7047
7048 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
7050
7051 return S_OK;
7052}

◆ d3d10_effect_vector_variable_GetIntVector()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetIntVector ( ID3D10EffectVectorVariable *  iface,
int *  value 
)
static

Definition at line 6966 of file effect.c.

6968{
6970
6971 TRACE("iface %p, value %p.\n", iface, value);
6973
6974 return S_OK;
6975}

◆ d3d10_effect_vector_variable_GetIntVectorArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetIntVectorArray ( ID3D10EffectVectorVariable *  iface,
int *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 7032 of file effect.c.

7034{
7036
7037 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
7039
7040 return S_OK;
7041}

◆ d3d10_effect_vector_variable_GetMemberByIndex()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetMemberByIndex ( ID3D10EffectVectorVariable *  iface,
UINT  index 
)
static

Definition at line 6800 of file effect.c.

◆ d3d10_effect_vector_variable_GetMemberByName()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetMemberByName ( ID3D10EffectVectorVariable *  iface,
const char *  name 
)
static

Definition at line 6806 of file effect.c.

◆ d3d10_effect_vector_variable_GetMemberBySemantic()

static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetMemberBySemantic ( ID3D10EffectVectorVariable *  iface,
const char *  semantic 
)
static

Definition at line 6812 of file effect.c.

6814{
6816}

◆ d3d10_effect_vector_variable_GetParentConstantBuffer()

static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetParentConstantBuffer ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6824 of file effect.c.

◆ d3d10_effect_vector_variable_GetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_GetRawValue ( ID3D10EffectVectorVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 6914 of file effect.c.

◆ d3d10_effect_vector_variable_GetType()

static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_vector_variable_GetType ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6776 of file effect.c.

6778{
6780}

◆ d3d10_effect_vector_variable_IsValid()

static BOOL STDMETHODCALLTYPE d3d10_effect_vector_variable_IsValid ( ID3D10EffectVectorVariable *  iface)
static

Definition at line 6767 of file effect.c.

6768{
6770
6771 TRACE("iface %p\n", iface);
6772
6773 return v != &null_vector_variable;
6774}

◆ d3d10_effect_vector_variable_SetBoolVector()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetBoolVector ( ID3D10EffectVectorVariable *  iface,
BOOL *  value 
)
static

Definition at line 6922 of file effect.c.

6924{
6926
6927 TRACE("iface %p, value %p.\n", iface, value);
6929
6930 return S_OK;
6931}

◆ d3d10_effect_vector_variable_SetBoolVectorArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetBoolVectorArray ( ID3D10EffectVectorVariable *  iface,
BOOL *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 6988 of file effect.c.

6990{
6992
6993 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
6995
6996 return S_OK;
6997}

◆ d3d10_effect_vector_variable_SetFloatVector()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetFloatVector ( ID3D10EffectVectorVariable *  iface,
float *  value 
)
static

Definition at line 6944 of file effect.c.

6946{
6948
6949 TRACE("iface %p, value %p.\n", iface, value);
6951
6952 return S_OK;
6953}

◆ d3d10_effect_vector_variable_SetFloatVectorArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetFloatVectorArray ( ID3D10EffectVectorVariable *  iface,
float *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 7010 of file effect.c.

7012{
7014
7015 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
7017
7018 return S_OK;
7019}

◆ d3d10_effect_vector_variable_SetIntVector()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetIntVector ( ID3D10EffectVectorVariable *  iface,
int *  value 
)
static

Definition at line 6933 of file effect.c.

6935{
6937
6938 TRACE("iface %p, value %p.\n", iface, value);
6940
6941 return S_OK;
6942}

◆ d3d10_effect_vector_variable_SetIntVectorArray()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetIntVectorArray ( ID3D10EffectVectorVariable *  iface,
int *  values,
UINT  offset,
UINT  count 
)
static

Definition at line 6999 of file effect.c.

7001{
7003
7004 TRACE("iface %p, values %p, offset %u, count %u.\n", iface, values, offset, count);
7006
7007 return S_OK;
7008}

◆ d3d10_effect_vector_variable_SetRawValue()

static HRESULT STDMETHODCALLTYPE d3d10_effect_vector_variable_SetRawValue ( ID3D10EffectVectorVariable *  iface,
void *  data,
UINT  offset,
UINT  count 
)
static

Definition at line 6908 of file effect.c.

◆ d3d10_get_shader_variable()

static HRESULT d3d10_get_shader_variable ( struct d3d10_effect_variable *  v,
UINT  shader_index,
struct d3d10_effect_shader_variable **  s,
D3D10_SHADER_VARIABLE_TYPE *  basetype 
)
static

Definition at line 8658 of file effect.c.

8660{
8661 unsigned int i;
8662
8664
8665 if (!shader_index)
8666 {
8667 *s = &v->u.shader;
8668 if (basetype) *basetype = v->type->basetype;
8669 return S_OK;
8670 }
8671
8672 /* Index is used as an offset from this variable. */
8673
8674 for (i = 0; i < v->effect->shaders.count; ++i)
8675 {
8676 if (v == v->effect->shaders.v[i]) break;
8677 }
8678
8679 if (i + shader_index >= v->effect->shaders.count)
8680 {
8681 WARN("Invalid shader index %u.\n", shader_index);
8682 return E_FAIL;
8683 }
8684
8685 *s = &v->effect->shaders.v[i + shader_index]->u.shader;
8686 if (basetype) *basetype = v->effect->shaders.v[i + shader_index]->type->basetype;
8687
8688 return S_OK;
8689}

Referenced by d3d10_effect_shader_variable_GetGeometryShader(), d3d10_effect_shader_variable_GetPixelShader(), d3d10_effect_shader_variable_GetShaderDesc(), d3d10_effect_shader_variable_GetVertexShader(), and d3d10_get_shader_variable_signature().

◆ d3d10_get_shader_variable_signature()

static HRESULT d3d10_get_shader_variable_signature ( struct d3d10_effect_variable *  v,
UINT  shader_index,
UINT  element_index,
BOOL  output,
D3D10_SIGNATURE_PARAMETER_DESC *  desc 
)
static

Definition at line 8807 of file effect.c.

8809{
8811 HRESULT hr;
8812
8813 if (FAILED(hr = d3d10_get_shader_variable(v, shader_index, &s, NULL)))
8814 return hr;
8815
8816 if (!s->reflection)
8817 return D3DERR_INVALIDCALL;
8818
8819 if (output)
8820 return s->reflection->lpVtbl->GetOutputParameterDesc(s->reflection, element_index, desc);
8821 else
8822 return s->reflection->lpVtbl->GetInputParameterDesc(s->reflection, element_index, desc);
8823}

Referenced by d3d10_effect_shader_variable_GetInputSignatureElementDesc(), and d3d10_effect_shader_variable_GetOutputSignatureElementDesc().

◆ d3d10_get_state_variable()

◆ d3d10_reg_table_allocate()

static HRESULT d3d10_reg_table_allocate ( struct d3d10_reg_table *  table,
unsigned int  count 
)
static

Definition at line 893 of file effect.c.

894{
895 if (!(table->f = calloc(count, sizeof(*table->f))))
896 return E_OUTOFMEMORY;
897 table->count = count;
898 return S_OK;
899}

Referenced by parse_fx10_cli4(), parse_fx10_ctab(), and parse_fx10_fxlc().

◆ d3d10_variable_class()

static D3D10_SHADER_VARIABLE_CLASS d3d10_variable_class ( uint32_t  c,
BOOL  is_column_major 
)
static

Definition at line 1818 of file effect.c.

1819{
1820 switch (c)
1821 {
1822 case 1: return D3D10_SVC_SCALAR;
1823 case 2: return D3D10_SVC_VECTOR;
1824 case 3: if (is_column_major) return D3D10_SVC_MATRIX_COLUMNS;
1825 else return D3D10_SVC_MATRIX_ROWS;
1826 default:
1827 FIXME("Unknown variable class %#x.\n", c);
1828 return 0;
1829 }
1830}
@ D3D10_SVC_MATRIX_COLUMNS
Definition: d3dcommon.idl:145
@ D3D10_SVC_MATRIX_ROWS
Definition: d3dcommon.idl:144
@ D3D10_SVC_SCALAR
Definition: d3dcommon.idl:142
const GLubyte * c
Definition: glext.h:8905

Referenced by parse_fx10_type().

◆ d3d10_variable_type()

static D3D10_SHADER_VARIABLE_TYPE d3d10_variable_type ( uint32_t  t,
BOOL  is_object,
uint32_t *  flags 
)
static

Definition at line 1832 of file effect.c.

1834{
1835 *flags = 0;
1836
1837 if(is_object)
1838 {
1839 switch (t)
1840 {
1841 case 1: return D3D10_SVT_STRING;
1842 case 2: return D3D10_SVT_BLEND;
1843 case 3: return D3D10_SVT_DEPTHSTENCIL;
1844 case 4: return D3D10_SVT_RASTERIZER;
1845 case 5: return D3D10_SVT_PIXELSHADER;
1846 case 6: return D3D10_SVT_VERTEXSHADER;
1847 case 7: return D3D10_SVT_GEOMETRYSHADER;
1848 case 8:
1851
1852 case 9: return D3D10_SVT_TEXTURE;
1853 case 10: return D3D10_SVT_TEXTURE1D;
1854 case 11: return D3D10_SVT_TEXTURE1DARRAY;
1855 case 12: return D3D10_SVT_TEXTURE2D;
1856 case 13: return D3D10_SVT_TEXTURE2DARRAY;
1857 case 14: return D3D10_SVT_TEXTURE2DMS;
1858 case 15: return D3D10_SVT_TEXTURE2DMSARRAY;
1859 case 16: return D3D10_SVT_TEXTURE3D;
1860 case 17: return D3D10_SVT_TEXTURECUBE;
1861
1862 case 19: return D3D10_SVT_RENDERTARGETVIEW;
1863 case 20: return D3D10_SVT_DEPTHSTENCILVIEW;
1864 case 21: return D3D10_SVT_SAMPLER;
1865 case 22: return D3D10_SVT_BUFFER;
1866 default:
1867 FIXME("Unknown variable type %#x.\n", t);
1868 return D3D10_SVT_VOID;
1869 }
1870 }
1871 else
1872 {
1873 switch (t)
1874 {
1875 case 1: return D3D10_SVT_FLOAT;
1876 case 2: return D3D10_SVT_INT;
1877 case 3: return D3D10_SVT_UINT;
1878 case 4: return D3D10_SVT_BOOL;
1879 default:
1880 FIXME("Unknown variable type %#x.\n", t);
1881 return D3D10_SVT_VOID;
1882 }
1883 }
1884}
@ D3D10_EOT_FLAG_GS_SO
Definition: d3d10_private.h:46
@ D3D10_SVT_DEPTHSTENCILVIEW
Definition: d3dcommon.idl:257
@ D3D10_SVT_TEXTURE
Definition: d3dcommon.idl:231
@ D3D10_SVT_RENDERTARGETVIEW
Definition: d3dcommon.idl:256
@ D3D10_SVT_VOID
Definition: d3dcommon.idl:226
@ D3D10_SVT_BUFFER
Definition: d3dcommon.idl:251
int is_object(const type_t *iface)
Definition: header.c:972

Referenced by parse_fx10_type(), and read_value_list().

◆ D3D10CreateEffectFromMemory()

HRESULT WINAPI D3D10CreateEffectFromMemory ( void *  data,
SIZE_T  data_size,
UINT  flags,
ID3D10Device *  device,
ID3D10EffectPool *  effect_pool,
ID3D10Effect **  effect 
)

Definition at line 10133 of file effect.c.

10135{
10136 struct d3d10_effect *object, *pool = NULL;
10137 HRESULT hr;
10138
10139 TRACE("data %p, data_size %Iu, flags %#x, device %p, effect_pool %p, effect %p.\n",
10140 data, data_size, flags, device, effect_pool, effect);
10141
10142 if (!(flags & D3D10_EFFECT_COMPILE_CHILD_EFFECT) != !effect_pool)
10143 return E_INVALIDARG;
10144
10145 if (effect_pool && !(pool = unsafe_impl_from_ID3D10EffectPool(effect_pool)))
10146 {
10147 WARN("External pool implementations are not supported.\n");
10148 return E_INVALIDARG;
10149 }
10150
10151 if (FAILED(hr = d3d10_create_effect(data, data_size, device, pool, 0, &object)))
10152 {
10153 WARN("Failed to create an effect, hr %#lx.\n", hr);
10154 return hr;
10155 }
10156
10157 *effect = &object->ID3D10Effect_iface;
10158
10159 TRACE("Created effect %p\n", object);
10160
10161 return hr;
10162}
const unsigned int D3D10_EFFECT_COMPILE_CHILD_EFFECT
static HRESULT d3d10_create_effect(void *data, SIZE_T data_size, ID3D10Device *device, struct d3d10_effect *pool, unsigned int flags, struct d3d10_effect **effect)
Definition: effect.c:10097
static struct d3d10_effect * unsafe_impl_from_ID3D10EffectPool(ID3D10EffectPool *iface)
Definition: effect.c:43

Referenced by create_effect().

◆ D3D10CreateEffectPoolFromMemory()

HRESULT WINAPI D3D10CreateEffectPoolFromMemory ( void *  data,
SIZE_T  data_size,
UINT  fx_flags,
ID3D10Device *  device,
ID3D10EffectPool **  effect_pool 
)

Definition at line 10196 of file effect.c.

10198{
10199 struct d3d10_effect *object;
10200 HRESULT hr;
10201
10202 TRACE("data %p, data_size %Iu, fx_flags %#x, device %p, effect_pool %p.\n",
10203 data, data_size, fx_flags, device, effect_pool);
10204
10205 if (!data)
10206 return E_INVALIDARG;
10207
10208 if (FAILED(hr = d3d10_create_effect(data, data_size, device, NULL,
10209 D3D10_EFFECT_IS_POOL, &object)))
10210 {
10211 WARN("Failed to create an effect, hr %#lx.\n", hr);
10212 return hr;
10213 }
10214
10215 *effect_pool = &object->ID3D10EffectPool_iface;
10216
10217 TRACE("Created effect pool %p.\n", object);
10218
10219 return hr;
10220}

◆ d3d_array_reserve()

static BOOL d3d_array_reserve ( void **  elements,
SIZE_T *  capacity,
SIZE_T  count,
SIZE_T  size 
)
static

Definition at line 1413 of file effect.c.

1414{
1415 SIZE_T max_capacity, new_capacity;
1416 void *new_elements;
1417
1418 if (count <= *capacity)
1419 return TRUE;
1420
1421 max_capacity = ~(SIZE_T)0 / size;
1422 if (count > max_capacity)
1423 return FALSE;
1424
1425 new_capacity = max(1, *capacity);
1426 while (new_capacity < count && new_capacity <= max_capacity / 2)
1427 new_capacity *= 2;
1428 if (new_capacity < count)
1429 new_capacity = count;
1430
1431 if (!(new_elements = realloc(*elements, new_capacity * size)))
1432 return FALSE;
1433
1434 *elements = new_elements;
1435 *capacity = new_capacity;
1436 return TRUE;
1437}
#define realloc
Definition: debug_ros.c:6
GLsizeiptr size
Definition: glext.h:5919
#define max(a, b)
Definition: svc.c:63
ULONG_PTR SIZE_T
Definition: typedefs.h:80

Referenced by d3d10_effect_add_prop_dependency(), and d3d10_effect_parse_stream_output_declaration().

◆ debug_d3d10_shader_variable_class()

static const char * debug_d3d10_shader_variable_class ( D3D10_SHADER_VARIABLE_CLASS  c)
static

Definition at line 1145 of file effect.c.

1146{
1147 switch (c)
1148 {
1155 default:
1156 FIXME("Unrecognised D3D10_SHADER_VARIABLE_CLASS %#x.\n", c);
1157 return "unrecognised";
1158 }
1159}
@ D3D10_SVC_STRUCT
Definition: d3dcommon.idl:147
#define WINE_D3D10_TO_STR(x)
Definition: effect.c:1143

Referenced by parse_fx10_buffer(), parse_fx10_type(), and set_variable_vtbl().

◆ debug_d3d10_shader_variable_type()

static const char * debug_d3d10_shader_variable_type ( D3D10_SHADER_VARIABLE_TYPE  t)
static

Definition at line 1161 of file effect.c.

1162{
1163 switch (t)
1164 {
1194 default:
1195 FIXME("Unrecognised D3D10_SHADER_VARIABLE_TYPE %#x.\n", t);
1196 return "unrecognised";
1197 }
1198}
@ D3D10_SVT_TEXTURECUBEARRAY
Definition: d3dcommon.idl:260

Referenced by create_state_object(), d3d10_effect_constant_buffer_GetConstantBuffer(), d3d10_effect_constant_buffer_GetTextureBuffer(), d3d10_effect_shader_variable_destroy(), d3d10_effect_variable_get_raw_value(), d3d10_effect_variable_SetRawValue(), parse_fx10_buffer(), parse_fx10_object_variable(), parse_fx10_type(), read_value_list(), and set_variable_vtbl().

◆ fx10_copy_string()

static BOOL fx10_copy_string ( const char *  data,
size_t  data_size,
DWORD  offset,
char **  s 
)
static

Definition at line 1471 of file effect.c.

1472{
1473 const char *p;
1474 size_t len;
1475
1476 if (!fx10_get_string(data, data_size, offset, &p, &len))
1477 return FALSE;
1478
1479 if (!p)
1480 {
1481 *s = NULL;
1482 return TRUE;
1483 }
1484
1485 if (!(*s = malloc(len)))
1486 {
1487 ERR("Failed to allocate string memory.\n");
1488 return FALSE;
1489 }
1490
1491 memcpy(*s, p, len);
1492
1493 return TRUE;
1494}
#define malloc
Definition: debug_ros.c:4
static BOOL fx10_get_string(const char *data, size_t data_size, uint32_t offset, const char **s, size_t *l)
Definition: effect.c:1444

Referenced by parse_fx10_annotation(), parse_fx10_buffer(), parse_fx10_numeric_variable(), parse_fx10_object_variable(), parse_fx10_pass(), parse_fx10_property_assignment(), parse_fx10_technique(), parse_fx10_type(), and parse_fx10_variable_head().

◆ fx10_get_string()

static BOOL fx10_get_string ( const char *  data,
size_t  data_size,
uint32_t  offset,
const char **  s,
size_t *  l 
)
static

Definition at line 1444 of file effect.c.

1445{
1446 size_t len, max_len;
1447
1448 if (offset >= data_size)
1449 {
1450 WARN("Invalid offset %#x (data size %#Ix).\n", offset, data_size);
1451 return FALSE;
1452 }
1453
1454 max_len = data_size - offset;
1455 if (!(len = strnlen(data + offset, max_len)))
1456 {
1457 *s = NULL;
1458 *l = 0;
1459 return TRUE;
1460 }
1461
1462 if (len == max_len)
1463 return FALSE;
1464
1465 *s = data + offset;
1466 *l = ++len;
1467
1468 return TRUE;
1469}
_ACRTIMP size_t __cdecl strnlen(const char *, size_t)
Definition: string.c:1607

Referenced by fx10_copy_string(), parse_fx10_ctab(), and parse_fx10_property_assignment().

◆ fxlvm_chunk_handler()

static HRESULT fxlvm_chunk_handler ( const struct vkd3d_shader_dxbc_section_desc *  section,
struct d3d10_preshader_parse_context *  ctx 
)
static

Definition at line 2848 of file effect.c.

2850{
2851 const char *data = section->data.code;
2852 size_t data_size = section->data.size;
2853 uint32_t tag = section->tag;
2854
2855 TRACE("Chunk tag: %s, size: %Iu.\n", debugstr_fourcc(tag), data_size);
2856
2857 switch (tag)
2858 {
2859 case TAG_FXLC:
2860 return parse_fx10_fxlc(ctx, data, data_size);
2861
2862 case TAG_CLI4:
2863 return parse_fx10_cli4(ctx, data, data_size);
2864
2865 case TAG_CTAB:
2866 return parse_fx10_ctab(ctx, data, data_size);
2867
2868 default:
2869 FIXME("Unhandled chunk %s.\n", debugstr_fourcc(tag));
2870 return S_OK;
2871 }
2872}
#define TAG_FXLC
Definition: effect.c:33
#define TAG_CTAB
Definition: effect.c:35
#define TAG_CLI4
Definition: effect.c:34
static HRESULT parse_fx10_ctab(void *ctx, const char *data, unsigned int data_size)
Definition: effect.c:2762
static HRESULT parse_fx10_cli4(void *ctx, const char *data, unsigned int data_size)
Definition: effect.c:2729
static HRESULT parse_fx10_fxlc(void *ctx, const char *data, unsigned int data_size)
Definition: effect.c:2689
Definition: ecma_167.h:138

Referenced by parse_fx10_preshader().

◆ get_fx10_shader_resources()

static HRESULT get_fx10_shader_resources ( struct d3d10_effect_variable *  v)
static

Definition at line 1550 of file effect.c.

1551{
1552 struct d3d10_effect_shader_variable *sv = &v->u.shader;
1556 unsigned int i;
1557
1558 sv->reflection->lpVtbl->GetDesc(sv->reflection, &desc);
1559 sv->resource_count = desc.BoundResources;
1560
1561 if (!(sv->resources = calloc(sv->resource_count, sizeof(*sv->resources))))
1562 {
1563 ERR("Failed to allocate shader resource binding information memory.\n");
1564 return E_OUTOFMEMORY;
1565 }
1566
1567 for (i = 0; i < desc.BoundResources; ++i)
1568 {
1569 sv->reflection->lpVtbl->GetResourceBindingDesc(sv->reflection, i, &bind_desc);
1570 sr = &sv->resources[i];
1571
1572 sr->in_type = bind_desc.Type;
1573 sr->bind_point = bind_desc.BindPoint;
1574 sr->bind_count = bind_desc.BindCount;
1575
1576 switch (bind_desc.Type)
1577 {
1578 case D3D10_SIT_CBUFFER:
1579 case D3D10_SIT_TBUFFER:
1580 if (sr->bind_count != 1)
1581 {
1582 WARN("Unexpected bind count %u for a buffer %s.\n", bind_desc.BindCount,
1583 debugstr_a(bind_desc.Name));
1584 return E_UNEXPECTED;
1585 }
1586 sr->variable = d3d10_effect_get_buffer_by_name(v->effect, bind_desc.Name);
1587 break;
1588
1589 case D3D10_SIT_SAMPLER:
1590 case D3D10_SIT_TEXTURE:
1591 sr->variable = d3d10_effect_get_variable_by_name(v->effect, bind_desc.Name);
1592 break;
1593
1594 default:
1595 break;
1596 }
1597
1598 if (!sr->variable)
1599 {
1600 WARN("Failed to find shader resource.\n");
1601 return E_FAIL;
1602 }
1603 }
1604
1605 return S_OK;
1606}
HRESULT GetResourceBindingDesc(UINT index, D3D10_SHADER_INPUT_BIND_DESC *desc)
HRESULT GetDesc(D3D10_SHADER_DESC *desc)
D3D10_SHADER_INPUT_TYPE Type
Definition: d3d10shader.idl:71
ID3D10ShaderReflection * reflection
Definition: d3d10_private.h:84
#define E_UNEXPECTED
Definition: winerror.h:3528

Referenced by parse_fx10_shader().

◆ get_fx10_type()

static struct d3d10_effect_type * get_fx10_type ( struct d3d10_effect *  effect,
const char *  data,
size_t  data_size,
uint32_t  offset 
)
static

Definition at line 2121 of file effect.c.

2123{
2124 struct d3d10_effect_type *type;
2125 struct wine_rb_entry *entry;
2126 HRESULT hr;
2127
2128 entry = wine_rb_get(&effect->types, &offset);
2129 if (entry)
2130 {
2131 TRACE("Returning existing type.\n");
2133 }
2134
2135 if (!(type = calloc(1, sizeof(*type))))
2136 {
2137 ERR("Failed to allocate type memory.\n");
2138 return NULL;
2139 }
2140
2141 type->ID3D10EffectType_iface.lpVtbl = &d3d10_effect_type_vtbl;
2142 type->id = offset;
2143 type->effect = effect;
2144 if (FAILED(hr = parse_fx10_type(data, data_size, offset, type)))
2145 {
2146 ERR("Failed to parse type info, hr %#lx.\n", hr);
2147 free(type);
2148 return NULL;
2149 }
2150
2151 if (wine_rb_put(&effect->types, &offset, &type->entry) == -1)
2152 {
2153 ERR("Failed to insert type entry.\n");
2154 free(type);
2155 return NULL;
2156 }
2157
2158 return type;
2159}
static const struct ID3D10EffectTypeVtbl d3d10_effect_type_vtbl
Definition: effect.c:69
static HRESULT parse_fx10_type(const char *data, size_t data_size, uint32_t offset, struct d3d10_effect_type *t)
Definition: effect.c:1896
#define wine_rb_entry
Definition: rbtree.h:404
#define wine_rb_put
Definition: rbtree.h:410
#define wine_rb_get
Definition: rbtree.h:409

Referenced by parse_fx10_type(), and parse_fx10_variable_head().

◆ get_storage_info()

static const struct d3d10_effect_state_storage_info * get_storage_info ( D3D_SHADER_VARIABLE_TYPE  id)
static

Definition at line 2485 of file effect.c.

2486{
2487 unsigned int i;
2488
2490 {
2491 if (d3d10_effect_state_storage_info[i].id == id)
2493 }
2494
2495 return NULL;
2496}

Referenced by parse_fx10_object_variable().

◆ get_value_as_bool()

static BOOL get_value_as_bool ( void *  src_data,
D3D10_SHADER_VARIABLE_TYPE  src_type 
)
static

Definition at line 6229 of file effect.c.

6230{
6231 switch (src_type)
6232 {
6233 case D3D10_SVT_FLOAT:
6234 case D3D10_SVT_INT:
6235 case D3D10_SVT_UINT:
6236 case D3D10_SVT_BOOL:
6237 if (*(DWORD *)src_data)
6238 return -1;
6239 break;
6240
6241 default:
6242 break;
6243 }
6244
6245 return 0;
6246}

Referenced by get_value_as_float(), get_value_as_int(), and get_vector_as_type().

◆ get_value_as_float()

static float get_value_as_float ( void *  src_data,
D3D10_SHADER_VARIABLE_TYPE  src_type 
)
static

Definition at line 6267 of file effect.c.

6268{
6269 switch (src_type)
6270 {
6271 case D3D10_SVT_FLOAT:
6272 return *(float *)src_data;
6273
6274 case D3D10_SVT_INT:
6275 case D3D10_SVT_UINT:
6276 return (float)(*(int *)src_data);
6277
6278 case D3D10_SVT_BOOL:
6279 return (float)get_value_as_bool(src_data, src_type);
6280
6281 default:
6282 return 0.0f;
6283 }
6284}
static BOOL get_value_as_bool(void *src_data, D3D10_SHADER_VARIABLE_TYPE src_type)
Definition: effect.c:6229

Referenced by get_vector_as_type().

◆ get_value_as_int()

static int get_value_as_int ( void *  src_data,
D3D10_SHADER_VARIABLE_TYPE  src_type 
)
static

Definition at line 6248 of file effect.c.

6249{
6250 switch (src_type)
6251 {
6252 case D3D10_SVT_FLOAT:
6253 return (int)(*(float *)src_data);
6254
6255 case D3D10_SVT_INT:
6256 case D3D10_SVT_UINT:
6257 return *(int *)src_data;
6258
6259 case D3D10_SVT_BOOL:
6260 return get_value_as_bool(src_data, src_type);
6261
6262 default:
6263 return 0;
6264 }
6265}

Referenced by get_vector_as_type().

◆ get_var_container_type()

static enum d3d10_effect_container_type get_var_container_type ( const struct d3d10_effect_variable *  v)
static

Definition at line 174 of file effect.c.

175{
176 switch (v->type->basetype)
177 {
179 case D3D10_SVT_BLEND: return D3D10_C_BLEND;
182 default: return D3D10_C_NONE;
183 }
184}

Referenced by parse_fx10_object_variable().

◆ get_vector_as_type()

static void get_vector_as_type ( BYTE *  dst_data,
D3D_SHADER_VARIABLE_TYPE  dst_type,
BYTE *  src_data,
D3D_SHADER_VARIABLE_TYPE  src_type,
unsigned int  count 
)
static

Definition at line 6286 of file effect.c.

6288{
6289 DWORD *src_data_dword = (DWORD *)src_data;
6290 DWORD *dst_data_dword = (DWORD *)dst_data;
6291 unsigned int i;
6292
6293 for (i = 0; i < count; ++i, ++dst_data_dword, ++src_data_dword)
6294 {
6295 if (dst_type == src_type)
6296 *dst_data_dword = *src_data_dword;
6297 else
6298 {
6299 switch (dst_type)
6300 {
6301 case D3D10_SVT_FLOAT:
6302 *(float *)dst_data_dword = get_value_as_float(src_data_dword, src_type);
6303 break;
6304
6305 case D3D10_SVT_INT:
6306 case D3D10_SVT_UINT:
6307 *(int *)dst_data_dword = get_value_as_int(src_data_dword, src_type);
6308 break;
6309
6310 case D3D10_SVT_BOOL:
6311 *(BOOL *)dst_data_dword = get_value_as_bool(src_data_dword, src_type);
6312 break;
6313
6314 default:
6315 *dst_data_dword = 0;
6316 break;
6317 }
6318 }
6319 }
6320}
static float get_value_as_float(void *src_data, D3D10_SHADER_VARIABLE_TYPE src_type)
Definition: effect.c:6267
static int get_value_as_int(void *src_data, D3D10_SHADER_VARIABLE_TYPE src_type)
Definition: effect.c:6248

Referenced by read_variable_array_from_buffer(), read_variable_from_buffer(), write_variable_array_to_buffer(), and write_variable_to_buffer().

◆ impl_from_ID3D10Effect()

◆ impl_from_ID3D10EffectBlendVariable()

static struct d3d10_effect_variable * impl_from_ID3D10EffectBlendVariable ( ID3D10EffectBlendVariable *  iface)
inlinestatic

Definition at line 8901 of file effect.c.

8903{
8904 return CONTAINING_RECORD(iface, struct d3d10_effect_variable, ID3D10EffectVariable_iface);
8905}

Referenced by d3d10_effect_blend_variable_GetBackingStore(), d3d10_effect_blend_variable_GetBlendState(), and d3d10_effect_blend_variable_IsValid().

◆ impl_from_ID3D10EffectConstantBuffer()

static struct d3d10_effect_variable * impl_from_ID3D10EffectConstantBuffer ( ID3D10EffectConstantBuffer *  iface)
inlinestatic

Definition at line 5973 of file effect.c.

5974{
5975 return CONTAINING_RECORD(iface, struct d3d10_effect_variable, ID3D10EffectVariable_iface);
5976}

Referenced by d3d10_effect_constant_buffer_GetConstantBuffer(), d3d10_effect_constant_buffer_GetTextureBuffer(), and d3d10_effect_constant_buffer_IsValid().

◆ impl_from_ID3D10EffectDepthStencilVariable()

static struct d3d10_effect_variable * impl_from_ID3D10EffectDepthStencilVariable ( ID3D10EffectDepthStencilVariable *  iface)
inlinestatic

◆ impl_from_ID3D10EffectDepthStencilViewVariable()

static struct d3d10_effect_variable * impl_from_ID3D10EffectDepthStencilViewVariable ( ID3D10EffectDepthStencilViewVariable *  iface)
inlinestatic

Definition at line 8271 of file effect.c.

8273{
8274 return CONTAINING_RECORD(iface, struct d3d10_effect_variable, ID3D10EffectVariable_iface);
8275}

Referenced by d3d10_effect_depth_stencil_view_variable_IsValid().

◆ impl_from_ID3D10EffectMatrixVariable()

◆ impl_from_ID3D10EffectPass()

◆ impl_from_ID3D10EffectPool()

static struct d3d10_effect * impl_from_ID3D10EffectPool ( ID3D10EffectPool *  iface)
inlinestatic

Definition at line 37 of file effect.c.

38{
39 return CONTAINING_RECORD(iface, struct d3d10_effect, ID3D10EffectPool_iface);
40}

Referenced by d3d10_effect_pool_AddRef(), d3d10_effect_pool_AsEffect(), and d3d10_effect_pool_Release().

◆ impl_from_ID3D10EffectRasterizerVariable()

static struct d3d10_effect_variable * impl_from_ID3D10EffectRasterizerVariable ( ID3D10EffectRasterizerVariable *  iface)
inlinestatic

◆ impl_from_ID3D10EffectRenderTargetViewVariable()

static struct d3d10_effect_variable * impl_from_ID3D10EffectRenderTargetViewVariable ( ID3D10EffectRenderTargetViewVariable *  iface)
inlinestatic

Definition at line 8039 of file effect.c.

8041{
8042 return CONTAINING_RECORD(iface, struct d3d10_effect_variable, ID3D10EffectVariable_iface);
8043}

Referenced by d3d10_effect_render_target_view_variable_IsValid().

◆ impl_from_ID3D10EffectSamplerVariable()

static struct d3d10_effect_variable * impl_from_ID3D10EffectSamplerVariable ( ID3D10EffectSamplerVariable *  iface)
inlinestatic

Definition at line 9620 of file effect.c.

9622{
9623 return CONTAINING_RECORD(iface, struct d3d10_effect_variable, ID3D10EffectVariable_iface);
9624}

Referenced by d3d10_effect_sampler_variable_GetBackingStore(), d3d10_effect_sampler_variable_GetSampler(), and d3d10_effect_sampler_variable_IsValid().

◆ impl_from_ID3D10EffectScalarVariable()

◆ impl_from_ID3D10EffectShaderResourceVariable()

static struct d3d10_effect_variable * impl_from_ID3D10EffectShaderResourceVariable ( ID3D10EffectShaderResourceVariable *  iface)
inlinestatic

◆ impl_from_ID3D10EffectShaderVariable()

◆ impl_from_ID3D10EffectStringVariable()

static struct d3d10_effect_variable * impl_from_ID3D10EffectStringVariable ( ID3D10EffectStringVariable *  iface)
inlinestatic

Definition at line 7541 of file effect.c.

7542{
7543 return CONTAINING_RECORD(iface, struct d3d10_effect_variable, ID3D10EffectVariable_iface);
7544}

Referenced by d3d10_effect_string_variable_GetString(), and d3d10_effect_string_variable_IsValid().

◆ impl_from_ID3D10EffectTechnique()

◆ impl_from_ID3D10EffectType()

◆ impl_from_ID3D10EffectVariable()

◆ impl_from_ID3D10EffectVectorVariable()

◆ is_object_property()

static BOOL is_object_property ( const struct d3d10_effect_state_property_info *  property_info)
static

Definition at line 2579 of file effect.c.

2580{
2581 switch (property_info->type)
2582 {
2585 case D3D10_SVT_BLEND:
2591 case D3D10_SVT_TEXTURE:
2592 return TRUE;
2593 default:
2594 return FALSE;
2595 }
2596}

Referenced by parse_fx10_property_assignment().

◆ is_object_property_type_matching()

static BOOL is_object_property_type_matching ( const struct d3d10_effect_state_property_info *  property_info,
const struct d3d10_effect_variable *  v 
)
static

Definition at line 2598 of file effect.c.

2600{
2601 if (property_info->type == v->type->basetype) return TRUE;
2602
2603 switch (v->type->basetype)
2604 {
2613 if (property_info->type == D3D10_SVT_TEXTURE) return TRUE;
2614 /* fallthrough */
2615 default:
2616 return FALSE;
2617 }
2618}

Referenced by parse_fx10_property_assignment().

◆ is_var_shared()

◆ parse_fx10()

static HRESULT parse_fx10 ( struct d3d10_effect *  e,
const char *  data,
size_t  data_size 
)
static

Definition at line 4230 of file effect.c.

4231{
4232 const char *ptr = data;
4234
4235 if (!require_space(0, 19, sizeof(uint32_t), data_size))
4236 {
4237 WARN("Invalid data size %#Ix.\n", data_size);
4238 return E_INVALIDARG;
4239 }
4240
4241 /* Compiled target version (e.g. fx_4_0=0xfeff1001, fx_4_1=0xfeff1011). */
4242 e->version = read_u32(&ptr);
4243 TRACE("Target: %#x.\n", e->version);
4244
4245 e->local_buffer_count = read_u32(&ptr);
4246 TRACE("Local buffer count: %u.\n", e->local_buffer_count);
4247
4248 e->numeric_variable_count = read_u32(&ptr);
4249 TRACE("Numeric variable count: %u.\n", e->numeric_variable_count);
4250
4251 e->object_count = read_u32(&ptr);
4252 TRACE("Object count: %u.\n", e->object_count);
4253
4254 e->shared_buffer_count = read_u32(&ptr);
4255 TRACE("Pool buffer count: %u.\n", e->shared_buffer_count);
4256
4257 unused = read_u32(&ptr);
4258 TRACE("Pool variable count: %u.\n", unused);
4259
4260 e->shared_object_count = read_u32(&ptr);
4261 TRACE("Pool objects count: %u.\n", e->shared_object_count);
4262
4263 e->technique_count = read_u32(&ptr);
4264 TRACE("Technique count: %u.\n", e->technique_count);
4265
4266 e->index_offset = read_u32(&ptr);
4267 TRACE("Index offset: %#x.\n", e->index_offset);
4268
4269 unused = read_u32(&ptr);
4270 TRACE("String count: %u.\n", unused);
4271
4272 e->texture_count = read_u32(&ptr);
4273 TRACE("Texture count: %u.\n", e->texture_count);
4274
4275 e->ds_states.count = read_u32(&ptr);
4276 TRACE("Depthstencilstate count: %u.\n", e->ds_states.count);
4277
4278 e->blend_states.count = read_u32(&ptr);
4279 TRACE("Blendstate count: %u.\n", e->blend_states.count);
4280
4281 e->rs_states.count = read_u32(&ptr);
4282 TRACE("Rasterizerstate count: %u.\n", e->rs_states.count);
4283
4284 e->samplers.count = read_u32(&ptr);
4285 TRACE("Samplerstate count: %u.\n", e->samplers.count);
4286
4287 e->rtvs.count = read_u32(&ptr);
4288 TRACE("Rendertargetview count: %u.\n", e->rtvs.count);
4289
4290 e->dsvs.count = read_u32(&ptr);
4291 TRACE("Depthstencilview count: %u.\n", e->dsvs.count);
4292
4293 e->shaders.count = read_u32(&ptr);
4294 TRACE("Used shader count: %u.\n", e->shaders.count);
4295
4296 e->anonymous_shader_count = read_u32(&ptr);
4297 TRACE("Anonymous shader count: %u.\n", e->anonymous_shader_count);
4298
4299 if (!e->pool && (e->shared_object_count || e->shared_buffer_count))
4300 {
4301 WARN("Effect requires a pool to load.\n");
4302 return E_FAIL;
4303 }
4304
4305 return parse_fx10_body(e, ptr, data_size - (ptr - data));
4306}
static BOOL require_space(size_t offset, size_t count, size_t size, size_t data_size)
Definition: effect.c:1439
static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, size_t data_size)
Definition: effect.c:4092
static uint32_t read_u32(const char **ptr)
Definition: utils.h:24
WORD unused[29]
Definition: crypt.c:1298

Referenced by d3d10_effect_parse().

◆ parse_fx10_annotation()

static HRESULT parse_fx10_annotation ( const char *  data,
size_t  data_size,
const char **  ptr,
struct d3d10_effect_variable *  a 
)
static

Definition at line 2374 of file effect.c.

2376{
2378 HRESULT hr;
2379
2380 if (FAILED(hr = parse_fx10_variable_head(data, data_size, ptr, a)))
2381 return hr;
2382
2383 offset = read_u32(ptr);
2384 TRACE("Annotation value is at offset %#x.\n", offset);
2385
2386 switch (a->type->basetype)
2387 {
2388 case D3D10_SVT_STRING:
2389 if (!fx10_copy_string(data, data_size, offset, (char **)&a->u.buffer.local_buffer))
2390 {
2391 ERR("Failed to copy name.\n");
2392 return E_OUTOFMEMORY;
2393 }
2394 break;
2395
2396 default:
2397 FIXME("Unhandled object type %#x.\n", a->type->basetype);
2398 }
2399
2400 /* mark the variable as annotation */
2402
2403 return S_OK;
2404}
const unsigned int D3D10_EFFECT_VARIABLE_ANNOTATION
Definition: d3d10effect.idl:45
static BOOL fx10_copy_string(const char *data, size_t data_size, DWORD offset, char **s)
Definition: effect.c:1471
static HRESULT parse_fx10_variable_head(const char *data, size_t data_size, const char **ptr, struct d3d10_effect_variable *v)
Definition: effect.c:2341

Referenced by parse_fx10_annotations().

◆ parse_fx10_annotations()

static HRESULT parse_fx10_annotations ( const char *  data,
size_t  data_size,
const char **  ptr,
struct d3d10_effect *  effect,
struct d3d10_effect_annotations *  annotations 
)
static

Definition at line 2406 of file effect.c.

2408{
2409 unsigned int i;
2410 HRESULT hr;
2411
2412 if (!(annotations->elements = calloc(annotations->count, sizeof(*annotations->elements))))
2413 {
2414 ERR("Failed to allocate annotations memory.\n");
2415 return E_OUTOFMEMORY;
2416 }
2417
2418 for (i = 0; i < annotations->count; ++i)
2419 {
2420 struct d3d10_effect_variable *a = &annotations->elements[i];
2421
2422 a->effect = effect;
2423 a->buffer = &null_local_buffer;
2424
2426 return hr;
2427 }
2428
2429 return hr;
2430}
static HRESULT parse_fx10_annotation(const char *data, size_t data_size, const char **ptr, struct d3d10_effect_variable *a)
Definition: effect.c:2374
struct d3d10_effect_variable * elements

Referenced by parse_fx10_buffer(), parse_fx10_numeric_variable(), parse_fx10_object_variable(), parse_fx10_pass(), and parse_fx10_technique().

◆ parse_fx10_anonymous_shader()

static HRESULT parse_fx10_anonymous_shader ( struct d3d10_effect *  e,
D3D_SHADER_VARIABLE_TYPE  basetype,
struct d3d10_effect_anonymous_shader *  s 
)
static

Definition at line 2432 of file effect.c.

2434{
2435 struct d3d10_effect_variable *v = &s->shader;
2436 struct d3d10_effect_type *t = &s->type;
2437 const char *name = NULL;
2438
2439 switch (basetype)
2440 {
2442 name = "vertexshader";
2443 break;
2444
2446 name = "pixelshader";
2447 break;
2448
2450 name = "geometryshader";
2451 break;
2452
2453 default:
2454 WARN("Unhandled shader type %#x.\n", basetype);
2455 return E_FAIL;
2456 }
2457 t->basetype = basetype;
2458
2459 if (!copy_name(name, &t->name))
2460 {
2461 ERR("Failed to copy name.\n");
2462 return E_OUTOFMEMORY;
2463 }
2464 TRACE("Type name: %s.\n", debugstr_a(t->name));
2465
2466 t->type_class = D3D10_SVC_OBJECT;
2467
2468 t->ID3D10EffectType_iface.lpVtbl = &d3d10_effect_type_vtbl;
2469
2470 v->type = t;
2471 v->effect = e;
2472 v->u.shader.isinline = 1;
2474
2475 if (!copy_name("$Anonymous", &v->name))
2476 {
2477 ERR("Failed to copy semantic.\n");
2478 return E_OUTOFMEMORY;
2479 }
2480 TRACE("Variable name: %s.\n", debugstr_a(v->name));
2481
2482 return S_OK;
2483}
struct d3d10_effect_shader_variable shader
WCHAR * name
Definition: name.c:42

Referenced by parse_fx10_property_assignment().

◆ parse_fx10_body()

static HRESULT parse_fx10_body ( struct d3d10_effect *  e,
const char *  data,
size_t  data_size 
)
static

Definition at line 4092 of file effect.c.

4093{
4094 const char *ptr;
4095 unsigned int i;
4096 HRESULT hr;
4097
4098 if (e->index_offset >= data_size)
4099 {
4100 WARN("Invalid index offset %#x (data size %#Ix).\n", e->index_offset, data_size);
4101 return E_FAIL;
4102 }
4103 ptr = data + e->index_offset;
4104
4105 if (!(e->local_buffers = calloc(e->local_buffer_count, sizeof(*e->local_buffers))))
4106 {
4107 ERR("Failed to allocate local buffer memory.\n");
4108 return E_OUTOFMEMORY;
4109 }
4110
4111 if (!(e->object_variables = calloc(e->object_count, sizeof(*e->object_variables))))
4112 {
4113 ERR("Failed to allocate object variables memory.\n");
4114 return E_OUTOFMEMORY;
4115 }
4116
4117 if (!(e->anonymous_shaders = calloc(e->anonymous_shader_count, sizeof(*e->anonymous_shaders))))
4118 {
4119 ERR("Failed to allocate anonymous shaders memory\n");
4120 return E_OUTOFMEMORY;
4121 }
4122
4123 if (!(e->shaders.v = calloc(e->shaders.count, sizeof(*e->shaders.v))))
4124 {
4125 ERR("Failed to allocate used shaders memory\n");
4126 return E_OUTOFMEMORY;
4127 }
4128
4129 if (!(e->samplers.v = calloc(e->samplers.count, sizeof(*e->samplers.v))))
4130 {
4131 ERR("Failed to allocate samplers array.\n");
4132 return E_OUTOFMEMORY;
4133 }
4134
4135 if (!(e->blend_states.v = calloc(e->blend_states.count, sizeof(*e->blend_states.v))))
4136 {
4137 ERR("Failed to allocate blend states array.\n");
4138 return E_OUTOFMEMORY;
4139 }
4140
4141 if (!(e->ds_states.v = calloc(e->ds_states.count, sizeof(*e->ds_states.v))))
4142 {
4143 ERR("Failed to allocate depth stencil states array.\n");
4144 return E_OUTOFMEMORY;
4145 }
4146
4147 if (!(e->rs_states.v = calloc(e->rs_states.count, sizeof(*e->rs_states.v))))
4148 {
4149 ERR("Failed to allocate rasterizer states array.\n");
4150 return E_OUTOFMEMORY;
4151 }
4152
4153 if (!(e->techniques = calloc(e->technique_count, sizeof(*e->techniques))))
4154 {
4155 ERR("Failed to allocate techniques memory\n");
4156 return E_OUTOFMEMORY;
4157 }
4158
4159 for (i = 0; i < e->local_buffer_count; ++i)
4160 {
4161 struct d3d10_effect_variable *l = &e->local_buffers[i];
4162 l->ID3D10EffectVariable_iface.lpVtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_constant_buffer_vtbl;
4163 l->effect = e;
4164 l->buffer = &null_local_buffer;
4165
4167 return hr;
4168 }
4169
4170 for (i = 0; i < e->object_count; ++i)
4171 {
4172 struct d3d10_effect_variable *v = &e->object_variables[i];
4173
4174 v->effect = e;
4175 v->ID3D10EffectVariable_iface.lpVtbl = &d3d10_effect_variable_vtbl;
4176 v->buffer = &null_local_buffer;
4177
4179 return hr;
4180 }
4181
4182 for (i = 0; i < e->shared_buffer_count; ++i)
4183 {
4184 struct d3d10_effect_variable b = {{ 0 }};
4185
4186 b.effect = e;
4187
4189 {
4191 return hr;
4192 }
4193
4196 if (FAILED(hr)) return hr;
4197 }
4198
4199 for (i = 0; i < e->shared_object_count; ++i)
4200 {
4201 struct d3d10_effect_variable o = {{ 0 }};
4202
4203 o.effect = e;
4204
4206 {
4208 return hr;
4209 }
4210
4213 if (FAILED(hr)) return hr;
4214 }
4215
4216 for (i = 0; i < e->technique_count; ++i)
4217 {
4218 struct d3d10_effect_technique *t = &e->techniques[i];
4219
4220 t->ID3D10EffectTechnique_iface.lpVtbl = &d3d10_effect_technique_vtbl;
4221 t->effect = e;
4222
4223 if (FAILED(hr = parse_fx10_technique(data, data_size, &ptr, t)))
4224 return hr;
4225 }
4226
4227 return S_OK;
4228}
static const struct ID3D10EffectTechniqueVtbl d3d10_effect_technique_vtbl
Definition: effect.c:53
static HRESULT parse_fx10_buffer(const char *data, size_t data_size, const char **ptr, BOOL local, struct d3d10_effect_variable *l)
Definition: effect.c:3796
static const struct ID3D10EffectVariableVtbl d3d10_effect_variable_vtbl
Definition: effect.c:55
static HRESULT parse_fx10_object_variable(const char *data, size_t data_size, const char **ptr, BOOL shared_type_desc, struct d3d10_effect_variable *v)
Definition: effect.c:3564
static HRESULT parse_fx10_technique(const char *data, size_t data_size, const char **ptr, struct d3d10_effect_technique *t)
Definition: effect.c:3335
static HRESULT d3d10_effect_validate_shared_variable(const struct d3d10_effect *effect, const struct d3d10_effect_variable *v)
Definition: effect.c:4062
GLboolean GLboolean GLboolean b
Definition: glext.h:6204

Referenced by parse_fx10().

◆ parse_fx10_buffer()

static HRESULT parse_fx10_buffer ( const char *  data,
size_t  data_size,
const char **  ptr,
BOOL  local,
struct d3d10_effect_variable *  l 
)
static

Definition at line 3796 of file effect.c.

3798{
3799 enum buffer_flags
3800 {
3801 IS_TBUFFER = 1,
3802 };
3803 const char *prefix = local ? "Local" : "Shared";
3805 unsigned int i;
3806 HRESULT hr;
3807 unsigned int stride = 0;
3808
3809 /* Generate our own type, it isn't in the fx blob. */
3810 if (!(l->type = calloc(1, sizeof(*l->type))))
3811 {
3812 ERR("Failed to allocate local buffer type memory.\n");
3813 return E_OUTOFMEMORY;
3814 }
3815 l->type->ID3D10EffectType_iface.lpVtbl = &d3d10_effect_type_vtbl;
3816 l->type->type_class = D3D10_SVC_OBJECT;
3817 l->type->effect = l->effect;
3818
3819 offset = read_u32(ptr);
3820 TRACE("%s buffer name at offset %#x.\n", prefix, offset);
3821
3822 if (!fx10_copy_string(data, data_size, offset, &l->name))
3823 {
3824 ERR("Failed to copy name.\n");
3825 return E_OUTOFMEMORY;
3826 }
3827 TRACE("%s buffer name: %s.\n", prefix, debugstr_a(l->name));
3828
3829 l->data_size = read_u32(ptr);
3830 TRACE("%s buffer data size: %#x.\n", prefix, l->data_size);
3831
3832 flags = read_u32(ptr);
3833 TRACE("%s buffer flags: %#x.\n", prefix, flags);
3834
3835 if (flags & IS_TBUFFER)
3836 {
3837 l->type->basetype = D3D10_SVT_TBUFFER;
3838 copy_name("tbuffer", &l->type->name);
3839 }
3840 else
3841 {
3842 l->type->basetype = D3D10_SVT_CBUFFER;
3843 copy_name("cbuffer", &l->type->name);
3844 }
3845 if (!l->type->name)
3846 {
3847 ERR("Failed to copy name.\n");
3848 return E_OUTOFMEMORY;
3849 }
3850
3851 flags &= ~IS_TBUFFER;
3852 if (flags)
3853 {
3854 ERR("Unexpected buffer flags %#x.\n", flags);
3855 return E_FAIL;
3856 }
3857
3858 l->type->member_count = read_u32(ptr);
3859 TRACE("%s buffer member count: %#x.\n", prefix, l->type->member_count);
3860
3861 l->explicit_bind_point = read_u32(ptr);
3862 TRACE("%s buffer explicit bind point: %#x.\n", prefix, l->explicit_bind_point);
3863
3864 if (l->effect->flags & D3D10_EFFECT_IS_POOL)
3866
3867 if (local)
3868 {
3869 l->annotations.count = read_u32(ptr);
3870 TRACE("Local buffer has %u annotations.\n", l->annotations.count);
3871
3872 if (FAILED(hr = parse_fx10_annotations(data, data_size, ptr, l->effect,
3873 &l->annotations)))
3874 {
3875 ERR("Failed to parse buffer annotations, hr %#lx.\n", hr);
3876 return hr;
3877 }
3878 }
3879
3880 if (!(l->members = calloc(l->type->member_count, sizeof(*l->members))))
3881 {
3882 ERR("Failed to allocate members memory.\n");
3883 return E_OUTOFMEMORY;
3884 }
3885
3886 if (!(l->type->members = calloc(l->type->member_count, sizeof(*l->type->members))))
3887 {
3888 ERR("Failed to allocate type members memory.\n");
3889 return E_OUTOFMEMORY;
3890 }
3891
3892 if (local && !(l->u.buffer.local_buffer = calloc(1, l->data_size)))
3893 {
3894 ERR("Failed to allocate local constant buffer memory.\n");
3895 return E_OUTOFMEMORY;
3896 }
3897
3898 for (i = 0; i < l->type->member_count; ++i)
3899 {
3900 struct d3d10_effect_variable *v = &l->members[i];
3901 struct d3d10_effect_type_member *typem = &l->type->members[i];
3902
3903 v->buffer = l;
3904 v->effect = l->effect;
3905
3906 if (FAILED(hr = parse_fx10_numeric_variable(data, data_size, ptr, local, v)))
3907 return hr;
3908
3909 /*
3910 * Copy the values from the variable type to the constant buffers type
3911 * members structure, because it is our own generated type.
3912 */
3913 typem->type = v->type;
3914
3915 if (!copy_name(v->name, &typem->name))
3916 {
3917 ERR("Failed to copy name.\n");
3918 return E_OUTOFMEMORY;
3919 }
3920 TRACE("Variable name: %s.\n", debugstr_a(typem->name));
3921
3922 if (!copy_name(v->semantic, &typem->semantic))
3923 {
3924 ERR("Failed to copy name.\n");
3925 return E_OUTOFMEMORY;
3926 }
3927 TRACE("Variable semantic: %s.\n", debugstr_a(typem->semantic));
3928
3929 typem->buffer_offset = v->buffer_offset;
3930 TRACE("Variable buffer offset: %u.\n", typem->buffer_offset);
3931
3932 l->type->size_packed += v->type->size_packed;
3933
3934 /*
3935 * For the complete constantbuffer the size_unpacked = stride,
3936 * the stride is calculated like this:
3937 *
3938 * 1) if the constant buffer variables are packed with packoffset
3939 * - stride = the highest used constant
3940 * - the complete stride has to be a multiple of 0x10
3941 *
3942 * 2) if the constant buffer variables are NOT packed with packoffset
3943 * - sum of unpacked size for all variables which fit in a 0x10 part
3944 * - if the size exceeds a 0x10 part, the rest of the old part is skipped
3945 * and a new part is started
3946 * - if the variable is a struct it is always used a new part
3947 * - the complete stride has to be a multiple of 0x10
3948 *
3949 * e.g.:
3950 * 0x4, 0x4, 0x4, 0x8, 0x4, 0x14, 0x4
3951 * part 0x10 0x10 0x20 -> 0x40
3952 */
3954 {
3955 if ((v->type->size_unpacked + v->buffer_offset) > stride)
3956 {
3957 stride = v->type->size_unpacked + v->buffer_offset;
3958 }
3959 }
3960 else
3961 {
3962 if (v->type->type_class == D3D10_SVC_STRUCT)
3963 {
3964 stride = (stride + 0xf) & ~0xf;
3965 }
3966
3967 if ( ((stride & 0xf) + v->type->size_unpacked) > 0x10)
3968 {
3969 stride = (stride + 0xf) & ~0xf;
3970 }
3971
3972 stride += v->type->size_unpacked;
3973 }
3974 }
3975 l->type->stride = l->type->size_unpacked = (stride + 0xf) & ~0xf;
3976
3977 TRACE("%s constant buffer:\n", prefix);
3978 TRACE("\tType name: %s.\n", debugstr_a(l->type->name));
3979 TRACE("\tElement count: %u.\n", l->type->element_count);
3980 TRACE("\tMember count: %u.\n", l->type->member_count);
3981 TRACE("\tUnpacked size: %#x.\n", l->type->size_unpacked);
3982 TRACE("\tStride: %#x.\n", l->type->stride);
3983 TRACE("\tPacked size %#x.\n", l->type->size_packed);
3984 TRACE("\tBasetype: %s.\n", debug_d3d10_shader_variable_type(l->type->basetype));
3985 TRACE("\tTypeclass: %s.\n", debug_d3d10_shader_variable_class(l->type->type_class));
3986
3987 if (local && l->data_size)
3988 {
3990 {
3991 WARN("Failed to create a buffer object, hr %#lx.\n", hr);
3992 return hr;
3993 }
3994 }
3995
3996 if (l->explicit_bind_point != ~0u)
3998
3999 return S_OK;
4000}
static HRESULT parse_fx10_annotations(const char *data, size_t data_size, const char **ptr, struct d3d10_effect *effect, struct d3d10_effect_annotations *annotations)
Definition: effect.c:2406
static const char * debug_d3d10_shader_variable_class(D3D10_SHADER_VARIABLE_CLASS c)
Definition: effect.c:1145
static HRESULT parse_fx10_numeric_variable(const char *data, size_t data_size, const char **ptr, BOOL local, struct d3d10_effect_variable *v)
Definition: effect.c:3458
static HRESULT create_buffer_object(struct d3d10_effect_variable *v)
Definition: effect.c:3753
#define local
Definition: zutil.h:30
GLsizei stride
Definition: glext.h:5848
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 * u
Definition: glfuncs.h:240
Character const *const prefix
Definition: tempnam.cpp:195

Referenced by parse_fx10_body().

◆ parse_fx10_cli4()

static HRESULT parse_fx10_cli4 ( void *  ctx,
const char *  data,
unsigned int  data_size 
)
static

Definition at line 2729 of file effect.c.

2730{
2732 struct d3d10_effect_preshader *p = context->preshader;
2733 struct d3d10_reg_table *table = &p->reg_tables[D3D10_REG_TABLE_CONSTANTS];
2734 const char *ptr = data;
2736 HRESULT hr;
2737
2738 if (data_size < sizeof(DWORD))
2739 {
2740 WARN("Invalid CLI4 chunk size %u.\n", data_size);
2741 return E_FAIL;
2742 }
2743
2744 count = read_u32(&ptr);
2745
2746 TRACE("%u literal constants.\n", count);
2747
2748 if (!require_space(4, count, sizeof(float), data_size))
2749 {
2750 WARN("Invalid constant table size %u.\n", data_size);
2751 return E_FAIL;
2752 }
2753
2755 return hr;
2756
2757 memcpy(table->f, ptr, table->count * sizeof(*table->f));
2758
2759 return S_OK;
2760}
static HRESULT d3d10_reg_table_allocate(struct d3d10_reg_table *table, unsigned int count)
Definition: effect.c:893
Definition: http.c:7252

Referenced by fxlvm_chunk_handler().

◆ parse_fx10_ctab()

static HRESULT parse_fx10_ctab ( void *  ctx,
const char *  data,
unsigned int  data_size 
)
static

Definition at line 2762 of file effect.c.

2763{
2765 struct d3d10_effect_preshader *p = context->preshader;
2766 struct ctab_header
2767 {
2768 uint32_t size;
2769 uint32_t creator;
2772 uint32_t constantinfo;
2775 } header;
2776 struct ctab_const_info
2777 {
2778 uint32_t name;
2779 WORD register_set;
2780 WORD register_index;
2781 WORD register_count;
2782 WORD reserved;
2784 uint32_t default_value;
2785 } *info;
2786 unsigned int i, cb_reg_count = 0;
2787 const char *ptr = data;
2788 const char *name;
2789 size_t name_len;
2790 HRESULT hr;
2791
2792 if (data_size < sizeof(header))
2793 {
2794 WARN("Invalid constant table size %u.\n", data_size);
2795 return E_FAIL;
2796 }
2797
2798 header.size = read_u32(&ptr);
2799 header.creator = read_u32(&ptr);
2800 header.version = read_u32(&ptr);
2801 header.constants = read_u32(&ptr);
2802 header.constantinfo = read_u32(&ptr);
2803 header.flags = read_u32(&ptr);
2804 header.target = read_u32(&ptr);
2805
2806 if (!require_space(header.constantinfo, header.constants, sizeof(*info), data_size))
2807 {
2808 WARN("Invalid constant info section offset %#x.\n", header.constantinfo);
2809 return E_FAIL;
2810 }
2811
2812 p->vars_count = header.constants;
2813
2814 TRACE("Variable count %u.\n", p->vars_count);
2815
2816 if (!(p->vars = calloc(p->vars_count, sizeof(*p->vars))))
2817 return E_OUTOFMEMORY;
2818
2819 info = (struct ctab_const_info *)(data + header.constantinfo);
2820 for (i = 0; i < p->vars_count; ++i, ++info)
2821 {
2822 if (!fx10_get_string(data, data_size, info->name, &name, &name_len))
2823 return E_FAIL;
2824
2825 if (!(p->vars[i].v = d3d10_effect_get_variable_by_name(context->effect, name)))
2826 {
2827 WARN("Couldn't find variable %s.\n", debugstr_a(name));
2828 return E_FAIL;
2829 }
2830
2831 /* 4 components per register */
2832 p->vars[i].offset = info->register_index * 4;
2833 p->vars[i].length = info->register_count * 4;
2834
2835 cb_reg_count = max(cb_reg_count, info->register_index + info->register_count);
2836 }
2837
2838 /* Allocate contiguous "constant buffer" for all referenced variables. */
2839 if (FAILED(hr = d3d10_reg_table_allocate(&p->reg_tables[D3D10_REG_TABLE_CB], cb_reg_count * 4)))
2840 {
2841 WARN("Failed to allocate variables buffer.\n");
2842 return hr;
2843 }
2844
2845 return S_OK;
2846}
static const WCHAR version[]
Definition: asmname.c:66
r reserved
Definition: btrfs.c:3006
unsigned short WORD
Definition: ntddk_ex.h:93
constants
Definition: resource.c:30
Definition: tools.h:99

Referenced by fxlvm_chunk_handler().

◆ parse_fx10_default_value()

static void parse_fx10_default_value ( const char **  ptr,
struct d3d10_effect_variable *  var 
)
static

Definition at line 3416 of file effect.c.

3417{
3418 unsigned int element_count = max(var->type->element_count, 1), i, m;
3419 struct d3d10_effect_variable *v;
3420
3421 for (i = 0; i < element_count; ++i)
3422 {
3424
3425 switch (v->type->type_class)
3426 {
3427 case D3D10_SVC_STRUCT:
3428 for (m = 0; m < v->type->member_count; ++m)
3429 parse_fx10_default_value(ptr, &v->members[m]);
3430 break;
3431 case D3D10_SVC_SCALAR:
3432 case D3D10_SVC_VECTOR:
3436 break;
3437 default:
3438 FIXME("Unexpected initial value for type %#x.\n", v->type->basetype);
3439 return;
3440 }
3441 }
3442}
static void parse_fx10_default_value(const char **ptr, struct d3d10_effect_variable *var)
Definition: effect.c:3416
static void parse_fx10_set_default_numeric_value(const char **ptr, struct d3d10_effect_variable *v)
Definition: effect.c:3385
static ULONG ** element_count
Definition: exception.c:124

Referenced by parse_fx10_default_value(), and parse_fx10_numeric_variable().

◆ parse_fx10_fxlc()

static HRESULT parse_fx10_fxlc ( void *  ctx,
const char *  data,
unsigned int  data_size 
)
static

Definition at line 2689 of file effect.c.

2690{
2692 struct d3d10_effect_preshader *p = context->preshader;
2693 unsigned int i, offset = 4;
2694 uint32_t ins_count;
2695 const char *ptr;
2696 HRESULT hr;
2697
2698 if (data_size % sizeof(uint32_t))
2699 {
2700 WARN("FXLC size misaligned %u.\n", data_size);
2701 return E_FAIL;
2702 }
2703
2704 if (FAILED(hr = D3DCreateBlob(data_size, &p->code)))
2705 return hr;
2706 memcpy(ID3D10Blob_GetBufferPointer(p->code), data, data_size);
2707
2708 ptr = data;
2709 ins_count = read_u32(&ptr);
2710 TRACE("%u instructions.\n", ins_count);
2711
2712 for (i = 0; i < ins_count; ++i)
2713 {
2714 if (FAILED(hr = parse_fx10_preshader_instr(context, &offset, &ptr, data_size)))
2715 {
2716 WARN("Failed to parse instruction %u.\n", i);
2717 return hr;
2718 }
2719 }
2720
2722 context->table_sizes[D3D10_REG_TABLE_RESULT]))) return hr;
2724 context->table_sizes[D3D10_REG_TABLE_TEMP]))) return hr;
2725
2726 return S_OK;
2727}
static HRESULT parse_fx10_preshader_instr(struct d3d10_preshader_parse_context *context, unsigned int *offset, const char **ptr, unsigned int data_size)
Definition: effect.c:2620
HRESULT WINAPI D3DCreateBlob(SIZE_T data_size, ID3DBlob **blob)
Definition: blob.c:133

Referenced by fxlvm_chunk_handler().

◆ parse_fx10_numeric_variable()

static HRESULT parse_fx10_numeric_variable ( const char *  data,
size_t  data_size,
const char **  ptr,
BOOL  local,
struct d3d10_effect_variable *  v 
)
static

Definition at line 3458 of file effect.c.

3460{
3461 uint32_t offset, flags, default_value_offset, buffer_offset;
3462 const char *data_ptr;
3463 HRESULT hr;
3464
3465 if (FAILED(hr = parse_fx10_variable_head(data, data_size, ptr, v)))
3466 return hr;
3467
3468 offset = read_u32(ptr);
3469 TRACE("Variable semantic at offset %#x.\n", offset);
3470
3471 if (!fx10_copy_string(data, data_size, offset, &v->semantic))
3472 {
3473 ERR("Failed to copy semantic.\n");
3474 return E_OUTOFMEMORY;
3475 }
3476 TRACE("Variable semantic: %s.\n", debugstr_a(v->semantic));
3477
3478 buffer_offset = read_u32(ptr);
3479 TRACE("Variable offset in buffer: %#x.\n", buffer_offset);
3480
3481 default_value_offset = read_u32(ptr);
3482 TRACE("Variable default value offset: %#x.\n", default_value_offset);
3483
3484 flags = read_u32(ptr);
3485 TRACE("Variable flags: %#x.\n", flags);
3486
3487 v->flag |= flags;
3488
3489 /* At this point storage offsets for members and array elements are relative to containing
3490 variable. Update them by moving to correct offset within a buffer. */
3492
3493 if (local)
3494 {
3495 if (default_value_offset)
3496 {
3497 if (!require_space(default_value_offset, 1, v->type->size_packed, data_size))
3498 {
3499 WARN("Invalid default value offset %#x, variable packed size %u.\n", default_value_offset,
3500 v->type->size_packed);
3501 return E_FAIL;
3502 }
3503
3504 data_ptr = data + default_value_offset;
3505 parse_fx10_default_value(&data_ptr, v);
3506 }
3507
3508 v->annotations.count = read_u32(ptr);
3509 TRACE("Variable has %u annotations.\n", v->annotations.count);
3510
3511 if (FAILED(hr = parse_fx10_annotations(data, data_size, ptr, v->effect,
3512 &v->annotations)))
3513 {
3514 ERR("Failed to parse variable annotations, hr %#lx.\n", hr);
3515 return hr;
3516 }
3517 }
3518
3520 v->explicit_bind_point = v->buffer_offset;
3521
3522 return S_OK;
3523}

Referenced by parse_fx10_buffer().

◆ parse_fx10_object_variable()

static HRESULT parse_fx10_object_variable ( const char *  data,
size_t  data_size,
const char **  ptr,
BOOL  shared_type_desc,
struct d3d10_effect_variable *  v 
)
static

Definition at line 3564 of file effect.c.

3566{
3567 struct d3d10_effect_var_array *vars;
3568 struct d3d10_effect_variable *var;
3569 unsigned int i, j, element_count;
3570 HRESULT hr;
3572
3574 return hr;
3575
3576 offset = read_u32(ptr);
3577 TRACE("Variable semantic at offset %#x.\n", offset);
3578
3579 if (!fx10_copy_string(data, data_size, offset, &v->semantic))
3580 {
3581 ERR("Failed to copy semantic.\n");
3582 return E_OUTOFMEMORY;
3583 }
3584 TRACE("Variable semantic: %s.\n", debugstr_a(v->semantic));
3585
3586 v->explicit_bind_point = read_u32(ptr);
3587 TRACE("Variable explicit bind point %#x.\n", v->explicit_bind_point);
3588
3589 /* Shared variable description contains only type information. */
3590 if (shared_type_desc) return S_OK;
3591
3592 element_count = max(v->type->element_count, 1);
3593
3594 switch (v->type->basetype)
3595 {
3596 case D3D10_SVT_TEXTURE:
3605 if (!(v->u.resource.srv = calloc(element_count, sizeof(*v->u.resource.srv))))
3606 {
3607 ERR("Failed to allocate shader resource view array memory.\n");
3608 return E_OUTOFMEMORY;
3609 }
3610 v->u.resource.parent = TRUE;
3611
3612 if (v->elements)
3613 {
3614 for (i = 0; i < v->type->element_count; ++i)
3615 {
3616 v->elements[i].u.resource.srv = &v->u.resource.srv[i];
3617 v->elements[i].u.resource.parent = FALSE;
3618 }
3619 }
3620 break;
3621
3624 case D3D10_SVT_BUFFER:
3625 TRACE("SVT could not have elements.\n");
3626 break;
3627
3631 TRACE("Shader type is %s\n", debug_d3d10_shader_variable_type(v->type->basetype));
3632 for (i = 0; i < element_count; ++i)
3633 {
3634 uint32_t shader_offset, sodecl_offset;
3635
3637
3638 shader_offset = read_u32(ptr);
3639 TRACE("Shader offset: %#x.\n", shader_offset);
3640
3641 if (v->type->flags & D3D10_EOT_FLAG_GS_SO)
3642 {
3643 sodecl_offset = read_u32(ptr);
3644 TRACE("Stream output declaration at offset %#x.\n", sodecl_offset);
3645
3646 if (!fx10_copy_string(data, data_size, sodecl_offset,
3647 &var->u.shader.stream_output_declaration))
3648 {
3649 ERR("Failed to copy stream output declaration.\n");
3650 return E_OUTOFMEMORY;
3651 }
3652
3653 TRACE("Stream output declaration: %s.\n", debugstr_a(var->u.shader.stream_output_declaration));
3654 }
3655
3656 if (FAILED(hr = parse_fx10_shader(data, data_size, shader_offset, var)))
3657 return hr;
3658 }
3659 break;
3660
3662 case D3D10_SVT_BLEND:
3664 case D3D10_SVT_SAMPLER:
3665 {
3666 const struct d3d10_effect_state_storage_info *storage_info;
3667
3668 if (!(storage_info = get_storage_info(v->type->basetype)))
3669 {
3670 FIXME("Failed to get backing store info for type %s.\n",
3671 debug_d3d10_shader_variable_type(v->type->basetype));
3672 return E_FAIL;
3673 }
3674
3675 if (storage_info->size > sizeof(v->u.state.desc))
3676 {
3677 ERR("Invalid storage size %#Ix.\n", storage_info->size);
3678 return E_FAIL;
3679 }
3680
3681 switch (v->type->basetype)
3682 {
3684 vars = &v->effect->ds_states;
3685 break;
3686 case D3D10_SVT_BLEND:
3687 vars = &v->effect->blend_states;
3688 break;
3690 vars = &v->effect->rs_states;
3691 break;
3692 case D3D10_SVT_SAMPLER:
3693 vars = &v->effect->samplers;
3694 break;
3695 default:
3696 ;
3697 }
3698
3699 for (i = 0; i < element_count; ++i)
3700 {
3701 unsigned int prop_count;
3702
3704
3705 if (vars->current >= vars->count)
3706 {
3707 WARN("Wrong variable array size for %#x.\n", v->type->basetype);
3708 return E_FAIL;
3709 }
3710 var->u.state.index = vars->current;
3711 vars->v[vars->current++] = var;
3712
3713 prop_count = read_u32(ptr);
3714 TRACE("State object property count: %#x.\n", prop_count);
3715
3716 memcpy(&var->u.state.desc, storage_info->default_state, storage_info->size);
3717
3718 for (j = 0; j < prop_count; ++j)
3719 {
3721 get_var_container_type(var), var->effect, &var->u.state.desc,
3722 &var->u.state.dependencies)))
3723 {
3724 ERR("Failed to read property list.\n");
3725 return hr;
3726 }
3727 }
3728
3730 return hr;
3731 }
3732 }
3733 break;
3734
3735 default:
3736 FIXME("Unhandled case %s.\n", debug_d3d10_shader_variable_type(v->type->basetype));
3737 return E_FAIL;
3738 }
3739
3740 v->annotations.count = read_u32(ptr);
3741 TRACE("Variable has %u annotations.\n", v->annotations.count);
3742
3743 if (FAILED(hr = parse_fx10_annotations(data, data_size, ptr, v->effect,
3744 &v->annotations)))
3745 {
3746 ERR("Failed to parse variable annotations, hr %#lx.\n", hr);
3747 return hr;
3748 }
3749
3750 return S_OK;
3751}
static const struct d3d10_effect_state_storage_info * get_storage_info(D3D_SHADER_VARIABLE_TYPE id)
Definition: effect.c:2485
static enum d3d10_effect_container_type get_var_container_type(const struct d3d10_effect_variable *v)
Definition: effect.c:174
static HRESULT create_state_object(struct d3d10_effect_variable *v)
Definition: effect.c:3525
static HRESULT parse_fx10_shader(const char *data, size_t data_size, uint32_t offset, struct d3d10_effect_variable *v)
Definition: effect.c:1732
static HRESULT parse_fx10_property_assignment(const char *data, size_t data_size, const char **ptr, enum d3d10_effect_container_type container_type, struct d3d10_effect *effect, void *container, struct d3d10_effect_prop_dependencies *d)
Definition: effect.c:2935
struct d3d10_effect_variable ** v

Referenced by parse_fx10_body().

◆ parse_fx10_pass()

static HRESULT parse_fx10_pass ( const char *  data,
size_t  data_size,
const char **  ptr,
struct d3d10_effect_pass *  p 
)
static

Definition at line 3288 of file effect.c.

3290{
3292 unsigned int i;
3293 HRESULT hr;
3294
3295 offset = read_u32(ptr);
3296 TRACE("Pass name at offset %#x.\n", offset);
3297
3298 if (!fx10_copy_string(data, data_size, offset, &p->name))
3299 {
3300 ERR("Failed to copy name.\n");
3301 return E_OUTOFMEMORY;
3302 }
3303 TRACE("Pass name: %s.\n", debugstr_a(p->name));
3304
3306 TRACE("Pass has %u effect objects.\n", object_count);
3307
3308 p->annotations.count = read_u32(ptr);
3309 TRACE("Pass has %u annotations.\n", p->annotations.count);
3310
3311 if (FAILED(hr = parse_fx10_annotations(data, data_size, ptr, p->technique->effect,
3312 &p->annotations)))
3313 {
3314 ERR("Failed to parse pass annotations, hr %#lx.\n", hr);
3315 return hr;
3316 }
3317
3318 p->vs.shader = &null_shader_variable;
3319 p->ps.shader = &null_shader_variable;
3320 p->gs.shader = &null_shader_variable;
3321
3322 for (i = 0; i < object_count; ++i)
3323 {
3325 D3D10_C_PASS, p->technique->effect, p, &p->dependencies)))
3326 {
3327 WARN("Failed to parse pass assignment %u, hr %#lx.\n", i, hr);
3328 return hr;
3329 }
3330 }
3331
3332 return hr;
3333}

Referenced by parse_fx10_technique().

◆ parse_fx10_preshader()

static HRESULT parse_fx10_preshader ( const char *  data,
size_t  data_size,
struct d3d10_effect *  effect,
struct d3d10_effect_preshader *  preshader 
)
static

Definition at line 2874 of file effect.c.

2876{
2877 const struct vkd3d_shader_code dxbc = {.code = data, .size = data_size};
2880 struct vkd3d_shader_dxbc_desc dxbc_desc;
2881 HRESULT hr = S_OK;
2882 unsigned int i;
2883 int ret;
2884
2885 memset(preshader, 0, sizeof(*preshader));
2886 memset(&context, 0, sizeof(context));
2887 context.preshader = preshader;
2888 context.effect = effect;
2889
2890 if ((ret = vkd3d_shader_parse_dxbc(&dxbc, 0, &dxbc_desc, NULL)) < 0)
2891 {
2892 WARN("Failed to parse DXBC, ret %d.\n", ret);
2893 return E_FAIL;
2894 }
2895
2896 for (i = 0; i < dxbc_desc.section_count; ++i)
2897 {
2898 section = &dxbc_desc.sections[i];
2900 break;
2901 }
2902
2903 vkd3d_shader_free_dxbc(&dxbc_desc);
2904
2905 /* Constant buffer and literal constants are preallocated, validate here that expression
2906 has no invalid accesses for those. */
2907
2908 if (context.table_sizes[D3D10_REG_TABLE_CONSTANTS] >
2909 preshader->reg_tables[D3D10_REG_TABLE_CONSTANTS].count)
2910 {
2911 WARN("Expression references out of bounds literal constant.\n");
2912 return E_FAIL;
2913 }
2914
2915 if (context.table_sizes[D3D10_REG_TABLE_CB] > preshader->reg_tables[D3D10_REG_TABLE_CB].count)
2916 {
2917 WARN("Expression references out of bounds variable.\n");
2918 return E_FAIL;
2919 }
2920
2921 return hr;
2922}
static HRESULT fxlvm_chunk_handler(const struct vkd3d_shader_dxbc_section_desc *section, struct d3d10_preshader_parse_context *ctx)
Definition: effect.c:2848
struct d3d10_reg_table reg_tables[D3D10_REG_TABLE_COUNT]
Definition: effect.c:855

Referenced by parse_fx10_property_assignment().

◆ parse_fx10_preshader_instr()

static HRESULT parse_fx10_preshader_instr ( struct d3d10_preshader_parse_context *  context,
unsigned int *  offset,
const char **  ptr,
unsigned int  data_size 
)
static

Definition at line 2620 of file effect.c.

2622{
2623 const struct preshader_op_info *op_info;
2624 unsigned int i, param_count, size;
2625 struct preshader_instr ins;
2626 uint32_t input_count;
2627
2628 if (!require_space(*offset, 2, sizeof(uint32_t), data_size))
2629 {
2630 WARN("Malformed FXLC table, size %u.\n", data_size);
2631 return E_FAIL;
2632 }
2633
2634 *(uint32_t *)&ins = read_u32(ptr);
2635 input_count = read_u32(ptr);
2636 *offset += 2 * sizeof(uint32_t);
2637
2638 if (!(op_info = d3d10_effect_get_op_info(ins.opcode)))
2639 {
2640 FIXME("Unrecognized opcode %#x.\n", ins.opcode);
2641 return E_FAIL;
2642 }
2643
2644 TRACE("Opcode %#x (%s) (%u,%u), input count %u.\n", ins.opcode, op_info->name,
2645 ins.comp_count, ins.scalar, input_count);
2646
2647 /* Inputs + one output */
2648 param_count = input_count + 1;
2649
2650 if (!require_space(*offset, 3 * param_count, sizeof(uint32_t), data_size))
2651 {
2652 WARN("Malformed FXLC table, opcode %#x.\n", ins.opcode);
2653 return E_FAIL;
2654 }
2655 *offset += 3 * param_count * sizeof(uint32_t);
2656
2657 for (i = 0; i < param_count; ++i)
2658 {
2659 uint32_t flags, regt, param_offset;
2660
2661 flags = read_u32(ptr);
2662 if (flags)
2663 {
2664 FIXME("Argument flags are not supported %#x.\n", flags);
2665 return E_UNEXPECTED;
2666 }
2667
2668 regt = read_u32(ptr);
2669 param_offset = read_u32(ptr);
2670
2671 switch (regt)
2672 {
2674 case D3D10_REG_TABLE_CB:
2677 size = param_offset + (ins.scalar && i == 0 ? 1 : ins.comp_count);
2678 context->table_sizes[regt] = max(context->table_sizes[regt], size);
2679 break;
2680 default:
2681 FIXME("Unexpected register table index %u.\n", regt);
2682 break;
2683 }
2684 }
2685
2686 return S_OK;
2687}
#define uint32_t
Definition: nsiface.idl:61

Referenced by parse_fx10_fxlc().

◆ parse_fx10_property_assignment()

static HRESULT parse_fx10_property_assignment ( const char *  data,
size_t  data_size,
const char **  ptr,
enum d3d10_effect_container_type  container_type,
struct d3d10_effect *  effect,
void *  container,
struct d3d10_effect_prop_dependencies *  d 
)
static

Definition at line 2935 of file effect.c.

2938{
2939 uint32_t id, idx, variable_idx, operation, value_offset, sodecl_offset;
2943 uint32_t code_offset, blob_size;
2944 const char *data_ptr, *name;
2945 unsigned int *dst_index;
2946 size_t name_len;
2947 HRESULT hr;
2948 void *dst;
2949
2950 id = read_u32(ptr);
2951 idx = read_u32(ptr);
2953 value_offset = read_u32(ptr);
2954
2955 if (id >= ARRAY_SIZE(property_infos))
2956 {
2957 FIXME("Unknown property id %#x.\n", id);
2958 return E_FAIL;
2959 }
2961
2962 TRACE("Property %s[%#x] = value list @ offset %#x.\n", property_info->name, idx, value_offset);
2963
2964 if (property_info->container_type != container_type)
2965 {
2966 ERR("Invalid container type %#x for property %#x.\n", container_type, id);
2967 return E_FAIL;
2968 }
2969
2970 if (idx >= property_info->count)
2971 {
2972 ERR("Invalid index %#x for property %#x.\n", idx, id);
2973 return E_FAIL;
2974 }
2975
2976 if (property_info->offset == ~0u)
2977 {
2978 ERR("Unsupported property %#x.\n", id);
2979 return E_NOTIMPL;
2980 }
2981
2982 dst = (char *)container + property_info->offset;
2983 dst_index = (unsigned int *)((char *)container + property_info->index_offset);
2984
2985 switch (operation)
2986 {
2987 case D3D10_EOO_CONST:
2988
2989 /* Constant values output directly to backing store. */
2990 if (!read_value_list(data, data_size, value_offset, property_info->type, idx,
2991 property_info->size, dst))
2992 {
2993 ERR("Failed to read values for property %#x.\n", id);
2994 return E_FAIL;
2995 }
2996 break;
2997
2998 case D3D10_EOO_VAR:
2999
3000 /* Variable. */
3001 if (!fx10_get_string(data, data_size, value_offset, &name, &name_len))
3002 {
3003 WARN("Failed to get variable name.\n");
3004 return E_FAIL;
3005 }
3006 TRACE("Variable name %s.\n", debugstr_a(name));
3007
3009 {
3010 WARN("Couldn't find variable %s.\n", debugstr_a(name));
3011 return E_FAIL;
3012 }
3013
3015 {
3016 if (variable->type->element_count)
3017 {
3018 WARN("Unexpected array variable value %s.\n", debugstr_a(name));
3019 return E_FAIL;
3020 }
3021
3023 {
3024 WARN("Object type mismatch. Variable type %#x, property type %#x.\n",
3025 variable->type->basetype, property_info->type);
3026 return E_FAIL;
3027 }
3028
3029 ((void **)dst)[idx] = variable;
3030 }
3031 else
3032 {
3033 if (property_info->size * sizeof(float) > variable->type->size_unpacked)
3034 {
3035 WARN("Mismatching variable size %u, property size %u.\n",
3036 variable->type->size_unpacked, property_info->size);
3037 return E_FAIL;
3038 }
3039
3040 dep.id = id;
3041 dep.idx = idx;
3042 dep.operation = operation;
3043 dep.var.v = variable;
3044 dep.var.offset = 0;
3045
3046 return d3d10_effect_add_prop_dependency(d, &dep);
3047 }
3048
3049 break;
3050
3052
3053 /* Array variable, constant index. */
3054 if (value_offset >= data_size || !require_space(value_offset, 2, sizeof(DWORD), data_size))
3055 {
3056 WARN("Invalid offset %#x (data size %#Ix).\n", value_offset, data_size);
3057 return E_FAIL;
3058 }
3059 data_ptr = data + value_offset;
3060 value_offset = read_u32(&data_ptr);
3061 variable_idx = read_u32(&data_ptr);
3062
3063 if (!fx10_get_string(data, data_size, value_offset, &name, &name_len))
3064 {
3065 WARN("Failed to get variable name.\n");
3066 return E_FAIL;
3067 }
3068
3069 TRACE("Variable name %s[%s%u].\n", debugstr_a(name), is_object_property(property_info) ?
3070 "" : "offset ", variable_idx);
3071
3073 {
3074 WARN("Couldn't find variable %s.\n", debugstr_a(name));
3075 return E_FAIL;
3076 }
3077
3079 {
3080 if (!variable->type->element_count || variable_idx >= variable->type->element_count)
3081 {
3082 WARN("Invalid array size %u.\n", variable->type->element_count);
3083 return E_FAIL;
3084 }
3085
3087 {
3088 WARN("Object type mismatch. Variable type %#x, property type %#x.\n",
3089 variable->type->basetype, property_info->type);
3090 return E_FAIL;
3091 }
3092
3093 /* Shader variables are special, they are referenced via array, with index stored separately. */
3094 switch (property_info->type)
3095 {
3099 ((void **)dst)[idx] = variable;
3100 *dst_index = variable_idx;
3101 break;
3102 default:
3103 ((void **)dst)[idx] = &variable->elements[variable_idx];
3104 }
3105 }
3106 else
3107 {
3108 unsigned int offset = variable_idx * sizeof(float);
3109
3110 if (offset >= variable->type->size_unpacked ||
3111 variable->type->size_unpacked - offset < property_info->size * sizeof(float))
3112 {
3113 WARN("Invalid numeric variable data offset %u.\n", variable_idx);
3114 return E_FAIL;
3115 }
3116
3117 dep.id = id;
3118 dep.idx = idx;
3119 dep.operation = operation;
3120 dep.var.v = variable;
3121 dep.var.offset = offset;
3122
3123 return d3d10_effect_add_prop_dependency(d, &dep);
3124 }
3125
3126 break;
3127
3129
3130 /* Variable, and an expression for its index. */
3131 if (value_offset >= data_size || !require_space(value_offset, 2, sizeof(DWORD), data_size))
3132 {
3133 WARN("Invalid offset %#x (data size %#Ix).\n", value_offset, data_size);
3134 return E_FAIL;
3135 }
3136
3137 data_ptr = data + value_offset;
3138 value_offset = read_u32(&data_ptr);
3139 code_offset = read_u32(&data_ptr);
3140
3141 if (!fx10_get_string(data, data_size, value_offset, &name, &name_len))
3142 {
3143 WARN("Failed to get variable name.\n");
3144 return E_FAIL;
3145 }
3146
3147 TRACE("Variable name %s[<expr>].\n", debugstr_a(name));
3148
3150 {
3151 WARN("Couldn't find variable %s.\n", debugstr_a(name));
3152 return E_FAIL;
3153 }
3154
3155 if (!variable->type->element_count)
3156 {
3157 WARN("Expected array variable.\n");
3158 return E_FAIL;
3159 }
3160
3162 {
3163 WARN("Expected object type property used with indexed expression.\n");
3164 return E_FAIL;
3165 }
3166
3167 if (code_offset >= data_size || !require_space(code_offset, 1, sizeof(DWORD), data_size))
3168 {
3169 WARN("Invalid offset %#x (data size %#Ix).\n", value_offset, data_size);
3170 return E_FAIL;
3171 }
3172
3173 data_ptr = data + code_offset;
3174 blob_size = read_u32(&data_ptr);
3175
3176 if (!require_space(code_offset, 1, sizeof(uint32_t) + blob_size, data_size))
3177 {
3178 WARN("Invalid offset %#x (data size %#Ix).\n", code_offset, data_size);
3179 return E_FAIL;
3180 }
3181
3182 dep.id = id;
3183 dep.idx = idx;
3184 dep.operation = operation;
3185 dep.index_expr.v = variable;
3186 if (FAILED(hr = parse_fx10_preshader(data_ptr, blob_size, effect, &dep.index_expr.index)))
3187 {
3188 WARN("Failed to parse preshader, hr %#lx.\n", hr);
3189 return hr;
3190 }
3191
3192 return d3d10_effect_add_prop_dependency(d, &dep);
3193
3195
3196 if (value_offset >= data_size || !require_space(value_offset, 1, sizeof(uint32_t), data_size))
3197 {
3198 WARN("Invalid offset %#x (data size %#Ix).\n", value_offset, data_size);
3199 return E_FAIL;
3200 }
3201
3202 data_ptr = data + value_offset;
3203 blob_size = read_u32(&data_ptr);
3204
3205 if (!require_space(value_offset, 1, sizeof(uint32_t) + blob_size, data_size))
3206 {
3207 WARN("Invalid offset %#x (data size %#Ix).\n", value_offset, data_size);
3208 return E_FAIL;
3209 }
3210
3211 dep.id = id;
3212 dep.idx = idx;
3213 dep.operation = operation;
3214 if (FAILED(hr = parse_fx10_preshader(data_ptr, blob_size, effect, &dep.value_expr.value)))
3215 {
3216 WARN("Failed to parse preshader, hr %#lx.\n", hr);
3217 return hr;
3218 }
3219
3220 return d3d10_effect_add_prop_dependency(d, &dep);
3221
3223
3224 /* Anonymous shader */
3225 if (effect->anonymous_shader_current >= effect->anonymous_shader_count)
3226 {
3227 ERR("Anonymous shader count is wrong!\n");
3228 return E_FAIL;
3229 }
3230
3231 if (value_offset >= data_size || !require_space(value_offset, 2, sizeof(DWORD), data_size))
3232 {
3233 WARN("Invalid offset %#x (data size %#Ix).\n", value_offset, data_size);
3234 return E_FAIL;
3235 }
3236 data_ptr = data + value_offset;
3237 value_offset = read_u32(&data_ptr);
3238 sodecl_offset = read_u32(&data_ptr);
3239
3240 TRACE("Effect object starts at offset %#x.\n", value_offset);
3241
3243 &effect->anonymous_shaders[effect->anonymous_shader_current])))
3244 return hr;
3245
3246 variable = &effect->anonymous_shaders[effect->anonymous_shader_current].shader;
3247 ++effect->anonymous_shader_current;
3248
3249 if (sodecl_offset)
3250 {
3251 TRACE("Anonymous shader stream output declaration at offset %#x.\n", sodecl_offset);
3252 if (!fx10_copy_string(data, data_size, sodecl_offset,
3253 &variable->u.shader.stream_output_declaration))
3254 {
3255 ERR("Failed to copy stream output declaration.\n");
3256 return E_FAIL;
3257 }
3258
3259 TRACE("Stream output declaration: %s.\n", debugstr_a(variable->u.shader.stream_output_declaration));
3260 }
3261
3262 switch (property_info->type)
3263 {
3267 if (FAILED(hr = parse_fx10_shader(data, data_size, value_offset, variable)))
3268 return hr;
3269 break;
3270
3271 default:
3272 WARN("Unexpected shader type %#x.\n", property_info->type);
3273 return E_FAIL;
3274 }
3275
3276 ((void **)dst)[idx] = variable;
3277
3278 break;
3279
3280 default:
3281 FIXME("Unhandled operation %#x.\n", operation);
3282 return E_FAIL;
3283 }
3284
3285 return S_OK;
3286}
operation
Definition: copy.c:29
@ D3D10_EOO_CONST
Definition: d3d10_private.h:51
@ D3D10_EOO_ANONYMOUS_SHADER
Definition: d3d10_private.h:57
static HRESULT d3d10_effect_add_prop_dependency(struct d3d10_effect_prop_dependencies *d, const struct d3d10_effect_prop_dependency *dep)
Definition: effect.c:2924
static BOOL is_object_property_type_matching(const struct d3d10_effect_state_property_info *property_info, const struct d3d10_effect_variable *v)
Definition: effect.c:2598
static HRESULT parse_fx10_anonymous_shader(struct d3d10_effect *e, D3D_SHADER_VARIABLE_TYPE basetype, struct d3d10_effect_anonymous_shader *s)
Definition: effect.c:2432
static BOOL is_object_property(const struct d3d10_effect_state_property_info *property_info)
Definition: effect.c:2579
static BOOL read_value_list(const char *data, size_t data_size, uint32_t offset, D3D_SHADER_VARIABLE_TYPE out_type, unsigned int out_base, unsigned int out_size, void *out_data)
Definition: effect.c:2498
static HRESULT parse_fx10_preshader(const char *data, size_t data_size, struct d3d10_effect *effect, struct d3d10_effect_preshader *preshader)
Definition: effect.c:2874
unsigned int idx
Definition: utils.c:40
container_type
Definition: metafile.c:150
GLenum GLenum variable
Definition: glext.h:9031
GLuint id
Definition: glext.h:5910
UINT blob_size
Definition: effect.c:1153

Referenced by parse_fx10_object_variable(), and parse_fx10_pass().

◆ parse_fx10_set_default_numeric_value()

static void parse_fx10_set_default_numeric_value ( const char **  ptr,
struct d3d10_effect_variable *  v 
)
static

Definition at line 3385 of file effect.c.

3386{
3387 float *dst = (float *)(v->buffer->u.buffer.local_buffer + v->buffer_offset), *src;
3388 BOOL col_major = v->type->type_class == D3D10_SVC_MATRIX_COLUMNS;
3389 unsigned int col_count = v->type->column_count, col;
3390 unsigned int row_count = v->type->row_count, row;
3391
3392 src = (float *)*ptr;
3393
3394 if (col_major)
3395 {
3396 for (col = 0; col < col_count; ++col)
3397 {
3398 for (row = 0; row < row_count; ++row)
3399 dst[row] = src[row * col_count + col];
3400 dst += 4;
3401 }
3402 }
3403 else
3404 {
3405 for (row = 0; row < row_count; ++row)
3406 {
3407 memcpy(dst, src, col_count * sizeof(float));
3408 src += col_count;
3409 dst += 4;
3410 }
3411 }
3412
3413 *ptr += col_count * row_count * sizeof(float);
3414}
struct png_info_def *typedef unsigned char **typedef struct png_info_def *typedef struct png_info_def *typedef struct png_info_def *typedef unsigned char ** row
Definition: typeof.h:78
GLenum src
Definition: glext.h:6340

Referenced by parse_fx10_default_value().

◆ parse_fx10_shader()

static HRESULT parse_fx10_shader ( const char *  data,
size_t  data_size,
uint32_t  offset,
struct d3d10_effect_variable *  v 
)
static

Definition at line 1732 of file effect.c.

1733{
1734 ID3D10Device *device = v->effect->device;
1735 uint32_t dxbc_size;
1736 const char *ptr;
1737 HRESULT hr;
1738
1739 if (v->effect->shaders.current >= v->effect->shaders.count)
1740 {
1741 WARN("Invalid effect? Used shader current(%u) >= used shader count(%u)\n",
1742 v->effect->shaders.current, v->effect->shaders.count);
1743 return E_FAIL;
1744 }
1745
1746 v->effect->shaders.v[v->effect->shaders.current++] = v;
1747
1748 if (offset >= data_size || !require_space(offset, 1, sizeof(dxbc_size), data_size))
1749 {
1750 WARN("Invalid offset %#x (data size %#Ix).\n", offset, data_size);
1751 return E_FAIL;
1752 }
1753
1754 ptr = data + offset;
1755 dxbc_size = read_u32(&ptr);
1756 TRACE("DXBC size: %#x.\n", dxbc_size);
1757
1758 if (!require_space(ptr - data, 1, dxbc_size, data_size))
1759 {
1760 WARN("Invalid dxbc size %#x (data size %#Ix, offset %#x).\n", offset, data_size, offset);
1761 return E_FAIL;
1762 }
1763
1764 if (!dxbc_size)
1765 return S_OK;
1766
1767 if (FAILED(hr = D3D10ReflectShader(ptr, dxbc_size, &v->u.shader.reflection)))
1768 return hr;
1769
1770 D3DGetInputSignatureBlob(ptr, dxbc_size, &v->u.shader.input_signature);
1771
1772 if (FAILED(hr = D3DCreateBlob(dxbc_size, &v->u.shader.bytecode)))
1773 return hr;
1774
1775 memcpy(ID3D10Blob_GetBufferPointer(v->u.shader.bytecode), ptr, dxbc_size);
1776
1778 return hr;
1779
1780 switch (v->type->basetype)
1781 {
1783 hr = ID3D10Device_CreateVertexShader(device, ptr, dxbc_size, &v->u.shader.shader.vs);
1784 break;
1785
1787 hr = ID3D10Device_CreatePixelShader(device, ptr, dxbc_size, &v->u.shader.shader.ps);
1788 break;
1789
1791 if (v->u.shader.stream_output_declaration)
1792 {
1793 struct d3d10_effect_so_decl so_decl;
1794
1795 if (FAILED(hr = d3d10_effect_parse_stream_output_declaration(v->u.shader.stream_output_declaration, &so_decl)))
1796 {
1797 WARN("Failed to parse stream output declaration, hr %#lx.\n", hr);
1798 break;
1799 }
1800
1801 hr = ID3D10Device_CreateGeometryShaderWithStreamOutput(device, ptr, dxbc_size,
1802 so_decl.entries, so_decl.count, so_decl.stride, &v->u.shader.shader.gs);
1803
1805 }
1806 else
1807 hr = ID3D10Device_CreateGeometryShader(device, ptr, dxbc_size, &v->u.shader.shader.gs);
1808 break;
1809
1810 default:
1811 ERR("This should not happen!\n");
1812 return E_FAIL;
1813 }
1814
1815 return hr;
1816}
static HRESULT get_fx10_shader_resources(struct d3d10_effect_variable *v)
Definition: effect.c:1550
static HRESULT d3d10_effect_parse_stream_output_declaration(const char *decl, struct d3d10_effect_so_decl *so_decl)
Definition: effect.c:1624
HRESULT WINAPI D3DGetInputSignatureBlob(const void *data, SIZE_T data_size, ID3DBlob **blob)
Definition: blob.c:421
HRESULT WINAPI D3D10ReflectShader(const void *data, SIZE_T data_size, ID3D10ShaderReflection **reflector)
Definition: reflection.c:1969

Referenced by parse_fx10_object_variable(), and parse_fx10_property_assignment().

◆ parse_fx10_technique()

static HRESULT parse_fx10_technique ( const char *  data,
size_t  data_size,
const char **  ptr,
struct d3d10_effect_technique *  t 
)
static

Definition at line 3335 of file effect.c.

3337{
3338 unsigned int i;
3340 HRESULT hr;
3341
3342 offset = read_u32(ptr);
3343 TRACE("Technique name at offset %#x.\n", offset);
3344
3345 if (!fx10_copy_string(data, data_size, offset, &t->name))
3346 {
3347 ERR("Failed to copy name.\n");
3348 return E_OUTOFMEMORY;
3349 }
3350 TRACE("Technique name: %s.\n", debugstr_a(t->name));
3351
3352 t->pass_count = read_u32(ptr);
3353 TRACE("Technique has %u passes.\n", t->pass_count);
3354
3355 t->annotations.count = read_u32(ptr);
3356 TRACE("Technique has %u annotations.\n", t->annotations.count);
3357
3358 if (FAILED(hr = parse_fx10_annotations(data, data_size, ptr, t->effect,
3359 &t->annotations)))
3360 {
3361 ERR("Failed to parse technique annotations, hr %#lx.\n", hr);
3362 return hr;
3363 }
3364
3365 if (!(t->passes = calloc(t->pass_count, sizeof(*t->passes))))
3366 {
3367 ERR("Failed to allocate passes memory\n");
3368 return E_OUTOFMEMORY;
3369 }
3370
3371 for (i = 0; i < t->pass_count; ++i)
3372 {
3373 struct d3d10_effect_pass *p = &t->passes[i];
3374
3376 p->technique = t;
3377
3378 if (FAILED(hr = parse_fx10_pass(data, data_size, ptr, p)))
3379 return hr;
3380 }
3381
3382 return S_OK;
3383}
static const struct ID3D10EffectPassVtbl d3d10_effect_pass_vtbl
Definition: effect.c:54
static HRESULT parse_fx10_pass(const char *data, size_t data_size, const char **ptr, struct d3d10_effect_pass *p)
Definition: effect.c:3288
ID3D10EffectPass ID3D10EffectPass_iface

Referenced by parse_fx10_body().

◆ parse_fx10_type()

static HRESULT parse_fx10_type ( const char *  data,
size_t  data_size,
uint32_t  offset,
struct d3d10_effect_type *  t 
)
static

Definition at line 1896 of file effect.c.

1897{
1898 uint32_t typeinfo, type_flags, type_kind;
1899 union
1900 {
1901 struct numeric_type type;
1902 uint32_t data;
1903 } numeric;
1904
1905 const char *ptr;
1906 unsigned int i;
1907
1908 if (offset >= data_size || !require_space(offset, 6, sizeof(DWORD), data_size))
1909 {
1910 WARN("Invalid offset %#x (data size %#Ix).\n", offset, data_size);
1911 return E_FAIL;
1912 }
1913
1914 ptr = data + offset;
1915 offset = read_u32(&ptr);
1916 TRACE("Type name at offset %#x.\n", offset);
1917
1918 if (!fx10_copy_string(data, data_size, offset, &t->name))
1919 {
1920 ERR("Failed to copy name.\n");
1921 return E_OUTOFMEMORY;
1922 }
1923 TRACE("Type name: %s.\n", debugstr_a(t->name));
1924
1926 TRACE("Kind: %u.\n", type_kind);
1927
1928 t->element_count = read_u32(&ptr);
1929 TRACE("Element count: %u.\n", t->element_count);
1930
1931 t->size_unpacked = read_u32(&ptr);
1932 TRACE("Unpacked size: %#x.\n", t->size_unpacked);
1933
1934 t->stride = read_u32(&ptr);
1935 TRACE("Stride: %#x.\n", t->stride);
1936
1937 t->size_packed = read_u32(&ptr);
1938 TRACE("Packed size %#x.\n", t->size_packed);
1939
1940 switch (type_kind)
1941 {
1942 case 1:
1943 TRACE("Type is numeric.\n");
1944
1945 if (!require_space(ptr - data, 1, sizeof(numeric), data_size))
1946 {
1947 WARN("Invalid offset %#x (data size %#Ix).\n", offset, data_size);
1948 return E_FAIL;
1949 }
1950
1951 numeric.data = read_u32(&ptr);
1952 t->member_count = 0;
1953 t->column_count = numeric.type.columns;
1954 t->row_count = numeric.type.rows;
1955 t->basetype = d3d10_variable_type(numeric.type.base_type, FALSE, &type_flags);
1956 t->type_class = d3d10_variable_class(numeric.type.type_class, numeric.type.column_major);
1957
1958 TRACE("Type description: %#x.\n", numeric.data);
1959 TRACE("\tcolumns: %u.\n", t->column_count);
1960 TRACE("\trows: %u.\n", t->row_count);
1961 TRACE("\tbasetype: %s.\n", debug_d3d10_shader_variable_type(t->basetype));
1962 TRACE("\tclass: %s.\n", debug_d3d10_shader_variable_class(t->type_class));
1963 TRACE("\tunknown bits: %#x.\n", numeric.type.unknown);
1964 break;
1965
1966 case 2:
1967 TRACE("Type is an object.\n");
1968
1969 if (!require_space(ptr - data, 1, sizeof(typeinfo), data_size))
1970 {
1971 WARN("Invalid offset %#x (data size %#Ix).\n", offset, data_size);
1972 return E_FAIL;
1973 }
1974
1975 typeinfo = read_u32(&ptr);
1976 t->member_count = 0;
1977 t->column_count = 0;
1978 t->row_count = 0;
1979 t->basetype = d3d10_variable_type(typeinfo, TRUE, &type_flags);
1980 t->type_class = D3D10_SVC_OBJECT;
1981 t->flags = type_flags;
1982
1983 TRACE("Type description: %#x.\n", typeinfo);
1984 TRACE("\tbasetype: %s.\n", debug_d3d10_shader_variable_type(t->basetype));
1985 TRACE("\tclass: %s.\n", debug_d3d10_shader_variable_class(t->type_class));
1986 TRACE("\tflags: %#x.\n", t->flags);
1987 break;
1988
1989 case 3:
1990 TRACE("Type is a structure.\n");
1991
1992 if (!require_space(ptr - data, 1, sizeof(t->member_count), data_size))
1993 {
1994 WARN("Invalid offset %#x (data size %#Ix).\n", offset, data_size);
1995 return E_FAIL;
1996 }
1997
1998 t->member_count = read_u32(&ptr);
1999 TRACE("Member count: %u.\n", t->member_count);
2000
2001 t->column_count = 0;
2002 t->row_count = 0;
2003 t->basetype = 0;
2004 t->type_class = D3D10_SVC_STRUCT;
2005
2006 if (!(t->members = calloc(t->member_count, sizeof(*t->members))))
2007 {
2008 ERR("Failed to allocate members memory.\n");
2009 return E_OUTOFMEMORY;
2010 }
2011
2012 if (!require_space(ptr - data, t->member_count, 4 * sizeof(DWORD), data_size))
2013 {
2014 WARN("Invalid member count %#x (data size %#Ix, offset %#x).\n",
2015 t->member_count, data_size, offset);
2016 return E_FAIL;
2017 }
2018
2019 for (i = 0; i < t->member_count; ++i)
2020 {
2021 struct d3d10_effect_type_member *typem = &t->members[i];
2022
2023 offset = read_u32(&ptr);
2024 TRACE("Member name at offset %#x.\n", offset);
2025
2026 if (!fx10_copy_string(data, data_size, offset, &typem->name))
2027 {
2028 ERR("Failed to copy name.\n");
2029 return E_OUTOFMEMORY;
2030 }
2031 TRACE("Member name: %s.\n", debugstr_a(typem->name));
2032
2033 offset = read_u32(&ptr);
2034 TRACE("Member semantic at offset %#x.\n", offset);
2035
2036 if (!fx10_copy_string(data, data_size, offset, &typem->semantic))
2037 {
2038 ERR("Failed to copy semantic.\n");
2039 return E_OUTOFMEMORY;
2040 }
2041 TRACE("Member semantic: %s.\n", debugstr_a(typem->semantic));
2042
2043 typem->buffer_offset = read_u32(&ptr);
2044 TRACE("Member offset in struct: %#x.\n", typem->buffer_offset);
2045
2046 offset = read_u32(&ptr);
2047 TRACE("Member type info at offset %#x.\n", offset);
2048
2049 if (!(typem->type = get_fx10_type(t->effect, data, data_size, offset)))
2050 {
2051 ERR("Failed to get variable type.\n");
2052 return E_FAIL;
2053 }
2054 }
2055 break;
2056
2057 default:
2058 FIXME("Unhandled type kind %#x.\n", type_kind);
2059 return E_FAIL;
2060 }
2061
2062 if (t->element_count)
2063 {
2064 TRACE("Elementtype for type at offset: %#lx\n", t->id);
2065
2066 /* allocate elementtype - we need only one, because all elements have the same type */
2067 if (!(t->elementtype = calloc(1, sizeof(*t->elementtype))))
2068 {
2069 ERR("Failed to allocate members memory.\n");
2070 return E_OUTOFMEMORY;
2071 }
2072
2073 /* create a copy of the original type with some minor changes */
2074 t->elementtype->ID3D10EffectType_iface.lpVtbl = &d3d10_effect_type_vtbl;
2075 t->elementtype->effect = t->effect;
2076
2077 if (!copy_name(t->name, &t->elementtype->name))
2078 {
2079 ERR("Failed to copy name.\n");
2080 return E_OUTOFMEMORY;
2081 }
2082 TRACE("\tType name: %s.\n", debugstr_a(t->elementtype->name));
2083
2084 t->elementtype->element_count = 0;
2085 TRACE("\tElement count: %u.\n", t->elementtype->element_count);
2086
2087 /*
2088 * Not sure if this calculation is 100% correct, but a test
2089 * shows that these values work.
2090 */
2091 t->elementtype->size_unpacked = t->size_packed / t->element_count;
2092 TRACE("\tUnpacked size: %#x.\n", t->elementtype->size_unpacked);
2093
2094 t->elementtype->stride = t->stride;
2095 TRACE("\tStride: %#x.\n", t->elementtype->stride);
2096
2097 t->elementtype->size_packed = t->size_packed / t->element_count;
2098 TRACE("\tPacked size: %#x.\n", t->elementtype->size_packed);
2099
2100 t->elementtype->member_count = t->member_count;
2101 TRACE("\tMember count: %u.\n", t->elementtype->member_count);
2102
2103 t->elementtype->column_count = t->column_count;
2104 TRACE("\tColumns: %u.\n", t->elementtype->column_count);
2105
2106 t->elementtype->row_count = t->row_count;
2107 TRACE("\tRows: %u.\n", t->elementtype->row_count);
2108
2109 t->elementtype->basetype = t->basetype;
2110 TRACE("\tBasetype: %s.\n", debug_d3d10_shader_variable_type(t->elementtype->basetype));
2111
2112 t->elementtype->type_class = t->type_class;
2113 TRACE("\tClass: %s.\n", debug_d3d10_shader_variable_class(t->elementtype->type_class));
2114
2115 t->elementtype->members = t->members;
2116 }
2117
2118 return S_OK;
2119}
static struct d3d10_effect_type * get_fx10_type(struct d3d10_effect *effect, const char *data, size_t data_size, uint32_t offset)
Definition: effect.c:2121
static D3D10_SHADER_VARIABLE_TYPE d3d10_variable_type(uint32_t t, BOOL is_object, uint32_t *flags)
Definition: effect.c:1832
static D3D10_SHADER_VARIABLE_CLASS d3d10_variable_class(uint32_t c, BOOL is_column_major)
Definition: effect.c:1818
type_kind
Definition: widltypes.h:232

Referenced by get_fx10_type().

◆ parse_fx10_variable_head()

static HRESULT parse_fx10_variable_head ( const char *  data,
size_t  data_size,
const char **  ptr,
struct d3d10_effect_variable *  v 
)
static

Definition at line 2341 of file effect.c.

2343{
2345
2346 offset = read_u32(ptr);
2347 TRACE("Variable name at offset %#x.\n", offset);
2348
2349 if (!fx10_copy_string(data, data_size, offset, &v->name))
2350 {
2351 ERR("Failed to copy name.\n");
2352 return E_OUTOFMEMORY;
2353 }
2354 TRACE("Variable name: %s.\n", debugstr_a(v->name));
2355
2356 offset = read_u32(ptr);
2357 TRACE("Variable type info at offset %#x.\n", offset);
2358
2359 if (!(v->type = get_fx10_type(v->effect, data, data_size, offset)))
2360 {
2361 ERR("Failed to get variable type.\n");
2362 return E_FAIL;
2363 }
2365
2366 v->explicit_bind_point = ~0u;
2367
2368 if (v->effect->flags & D3D10_EFFECT_IS_POOL)
2370
2372}

Referenced by parse_fx10_annotation(), parse_fx10_numeric_variable(), and parse_fx10_object_variable().

◆ pres_acos()

static void pres_acos ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 286 of file effect.c.

287{
288 float *retval = args[1];
289 unsigned int i;
290
291 for (i = 0; i < instr->comp_count; ++i)
292 retval[i] = acosf(args[0][i]);
293}
_ACRTIMP float __cdecl acosf(float)
Definition: acosf.c:47
unsigned int comp_count
Definition: effect.c:188
int retval
Definition: wcstombs.cpp:91

◆ pres_add()

static void pres_add ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 421 of file effect.c.

422{
423 float *retval = args[2];
424 unsigned int i;
425
426 for (i = 0; i < instr->comp_count; ++i)
427 retval[i] = args[0][instr->scalar ? 0 : i] + args[1][i];
428}
unsigned int scalar
Definition: effect.c:191

◆ pres_and()

static void pres_and ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 635 of file effect.c.

636{
637 unsigned int *arg1 = (unsigned int *)args[0];
638 unsigned int *arg2 = (unsigned int *)args[1];
639 float *retval = args[2];
640 unsigned int i;
641
642 for (i = 0; i < instr->comp_count; ++i)
643 {
644 unsigned int v = arg1[instr->scalar ? 0 : i] & arg2[i];
645 retval[i] = *(float *)&v;
646 }
647}
GLuint GLuint GLuint GLuint arg1
Definition: glext.h:9513
GLuint GLuint GLuint GLuint GLuint GLuint GLuint arg2
Definition: glext.h:9514

◆ pres_asin()

static void pres_asin ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 277 of file effect.c.

278{
279 float *retval = args[1];
280 unsigned int i;
281
282 for (i = 0; i < instr->comp_count; ++i)
283 retval[i] = asinf(args[0][i]);
284}
_ACRTIMP float __cdecl asinf(float)
Definition: asinf.c:47

◆ pres_atan()

static void pres_atan ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 295 of file effect.c.

296{
297 float *retval = args[1];
298 unsigned int i;
299
300 for (i = 0; i < instr->comp_count; ++i)
301 retval[i] = atanf(args[0][i]);
302}
_ACRTIMP float __cdecl atanf(float)
Definition: atanf.c:47

◆ pres_atan2()

static void pres_atan2 ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 439 of file effect.c.

440{
441 float *retval = args[2];
442 unsigned int i;
443
444 for (i = 0; i < instr->comp_count; ++i)
445 retval[i] = atan2f(args[0][instr->scalar ? 0 : i], args[1][i]);
446}
_ACRTIMP float __cdecl atan2f(float, float)
Definition: atan2f.c:51

◆ pres_bieq()

static void pres_bieq ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 513 of file effect.c.

514{
515 int *arg1 = (int *)args[0];
516 int *arg2 = (int *)args[1];
517 float *retval = args[2];
518 unsigned int i;
519
520 for (i = 0; i < instr->comp_count; ++i)
521 {
522 unsigned int v = arg1[instr->scalar ? 0 : i] == arg2[i] ? ~0u : 0;
523 retval[i] = *(float *)&v;
524 }
525}

◆ pres_bige()

static void pres_bige ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 499 of file effect.c.

500{
501 int *arg1 = (int *)args[0];
502 int *arg2 = (int *)args[1];
503 float *retval = args[2];
504 unsigned int i;
505
506 for (i = 0; i < instr->comp_count; ++i)
507 {
508 unsigned int v = arg1[instr->scalar ? 0 : i] >= arg2[i] ? ~0u : 0;
509 retval[i] = *(float *)&v;
510 }
511}

◆ pres_bilt()

static void pres_bilt ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 485 of file effect.c.

486{
487 int *arg1 = (int *)args[0];
488 int *arg2 = (int *)args[1];
489 float *retval = args[2];
490 unsigned int i;
491
492 for (i = 0; i < instr->comp_count; ++i)
493 {
494 unsigned int v = arg1[instr->scalar ? 0 : i] < arg2[i] ? ~0u : 0;
495 retval[i] = *(float *)&v;
496 }
497}

◆ pres_bine()

static void pres_bine ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 527 of file effect.c.

528{
529 int *arg1 = (int *)args[0];
530 int *arg2 = (int *)args[1];
531 float *retval = args[2];
532 unsigned int i;
533
534 for (i = 0; i < instr->comp_count; ++i)
535 {
536 unsigned int v = arg1[instr->scalar ? 0 : i] != arg2[i] ? ~0u : 0;
537 retval[i] = *(float *)&v;
538 }
539}

◆ pres_buge()

static void pres_buge ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 541 of file effect.c.

542{
543 unsigned int *arg1 = (unsigned int *)args[0];
544 unsigned int *arg2 = (unsigned int *)args[1];
545 float *retval = args[2];
546 unsigned int i;
547
548 for (i = 0; i < instr->comp_count; ++i)
549 {
550 unsigned int v = arg1[instr->scalar ? 0 : i] >= arg2[i] ? ~0u : 0;
551 retval[i] = *(float *)&v;
552 }
553}

◆ pres_bult()

static void pres_bult ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 555 of file effect.c.

556{
557 unsigned int *arg1 = (unsigned int *)args[0];
558 unsigned int *arg2 = (unsigned int *)args[1];
559 float *retval = args[2];
560 unsigned int i;
561
562 for (i = 0; i < instr->comp_count; ++i)
563 {
564 unsigned int v = arg1[instr->scalar ? 0 : i] < arg2[i] ? ~0u : 0;
565 retval[i] = *(float *)&v;
566 }
567}

◆ pres_ceil()

static void pres_ceil ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 393 of file effect.c.

394{
395 float value = ceilf(args[0][0]);
396 float *retval = args[1];
397 unsigned int i;
398
399 for (i = 0; i < instr->comp_count; ++i)
400 retval[i] = value;
401}
#define ceilf(x)
Definition: mymath.h:62

◆ pres_cos()

static void pres_cos ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 268 of file effect.c.

269{
270 float *retval = args[1];
271 unsigned int i;
272
273 for (i = 0; i < instr->comp_count; ++i)
274 retval[i] = cos(args[0][i]);
275}
_ACRTIMP double __cdecl cos(double)
Definition: cos.c:21

◆ pres_div()

static void pres_div ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 448 of file effect.c.

449{
450 float *retval = args[2];
451 unsigned int i;
452
453 for (i = 0; i < instr->comp_count; ++i)
454 retval[i] = args[0][instr->scalar ? 0 : i] / args[1][i];
455}

◆ pres_dot()

static void pres_dot ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 727 of file effect.c.

728{
729 float *retval = args[2];
730 unsigned int i;
731
732 *retval = 0.0f;
733 for (i = 0; i < instr->comp_count; ++i)
734 *retval += args[0][instr->scalar ? 0 : i] * args[1][i];
735}

◆ pres_dotswiz()

static void pres_dotswiz ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 737 of file effect.c.

738{
739 float *retval = args[--n];
740 unsigned int i;
741
742 *retval = 0.0f;
743
744 if (n != 6 && n != 8 && instr->comp_count == 1)
745 {
746 WARN("Unexpected argument count %u, or component count %u.\n", n, instr->comp_count);
747 return;
748 }
749
750 for (i = 0; i < n / 2; ++i)
751 *retval += args[i][0] * args[i + n / 2][0];
752}
GLdouble n
Definition: glext.h:7729

◆ pres_exp()

static void pres_exp ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 232 of file effect.c.

233{
234 float *retval = args[1];
235 unsigned int i;
236
237 for (i = 0; i < instr->comp_count; ++i)
238 retval[i] = exp2f(args[0][i]);
239}
_ACRTIMP float __cdecl exp2f(float)
Definition: mathf.c:69

◆ pres_floor()

static void pres_floor ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 382 of file effect.c.

383{
384 float value = floorf(args[0][0]);
385 float *retval = args[1];
386 unsigned int i;
387
388 for (i = 0; i < instr->comp_count; ++i)
389 retval[i] = value;
390}
#define floorf(x)
Definition: mymath.h:65

◆ pres_frc()

static void pres_frc ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 223 of file effect.c.

224{
225 float *retval = args[1];
226 unsigned int i;
227
228 for (i = 0; i < instr->comp_count; ++i)
229 retval[i] = args[0][i] - floor(args[0][i]);
230}
_ACRTIMP double __cdecl floor(double)
Definition: floor.c:18

◆ pres_ftob()

static void pres_ftob ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 369 of file effect.c.

370{
371 float *retval = args[1];
372 unsigned int i;
373
374 for (i = 0; i < instr->comp_count; ++i)
375 {
376 unsigned int u = args[0][i] == 0.0f ? 0 : ~0u;
377 retval[i] = *(float *)&u;
378 }
379}

◆ pres_ftou()

static void pres_ftou ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 357 of file effect.c.

358{
359 float *retval = args[1];
360 unsigned int i;
361
362 for (i = 0; i < instr->comp_count; ++i)
363 {
364 unsigned int u = args[0][i];
365 retval[i] = *(float *)&u;
366 }
367}

◆ pres_iadd()

static void pres_iadd ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 457 of file effect.c.

458{
459 int *arg1 = (int *)args[0];
460 int *arg2 = (int *)args[1];
461 float *retval = args[2];
462 unsigned int i;
463
464 for (i = 0; i < instr->comp_count; ++i)
465 {
466 int v = arg1[instr->scalar ? 0 : i] + arg2[i];
467 retval[i] = *(float *)&v;
468 }
469}

◆ pres_imax()

static void pres_imax ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 596 of file effect.c.

597{
598 int *arg1 = (int *)args[0], *arg2 = (int *)args[1];
599 float *retval = args[2];
600 unsigned int i;
601
602 for (i = 0; i < instr->comp_count; ++i)
603 {
604 int v = max(arg1[instr->scalar ? 0 : i], arg2[i]);
605 retval[i] = *(float *)&v;
606 }
607}

◆ pres_imin()

static void pres_imin ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 583 of file effect.c.

584{
585 int *arg1 = (int *)args[0], *arg2 = (int *)args[1];
586 float *retval = args[2];
587 unsigned int i;
588
589 for (i = 0; i < instr->comp_count; ++i)
590 {
591 int v = min(arg1[instr->scalar ? 0 : i], arg2[i]);
592 retval[i] = *(float *)&v;
593 }
594}
#define min(a, b)
Definition: monoChain.cc:55

◆ pres_imul()

static void pres_imul ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 471 of file effect.c.

472{
473 int *arg1 = (int *)args[0];
474 int *arg2 = (int *)args[1];
475 float *retval = args[2];
476 unsigned int i;
477
478 for (i = 0; i < instr->comp_count; ++i)
479 {
480 int v = arg1[instr->scalar ? 0 : i] * arg2[i];
481 retval[i] = *(float *)&v;
482 }
483}

◆ pres_ineg()

static void pres_ineg ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 313 of file effect.c.

314{
315 int *arg1 = (int *)args[0];
316 float *retval = args[1];
317 unsigned int i;
318
319 for (i = 0; i < instr->comp_count; ++i)
320 {
321 int v = -arg1[i];
322 retval[i] = *(float *)&v;
323 }
324}

◆ pres_ishl()

static void pres_ishl ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 677 of file effect.c.

678{
679 int *arg1 = (int *)args[0], *arg2 = (int *)args[1];
680 float *retval = args[2];
681 unsigned int i;
682
683 for (i = 0; i < instr->comp_count; ++i)
684 {
685 unsigned int v = arg1[instr->scalar ? 0 : i] << (arg2[i] % 32);
686 retval[i] = *(float *)&v;
687 }
688}

◆ pres_ishr()

static void pres_ishr ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 690 of file effect.c.

691{
692 int *arg1 = (int *)args[0], *arg2 = (int *)args[1];
693 float *retval = args[2];
694 unsigned int i;
695
696 for (i = 0; i < instr->comp_count; ++i)
697 {
698 unsigned int v = arg1[instr->scalar ? 0 : i] >> (arg2[i] % 32);
699 retval[i] = *(float *)&v;
700 }
701}

◆ pres_itof()

static void pres_itof ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 339 of file effect.c.

340{
341 float *retval = args[1];
342 unsigned int i;
343
344 for (i = 0; i < instr->comp_count; ++i)
345 retval[i] = *(int *)&args[0][i];
346}

◆ pres_log()

static void pres_log ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 241 of file effect.c.

242{
243 float *retval = args[1];
244 unsigned int i;
245
246 for (i = 0; i < instr->comp_count; ++i)
247 retval[i] = (args[0][i] == 0.0f ? 0.0f : log2f(fabsf(args[0][i])));
248}
_ACRTIMP float __cdecl fabsf(float)
_ACRTIMP float __cdecl log2f(float)
Definition: stubs.c:68

◆ pres_max()

static void pres_max ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 412 of file effect.c.

413{
414 float *retval = args[2];
415 unsigned int i;
416
417 for (i = 0; i < instr->comp_count; ++i)
418 retval[i] = max(args[0][instr->scalar ? 0 : i], args[1][i]);
419}

◆ pres_min()

static void pres_min ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 403 of file effect.c.

404{
405 float *retval = args[2];
406 unsigned int i;
407
408 for (i = 0; i < instr->comp_count; ++i)
409 retval[i] = min(args[0][instr->scalar ? 0 : i], args[1][i]);
410}

◆ pres_mov()

static void pres_mov ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 196 of file effect.c.

197{
198 float *retval = args[1];
199 unsigned int i;
200
201 for (i = 0; i < instr->comp_count; ++i)
202 retval[i] = args[0][i];
203}

◆ pres_movc()

static void pres_movc ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 717 of file effect.c.

718{
719 float *arg1 = args[0], *arg2 = args[1], *arg3 = args[2];
720 float *retval = args[3];
721 unsigned int i;
722
723 for (i = 0; i < instr->comp_count; ++i)
724 retval[i] = arg1[i] ? arg2[i] : arg3[i];
725}
GLuint GLuint GLuint GLuint GLuint GLuint GLuint GLuint GLuint GLuint arg3
Definition: glext.h:9515

◆ pres_mul()

static void pres_mul ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 430 of file effect.c.

431{
432 float *retval = args[2];
433 unsigned int i;
434
435 for (i = 0; i < instr->comp_count; ++i)
436 retval[i] = args[0][instr->scalar ? 0 : i] * args[1][i];
437}

◆ pres_neg()

static void pres_neg ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 205 of file effect.c.

206{
207 float *retval = args[1];
208 unsigned int i;
209
210 for (i = 0; i < instr->comp_count; ++i)
211 retval[i] = -args[0][i];
212}

◆ pres_not()

static void pres_not ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 326 of file effect.c.

327{
328 int *arg1 = (int *)args[0];
329 float *retval = args[1];
330 unsigned int i;
331
332 for (i = 0; i < instr->comp_count; ++i)
333 {
334 int v = ~arg1[0];
335 retval[i] = *(float *)&v;
336 }
337}

◆ pres_or()

static void pres_or ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 649 of file effect.c.

650{
651 unsigned int *arg1 = (unsigned int *)args[0];
652 unsigned int *arg2 = (unsigned int *)args[1];
653 float *retval = args[2];
654 unsigned int i;
655
656 for (i = 0; i < instr->comp_count; ++i)
657 {
658 unsigned int v = arg1[0] | arg2[0];
659 retval[i] = *(float *)&v;
660 }
661}

◆ pres_rcp()

static void pres_rcp ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 214 of file effect.c.

215{
216 float *retval = args[1];
217 unsigned int i;
218
219 for (i = 0; i < instr->comp_count; ++i)
220 retval[i] = 1.0f / args[0][i];
221}

◆ pres_rsq()

static void pres_rsq ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 250 of file effect.c.

251{
252 float *retval = args[1];
253 unsigned int i;
254
255 for (i = 0; i < instr->comp_count; ++i)
256 retval[i] = 1.0f / sqrtf(args[0][i]);
257}
#define sqrtf(x)
Definition: mymath.h:59

◆ pres_sin()

static void pres_sin ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 259 of file effect.c.

260{
261 float *retval = args[1];
262 unsigned int i;
263
264 for (i = 0; i < instr->comp_count; ++i)
265 retval[i] = sin(args[0][i]);
266}
_ACRTIMP double __cdecl sin(double)
Definition: sin.c:21

◆ pres_sqrt()

static void pres_sqrt ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 304 of file effect.c.

305{
306 float *retval = args[1];
307 unsigned int i;
308
309 for (i = 0; i < instr->comp_count; ++i)
310 retval[i] = sqrtf(args[0][i]);
311}

◆ pres_udiv()

static void pres_udiv ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 569 of file effect.c.

570{
571 unsigned int *arg1 = (unsigned int *)args[0];
572 unsigned int *arg2 = (unsigned int *)args[1];
573 float *retval = args[2];
574 unsigned int i;
575
576 for (i = 0; i < instr->comp_count; ++i)
577 {
578 unsigned int v = arg2[i] ? arg1[instr->scalar ? 0 : i] / arg2[i] : UINT_MAX;
579 retval[i] = *(float *)&v;
580 }
581}
#define UINT_MAX
Definition: limits.h:27

◆ pres_umax()

static void pres_umax ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 622 of file effect.c.

623{
624 unsigned int *arg1 = (unsigned int *)args[0], *arg2 = (unsigned int *)args[1];
625 float *retval = args[2];
626 unsigned int i;
627
628 for (i = 0; i < instr->comp_count; ++i)
629 {
630 unsigned int v = max(arg1[instr->scalar ? 0 : i], arg2[i]);
631 retval[i] = *(float *)&v;
632 }
633}

◆ pres_umin()

static void pres_umin ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 609 of file effect.c.

610{
611 unsigned int *arg1 = (unsigned int *)args[0], *arg2 = (unsigned int *)args[1];
612 float *retval = args[2];
613 unsigned int i;
614
615 for (i = 0; i < instr->comp_count; ++i)
616 {
617 unsigned int v = min(arg1[instr->scalar ? 0 : i], arg2[i]);
618 retval[i] = *(float *)&v;
619 }
620}

◆ pres_ushr()

static void pres_ushr ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 703 of file effect.c.

704{
705 unsigned int *arg1 = (unsigned int *)args[0];
706 unsigned int *arg2 = (unsigned int *)args[1];
707 float *retval = args[2];
708 unsigned int i;
709
710 for (i = 0; i < instr->comp_count; ++i)
711 {
712 unsigned int v = arg1[instr->scalar ? 0 : i] >> (arg2[i] % 32);
713 retval[i] = *(float *)&v;
714 }
715}

◆ pres_utof()

static void pres_utof ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 348 of file effect.c.

349{
350 float *retval = args[1];
351 unsigned int i;
352
353 for (i = 0; i < instr->comp_count; ++i)
354 retval[i] = *(unsigned int *)&args[0][i];
355}

◆ pres_xor()

static void pres_xor ( float **  args,
unsigned int  n,
const struct preshader_instr *  instr 
)
static

Definition at line 663 of file effect.c.

664{
665 unsigned int *arg1 = (unsigned int *)args[0];
666 unsigned int *arg2 = (unsigned int *)args[1];
667 float *retval = args[2];
668 unsigned int i;
669
670 for (i = 0; i < instr->comp_count; ++i)
671 {
672 unsigned int v = arg1[instr->scalar ? 0 : i] ^ arg2[i];
673 retval[i] = *(float *)&v;
674 }
675}

◆ preshader_op_compare()

static int __cdecl preshader_op_compare ( const void *  a,
const void *  b 
)
static

Definition at line 814 of file effect.c.

815{
816 int opcode = *(int *)a;
817 const struct preshader_op_info *op_info = b;
818 return opcode - op_info->opcode;
819}
#define b
Definition: ke_i.h:79
unsigned int opcode
Definition: preshader.c:151

Referenced by d3d10_effect_get_op_info().

◆ read_float_value()

static BOOL read_float_value ( uint32_t  value,
D3D_SHADER_VARIABLE_TYPE  in_type,
float *  out_data,
unsigned int  out_idx 
)
static

Definition at line 1227 of file effect.c.

1229{
1230 switch (in_type)
1231 {
1232 case D3D10_SVT_FLOAT:
1233 out_data[out_idx] = *(float *)&value;
1234 return TRUE;
1235
1236 case D3D10_SVT_INT:
1237 out_data[out_idx] = (INT)value;
1238 return TRUE;
1239
1240 case D3D10_SVT_UINT:
1241 out_data[out_idx] = value;
1242 return TRUE;
1243
1244 default:
1245 FIXME("Unhandled in_type %#x.\n", in_type);
1246 return FALSE;
1247 }
1248}
#define INT
Definition: polytest.cpp:20

Referenced by d3d10_effect_read_numeric_value().

◆ read_int32_value()

static BOOL read_int32_value ( uint32_t  value,
D3D_SHADER_VARIABLE_TYPE  in_type,
int *  out_data,
unsigned int  out_idx 
)
static

Definition at line 1250 of file effect.c.

1252{
1253 switch (in_type)
1254 {
1255 case D3D10_SVT_FLOAT:
1256 out_data[out_idx] = *(float *)&value;
1257 return TRUE;
1258
1259 case D3D10_SVT_INT:
1260 case D3D10_SVT_UINT:
1261 case D3D10_SVT_BOOL:
1262 out_data[out_idx] = value;
1263 return TRUE;
1264
1265 default:
1266 FIXME("Unhandled in_type %#x.\n", in_type);
1267 return FALSE;
1268 }
1269}

Referenced by d3d10_effect_read_numeric_value().

◆ read_int8_value()

static BOOL read_int8_value ( uint32_t  value,
D3D_SHADER_VARIABLE_TYPE  in_type,
INT8 *  out_data,
unsigned int  out_idx 
)
static

Definition at line 1271 of file effect.c.

1273{
1274 switch (in_type)
1275 {
1276 case D3D10_SVT_INT:
1277 case D3D10_SVT_UINT:
1278 out_data[out_idx] = value;
1279 return TRUE;
1280
1281 default:
1282 FIXME("Unhandled in_type %#x.\n", in_type);
1283 return FALSE;
1284 }
1285}

Referenced by d3d10_effect_read_numeric_value().

◆ read_matrix_from_buffer()

static void read_matrix_from_buffer ( struct d3d10_effect_variable *  variable,
void *  src_void,
struct d3d10_matrix *  dst,
BOOL  transpose 
)
static

Definition at line 7175 of file effect.c.

7177{
7178 unsigned int col_count = !transpose ? variable->type->column_count : variable->type->row_count;
7179 unsigned int row_count = !transpose ? variable->type->row_count : variable->type->column_count;
7180 BOOL major = variable->type->type_class == D3D10_SVC_MATRIX_COLUMNS;
7181 float *src = src_void;
7182 unsigned int row, col;
7183
7184 if (transpose)
7185 major = !major;
7186
7187 if (major)
7188 {
7189 for (col = 0; col < col_count; ++col)
7190 {
7191 for (row = 0; row < row_count; ++row)
7192 dst->m[row][col] = src[(col * 4) + row];
7193 }
7194 }
7195 else
7196 {
7197 for (row = 0; row < row_count; ++row)
7198 {
7199 for (col = 0; col < col_count; ++col)
7200 dst->m[row][col] = src[(row * 4) + col];
7201 }
7202 }
7203}
GLsizei GLboolean transpose
Definition: glext.h:6077
#define major(rdev)
Definition: propsheet.cpp:928

Referenced by read_matrix_variable_array_from_buffer(), and read_matrix_variable_from_buffer().

◆ read_matrix_variable_array_from_buffer()

static void read_matrix_variable_array_from_buffer ( struct d3d10_effect_variable *  variable,
void *  dst_data,
UINT  offset,
UINT  count,
BOOL  transpose 
)
static

Definition at line 7212 of file effect.c.

7214{
7215 BYTE *src = variable->buffer->u.buffer.local_buffer + variable->buffer_offset;
7216 struct d3d10_matrix *dst = dst_data;
7217 unsigned int i;
7218
7219 if (!variable->type->element_count)
7220 {
7222 return;
7223 }
7224
7225 if (offset >= variable->type->element_count)
7226 {
7227 WARN("Offset %u larger than element count %u, ignoring.\n", offset, variable->type->element_count);
7228 return;
7229 }
7230
7231 if (count > variable->type->element_count - offset)
7232 {
7233 WARN("Offset %u, count %u overruns the variable (element count %u), fixing up.\n",
7234 offset, count, variable->type->element_count);
7235 count = variable->type->element_count - offset;
7236 }
7237
7238 if (offset)
7239 src += variable->type->stride * offset;
7240
7241 for (i = 0; i < count; ++i)
7242 {
7244
7245 src += variable->type->stride;
7246 }
7247}
static void read_matrix_from_buffer(struct d3d10_effect_variable *variable, void *src_void, struct d3d10_matrix *dst, BOOL transpose)
Definition: effect.c:7175
unsigned char BYTE
Definition: xxhash.c:193

Referenced by d3d10_effect_matrix_variable_GetMatrixArray(), and d3d10_effect_matrix_variable_GetMatrixTransposeArray().

◆ read_matrix_variable_from_buffer()

static void read_matrix_variable_from_buffer ( struct d3d10_effect_variable *  variable,
void *  dst,
BOOL  transpose 
)
static

Definition at line 7205 of file effect.c.

7206{
7207 BYTE *src = variable->buffer->u.buffer.local_buffer + variable->buffer_offset;
7208
7210}

Referenced by d3d10_effect_matrix_variable_GetMatrix(), d3d10_effect_matrix_variable_GetMatrixTranspose(), and read_matrix_variable_array_from_buffer().

◆ read_value_list()

static BOOL read_value_list ( const char *  data,
size_t  data_size,
uint32_t  offset,
D3D_SHADER_VARIABLE_TYPE  out_type,
unsigned int  out_base,
unsigned int  out_size,
void *  out_data 
)
static

Definition at line 2498 of file effect.c.

2501{
2502 uint32_t t, value, count, type_flags;
2504 const char *ptr;
2505 unsigned int i;
2506
2507 if (offset >= data_size || !require_space(offset, 1, sizeof(count), data_size))
2508 {
2509 WARN("Invalid offset %#x (data size %#Ix).\n", offset, data_size);
2510 return FALSE;
2511 }
2512
2513 ptr = data + offset;
2514 count = read_u32(&ptr);
2515 if (count != out_size)
2516 return FALSE;
2517
2518 if (!require_space(ptr - data, count, 2 * sizeof(DWORD), data_size))
2519 {
2520 WARN("Invalid value count %#x (offset %#x, data size %#Ix).\n", count, offset, data_size);
2521 return FALSE;
2522 }
2523
2524 TRACE("%u values:\n", count);
2525 for (i = 0; i < count; ++i)
2526 {
2527 unsigned int out_idx = out_base * out_size + i;
2528
2529 t = read_u32(&ptr);
2530 value = read_u32(&ptr);
2531
2532 in_type = d3d10_variable_type(t, FALSE, &type_flags);
2533 TRACE("\t%s: %#x.\n", debug_d3d10_shader_variable_type(in_type), value);
2534
2535 switch (out_type)
2536 {
2537 case D3D10_SVT_FLOAT:
2538 case D3D10_SVT_INT:
2539 case D3D10_SVT_UINT:
2540 case D3D10_SVT_UINT8:
2541 case D3D10_SVT_BOOL:
2542 if (!d3d10_effect_read_numeric_value(value, in_type, out_type, out_data, out_idx))
2543 return FALSE;
2544 break;
2545
2547 *(void **)out_data = &anonymous_vs;
2548 break;
2549
2551 *(void **)out_data = &anonymous_ps;
2552 break;
2553
2555 *(void **)out_data = &anonymous_gs;
2556 break;
2557
2558 case D3D10_SVT_TEXTURE:
2559 *(void **)out_data = &null_shader_resource_variable;
2560 break;
2561
2563 *(void **)out_data = &null_depth_stencil_variable;
2564 break;
2565
2566 case D3D10_SVT_BLEND:
2567 *(void **)out_data = &null_blend_variable;
2568 break;
2569
2570 default:
2571 FIXME("Unhandled out_type %#x.\n", out_type);
2572 return FALSE;
2573 }
2574 }
2575
2576 return TRUE;
2577}
enum _D3D_SHADER_VARIABLE_TYPE D3D_SHADER_VARIABLE_TYPE
static struct d3d10_effect_variable anonymous_vs
Definition: effect.c:123
static struct d3d10_effect_variable anonymous_gs
Definition: effect.c:127
static struct d3d10_effect_variable anonymous_ps
Definition: effect.c:125
static HANDLE PIO_APC_ROUTINE PVOID PIO_STATUS_BLOCK ULONG PVOID ULONG PVOID ULONG out_size
Definition: file.c:72

Referenced by parse_fx10_property_assignment().

◆ read_variable_array_from_buffer()

static void read_variable_array_from_buffer ( struct d3d10_effect_variable *  variable,
void *  dst,
D3D_SHADER_VARIABLE_TYPE  dst_type,
unsigned int  offset,
unsigned int  count 
)
static

Definition at line 6383 of file effect.c.

6385{
6386 BYTE *src = variable->buffer->u.buffer.local_buffer + variable->buffer_offset;
6387 D3D_SHADER_VARIABLE_TYPE src_type = variable->type->basetype;
6388 unsigned int element_size, i;
6389 BYTE *cur_element = dst;
6390
6391 if (!variable->type->element_count)
6392 {
6394 return;
6395 }
6396
6397 if (offset >= variable->type->element_count)
6398 {
6399 WARN("Offset %u larger than element count %u, ignoring.\n", offset, variable->type->element_count);
6400 return;
6401 }
6402
6403 if (count > variable->type->element_count - offset)
6404 {
6405 WARN("Offset %u, count %u overruns the variable (element count %u), fixing up.\n",
6406 offset, count, variable->type->element_count);
6407 count = variable->type->element_count - offset;
6408 }
6409
6410 element_size = variable->type->elementtype->size_packed;
6411 src += variable->type->stride * offset;
6412
6413 for (i = 0; i < count; ++i)
6414 {
6415 get_vector_as_type(cur_element, dst_type, src, src_type, variable->type->column_count);
6416
6417 cur_element += element_size;
6418 src += variable->type->stride;
6419 }
6420}
size_t const element_size
Definition: debug_heap.cpp:510
static void get_vector_as_type(BYTE *dst_data, D3D_SHADER_VARIABLE_TYPE dst_type, BYTE *src_data, D3D_SHADER_VARIABLE_TYPE src_type, unsigned int count)
Definition: effect.c:6286

Referenced by d3d10_effect_scalar_variable_GetBoolArray(), d3d10_effect_scalar_variable_GetFloatArray(), d3d10_effect_scalar_variable_GetIntArray(), d3d10_effect_vector_variable_GetBoolVectorArray(), d3d10_effect_vector_variable_GetFloatVectorArray(), and d3d10_effect_vector_variable_GetIntVectorArray().

◆ read_variable_from_buffer()

static void read_variable_from_buffer ( struct d3d10_effect_variable *  variable,
void *  dst,
D3D_SHADER_VARIABLE_TYPE  dst_type 
)
static

◆ require_space()

static BOOL require_space ( size_t  offset,
size_t  count,
size_t  size,
size_t  data_size 
)
static

◆ set_sampler()

static void set_sampler ( ID3D10Device *  device,
D3D10_SHADER_VARIABLE_TYPE  shader_type,
struct d3d10_effect_variable *  v,
unsigned int  bind_point 
)
static

Definition at line 5328 of file effect.c.

5330{
5331 switch (shader_type)
5332 {
5334 ID3D10Device_VSSetSamplers(device, bind_point, 1, &v->u.state.object.sampler);
5335 break;
5336
5338 ID3D10Device_PSSetSamplers(device, bind_point, 1, &v->u.state.object.sampler);
5339 break;
5340
5342 ID3D10Device_GSSetSamplers(device, bind_point, 1, &v->u.state.object.sampler);
5343 break;
5344
5345 default:
5346 WARN("Incorrect shader type to bind sampler.\n");
5347 break;
5348 }
5349}

Referenced by apply_shader_resources().

◆ set_shader_resource_variable()

static void set_shader_resource_variable ( ID3D10ShaderResourceView **  src,
ID3D10ShaderResourceView **  dst 
)
static

Definition at line 7762 of file effect.c.

7763{
7764 if (*dst == *src)
7765 return;
7766
7767 if (*src)
7768 ID3D10ShaderResourceView_AddRef(*src);
7769 if (*dst)
7770 ID3D10ShaderResourceView_Release(*dst);
7771
7772 *dst = *src;
7773}

Referenced by d3d10_effect_shader_resource_variable_SetResource(), and d3d10_effect_shader_resource_variable_SetResourceArray().

◆ set_variable_vtbl()

static void set_variable_vtbl ( struct d3d10_effect_variable *  v)
static

Definition at line 2161 of file effect.c.

2162{
2163 const ID3D10EffectVariableVtbl **vtbl = &v->ID3D10EffectVariable_iface.lpVtbl;
2164
2165 switch (v->type->type_class)
2166 {
2167 case D3D10_SVC_SCALAR:
2168 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_scalar_variable_vtbl;
2169 break;
2170
2171 case D3D10_SVC_VECTOR:
2172 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_vector_variable_vtbl;
2173 break;
2174
2177 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_matrix_variable_vtbl;
2178 break;
2179
2180 case D3D10_SVC_STRUCT:
2182 break;
2183
2184 case D3D10_SVC_OBJECT:
2185 switch(v->type->basetype)
2186 {
2187 case D3D10_SVT_STRING:
2188 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_string_variable_vtbl;
2189 break;
2190
2191 case D3D10_SVT_TEXTURE:
2200 case D3D10_SVT_BUFFER: /* Either resource or constant buffer. */
2201 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_shader_resource_variable_vtbl;
2202 break;
2203
2205 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_render_target_view_variable_vtbl;
2206 break;
2207
2209 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_depth_stencil_view_variable_vtbl;
2210 break;
2211
2213 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_depth_stencil_variable_vtbl;
2214 break;
2215
2219 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_shader_variable_vtbl;
2220 break;
2221
2222 case D3D10_SVT_BLEND:
2223 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_blend_variable_vtbl;
2224 break;
2225
2227 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_rasterizer_variable_vtbl;
2228 break;
2229
2230 case D3D10_SVT_SAMPLER:
2231 *vtbl = (const ID3D10EffectVariableVtbl *)&d3d10_effect_sampler_variable_vtbl;
2232 break;
2233
2234 default:
2235 FIXME("Unhandled basetype %s.\n", debug_d3d10_shader_variable_type(v->type->basetype));
2237 break;
2238 }
2239 break;
2240
2241 default:
2242 FIXME("Unhandled type class %s.\n", debug_d3d10_shader_variable_class(v->type->type_class));
2244 break;
2245 }
2246}

Referenced by copy_variableinfo_from_type(), parse_fx10_anonymous_shader(), and parse_fx10_variable_head().

◆ unsafe_impl_from_ID3D10EffectPool()

static struct d3d10_effect * unsafe_impl_from_ID3D10EffectPool ( ID3D10EffectPool *  iface)
inlinestatic

Definition at line 43 of file effect.c.

44{
45 if (!iface || iface->lpVtbl != &d3d10_effect_pool_vtbl)
46 return NULL;
47 return CONTAINING_RECORD(iface, struct d3d10_effect, ID3D10EffectPool_iface);
48}

Referenced by D3D10CreateEffectFromMemory().

◆ update_buffer()

static void update_buffer ( ID3D10Device *  device,
struct d3d10_effect_variable *  v 
)
static

Definition at line 5315 of file effect.c.

5316{
5317 struct d3d10_effect_buffer_variable *b = &v->u.buffer;
5318
5319 if (!b->changed)
5320 return;
5321
5322 ID3D10Device_UpdateSubresource(device, (ID3D10Resource *)b->buffer, 0, NULL,
5323 b->local_buffer, v->data_size, 0);
5324
5325 b->changed = FALSE;
5326}

Referenced by apply_shader_resources().

◆ WINE_DEFAULT_DEBUG_CHANNEL()

WINE_DEFAULT_DEBUG_CHANNEL ( d3d10  )

◆ write_matrix_to_buffer()

static void write_matrix_to_buffer ( struct d3d10_effect_variable *  variable,
void *  dst_void,
struct d3d10_matrix *  src,
BOOL  transpose 
)
static

Definition at line 7097 of file effect.c.

7099{
7100 unsigned int col_count = !transpose ? variable->type->column_count : variable->type->row_count;
7101 unsigned int row_count = !transpose ? variable->type->row_count : variable->type->column_count;
7102 BOOL major = variable->type->type_class == D3D10_SVC_MATRIX_COLUMNS;
7103 float *dst = dst_void;
7104 unsigned int row, col;
7105
7106 if (transpose)
7107 major = !major;
7108
7109 if (major)
7110 {
7111 for (col = 0; col < col_count; ++col)
7112 {
7113 for (row = 0; row < row_count; ++row)
7114 dst[(col * 4) + row] = src->m[row][col];
7115 }
7116 }
7117 else
7118 {
7119 for (row = 0; row < row_count; ++row)
7120 {
7121 for (col = 0; col < col_count; ++col)
7122 dst[(row * 4) + col] = src->m[row][col];
7123 }
7124 }
7125}

Referenced by write_matrix_variable_array_to_buffer(), and write_matrix_variable_to_buffer().

◆ write_matrix_variable_array_to_buffer()

static void write_matrix_variable_array_to_buffer ( struct d3d10_effect_variable *  variable,
void *  src_data,
unsigned int  offset,
unsigned int  count,
BOOL  transpose 
)
static

Definition at line 7136 of file effect.c.

7138{
7139 BYTE *dst = variable->buffer->u.buffer.local_buffer + variable->buffer_offset;
7140 struct d3d10_matrix *src = src_data;
7141 unsigned int i;
7142
7143 if (!variable->type->element_count)
7144 {
7146 return;
7147 }
7148
7149 if (offset >= variable->type->element_count)
7150 {
7151 WARN("Offset %u larger than element count %u, ignoring.\n", offset, variable->type->element_count);
7152 return;
7153 }
7154
7155 if (count > variable->type->element_count - offset)
7156 {
7157 WARN("Offset %u, count %u overruns the variable (element count %u), fixing up.\n",
7158 offset, count, variable->type->element_count);
7159 count = variable->type->element_count - offset;
7160 }
7161
7162 if (offset)
7163 dst += variable->type->stride * offset;
7164
7165 for (i = 0; i < count; ++i)
7166 {
7168
7169 dst += variable->type->stride;
7170 }
7171
7172 variable->buffer->u.buffer.changed = TRUE;
7173}
static void write_matrix_to_buffer(struct d3d10_effect_variable *variable, void *dst_void, struct d3d10_matrix *src, BOOL transpose)
Definition: effect.c:7097

Referenced by d3d10_effect_matrix_variable_SetMatrixArray(), and d3d10_effect_matrix_variable_SetMatrixTransposeArray().

◆ write_matrix_variable_to_buffer()

static void write_matrix_variable_to_buffer ( struct d3d10_effect_variable *  variable,
void *  src_data,
BOOL  transpose 
)
static

Definition at line 7127 of file effect.c.

7128{
7129 BYTE *dst = variable->buffer->u.buffer.local_buffer + variable->buffer_offset;
7130
7132
7133 variable->buffer->u.buffer.changed = TRUE;
7134}

Referenced by d3d10_effect_matrix_variable_SetMatrix(), d3d10_effect_matrix_variable_SetMatrixTranspose(), and write_matrix_variable_array_to_buffer().

◆ write_variable_array_to_buffer()

static void write_variable_array_to_buffer ( struct d3d10_effect_variable *  variable,
void *  src,
D3D_SHADER_VARIABLE_TYPE  src_type,
unsigned int  offset,
unsigned int  count 
)
static

Definition at line 6333 of file effect.c.

6335{
6336 BYTE *dst = variable->buffer->u.buffer.local_buffer + variable->buffer_offset;
6337 D3D_SHADER_VARIABLE_TYPE dst_type = variable->type->basetype;
6338 unsigned int element_size, i;
6339 BYTE *cur_element = src;
6340
6341 if (!variable->type->element_count)
6342 {
6344 return;
6345 }
6346
6347 if (offset >= variable->type->element_count)
6348 {
6349 WARN("Offset %u larger than element count %u, ignoring.\n", offset, variable->type->element_count);
6350 return;
6351 }
6352
6353 if (count > variable->type->element_count - offset)
6354 {
6355 WARN("Offset %u, count %u overruns the variable (element count %u), fixing up.\n",
6356 offset, count, variable->type->element_count);
6357 count = variable->type->element_count - offset;
6358 }
6359
6360 element_size = variable->type->elementtype->size_packed;
6361 dst += variable->type->stride * offset;
6362
6363 for (i = 0; i < count; ++i)
6364 {
6365 get_vector_as_type(dst, dst_type, cur_element, src_type, variable->type->column_count);
6366
6367 cur_element += element_size;
6368 dst += variable->type->stride;
6369 }
6370
6371 variable->buffer->u.buffer.changed = TRUE;
6372}

Referenced by d3d10_effect_scalar_variable_SetBoolArray(), d3d10_effect_scalar_variable_SetFloatArray(), d3d10_effect_scalar_variable_SetIntArray(), d3d10_effect_vector_variable_SetBoolVectorArray(), d3d10_effect_vector_variable_SetFloatVectorArray(), and d3d10_effect_vector_variable_SetIntVectorArray().

◆ write_variable_to_buffer()

static void write_variable_to_buffer ( struct d3d10_effect_variable *  variable,
void *  src,
D3D_SHADER_VARIABLE_TYPE  src_type 
)
static

Definition at line 6322 of file effect.c.

6324{
6325 BYTE *dst = variable->buffer->u.buffer.local_buffer + variable->buffer_offset;
6326 D3D_SHADER_VARIABLE_TYPE dst_type = variable->type->basetype;
6327
6328 get_vector_as_type(dst, dst_type, src, src_type, variable->type->column_count);
6329
6330 variable->buffer->u.buffer.changed = TRUE;
6331}

Referenced by d3d10_effect_scalar_variable_SetBool(), d3d10_effect_scalar_variable_SetFloat(), d3d10_effect_scalar_variable_SetInt(), d3d10_effect_vector_variable_SetBoolVector(), d3d10_effect_vector_variable_SetFloatVector(), d3d10_effect_vector_variable_SetIntVector(), and write_variable_array_to_buffer().

Variable Documentation

◆ anonymous_geometryshader_name

char anonymous_geometryshader_name[] = "geometryshader"
static

Definition at line 116 of file effect.c.

◆ anonymous_gs

struct d3d10_effect_variable anonymous_gs
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_shader_variable_vtbl},
static char anonymous_name[]
Definition: effect.c:113
static struct d3d10_effect_type anonymous_gs_type
Definition: effect.c:121

Definition at line 127 of file effect.c.

Referenced by read_value_list().

◆ anonymous_gs_type

struct d3d10_effect_type anonymous_gs_type
static
Initial value:

Definition at line 121 of file effect.c.

◆ anonymous_name

char anonymous_name[] = "$Anonymous"
static

Definition at line 113 of file effect.c.

◆ anonymous_pixelshader_name

char anonymous_pixelshader_name[] = "pixelshader"
static

Definition at line 115 of file effect.c.

◆ anonymous_ps

struct d3d10_effect_variable anonymous_ps
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_shader_variable_vtbl},
static struct d3d10_effect_type anonymous_ps_type
Definition: effect.c:119

Definition at line 125 of file effect.c.

Referenced by read_value_list().

◆ anonymous_ps_type

struct d3d10_effect_type anonymous_ps_type
static
Initial value:

Definition at line 119 of file effect.c.

◆ anonymous_vertexshader_name

char anonymous_vertexshader_name[] = "vertexshader"
static

Definition at line 114 of file effect.c.

◆ anonymous_vs

struct d3d10_effect_variable anonymous_vs
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_shader_variable_vtbl},
static struct d3d10_effect_type anonymous_vs_type
Definition: effect.c:117

Definition at line 123 of file effect.c.

Referenced by read_value_list().

◆ anonymous_vs_type

struct d3d10_effect_type anonymous_vs_type
static
Initial value:

Definition at line 117 of file effect.c.

◆ d3d10_effect_blend_variable_vtbl

static const struct ID3D10EffectBlendVariableVtbl d3d10_effect_blend_variable_vtbl
static

Definition at line 65 of file effect.c.

Referenced by d3d10_effect_variable_AsBlend(), and set_variable_vtbl().

◆ d3d10_effect_constant_buffer_vtbl

static const struct ID3D10EffectConstantBufferVtbl d3d10_effect_constant_buffer_vtbl
static

Definition at line 56 of file effect.c.

Referenced by d3d10_effect_variable_AsConstantBuffer(), and parse_fx10_body().

◆ d3d10_effect_depth_stencil_variable_vtbl

static const struct ID3D10EffectDepthStencilVariableVtbl d3d10_effect_depth_stencil_variable_vtbl
static

Definition at line 66 of file effect.c.

Referenced by d3d10_effect_variable_AsDepthStencil(), and set_variable_vtbl().

◆ d3d10_effect_depth_stencil_view_variable_vtbl

static const struct ID3D10EffectDepthStencilViewVariableVtbl d3d10_effect_depth_stencil_view_variable_vtbl
static

Definition at line 63 of file effect.c.

Referenced by d3d10_effect_variable_AsDepthStencilView(), and set_variable_vtbl().

◆ d3d10_effect_matrix_variable_vtbl

static const struct ID3D10EffectMatrixVariableVtbl d3d10_effect_matrix_variable_vtbl
static

Definition at line 59 of file effect.c.

Referenced by d3d10_effect_variable_AsMatrix(), and set_variable_vtbl().

◆ d3d10_effect_pass_vtbl

static const struct ID3D10EffectPassVtbl d3d10_effect_pass_vtbl
static
Initial value:
=
{
}
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_pass_GetAnnotationByName(ID3D10EffectPass *iface, const char *name)
Definition: effect.c:5305
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetDesc(ID3D10EffectPass *iface, D3D10_PASS_DESC *desc)
Definition: effect.c:5169
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetGeometryShaderDesc(ID3D10EffectPass *iface, D3D10_PASS_SHADER_DESC *desc)
Definition: effect.c:5241
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_ComputeStateBlockMask(ID3D10EffectPass *iface, D3D10_STATE_BLOCK_MASK *mask)
Definition: effect.c:5503
static BOOL STDMETHODCALLTYPE d3d10_effect_pass_IsValid(ID3D10EffectPass *iface)
Definition: effect.c:5160
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetPixelShaderDesc(ID3D10EffectPass *iface, D3D10_PASS_SHADER_DESC *desc)
Definition: effect.c:5268
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_Apply(ID3D10EffectPass *iface, UINT flags)
Definition: effect.c:5474
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_pass_GetAnnotationByIndex(ID3D10EffectPass *iface, UINT index)
Definition: effect.c:5295
static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_GetVertexShaderDesc(ID3D10EffectPass *iface, D3D10_PASS_SHADER_DESC *desc)
Definition: effect.c:5214

Definition at line 54 of file effect.c.

Referenced by parse_fx10_technique().

◆ d3d10_effect_pool_effect_vtbl

static const struct ID3D10EffectVtbl d3d10_effect_pool_effect_vtbl
static
Initial value:
=
{
}
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_GetVariableByName(ID3D10Effect *iface, const char *name)
Definition: effect.c:4780
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_GetConstantBufferByIndex(ID3D10Effect *iface, UINT index)
Definition: effect.c:4703
static struct ID3D10EffectTechnique *STDMETHODCALLTYPE d3d10_effect_GetTechniqueByName(ID3D10Effect *iface, const char *name)
Definition: effect.c:4881
static HRESULT STDMETHODCALLTYPE d3d10_effect_GetDevice(ID3D10Effect *iface, ID3D10Device **device)
Definition: effect.c:4645
static BOOL STDMETHODCALLTYPE d3d10_effect_IsPool(ID3D10Effect *iface)
Definition: effect.c:4636
static struct ID3D10EffectTechnique *STDMETHODCALLTYPE d3d10_effect_GetTechniqueByIndex(ID3D10Effect *iface, UINT index)
Definition: effect.c:4860
static BOOL STDMETHODCALLTYPE d3d10_effect_IsOptimized(ID3D10Effect *iface)
Definition: effect.c:4956
static BOOL STDMETHODCALLTYPE d3d10_effect_IsValid(ID3D10Effect *iface)
Definition: effect.c:4629
static struct ID3D10EffectConstantBuffer *STDMETHODCALLTYPE d3d10_effect_GetConstantBufferByName(ID3D10Effect *iface, const char *name)
Definition: effect.c:4723
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_GetVariableBySemantic(ID3D10Effect *iface, const char *semantic)
Definition: effect.c:4835
static HRESULT STDMETHODCALLTYPE d3d10_effect_pool_effect_QueryInterface(ID3D10Effect *iface, REFIID riid, void **object)
Definition: effect.c:10164
static HRESULT STDMETHODCALLTYPE d3d10_effect_Optimize(ID3D10Effect *iface)
Definition: effect.c:4910
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_GetVariableByIndex(ID3D10Effect *iface, UINT index)
Definition: effect.c:4762
static HRESULT STDMETHODCALLTYPE d3d10_effect_GetDesc(ID3D10Effect *iface, D3D10_EFFECT_DESC *desc)
Definition: effect.c:4667

Definition at line 50 of file effect.c.

Referenced by d3d10_create_effect(), and d3d10_effect_IsPool().

◆ d3d10_effect_pool_vtbl

const struct ID3D10EffectPoolVtbl d3d10_effect_pool_vtbl
Initial value:
=
{
}
static ULONG STDMETHODCALLTYPE d3d10_effect_pool_AddRef(ID3D10EffectPool *iface)
Definition: effect.c:10057
static HRESULT STDMETHODCALLTYPE d3d10_effect_pool_QueryInterface(ID3D10EffectPool *iface, REFIID riid, void **object)
Definition: effect.c:10038
static ID3D10Effect *STDMETHODCALLTYPE d3d10_effect_pool_AsEffect(ID3D10EffectPool *iface)
Definition: effect.c:10069
static ULONG STDMETHODCALLTYPE d3d10_effect_pool_Release(ID3D10EffectPool *iface)
Definition: effect.c:10063

Definition at line 42 of file effect.c.

Referenced by d3d10_create_effect(), and unsafe_impl_from_ID3D10EffectPool().

◆ d3d10_effect_rasterizer_variable_vtbl

static const struct ID3D10EffectRasterizerVariableVtbl d3d10_effect_rasterizer_variable_vtbl
static

Definition at line 67 of file effect.c.

Referenced by d3d10_effect_variable_AsRasterizer(), and set_variable_vtbl().

◆ d3d10_effect_render_target_view_variable_vtbl

static const struct ID3D10EffectRenderTargetViewVariableVtbl d3d10_effect_render_target_view_variable_vtbl
static

Definition at line 62 of file effect.c.

Referenced by d3d10_effect_variable_AsRenderTargetView(), and set_variable_vtbl().

◆ d3d10_effect_sampler_variable_vtbl

static const struct ID3D10EffectSamplerVariableVtbl d3d10_effect_sampler_variable_vtbl
static

Definition at line 68 of file effect.c.

Referenced by d3d10_effect_variable_AsSampler(), and set_variable_vtbl().

◆ d3d10_effect_scalar_variable_vtbl

static const struct ID3D10EffectScalarVariableVtbl d3d10_effect_scalar_variable_vtbl
static

Definition at line 57 of file effect.c.

Referenced by d3d10_effect_variable_AsScalar(), and set_variable_vtbl().

◆ d3d10_effect_shader_resource_variable_vtbl

static const struct ID3D10EffectShaderResourceVariableVtbl d3d10_effect_shader_resource_variable_vtbl
static

Definition at line 61 of file effect.c.

Referenced by d3d10_effect_variable_AsShaderResource(), and set_variable_vtbl().

◆ d3d10_effect_shader_variable_vtbl

static const struct ID3D10EffectShaderVariableVtbl d3d10_effect_shader_variable_vtbl
static

Definition at line 64 of file effect.c.

Referenced by d3d10_effect_variable_AsShader(), and set_variable_vtbl().

◆ d3d10_effect_state_storage_info

Initial value:
=
{
}
static const D3D10_RASTERIZER_DESC default_rasterizer_desc
Definition: effect.c:1075
static const D3D10_DEPTH_STENCIL_DESC default_depth_stencil_desc
Definition: effect.c:1089
static const D3D10_SAMPLER_DESC default_sampler_desc
Definition: effect.c:1114
static const D3D10_BLEND_DESC default_blend_desc
Definition: effect.c:1101

Definition at line 1135 of file effect.c.

◆ d3d10_effect_string_variable_vtbl

static const struct ID3D10EffectStringVariableVtbl d3d10_effect_string_variable_vtbl
static

Definition at line 60 of file effect.c.

Referenced by d3d10_effect_variable_AsString(), and set_variable_vtbl().

◆ d3d10_effect_technique_vtbl

static const struct ID3D10EffectTechniqueVtbl d3d10_effect_technique_vtbl
static
Initial value:
=
{
}
static HRESULT STDMETHODCALLTYPE d3d10_effect_technique_ComputeStateBlockMask(ID3D10EffectTechnique *iface, D3D10_STATE_BLOCK_MASK *mask)
Definition: effect.c:5133
static BOOL STDMETHODCALLTYPE d3d10_effect_technique_IsValid(ID3D10EffectTechnique *iface)
Definition: effect.c:4994
static HRESULT STDMETHODCALLTYPE d3d10_effect_technique_GetDesc(ID3D10EffectTechnique *iface, D3D10_TECHNIQUE_DESC *desc)
Definition: effect.c:5003
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_technique_GetAnnotationByIndex(ID3D10EffectTechnique *iface, UINT index)
Definition: effect.c:5067
static struct ID3D10EffectPass *STDMETHODCALLTYPE d3d10_effect_technique_GetPassByIndex(ID3D10EffectTechnique *iface, UINT index)
Definition: effect.c:5087
static struct ID3D10EffectVariable *STDMETHODCALLTYPE d3d10_effect_technique_GetAnnotationByName(ID3D10EffectTechnique *iface, const char *name)
Definition: effect.c:5077
static struct ID3D10EffectPass *STDMETHODCALLTYPE d3d10_effect_technique_GetPassByName(ID3D10EffectTechnique *iface, const char *name)
Definition: effect.c:5108

Definition at line 53 of file effect.c.

Referenced by parse_fx10_body().

◆ d3d10_effect_type_vtbl

static const struct ID3D10EffectTypeVtbl d3d10_effect_type_vtbl
static
Initial value:
=
{
}
static HRESULT STDMETHODCALLTYPE d3d10_effect_type_GetDesc(ID3D10EffectType *iface, D3D10_EFFECT_TYPE_DESC *desc)
Definition: effect.c:9873
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_type_GetMemberTypeBySemantic(ID3D10EffectType *iface, const char *semantic)
Definition: effect.c:9956
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_type_GetMemberTypeByName(ID3D10EffectType *iface, const char *name)
Definition: effect.c:9926
static struct ID3D10EffectType *STDMETHODCALLTYPE d3d10_effect_type_GetMemberTypeByIndex(ID3D10EffectType *iface, UINT index)
Definition: effect.c:9905
static const char *STDMETHODCALLTYPE d3d10_effect_type_GetMemberSemantic(ID3D10EffectType *iface, UINT index)
Definition: effect.c:10006
static BOOL STDMETHODCALLTYPE d3d10_effect_type_IsValid(ID3D10EffectType *iface)
Definition: effect.c:9864
static const char *STDMETHODCALLTYPE d3d10_effect_type_GetMemberName(ID3D10EffectType *iface, UINT index)
Definition: effect.c:9986

Definition at line 69 of file effect.c.

Referenced by get_fx10_type(), parse_fx10_anonymous_shader(), parse_fx10_buffer(), and parse_fx10_type().

◆ d3d10_effect_variable_vtbl

◆ d3d10_effect_vector_variable_vtbl

static const struct ID3D10EffectVectorVariableVtbl d3d10_effect_vector_variable_vtbl
static

Definition at line 58 of file effect.c.

Referenced by d3d10_effect_variable_AsVector(), and set_variable_vtbl().

◆ d3d10_effect_vtbl

◆ default_blend_desc

const D3D10_BLEND_DESC default_blend_desc
static
Initial value:
=
{
{0xf, 0xf, 0xf, 0xf, 0xf, 0xf, 0xf, 0xf},
}
@ D3D10_BLEND_INV_SRC_ALPHA
Definition: d3d10.idl:266
@ D3D10_BLEND_SRC_ALPHA
Definition: d3d10.idl:265
@ D3D10_BLEND_OP_ADD
Definition: d3d10.idl:281

Definition at line 1101 of file effect.c.

◆ default_depth_stencil_desc

const D3D10_DEPTH_STENCIL_DESC default_depth_stencil_desc
static
Initial value:

Definition at line 1089 of file effect.c.

◆ default_rasterizer_desc

const D3D10_RASTERIZER_DESC default_rasterizer_desc
static
Initial value:
=
{
0,
0.0f,
0.0f,
}
@ D3D10_FILL_SOLID
Definition: d3d10.idl:347
@ D3D10_CULL_BACK
Definition: d3d10.idl:353

Definition at line 1075 of file effect.c.

◆ default_sampler_desc

const D3D10_SAMPLER_DESC default_sampler_desc
static
Initial value:
=
{
0.0f,
16,
{0.0f, 0.0f, 0.0f, 0.0f},
0.0f,
}
@ D3D10_TEXTURE_ADDRESS_WRAP
Definition: d3d10.idl:392
@ D3D10_FILTER_MIN_MAG_MIP_POINT
Definition: d3d10.idl:370
@ D3D10_COMPARISON_NEVER
Definition: d3d10.idl:306
#define FLT_MAX
Definition: float.h:37

Definition at line 1114 of file effect.c.

◆ null_blend_variable

struct d3d10_effect_variable null_blend_variable
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_blend_variable_vtbl},

Definition at line 93 of file effect.c.

Referenced by d3d10_effect_blend_variable_IsValid(), d3d10_effect_variable_AsBlend(), and read_value_list().

◆ null_depth_stencil_variable

struct d3d10_effect_variable null_depth_stencil_variable
static

◆ null_depth_stencil_view_variable

struct d3d10_effect_variable null_depth_stencil_view_variable
static

◆ null_local_buffer

◆ null_matrix_variable

struct d3d10_effect_variable null_matrix_variable
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_matrix_variable_vtbl},

Definition at line 83 of file effect.c.

Referenced by d3d10_effect_matrix_variable_IsValid(), and d3d10_effect_variable_AsMatrix().

◆ null_pass

◆ null_rasterizer_variable

struct d3d10_effect_variable null_rasterizer_variable
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_rasterizer_variable_vtbl},

Definition at line 97 of file effect.c.

Referenced by d3d10_effect_rasterizer_variable_IsValid(), and d3d10_effect_variable_AsRasterizer().

◆ null_render_target_view_variable

struct d3d10_effect_variable null_render_target_view_variable
static

◆ null_sampler_variable

struct d3d10_effect_variable null_sampler_variable
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_sampler_variable_vtbl},

Definition at line 99 of file effect.c.

Referenced by d3d10_effect_sampler_variable_IsValid(), and d3d10_effect_variable_AsSampler().

◆ null_scalar_variable

struct d3d10_effect_variable null_scalar_variable
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_scalar_variable_vtbl},

Definition at line 79 of file effect.c.

Referenced by d3d10_effect_scalar_variable_IsValid(), and d3d10_effect_variable_AsScalar().

◆ null_shader_resource_variable

struct d3d10_effect_variable null_shader_resource_variable
static
Initial value:
=
{
.ID3D10EffectVariable_iface.lpVtbl = (ID3D10EffectVariableVtbl *)&d3d10_effect_shader_resource_variable_vtbl,
.u.resource.srv = null_srvs,
}
static ID3D10ShaderResourceView * null_srvs[D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT]
Definition: effect.c:102

Definition at line 104 of file effect.c.

Referenced by d3d10_effect_shader_resource_variable_IsValid(), d3d10_effect_variable_AsShaderResource(), and read_value_list().

◆ null_shader_variable

◆ null_srvs

◆ null_string_variable

struct d3d10_effect_variable null_string_variable
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_string_variable_vtbl},

Definition at line 85 of file effect.c.

Referenced by d3d10_effect_string_variable_IsValid(), and d3d10_effect_variable_AsString().

◆ null_technique

◆ null_type

◆ null_variable

◆ null_vector_variable

struct d3d10_effect_variable null_vector_variable
static
Initial value:
= {{(const ID3D10EffectVariableVtbl *)&d3d10_effect_vector_variable_vtbl},

Definition at line 81 of file effect.c.

Referenced by d3d10_effect_variable_AsVector(), and d3d10_effect_vector_variable_IsValid().

◆ preshader_ops

const struct preshader_op_info preshader_ops[]
static

Definition at line 761 of file effect.c.

Referenced by d3d10_effect_get_op_info().

◆ property_infos