ReactOS  0.4.15-dev-1033-gd7d716a
d3dx9effect.h File Reference
#include "d3dx9.h"
Include dependency graph for d3dx9effect.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  _D3DXEFFECT_DESC
 
struct  _D3DXPARAMETER_DESC
 
struct  _D3DXTECHNIQUE_DESC
 
struct  _D3DXPASS_DESC
 
struct  _D3DXFUNCTION_DESC
 

Macros

#define D3DXFX_DONOTSAVESTATE   (1 << 0)
 
#define D3DXFX_DONOTSAVESHADERSTATE   (1 << 1)
 
#define D3DXFX_DONOTSAVESAMPLERSTATE   (1 << 2)
 
#define D3DXFX_NOT_CLONEABLE   (1 << 11)
 
#define D3DXFX_LARGEADDRESSAWARE   (1 << 17)
 
#define D3DX_PARAMETER_SHARED   1
 
#define D3DX_PARAMETER_LITERAL   2
 
#define D3DX_PARAMETER_ANNOTATION   4
 
#define INTERFACE   ID3DXEffectPool
 
#define INTERFACE   ID3DXBaseEffect
 
#define INTERFACE   ID3DXEffectStateManager
 
#define INTERFACE   ID3DXEffect
 
#define INTERFACE   ID3DXEffectCompiler
 
#define D3DXCreateEffectFromFileEx   WINELIB_NAME_AW(D3DXCreateEffectFromFileEx)
 
#define D3DXCreateEffectFromFile   WINELIB_NAME_AW(D3DXCreateEffectFromFile)
 
#define D3DXCreateEffectFromResourceEx   WINELIB_NAME_AW(D3DXCreateEffectFromResourceEx)
 
#define D3DXCreateEffectFromResource   WINELIB_NAME_AW(D3DXCreateEffectFromResource)
 
#define D3DXCreateEffectCompilerFromFile   WINELIB_NAME_AW(D3DXCreateEffectCompilerFromFile)
 
#define D3DXCreateEffectCompilerFromResource   WINELIB_NAME_AW(D3DXCreateEffectCompilerFromResource)
 

Typedefs

typedef struct _D3DXEFFECT_DESC D3DXEFFECT_DESC
 
typedef struct _D3DXPARAMETER_DESC D3DXPARAMETER_DESC
 
typedef struct _D3DXTECHNIQUE_DESC D3DXTECHNIQUE_DESC
 
typedef struct _D3DXPASS_DESC D3DXPASS_DESC
 
typedef struct _D3DXFUNCTION_DESC D3DXFUNCTION_DESC
 
typedef struct ID3DXEffectPool * LPD3DXEFFECTPOOL
 
typedef struct ID3DXBaseEffect * LPD3DXBASEEFFECT
 
typedef struct ID3DXEffectStateManager * LPD3DXEFFECTSTATEMANAGER
 
typedef struct ID3DXEffect * LPD3DXEFFECT
 
typedef struct ID3DXEffectCompiler * LPD3DXEFFECTCOMPILER
 

Functions

 DEFINE_GUID (IID_ID3DXEffectPool, 0x9537ab04, 0x3250, 0x412e, 0x82, 0x13, 0xfc, 0xd2, 0xf8, 0x67, 0x79, 0x33)
 
 DECLARE_INTERFACE_ (ID3DXEffectPool, IUnknown)
 
 DEFINE_GUID (IID_ID3DXBaseEffect, 0x17c18ac, 0x103f, 0x4417, 0x8c, 0x51, 0x6b, 0xf6, 0xef, 0x1e, 0x56, 0xbe)
 
 DECLARE_INTERFACE_ (ID3DXBaseEffect, IUnknown)
 
 DEFINE_GUID (IID_ID3DXEffectStateManager, 0x79aab587, 0x6dbc, 0x4fa7, 0x82, 0xde, 0x37, 0xfa, 0x17, 0x81, 0xc5, 0xce)
 
 DECLARE_INTERFACE_ (ID3DXEffectStateManager, IUnknown)
 
 DEFINE_GUID (IID_ID3DXEffect, 0xf6ceb4b3, 0x4e4c, 0x40dd, 0xb8, 0x83, 0x8d, 0x8d, 0xe5, 0xea, 0x0c, 0xd5)
 
 DECLARE_INTERFACE_ (ID3DXEffect, ID3DXBaseEffect)
 
 DEFINE_GUID (IID_ID3DXEffectCompiler, 0x51b8a949, 0x1a31, 0x47e6, 0xbe, 0xa0, 0x4b, 0x30, 0xdb, 0x53, 0xf1, 0xe0)
 
 DECLARE_INTERFACE_ (ID3DXEffectCompiler, ID3DXBaseEffect)
 
HRESULT WINAPI D3DXCreateEffectPool (ID3DXEffectPool **pool)
 
HRESULT WINAPI D3DXCreateEffect (struct IDirect3DDevice9 *device, const void *srcdata, UINT srcdatalen, const D3DXMACRO *defines, struct ID3DXInclude *include, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectEx (struct IDirect3DDevice9 *device, const void *srcdata, UINT srcdatalen, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skip_constants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectCompiler (const char *srcdata, UINT srcdatalen, const D3DXMACRO *defines, ID3DXInclude *include, DWORD flags, ID3DXEffectCompiler **compiler, ID3DXBuffer **parse_errors)
 
HRESULT WINAPI D3DXCreateEffectFromFileExA (struct IDirect3DDevice9 *device, const char *srcfile, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skip_constants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectFromFileExW (struct IDirect3DDevice9 *device, const WCHAR *srcfile, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skip_constants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectFromFileA (struct IDirect3DDevice9 *device, const char *srcfile, const D3DXMACRO *defines, struct ID3DXInclude *include, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectFromFileW (struct IDirect3DDevice9 *device, const WCHAR *srcfile, const D3DXMACRO *defines, struct ID3DXInclude *include, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectFromResourceExA (struct IDirect3DDevice9 *device, HMODULE srcmodule, const char *srcresource, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skip_constants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectFromResourceExW (struct IDirect3DDevice9 *device, HMODULE srcmodule, const WCHAR *srcresource, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skip_constants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectFromResourceA (struct IDirect3DDevice9 *device, HMODULE srcmodule, const char *srcresource, const D3DXMACRO *defines, struct ID3DXInclude *include, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectFromResourceW (struct IDirect3DDevice9 *device, HMODULE srcmodule, const WCHAR *srcresource, const D3DXMACRO *defines, struct ID3DXInclude *include, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
 
HRESULT WINAPI D3DXCreateEffectCompilerFromFileA (const char *srcfile, const D3DXMACRO *defines, ID3DXInclude *include, DWORD flags, ID3DXEffectCompiler **effectcompiler, ID3DXBuffer **parseerrors)
 
HRESULT WINAPI D3DXCreateEffectCompilerFromFileW (const WCHAR *srcfile, const D3DXMACRO *defines, ID3DXInclude *include, DWORD flags, ID3DXEffectCompiler **effectcompiler, ID3DXBuffer **parseerrors)
 
HRESULT WINAPI D3DXCreateEffectCompilerFromResourceA (HMODULE srcmodule, const char *srcresource, const D3DXMACRO *defines, ID3DXInclude *include, DWORD flags, ID3DXEffectCompiler **effectcompiler, ID3DXBuffer **parseerrors)
 
HRESULT WINAPI D3DXCreateEffectCompilerFromResourceW (HMODULE srcmodule, const WCHAR *srcresource, const D3DXMACRO *defines, ID3DXInclude *include, DWORD flags, ID3DXEffectCompiler **effectcompiler, ID3DXBuffer **parseerrors)
 
HRESULT WINAPI D3DXDisassembleEffect (ID3DXEffect *effect, BOOL enable_color_code, ID3DXBuffer **disassembly)
 

Macro Definition Documentation

◆ D3DX_PARAMETER_ANNOTATION

#define D3DX_PARAMETER_ANNOTATION   4

Definition at line 32 of file d3dx9effect.h.

◆ D3DX_PARAMETER_LITERAL

#define D3DX_PARAMETER_LITERAL   2

Definition at line 31 of file d3dx9effect.h.

◆ D3DX_PARAMETER_SHARED

#define D3DX_PARAMETER_SHARED   1

Definition at line 30 of file d3dx9effect.h.

◆ D3DXCreateEffectCompilerFromFile

#define D3DXCreateEffectCompilerFromFile   WINELIB_NAME_AW(D3DXCreateEffectCompilerFromFile)

Definition at line 429 of file d3dx9effect.h.

◆ D3DXCreateEffectCompilerFromResource

#define D3DXCreateEffectCompilerFromResource   WINELIB_NAME_AW(D3DXCreateEffectCompilerFromResource)

Definition at line 437 of file d3dx9effect.h.

◆ D3DXCreateEffectFromFile

#define D3DXCreateEffectFromFile   WINELIB_NAME_AW(D3DXCreateEffectFromFile)

Definition at line 405 of file d3dx9effect.h.

◆ D3DXCreateEffectFromFileEx

#define D3DXCreateEffectFromFileEx   WINELIB_NAME_AW(D3DXCreateEffectFromFileEx)

Definition at line 397 of file d3dx9effect.h.

◆ D3DXCreateEffectFromResource

#define D3DXCreateEffectFromResource   WINELIB_NAME_AW(D3DXCreateEffectFromResource)

Definition at line 423 of file d3dx9effect.h.

◆ D3DXCreateEffectFromResourceEx

#define D3DXCreateEffectFromResourceEx   WINELIB_NAME_AW(D3DXCreateEffectFromResourceEx)

Definition at line 415 of file d3dx9effect.h.

◆ D3DXFX_DONOTSAVESAMPLERSTATE

#define D3DXFX_DONOTSAVESAMPLERSTATE   (1 << 2)

Definition at line 26 of file d3dx9effect.h.

◆ D3DXFX_DONOTSAVESHADERSTATE

#define D3DXFX_DONOTSAVESHADERSTATE   (1 << 1)

Definition at line 25 of file d3dx9effect.h.

◆ D3DXFX_DONOTSAVESTATE

#define D3DXFX_DONOTSAVESTATE   (1 << 0)

Definition at line 24 of file d3dx9effect.h.

◆ D3DXFX_LARGEADDRESSAWARE

#define D3DXFX_LARGEADDRESSAWARE   (1 << 17)

Definition at line 28 of file d3dx9effect.h.

◆ D3DXFX_NOT_CLONEABLE

#define D3DXFX_NOT_CLONEABLE   (1 << 11)

Definition at line 27 of file d3dx9effect.h.

◆ INTERFACE [1/5]

#define INTERFACE   ID3DXEffectPool

Definition at line 306 of file d3dx9effect.h.

◆ INTERFACE [2/5]

#define INTERFACE   ID3DXBaseEffect

Definition at line 306 of file d3dx9effect.h.

◆ INTERFACE [3/5]

#define INTERFACE   ID3DXEffectStateManager

Definition at line 306 of file d3dx9effect.h.

◆ INTERFACE [4/5]

#define INTERFACE   ID3DXEffect

Definition at line 306 of file d3dx9effect.h.

◆ INTERFACE [5/5]

#define INTERFACE   ID3DXEffectCompiler

Definition at line 306 of file d3dx9effect.h.

Typedef Documentation

◆ D3DXEFFECT_DESC

◆ D3DXFUNCTION_DESC

◆ D3DXPARAMETER_DESC

◆ D3DXPASS_DESC

◆ D3DXTECHNIQUE_DESC

◆ LPD3DXBASEEFFECT

typedef struct ID3DXBaseEffect* LPD3DXBASEEFFECT

Definition at line 94 of file d3dx9effect.h.

◆ LPD3DXEFFECT

typedef struct ID3DXEffect* LPD3DXEFFECT

Definition at line 198 of file d3dx9effect.h.

◆ LPD3DXEFFECTCOMPILER

typedef struct ID3DXEffectCompiler* LPD3DXEFFECTCOMPILER

Definition at line 302 of file d3dx9effect.h.

◆ LPD3DXEFFECTPOOL

typedef struct ID3DXEffectPool* LPD3DXEFFECTPOOL

Definition at line 78 of file d3dx9effect.h.

◆ LPD3DXEFFECTSTATEMANAGER

typedef struct ID3DXEffectStateManager* LPD3DXEFFECTSTATEMANAGER

Definition at line 164 of file d3dx9effect.h.

Function Documentation

◆ D3DXCreateEffect()

HRESULT WINAPI D3DXCreateEffect ( struct IDirect3DDevice9 *  device,
const void srcdata,
UINT  srcdatalen,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 6834 of file effect.c.

6837 {
6838  TRACE("(%p, %p, %u, %p, %p, %#x, %p, %p, %p): Forwarded to D3DXCreateEffectEx\n", device, srcdata, srcdatalen, defines,
6839  include, flags, pool, effect, compilation_errors);
6840 
6841  return D3DXCreateEffectEx(device, srcdata, srcdatalen, defines, include, NULL, flags, pool, effect, compilation_errors);
6842 }
HRESULT WINAPI D3DXCreateEffectEx(struct IDirect3DDevice9 *device, const void *srcdata, UINT srcdatalen, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skip_constants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
Definition: effect.c:6789
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
GLbitfield flags
Definition: glext.h:7161
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30

Referenced by test_create_effect_and_pool(), test_cross_effect_handle(), test_effect_clone(), test_effect_commitchanges(), test_effect_compilation_errors(), test_effect_get_pass_desc(), test_effect_isparameterused(), test_effect_large_address_aware_flag(), test_effect_out_of_bounds_selector(), test_effect_parameter_value(), test_effect_preshader(), test_effect_preshader_ops(), test_effect_preshader_relative_addressing(), test_effect_setvalue_object(), test_effect_shared_parameters(), test_effect_state_manager(), test_effect_states(), test_effect_variable_names(), and test_refcount().

◆ D3DXCreateEffectCompiler()

HRESULT WINAPI D3DXCreateEffectCompiler ( const char srcdata,
UINT  srcdatalen,
const D3DXMACRO defines,
ID3DXInclude *  include,
DWORD  flags,
ID3DXEffectCompiler **  compiler,
ID3DXBuffer **  parse_errors 
)

Definition at line 6859 of file effect.c.

6861 {
6863  HRESULT hr;
6864 
6865  TRACE("srcdata %p, srcdatalen %u, defines %p, include %p, flags %#x, compiler %p, parse_errors %p\n",
6866  srcdata, srcdatalen, defines, include, flags, compiler, parse_errors);
6867 
6868  if (!srcdata || !compiler)
6869  {
6870  WARN("Invalid arguments supplied\n");
6871  return D3DERR_INVALIDCALL;
6872  }
6873 
6874  object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*object));
6875  if (!object)
6876  return E_OUTOFMEMORY;
6877 
6878  hr = d3dx9_effect_compiler_init(object, srcdata, srcdatalen, (const D3D_SHADER_MACRO *)defines,
6879  (ID3DInclude *)include, flags, (ID3DBlob **)parse_errors);
6880  if (FAILED(hr))
6881  {
6882  WARN("Failed to initialize effect compiler\n");
6883  HeapFree(GetProcessHeap(), 0, object);
6884  return hr;
6885  }
6886 
6887  *compiler = &object->ID3DXEffectCompiler_iface;
6888 
6889  TRACE("Created ID3DXEffectCompiler %p\n", object);
6890 
6891  return D3D_OK;
6892 }
HRESULT hr
Definition: shlfolder.c:183
#define WARN(fmt,...)
Definition: debug.h:112
#define D3DERR_INVALIDCALL
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
#define TRACE(s)
Definition: solgame.cpp:4
#define GetProcessHeap()
Definition: compat.h:484
PVOID WINAPI HeapAlloc(HANDLE, DWORD, SIZE_T)
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
LONG HRESULT
Definition: typedefs.h:79
GLbitfield flags
Definition: glext.h:7161
#define D3D_OK
Definition: d3d.h:106
#define HEAP_ZERO_MEMORY
Definition: compat.h:134
static HRESULT d3dx9_effect_compiler_init(struct ID3DXEffectCompilerImpl *compiler, const char *data, SIZE_T data_size, const D3D_SHADER_MACRO *defines, ID3DInclude *include, UINT eflags, ID3DBlob **error_messages)
Definition: effect.c:6844
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30
#define HeapFree(x, y, z)
Definition: compat.h:483
void * object
Definition: jmemsys.h:48

Referenced by D3DXCreateEffectCompilerFromFileW(), D3DXCreateEffectCompilerFromResourceA(), D3DXCreateEffectCompilerFromResourceW(), and test_create_effect_compiler().

◆ D3DXCreateEffectCompilerFromFileA()

HRESULT WINAPI D3DXCreateEffectCompilerFromFileA ( const char srcfile,
const D3DXMACRO defines,
ID3DXInclude *  include,
DWORD  flags,
ID3DXEffectCompiler **  effectcompiler,
ID3DXBuffer **  parseerrors 
)

Definition at line 7173 of file effect.c.

7175 {
7176  WCHAR *srcfileW;
7177  HRESULT ret;
7178  DWORD len;
7179 
7180  TRACE("srcfile %s, defines %p, include %p, flags %#x, effectcompiler %p, parseerrors %p.\n",
7181  debugstr_a(srcfile), defines, include, flags, effectcompiler, parseerrors);
7182 
7183  if (!srcfile)
7184  return D3DERR_INVALIDCALL;
7185 
7186  len = MultiByteToWideChar(CP_ACP, 0, srcfile, -1, NULL, 0);
7187  srcfileW = HeapAlloc(GetProcessHeap(), 0, len * sizeof(*srcfileW));
7188  MultiByteToWideChar(CP_ACP, 0, srcfile, -1, srcfileW, len);
7189 
7190  ret = D3DXCreateEffectCompilerFromFileW(srcfileW, defines, include, flags, effectcompiler, parseerrors);
7191  HeapFree(GetProcessHeap(), 0, srcfileW);
7192 
7193  return ret;
7194 }
#define CP_ACP
Definition: compat.h:109
#define D3DERR_INVALIDCALL
smooth NULL
Definition: ftsmooth.c:416
HRESULT WINAPI D3DXCreateEffectCompilerFromFileW(const WCHAR *srcfile, const D3DXMACRO *defines, ID3DXInclude *include, DWORD flags, ID3DXEffectCompiler **effectcompiler, ID3DXBuffer **parseerrors)
Definition: effect.c:7149
#define TRACE(s)
Definition: solgame.cpp:4
#define GetProcessHeap()
Definition: compat.h:484
PVOID WINAPI HeapAlloc(HANDLE, DWORD, SIZE_T)
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
__wchar_t WCHAR
Definition: xmlstorage.h:180
#define debugstr_a
Definition: kernel32.h:31
LONG HRESULT
Definition: typedefs.h:79
unsigned long DWORD
Definition: ntddk_ex.h:95
GLbitfield flags
Definition: glext.h:7161
int ret
GLenum GLsizei len
Definition: glext.h:6722
#define MultiByteToWideChar
Definition: compat.h:110
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30
#define HeapFree(x, y, z)
Definition: compat.h:483

◆ D3DXCreateEffectCompilerFromFileW()

HRESULT WINAPI D3DXCreateEffectCompilerFromFileW ( const WCHAR srcfile,
const D3DXMACRO defines,
ID3DXInclude *  include,
DWORD  flags,
ID3DXEffectCompiler **  effectcompiler,
ID3DXBuffer **  parseerrors 
)

Definition at line 7149 of file effect.c.

7151 {
7152  void *buffer;
7153  HRESULT ret;
7154  DWORD size;
7155 
7156  TRACE("srcfile %s, defines %p, include %p, flags %#x, effectcompiler %p, parseerrors %p.\n",
7157  debugstr_w(srcfile), defines, include, flags, effectcompiler, parseerrors);
7158 
7159  if (!srcfile)
7160  return D3DERR_INVALIDCALL;
7161 
7162  ret = map_view_of_file(srcfile, &buffer, &size);
7163 
7164  if (FAILED(ret))
7165  return D3DXERR_INVALIDDATA;
7166 
7167  ret = D3DXCreateEffectCompiler(buffer, size, defines, include, flags, effectcompiler, parseerrors);
7169 
7170  return ret;
7171 }
#define D3DERR_INVALIDCALL
GLuint buffer
Definition: glext.h:5915
HRESULT WINAPI D3DXCreateEffectCompiler(const char *srcdata, UINT srcdatalen, const D3DXMACRO *defines, ID3DXInclude *include, DWORD flags, ID3DXEffectCompiler **compiler, ID3DXBuffer **parse_errors)
Definition: effect.c:6859
#define debugstr_w
Definition: kernel32.h:32
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
LONG HRESULT
Definition: typedefs.h:79
unsigned long DWORD
Definition: ntddk_ex.h:95
GLbitfield flags
Definition: glext.h:7161
HRESULT map_view_of_file(const WCHAR *filename, void **buffer, DWORD *length) DECLSPEC_HIDDEN
Definition: util.c:118
int ret
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30
#define UnmapViewOfFile
Definition: compat.h:494

Referenced by D3DXCreateEffectCompilerFromFileA().

◆ D3DXCreateEffectCompilerFromResourceA()

HRESULT WINAPI D3DXCreateEffectCompilerFromResourceA ( HMODULE  srcmodule,
const char srcresource,
const D3DXMACRO defines,
ID3DXInclude *  include,
DWORD  flags,
ID3DXEffectCompiler **  effectcompiler,
ID3DXBuffer **  parseerrors 
)

Definition at line 7196 of file effect.c.

7199 {
7200  HRSRC resinfo;
7201  void *buffer;
7202  DWORD size;
7203 
7204  TRACE("srcmodule %p, srcresource %s, defines %p, include %p, flags %#x, effectcompiler %p, parseerrors %p.\n",
7205  srcmodule, debugstr_a(srcresource), defines, include, flags, effectcompiler, parseerrors);
7206 
7207  if (!(resinfo = FindResourceA(srcmodule, srcresource, (const char *)RT_RCDATA)))
7208  return D3DXERR_INVALIDDATA;
7209 
7210  if (FAILED(load_resource_into_memory(srcmodule, resinfo, &buffer, &size)))
7211  return D3DXERR_INVALIDDATA;
7212 
7213  return D3DXCreateEffectCompiler(buffer, size, defines, include, flags, effectcompiler, parseerrors);
7214 }
HRSRC WINAPI FindResourceA(HMODULE hModule, LPCSTR name, LPCSTR type)
Definition: res.c:155
GLuint buffer
Definition: glext.h:5915
HRESULT WINAPI D3DXCreateEffectCompiler(const char *srcdata, UINT srcdatalen, const D3DXMACRO *defines, ID3DXInclude *include, DWORD flags, ID3DXEffectCompiler **compiler, ID3DXBuffer **parse_errors)
Definition: effect.c:6859
HRESULT load_resource_into_memory(HMODULE module, HRSRC resinfo, void **buffer, DWORD *length) DECLSPEC_HIDDEN
Definition: util.c:166
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
#define debugstr_a
Definition: kernel32.h:31
unsigned long DWORD
Definition: ntddk_ex.h:95
GLbitfield flags
Definition: glext.h:7161
#define RT_RCDATA
Definition: pedump.c:372
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30

◆ D3DXCreateEffectCompilerFromResourceW()

HRESULT WINAPI D3DXCreateEffectCompilerFromResourceW ( HMODULE  srcmodule,
const WCHAR srcresource,
const D3DXMACRO defines,
ID3DXInclude *  include,
DWORD  flags,
ID3DXEffectCompiler **  effectcompiler,
ID3DXBuffer **  parseerrors 
)

Definition at line 7216 of file effect.c.

7219 {
7220  HRSRC resinfo;
7221  void *buffer;
7222  DWORD size;
7223 
7224  TRACE("srcmodule %p, srcresource %s, defines %p, include %p, flags %#x, effectcompiler %p, parseerrors %p.\n",
7225  srcmodule, debugstr_w(srcresource), defines, include, flags, effectcompiler, parseerrors);
7226 
7227  if (!(resinfo = FindResourceW(srcmodule, srcresource, (const WCHAR *)RT_RCDATA)))
7228  return D3DXERR_INVALIDDATA;
7229 
7230  if (FAILED(load_resource_into_memory(srcmodule, resinfo, &buffer, &size)))
7231  return D3DXERR_INVALIDDATA;
7232 
7233  return D3DXCreateEffectCompiler(buffer, size, defines, include, flags, effectcompiler, parseerrors);
7234 }
GLuint buffer
Definition: glext.h:5915
HRSRC WINAPI FindResourceW(HINSTANCE hModule, LPCWSTR name, LPCWSTR type)
Definition: res.c:176
HRESULT WINAPI D3DXCreateEffectCompiler(const char *srcdata, UINT srcdatalen, const D3DXMACRO *defines, ID3DXInclude *include, DWORD flags, ID3DXEffectCompiler **compiler, ID3DXBuffer **parse_errors)
Definition: effect.c:6859
#define debugstr_w
Definition: kernel32.h:32
HRESULT load_resource_into_memory(HMODULE module, HRSRC resinfo, void **buffer, DWORD *length) DECLSPEC_HIDDEN
Definition: util.c:166
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
__wchar_t WCHAR
Definition: xmlstorage.h:180
unsigned long DWORD
Definition: ntddk_ex.h:95
GLbitfield flags
Definition: glext.h:7161
#define RT_RCDATA
Definition: pedump.c:372
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30

◆ D3DXCreateEffectEx()

HRESULT WINAPI D3DXCreateEffectEx ( struct IDirect3DDevice9 *  device,
const void srcdata,
UINT  srcdatalen,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
const char skip_constants,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 6789 of file effect.c.

6792 {
6793  struct ID3DXEffectImpl *object;
6794  HRESULT hr;
6795 
6796  TRACE("device %p, srcdata %p, srcdatalen %u, defines %p, include %p,"
6797  " skip_constants %p, flags %#x, pool %p, effect %p, compilation_errors %p.\n",
6798  device, srcdata, srcdatalen, defines, include,
6799  skip_constants, flags, pool, effect, compilation_errors);
6800 
6801  if (compilation_errors)
6802  *compilation_errors = NULL;
6803 
6804  if (!device || !srcdata)
6805  return D3DERR_INVALIDCALL;
6806 
6807  if (!srcdatalen)
6808  return E_FAIL;
6809 
6810  /* Native dll allows effect to be null so just return D3D_OK after doing basic checks */
6811  if (!effect)
6812  return D3D_OK;
6813 
6814  object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*object));
6815  if (!object)
6816  return E_OUTOFMEMORY;
6817 
6818  hr = d3dx9_effect_init(object, device, srcdata, srcdatalen, (const D3D_SHADER_MACRO *)defines,
6819  (ID3DInclude *)include, flags, (ID3DBlob **)compilation_errors, pool, skip_constants);
6820  if (FAILED(hr))
6821  {
6822  WARN("Failed to create effect object.\n");
6823  HeapFree(GetProcessHeap(), 0, object);
6824  return hr;
6825  }
6826 
6827  *effect = &object->ID3DXEffect_iface;
6828 
6829  TRACE("Created ID3DXEffect %p\n", object);
6830 
6831  return D3D_OK;
6832 }
HRESULT hr
Definition: shlfolder.c:183
#define WARN(fmt,...)
Definition: debug.h:112
#define D3DERR_INVALIDCALL
#define E_FAIL
Definition: ddrawi.h:102
static HRESULT d3dx9_effect_init(struct ID3DXEffectImpl *effect, struct IDirect3DDevice9 *device, const char *data, SIZE_T data_size, const D3D_SHADER_MACRO *defines, ID3DInclude *include, UINT eflags, ID3DBlob **error_messages, struct ID3DXEffectPool *pool, const char *skip_constants)
Definition: effect.c:6749
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
#define GetProcessHeap()
Definition: compat.h:484
PVOID WINAPI HeapAlloc(HANDLE, DWORD, SIZE_T)
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
LONG HRESULT
Definition: typedefs.h:79
GLbitfield flags
Definition: glext.h:7161
#define D3D_OK
Definition: d3d.h:106
#define HEAP_ZERO_MEMORY
Definition: compat.h:134
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30
#define HeapFree(x, y, z)
Definition: compat.h:483
void * object
Definition: jmemsys.h:48

Referenced by D3DXCreateEffect(), D3DXCreateEffectFromFileExW(), D3DXCreateEffectFromResourceExA(), D3DXCreateEffectFromResourceExW(), test_effect_find_next_valid_technique(), test_effect_null_shader(), test_effect_skip_constants(), and test_effect_unsupported_shader().

◆ D3DXCreateEffectFromFileA()

HRESULT WINAPI D3DXCreateEffectFromFileA ( struct IDirect3DDevice9 *  device,
const char srcfile,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 7073 of file effect.c.

7076 {
7077  TRACE("(void): relay\n");
7078  return D3DXCreateEffectFromFileExA(device, srcfile, defines, include, NULL, flags, pool, effect, compilationerrors);
7079 }
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
GLbitfield flags
Definition: glext.h:7161
HRESULT WINAPI D3DXCreateEffectFromFileExA(struct IDirect3DDevice9 *device, const char *srcfile, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skipconstants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilationerrors)
Definition: effect.c:7039
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30

◆ D3DXCreateEffectFromFileExA()

HRESULT WINAPI D3DXCreateEffectFromFileExA ( struct IDirect3DDevice9 *  device,
const char srcfile,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
const char skip_constants,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 7039 of file effect.c.

7042 {
7043  WCHAR *srcfileW;
7044  HRESULT ret;
7045  DWORD len;
7046 
7047  TRACE("device %p, srcfile %s, defines %p, include %p, skipconstants %s, "
7048  "flags %#x, pool %p, effect %p, compilationerrors %p.\n",
7049  device, debugstr_a(srcfile), defines, include, debugstr_a(skipconstants),
7050  flags, pool, effect, compilationerrors);
7051 
7052  if (!srcfile)
7053  return D3DERR_INVALIDCALL;
7054 
7055  len = MultiByteToWideChar(CP_ACP, 0, srcfile, -1, NULL, 0);
7056  srcfileW = HeapAlloc(GetProcessHeap(), 0, len * sizeof(*srcfileW));
7057  MultiByteToWideChar(CP_ACP, 0, srcfile, -1, srcfileW, len);
7058 
7059  ret = D3DXCreateEffectFromFileExW(device, srcfileW, defines, include, skipconstants, flags, pool, effect, compilationerrors);
7060  HeapFree(GetProcessHeap(), 0, srcfileW);
7061 
7062  return ret;
7063 }
#define CP_ACP
Definition: compat.h:109
#define D3DERR_INVALIDCALL
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
#define GetProcessHeap()
Definition: compat.h:484
PVOID WINAPI HeapAlloc(HANDLE, DWORD, SIZE_T)
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
__wchar_t WCHAR
Definition: xmlstorage.h:180
#define debugstr_a
Definition: kernel32.h:31
LONG HRESULT
Definition: typedefs.h:79
HRESULT WINAPI D3DXCreateEffectFromFileExW(struct IDirect3DDevice9 *device, const WCHAR *srcfile, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skipconstants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilationerrors)
Definition: effect.c:6991
unsigned long DWORD
Definition: ntddk_ex.h:95
GLbitfield flags
Definition: glext.h:7161
int ret
GLenum GLsizei len
Definition: glext.h:6722
#define MultiByteToWideChar
Definition: compat.h:110
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30
#define HeapFree(x, y, z)
Definition: compat.h:483

Referenced by D3DXCreateEffectFromFileA().

◆ D3DXCreateEffectFromFileExW()

HRESULT WINAPI D3DXCreateEffectFromFileExW ( struct IDirect3DDevice9 *  device,
const WCHAR srcfile,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
const char skip_constants,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 6991 of file effect.c.

6994 {
6995  struct d3dx_include_from_file include_from_file;
6996  const void *buffer;
6997  unsigned int size;
6998  char *filename_a;
6999  HRESULT ret;
7000 
7001  TRACE("device %p, srcfile %s, defines %p, include %p, skipconstants %s, "
7002  "flags %#x, pool %p, effect %p, compilationerrors %p.\n",
7003  device, debugstr_w(srcfile), defines, include, debugstr_a(skipconstants),
7004  flags, pool, effect, compilationerrors);
7005 
7006  if (!device || !srcfile)
7007  return D3DERR_INVALIDCALL;
7008 
7009  if (!include)
7010  {
7011  include_from_file.ID3DXInclude_iface.lpVtbl = &d3dx_include_from_file_vtbl;
7012  include = &include_from_file.ID3DXInclude_iface;
7013  }
7014 
7015  size = WideCharToMultiByte(CP_ACP, 0, srcfile, -1, NULL, 0, NULL, NULL);
7016  filename_a = heap_alloc(size);
7017  if (!filename_a)
7018  return E_OUTOFMEMORY;
7019  WideCharToMultiByte(CP_ACP, 0, srcfile, -1, filename_a, size, NULL, NULL);
7020 
7022  ret = ID3DXInclude_Open(include, D3DXINC_LOCAL, filename_a, NULL, &buffer, &size);
7023  if (FAILED(ret))
7024  {
7026  heap_free(filename_a);
7027  return D3DXERR_INVALIDDATA;
7028  }
7029 
7030  ret = D3DXCreateEffectEx(device, buffer, size, defines, include, skipconstants, flags, pool,
7031  effect, compilationerrors);
7032 
7035  heap_free(filename_a);
7036  return ret;
7037 }
#define ID3DXInclude_Open(p, a, b, c, d, e)
Definition: d3dx9shader.h:303
const struct ID3DXIncludeVtbl d3dx_include_from_file_vtbl
Definition: shader.c:314
#define WideCharToMultiByte
Definition: compat.h:111
CRITICAL_SECTION from_file_mutex
Definition: shader.c:228
#define CP_ACP
Definition: compat.h:109
#define D3DERR_INVALIDCALL
GLuint buffer
Definition: glext.h:5915
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
HRESULT WINAPI D3DXCreateEffectEx(struct IDirect3DDevice9 *device, const void *srcdata, UINT srcdatalen, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skip_constants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
Definition: effect.c:6789
static void * heap_alloc(size_t len)
Definition: appwiz.h:65
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
Definition: devices.h:37
#define debugstr_w
Definition: kernel32.h:32
smooth NULL
Definition: ftsmooth.c:416
#define ID3DXInclude_Close(p, a)
Definition: d3dx9shader.h:304
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
#define debugstr_a
Definition: kernel32.h:31
LONG HRESULT
Definition: typedefs.h:79
GLbitfield flags
Definition: glext.h:7161
int ret
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)
static BOOL heap_free(void *mem)
Definition: appwiz.h:75

Referenced by D3DXCreateEffectFromFileExA(), D3DXCreateEffectFromFileW(), and test_create_effect_from_file().

◆ D3DXCreateEffectFromFileW()

HRESULT WINAPI D3DXCreateEffectFromFileW ( struct IDirect3DDevice9 *  device,
const WCHAR srcfile,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 7065 of file effect.c.

7068 {
7069  TRACE("(void): relay\n");
7070  return D3DXCreateEffectFromFileExW(device, srcfile, defines, include, NULL, flags, pool, effect, compilationerrors);
7071 }
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
HRESULT WINAPI D3DXCreateEffectFromFileExW(struct IDirect3DDevice9 *device, const WCHAR *srcfile, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skipconstants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilationerrors)
Definition: effect.c:6991
GLbitfield flags
Definition: glext.h:7161
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30

◆ D3DXCreateEffectFromResourceA()

HRESULT WINAPI D3DXCreateEffectFromResourceA ( struct IDirect3DDevice9 *  device,
HMODULE  srcmodule,
const char srcresource,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 7141 of file effect.c.

7144 {
7145  TRACE("(void): relay\n");
7146  return D3DXCreateEffectFromResourceExA(device, srcmodule, srcresource, defines, include, NULL, flags, pool, effect, compilationerrors);
7147 }
Definition: devices.h:37
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
GLbitfield flags
Definition: glext.h:7161
HRESULT WINAPI D3DXCreateEffectFromResourceExA(struct IDirect3DDevice9 *device, HMODULE srcmodule, const char *srcresource, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skipconstants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilationerrors)
Definition: effect.c:7107
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30

◆ D3DXCreateEffectFromResourceExA()

HRESULT WINAPI D3DXCreateEffectFromResourceExA ( struct IDirect3DDevice9 *  device,
HMODULE  srcmodule,
const char srcresource,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
const char skip_constants,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 7107 of file effect.c.

7110 {
7111  HRSRC resinfo;
7112  void *buffer;
7113  DWORD size;
7114 
7115  TRACE("device %p, srcmodule %p, srcresource %s, defines %p, include %p, skipconstants %s, "
7116  "flags %#x, pool %p, effect %p, compilationerrors %p.\n",
7117  device, srcmodule, debugstr_a(srcresource), defines, include, debugstr_a(skipconstants),
7118  flags, pool, effect, compilationerrors);
7119 
7120  if (!device)
7121  return D3DERR_INVALIDCALL;
7122 
7123  if (!(resinfo = FindResourceA(srcmodule, srcresource, (const char *)RT_RCDATA)))
7124  return D3DXERR_INVALIDDATA;
7125 
7126  if (FAILED(load_resource_into_memory(srcmodule, resinfo, &buffer, &size)))
7127  return D3DXERR_INVALIDDATA;
7128 
7130  skipconstants, flags, pool, effect, compilationerrors);
7131 }
HRSRC WINAPI FindResourceA(HMODULE hModule, LPCSTR name, LPCSTR type)
Definition: res.c:155
#define D3DERR_INVALIDCALL
GLuint buffer
Definition: glext.h:5915
HRESULT WINAPI D3DXCreateEffectEx(struct IDirect3DDevice9 *device, const void *srcdata, UINT srcdatalen, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skip_constants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
Definition: effect.c:6789
Definition: devices.h:37
HRESULT load_resource_into_memory(HMODULE module, HRSRC resinfo, void **buffer, DWORD *length) DECLSPEC_HIDDEN
Definition: util.c:166
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
#define debugstr_a
Definition: kernel32.h:31
unsigned long DWORD
Definition: ntddk_ex.h:95
GLbitfield flags
Definition: glext.h:7161
#define RT_RCDATA
Definition: pedump.c:372
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30

Referenced by D3DXCreateEffectFromResourceA().

◆ D3DXCreateEffectFromResourceExW()

HRESULT WINAPI D3DXCreateEffectFromResourceExW ( struct IDirect3DDevice9 *  device,
HMODULE  srcmodule,
const WCHAR srcresource,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
const char skip_constants,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 7081 of file effect.c.

7084 {
7085  HRSRC resinfo;
7086  void *buffer;
7087  DWORD size;
7088 
7089  TRACE("device %p, srcmodule %p, srcresource %s, defines %p, include %p, skipconstants %s, "
7090  "flags %#x, pool %p, effect %p, compilationerrors %p.\n",
7091  device, srcmodule, debugstr_w(srcresource), defines, include, debugstr_a(skipconstants),
7092  flags, pool, effect, compilationerrors);
7093 
7094  if (!device)
7095  return D3DERR_INVALIDCALL;
7096 
7097  if (!(resinfo = FindResourceW(srcmodule, srcresource, (const WCHAR *)RT_RCDATA)))
7098  return D3DXERR_INVALIDDATA;
7099 
7100  if (FAILED(load_resource_into_memory(srcmodule, resinfo, &buffer, &size)))
7101  return D3DXERR_INVALIDDATA;
7102 
7104  skipconstants, flags, pool, effect, compilationerrors);
7105 }
#define D3DERR_INVALIDCALL
GLuint buffer
Definition: glext.h:5915
HRESULT WINAPI D3DXCreateEffectEx(struct IDirect3DDevice9 *device, const void *srcdata, UINT srcdatalen, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skip_constants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilation_errors)
Definition: effect.c:6789
HRSRC WINAPI FindResourceW(HINSTANCE hModule, LPCWSTR name, LPCWSTR type)
Definition: res.c:176
Definition: devices.h:37
#define debugstr_w
Definition: kernel32.h:32
HRESULT load_resource_into_memory(HMODULE module, HRSRC resinfo, void **buffer, DWORD *length) DECLSPEC_HIDDEN
Definition: util.c:166
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
__wchar_t WCHAR
Definition: xmlstorage.h:180
#define debugstr_a
Definition: kernel32.h:31
unsigned long DWORD
Definition: ntddk_ex.h:95
GLbitfield flags
Definition: glext.h:7161
#define RT_RCDATA
Definition: pedump.c:372
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30

Referenced by D3DXCreateEffectFromResourceW().

◆ D3DXCreateEffectFromResourceW()

HRESULT WINAPI D3DXCreateEffectFromResourceW ( struct IDirect3DDevice9 *  device,
HMODULE  srcmodule,
const WCHAR srcresource,
const D3DXMACRO defines,
struct ID3DXInclude *  include,
DWORD  flags,
struct ID3DXEffectPool *  pool,
struct ID3DXEffect **  effect,
struct ID3DXBuffer **  compilation_errors 
)

Definition at line 7133 of file effect.c.

7136 {
7137  TRACE("(void): relay\n");
7138  return D3DXCreateEffectFromResourceExW(device, srcmodule, srcresource, defines, include, NULL, flags, pool, effect, compilationerrors);
7139 }
Definition: devices.h:37
HRESULT WINAPI D3DXCreateEffectFromResourceExW(struct IDirect3DDevice9 *device, HMODULE srcmodule, const WCHAR *srcresource, const D3DXMACRO *defines, struct ID3DXInclude *include, const char *skipconstants, DWORD flags, struct ID3DXEffectPool *pool, struct ID3DXEffect **effect, struct ID3DXBuffer **compilationerrors)
Definition: effect.c:7081
smooth NULL
Definition: ftsmooth.c:416
#define TRACE(s)
Definition: solgame.cpp:4
static SIZE_T const char const D3D_SHADER_MACRO ID3DInclude * include
Definition: asm.c:30
GLbitfield flags
Definition: glext.h:7161
static SIZE_T const char const D3D_SHADER_MACRO * defines
Definition: asm.c:30

◆ D3DXCreateEffectPool()

HRESULT WINAPI D3DXCreateEffectPool ( ID3DXEffectPool **  pool)

Definition at line 6970 of file effect.c.

6971 {
6972  struct d3dx_effect_pool *object;
6973 
6974  TRACE("pool %p.\n", pool);
6975 
6976  if (!pool)
6977  return D3DERR_INVALIDCALL;
6978 
6979  object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*object));
6980  if (!object)
6981  return E_OUTOFMEMORY;
6982 
6983  object->ID3DXEffectPool_iface.lpVtbl = &ID3DXEffectPool_Vtbl;
6984  object->refcount = 1;
6985 
6986  *pool = &object->ID3DXEffectPool_iface;
6987 
6988  return S_OK;
6989 }
#define D3DERR_INVALIDCALL
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
static const struct ID3DXEffectPoolVtbl ID3DXEffectPool_Vtbl
Definition: effect.c:6962
#define TRACE(s)
Definition: solgame.cpp:4
#define GetProcessHeap()
Definition: compat.h:484
PVOID WINAPI HeapAlloc(HANDLE, DWORD, SIZE_T)
#define S_OK
Definition: intsafe.h:51
#define HEAP_ZERO_MEMORY
Definition: compat.h:134
void * object
Definition: jmemsys.h:48

Referenced by test_create_effect_and_pool(), and test_effect_shared_parameters().

◆ D3DXDisassembleEffect()

HRESULT WINAPI D3DXDisassembleEffect ( ID3DXEffect *  effect,
BOOL  enable_color_code,
ID3DXBuffer **  disassembly 
)

Definition at line 7236 of file effect.c.

7237 {
7238  FIXME("(%p, %u, %p): stub\n", effect, enable_color_code, disassembly);
7239 
7240  return D3DXERR_INVALIDDATA;
7241 }
#define FIXME(fmt,...)
Definition: debug.h:111

◆ DECLARE_INTERFACE_() [1/5]

DECLARE_INTERFACE_ ( ID3DXEffectPool  ,
IUnknown   
)

Definition at line 85 of file d3dx9effect.h.

86 {
87  /*** IUnknown methods ***/
91 };
#define REFIID
Definition: guiddef.h:118
#define THIS_
Definition: basetyps.h:65
_In_ BOOLEAN Release
Definition: classpnp.h:1122
#define THIS
Definition: basetyps.h:66
REFIID riid
Definition: precomp.h:44
static HRESULT QueryInterface(REFIID, void **)
Definition: events.c:2587
#define STDMETHOD(m)
Definition: basetyps.h:62
static FILE * out
Definition: regtests2xml.c:44
#define PURE
Definition: basetyps.h:64
static ULONG WINAPI AddRef(IStream *iface)
Definition: clist.c:90
unsigned int ULONG
Definition: retypes.h:1
#define STDMETHOD_(t, m)
Definition: basetyps.h:63

◆ DECLARE_INTERFACE_() [2/5]

DECLARE_INTERFACE_ ( ID3DXBaseEffect  ,
IUnknown   
)

Definition at line 100 of file d3dx9effect.h.

101 {
102  /*** IUnknown methods ***/
106  /*** ID3DXBaseEffect methods ***/
108  STDMETHOD(GetParameterDesc)(THIS_ D3DXHANDLE parameter, D3DXPARAMETER_DESC* desc) PURE;
109  STDMETHOD(GetTechniqueDesc)(THIS_ D3DXHANDLE technique, D3DXTECHNIQUE_DESC* desc) PURE;
113  STDMETHOD_(D3DXHANDLE, GetParameterByName)(THIS_ D3DXHANDLE parameter, const char *name) PURE;
114  STDMETHOD_(D3DXHANDLE, GetParameterBySemantic)(THIS_ D3DXHANDLE parameter, const char *semantic) PURE;
115  STDMETHOD_(D3DXHANDLE, GetParameterElement)(THIS_ D3DXHANDLE parameter, UINT index) PURE;
116  STDMETHOD_(D3DXHANDLE, GetTechnique)(THIS_ UINT index) PURE;
117  STDMETHOD_(D3DXHANDLE, GetTechniqueByName)(THIS_ const char *name) PURE;
119  STDMETHOD_(D3DXHANDLE, GetPassByName)(THIS_ D3DXHANDLE technique, const char *name) PURE;
120  STDMETHOD_(D3DXHANDLE, GetFunction)(THIS_ UINT index);
121  STDMETHOD_(D3DXHANDLE, GetFunctionByName)(THIS_ const char *name);
123  STDMETHOD_(D3DXHANDLE, GetAnnotationByName)(THIS_ D3DXHANDLE object, const char *name) PURE;
124  STDMETHOD(SetValue)(THIS_ D3DXHANDLE parameter, const void *data, UINT bytes) PURE;
125  STDMETHOD(GetValue)(THIS_ D3DXHANDLE parameter, void *data, UINT bytes) PURE;
126  STDMETHOD(SetBool)(THIS_ D3DXHANDLE parameter, BOOL b) PURE;
127  STDMETHOD(GetBool)(THIS_ D3DXHANDLE parameter, BOOL* b) PURE;
128  STDMETHOD(SetBoolArray)(THIS_ D3DXHANDLE parameter, const BOOL *b, UINT count) PURE;
129  STDMETHOD(GetBoolArray)(THIS_ D3DXHANDLE parameter, BOOL* b, UINT count) PURE;
130  STDMETHOD(SetInt)(THIS_ D3DXHANDLE parameter, INT n) PURE;
131  STDMETHOD(GetInt)(THIS_ D3DXHANDLE parameter, INT* n) PURE;
132  STDMETHOD(SetIntArray)(THIS_ D3DXHANDLE parameter, const INT *n, UINT count) PURE;
133  STDMETHOD(GetIntArray)(THIS_ D3DXHANDLE parameter, INT* n, UINT count) PURE;
135  STDMETHOD(GetFloat)(THIS_ D3DXHANDLE parameter, FLOAT* f) PURE;
137  STDMETHOD(GetFloatArray)(THIS_ D3DXHANDLE parameter, FLOAT* f, UINT count) PURE;
139  STDMETHOD(GetVector)(THIS_ D3DXHANDLE parameter, D3DXVECTOR4* vector) PURE;
141  STDMETHOD(GetVectorArray)(THIS_ D3DXHANDLE parameter, D3DXVECTOR4* vector, UINT count) PURE;
145  STDMETHOD(GetMatrixArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX* matrix, UINT count) PURE;
147  STDMETHOD(GetMatrixPointerArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX** matrix, UINT count) PURE;
149  STDMETHOD(GetMatrixTranspose)(THIS_ D3DXHANDLE parameter, D3DXMATRIX* matrix) PURE;
151  STDMETHOD(GetMatrixTransposeArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX* matrix, UINT count) PURE;
153  STDMETHOD(GetMatrixTransposePointerArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX** matrix, UINT count) PURE;
154  STDMETHOD(SetString)(THIS_ D3DXHANDLE parameter, const char *string) PURE;
155  STDMETHOD(GetString)(THIS_ D3DXHANDLE parameter, const char **string) PURE;
156  STDMETHOD(SetTexture)(THIS_ D3DXHANDLE parameter, struct IDirect3DBaseTexture9 *texture) PURE;
157  STDMETHOD(GetTexture)(THIS_ D3DXHANDLE parameter, struct IDirect3DBaseTexture9 **texture) PURE;
158  STDMETHOD(GetPixelShader)(THIS_ D3DXHANDLE parameter, struct IDirect3DPixelShader9 **shader) PURE;
159  STDMETHOD(GetVertexShader)(THIS_ D3DXHANDLE parameter, struct IDirect3DVertexShader9 **shader) PURE;
160  STDMETHOD(SetArrayRange)(THIS_ D3DXHANDLE parameter, UINT start, UINT end) PURE;
161 };
#define REFIID
Definition: guiddef.h:118
#define THIS_
Definition: basetyps.h:65
static TCHAR * GetParameter(TCHAR **pPointer)
Definition: start.c:20
_In_ BOOLEAN Release
Definition: classpnp.h:1122
const char * D3DXHANDLE
Definition: d3dx9shader.h:48
#define THIS
Definition: basetyps.h:66
REFIID riid
Definition: precomp.h:44
GLuint GLenum matrix
Definition: glext.h:9407
GLuint GLuint GLsizei count
Definition: gl.h:1545
static HRESULT QueryInterface(REFIID, void **)
Definition: events.c:2587
GLdouble n
Definition: glext.h:7729
GLuint GLuint end
Definition: gl.h:1545
int32_t INT
Definition: typedefs.h:58
#define STDMETHOD(m)
Definition: basetyps.h:62
pass
Definition: typegen.h:24
static unsigned char bytes[4]
Definition: adnsresfilter.c:74
unsigned int BOOL
Definition: ntddk_ex.h:94
static const WCHAR desc[]
Definition: protectdata.c:36
#define b
Definition: ke_i.h:79
GLuint shader
Definition: glext.h:6030
GLenum GLuint texture
Definition: glext.h:6295
static FILE * out
Definition: regtests2xml.c:44
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
#define index(s, c)
Definition: various.h:29
char string[160]
Definition: util.h:11
char * GetPass(const char *const prompt)
Definition: util.c:186
GLuint start
Definition: gl.h:1545
#define f
Definition: ke_i.h:83
#define PURE
Definition: basetyps.h:64
unsigned int UINT
Definition: ndis.h:50
static ULONG WINAPI AddRef(IStream *iface)
Definition: clist.c:90
float FLOAT
Definition: typedefs.h:69
unsigned int ULONG
Definition: retypes.h:1
#define STDMETHOD_(t, m)
Definition: basetyps.h:63
MATRIX * GetMatrix(HWND hwnd)
Definition: matrix.c:289
void * object
Definition: jmemsys.h:48
GLuint const GLchar * name
Definition: glext.h:6031

◆ DECLARE_INTERFACE_() [3/5]

DECLARE_INTERFACE_ ( ID3DXEffectStateManager  ,
IUnknown   
)

Definition at line 170 of file d3dx9effect.h.

171 {
172  /*** IUnknown methods ***/
176  /*** ID3DXEffectStateManager methods ***/
178  STDMETHOD(SetMaterial)(THIS_ const D3DMATERIAL9 *material) PURE;
179  STDMETHOD(SetLight)(THIS_ DWORD index, const D3DLIGHT9 *light) PURE;
180  STDMETHOD(LightEnable)(THIS_ DWORD index, BOOL enable) PURE;
182  STDMETHOD(SetTexture)(THIS_ DWORD stage, struct IDirect3DBaseTexture9 *texture) PURE;
183  STDMETHOD(SetTextureStageState)(THIS_ DWORD stage, D3DTEXTURESTAGESTATETYPE type, DWORD value) PURE;
185  STDMETHOD(SetNPatchMode)(THIS_ FLOAT num_segments) PURE;
186  STDMETHOD(SetFVF)(THIS_ DWORD format) PURE;
187  STDMETHOD(SetVertexShader)(THIS_ struct IDirect3DVertexShader9 *shader) PURE;
188  STDMETHOD(SetVertexShaderConstantF)(THIS_ UINT register_index, const FLOAT *constant_data, UINT register_count) PURE;
189  STDMETHOD(SetVertexShaderConstantI)(THIS_ UINT register_index, const INT *constant_data, UINT register_count) PURE;
190  STDMETHOD(SetVertexShaderConstantB)(THIS_ UINT register_index, const BOOL *constant_data, UINT register_count) PURE;
191  STDMETHOD(SetPixelShader)(THIS_ struct IDirect3DPixelShader9 *shader) PURE;
192  STDMETHOD(SetPixelShaderConstantF)(THIS_ UINT register_index, const FLOAT *constant_data, UINT register_count) PURE;
193  STDMETHOD(SetPixelShaderConstantI)(THIS_ UINT register_index, const INT *constant_data, UINT register_count) PURE;
194  STDMETHOD(SetPixelShaderConstantB)(THIS_ UINT register_index, const BOOL *constant_data, UINT register_count) PURE;
195 };
#define REFIID
Definition: guiddef.h:118
#define THIS_
Definition: basetyps.h:65
_In_ BOOLEAN Release
Definition: classpnp.h:1122
#define THIS
Definition: basetyps.h:66
REFIID riid
Definition: precomp.h:44
GLuint GLenum matrix
Definition: glext.h:9407
static HRESULT QueryInterface(REFIID, void **)
Definition: events.c:2587
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
int32_t INT
Definition: typedefs.h:58
GLint GLint GLsizei GLsizei GLsizei GLint GLenum format
Definition: gl.h:1546
#define STDMETHOD(m)
Definition: basetyps.h:62
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 light
Definition: glfuncs.h:170
unsigned int BOOL
Definition: ntddk_ex.h:94
GLuint shader
Definition: glext.h:6030
GLenum GLuint texture
Definition: glext.h:6295
D3DRENDERSTATETYPE
Definition: d3dtypes.h:874
static FILE * out
Definition: regtests2xml.c:44
unsigned long DWORD
Definition: ntddk_ex.h:95
#define index(s, c)
Definition: various.h:29
enum _D3DSAMPLERSTATETYPE D3DSAMPLERSTATETYPE
static int state
Definition: maze.c:121
GLsizei const GLfloat * value
Definition: glext.h:6069
GLboolean enable
Definition: glext.h:11120
#define PURE
Definition: basetyps.h:64
unsigned int UINT
Definition: ndis.h:50
static ULONG WINAPI AddRef(IStream *iface)
Definition: clist.c:90
float FLOAT
Definition: typedefs.h:69
enum _D3DTEXTURESTAGESTATETYPE D3DTEXTURESTAGESTATETYPE
unsigned int ULONG
Definition: retypes.h:1
enum _D3DTRANSFORMSTATETYPE D3DTRANSFORMSTATETYPE
#define STDMETHOD_(t, m)
Definition: basetyps.h:63
GLuint sampler
Definition: glext.h:7283

◆ DECLARE_INTERFACE_() [4/5]

DECLARE_INTERFACE_ ( ID3DXEffect  ,
ID3DXBaseEffect   
)

Definition at line 210 of file d3dx9effect.h.

211 {
212  /*** IUnknown methods ***/
216  /*** ID3DXBaseEffect methods ***/
218  STDMETHOD(GetParameterDesc)(THIS_ D3DXHANDLE parameter, D3DXPARAMETER_DESC* desc) PURE;
219  STDMETHOD(GetTechniqueDesc)(THIS_ D3DXHANDLE technique, D3DXTECHNIQUE_DESC* desc) PURE;
223  STDMETHOD_(D3DXHANDLE, GetParameterByName)(THIS_ D3DXHANDLE parameter, const char *name) PURE;
224  STDMETHOD_(D3DXHANDLE, GetParameterBySemantic)(THIS_ D3DXHANDLE parameter, const char *semantic) PURE;
225  STDMETHOD_(D3DXHANDLE, GetParameterElement)(THIS_ D3DXHANDLE parameter, UINT index) PURE;
226  STDMETHOD_(D3DXHANDLE, GetTechnique)(THIS_ UINT index) PURE;
227  STDMETHOD_(D3DXHANDLE, GetTechniqueByName)(THIS_ const char *name) PURE;
229  STDMETHOD_(D3DXHANDLE, GetPassByName)(THIS_ D3DXHANDLE technique, const char *name) PURE;
230  STDMETHOD_(D3DXHANDLE, GetFunction)(THIS_ UINT index);
231  STDMETHOD_(D3DXHANDLE, GetFunctionByName)(THIS_ const char *name);
233  STDMETHOD_(D3DXHANDLE, GetAnnotationByName)(THIS_ D3DXHANDLE object, const char *name) PURE;
234  STDMETHOD(SetValue)(THIS_ D3DXHANDLE parameter, const void *data, UINT bytes) PURE;
235  STDMETHOD(GetValue)(THIS_ D3DXHANDLE parameter, void *data, UINT bytes) PURE;
236  STDMETHOD(SetBool)(THIS_ D3DXHANDLE parameter, BOOL b) PURE;
237  STDMETHOD(GetBool)(THIS_ D3DXHANDLE parameter, BOOL* b) PURE;
238  STDMETHOD(SetBoolArray)(THIS_ D3DXHANDLE parameter, const BOOL *b, UINT count) PURE;
239  STDMETHOD(GetBoolArray)(THIS_ D3DXHANDLE parameter, BOOL* b, UINT count) PURE;
240  STDMETHOD(SetInt)(THIS_ D3DXHANDLE parameter, INT n) PURE;
241  STDMETHOD(GetInt)(THIS_ D3DXHANDLE parameter, INT* n) PURE;
242  STDMETHOD(SetIntArray)(THIS_ D3DXHANDLE parameter, const INT *n, UINT count) PURE;
243  STDMETHOD(GetIntArray)(THIS_ D3DXHANDLE parameter, INT* n, UINT count) PURE;
245  STDMETHOD(GetFloat)(THIS_ D3DXHANDLE parameter, FLOAT* f) PURE;
247  STDMETHOD(GetFloatArray)(THIS_ D3DXHANDLE parameter, FLOAT* f, UINT count) PURE;
249  STDMETHOD(GetVector)(THIS_ D3DXHANDLE parameter, D3DXVECTOR4* vector) PURE;
251  STDMETHOD(GetVectorArray)(THIS_ D3DXHANDLE parameter, D3DXVECTOR4* vector, UINT count) PURE;
255  STDMETHOD(GetMatrixArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX* matrix, UINT count) PURE;
257  STDMETHOD(GetMatrixPointerArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX** matrix, UINT count) PURE;
259  STDMETHOD(GetMatrixTranspose)(THIS_ D3DXHANDLE parameter, D3DXMATRIX* matrix) PURE;
261  STDMETHOD(GetMatrixTransposeArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX* matrix, UINT count) PURE;
263  STDMETHOD(GetMatrixTransposePointerArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX** matrix, UINT count) PURE;
264  STDMETHOD(SetString)(THIS_ D3DXHANDLE parameter, const char *string) PURE;
265  STDMETHOD(GetString)(THIS_ D3DXHANDLE parameter, const char **string) PURE;
266  STDMETHOD(SetTexture)(THIS_ D3DXHANDLE parameter, struct IDirect3DBaseTexture9 *texture) PURE;
267  STDMETHOD(GetTexture)(THIS_ D3DXHANDLE parameter, struct IDirect3DBaseTexture9 **texture) PURE;
268  STDMETHOD(GetPixelShader)(THIS_ D3DXHANDLE parameter, struct IDirect3DPixelShader9 **shader) PURE;
269  STDMETHOD(GetVertexShader)(THIS_ D3DXHANDLE parameter, struct IDirect3DVertexShader9 **shader) PURE;
270  STDMETHOD(SetArrayRange)(THIS_ D3DXHANDLE parameter, UINT start, UINT end) PURE;
271  /*** ID3DXEffect methods ***/
272  STDMETHOD(GetPool)(THIS_ ID3DXEffectPool **pool) PURE;
273  STDMETHOD(SetTechnique)(THIS_ D3DXHANDLE technique) PURE;
274  STDMETHOD_(D3DXHANDLE, GetCurrentTechnique)(THIS) PURE;
275  STDMETHOD(ValidateTechnique)(THIS_ D3DXHANDLE technique) PURE;
276  STDMETHOD(FindNextValidTechnique)(THIS_ D3DXHANDLE technique, D3DXHANDLE* next_technique) PURE;
277  STDMETHOD_(BOOL, IsParameterUsed)(THIS_ D3DXHANDLE parameter, D3DXHANDLE technique) PURE;
278  STDMETHOD(Begin)(THIS_ UINT *passes, DWORD flags) PURE;
279  STDMETHOD(BeginPass)(THIS_ UINT pass) PURE;
280  STDMETHOD(CommitChanges)(THIS) PURE;
281  STDMETHOD(EndPass)(THIS) PURE;
282  STDMETHOD(End)(THIS) PURE;
283  STDMETHOD(GetDevice)(THIS_ struct IDirect3DDevice9 **device) PURE;
284  STDMETHOD(OnLostDevice)(THIS) PURE;
285  STDMETHOD(OnResetDevice)(THIS) PURE;
286  STDMETHOD(SetStateManager)(THIS_ ID3DXEffectStateManager *manager) PURE;
287  STDMETHOD(GetStateManager)(THIS_ ID3DXEffectStateManager **manager) PURE;
288  STDMETHOD(BeginParameterBlock)(THIS) PURE;
289  STDMETHOD_(D3DXHANDLE, EndParameterBlock)(THIS) PURE;
290  STDMETHOD(ApplyParameterBlock)(THIS_ D3DXHANDLE parameter_block) PURE;
291 #if D3DX_SDK_VERSION >= 26
292  STDMETHOD(DeleteParameterBlock)(THIS_ D3DXHANDLE parameter_block) PURE;
293 #endif
294  STDMETHOD(CloneEffect)(THIS_ struct IDirect3DDevice9 *device, struct ID3DXEffect **effect) PURE;
295 #if D3DX_SDK_VERSION >= 27
296  STDMETHOD(SetRawValue)(THIS_ D3DXHANDLE parameter, const void *data, UINT byte_offset, UINT bytes) PURE;
297 #endif
298 };
#define REFIID
Definition: guiddef.h:118
#define THIS_
Definition: basetyps.h:65
static TCHAR * GetParameter(TCHAR **pPointer)
Definition: start.c:20
_In_ BOOLEAN Release
Definition: classpnp.h:1122
const char * D3DXHANDLE
Definition: d3dx9shader.h:48
#define THIS
Definition: basetyps.h:66
REFIID riid
Definition: precomp.h:44
GLuint GLenum matrix
Definition: glext.h:9407
GLuint GLuint GLsizei count
Definition: gl.h:1545
static HRESULT QueryInterface(REFIID, void **)
Definition: events.c:2587
GLdouble n
Definition: glext.h:7729
GLuint GLuint end
Definition: gl.h:1545
int32_t INT
Definition: typedefs.h:58
#define STDMETHOD(m)
Definition: basetyps.h:62
pass
Definition: typegen.h:24
static unsigned char bytes[4]
Definition: adnsresfilter.c:74
unsigned int BOOL
Definition: ntddk_ex.h:94
Definition: devices.h:37
static const WCHAR desc[]
Definition: protectdata.c:36
#define b
Definition: ke_i.h:79
GLuint shader
Definition: glext.h:6030
GLenum GLuint texture
Definition: glext.h:6295
static FILE * out
Definition: regtests2xml.c:44
unsigned long DWORD
Definition: ntddk_ex.h:95
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
GLbitfield flags
Definition: glext.h:7161
#define index(s, c)
Definition: various.h:29
char string[160]
Definition: util.h:11
char * GetPass(const char *const prompt)
Definition: util.c:186
GLuint start
Definition: gl.h:1545
#define f
Definition: ke_i.h:83
#define PURE
Definition: basetyps.h:64
unsigned int UINT
Definition: ndis.h:50
static ULONG WINAPI AddRef(IStream *iface)
Definition: clist.c:90
float FLOAT
Definition: typedefs.h:69
unsigned int ULONG
Definition: retypes.h:1
ACPI_BUFFER *RetBuffer ACPI_BUFFER *RetBuffer char ACPI_WALK_RESOURCE_CALLBACK void *Context ACPI_BUFFER *RetBuffer UINT16 ACPI_RESOURCE **ResourcePtr ACPI_GENERIC_ADDRESS *Reg UINT32 *ReturnValue UINT8 UINT8 *Slp_TypB ACPI_PHYSICAL_ADDRESS PhysicalAddress64 UINT32 UINT32 *TimeElapsed UINT32 ACPI_STATUS const char UINT32 ACPI_STATUS const char UINT32 const char const char UINT32 const char BOOLEAN Begin
Definition: acpixf.h:1297
#define STDMETHOD_(t, m)
Definition: basetyps.h:63
MATRIX * GetMatrix(HWND hwnd)
Definition: matrix.c:289
void * object
Definition: jmemsys.h:48
GLuint const GLchar * name
Definition: glext.h:6031

◆ DECLARE_INTERFACE_() [5/5]

DECLARE_INTERFACE_ ( ID3DXEffectCompiler  ,
ID3DXBaseEffect   
)

Definition at line 308 of file d3dx9effect.h.

309 {
310  /*** IUnknown methods ***/
314  /*** ID3DXBaseEffect methods ***/
316  STDMETHOD(GetParameterDesc)(THIS_ D3DXHANDLE parameter, D3DXPARAMETER_DESC* desc) PURE;
317  STDMETHOD(GetTechniqueDesc)(THIS_ D3DXHANDLE technique, D3DXTECHNIQUE_DESC* desc) PURE;
321  STDMETHOD_(D3DXHANDLE, GetParameterByName)(THIS_ D3DXHANDLE parameter, const char *name) PURE;
322  STDMETHOD_(D3DXHANDLE, GetParameterBySemantic)(THIS_ D3DXHANDLE parameter, const char *semantic) PURE;
323  STDMETHOD_(D3DXHANDLE, GetParameterElement)(THIS_ D3DXHANDLE parameter, UINT index) PURE;
324  STDMETHOD_(D3DXHANDLE, GetTechnique)(THIS_ UINT index) PURE;
325  STDMETHOD_(D3DXHANDLE, GetTechniqueByName)(THIS_ const char *name) PURE;
327  STDMETHOD_(D3DXHANDLE, GetPassByName)(THIS_ D3DXHANDLE technique, const char *name) PURE;
328  STDMETHOD_(D3DXHANDLE, GetFunction)(THIS_ UINT index);
329  STDMETHOD_(D3DXHANDLE, GetFunctionByName)(THIS_ const char *name);
331  STDMETHOD_(D3DXHANDLE, GetAnnotationByName)(THIS_ D3DXHANDLE object, const char *name) PURE;
332  STDMETHOD(SetValue)(THIS_ D3DXHANDLE parameter, const void *data, UINT bytes) PURE;
333  STDMETHOD(GetValue)(THIS_ D3DXHANDLE parameter, void *data, UINT bytes) PURE;
334  STDMETHOD(SetBool)(THIS_ D3DXHANDLE parameter, BOOL b) PURE;
335  STDMETHOD(GetBool)(THIS_ D3DXHANDLE parameter, BOOL* b) PURE;
336  STDMETHOD(SetBoolArray)(THIS_ D3DXHANDLE parameter, const BOOL *b, UINT count) PURE;
337  STDMETHOD(GetBoolArray)(THIS_ D3DXHANDLE parameter, BOOL* b, UINT count) PURE;
338  STDMETHOD(SetInt)(THIS_ D3DXHANDLE parameter, INT n) PURE;
339  STDMETHOD(GetInt)(THIS_ D3DXHANDLE parameter, INT* n) PURE;
340  STDMETHOD(SetIntArray)(THIS_ D3DXHANDLE parameter, const INT *n, UINT count) PURE;
341  STDMETHOD(GetIntArray)(THIS_ D3DXHANDLE parameter, INT* n, UINT count) PURE;
343  STDMETHOD(GetFloat)(THIS_ D3DXHANDLE parameter, FLOAT* f) PURE;
345  STDMETHOD(GetFloatArray)(THIS_ D3DXHANDLE parameter, FLOAT* f, UINT count) PURE;
347  STDMETHOD(GetVector)(THIS_ D3DXHANDLE parameter, D3DXVECTOR4* vector) PURE;
349  STDMETHOD(GetVectorArray)(THIS_ D3DXHANDLE parameter, D3DXVECTOR4* vector, UINT count) PURE;
353  STDMETHOD(GetMatrixArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX* matrix, UINT count) PURE;
355  STDMETHOD(GetMatrixPointerArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX** matrix, UINT count) PURE;
357  STDMETHOD(GetMatrixTranspose)(THIS_ D3DXHANDLE parameter, D3DXMATRIX* matrix) PURE;
359  STDMETHOD(GetMatrixTransposeArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX* matrix, UINT count) PURE;
361  STDMETHOD(GetMatrixTransposePointerArray)(THIS_ D3DXHANDLE parameter, D3DXMATRIX** matrix, UINT count) PURE;
362  STDMETHOD(SetString)(THIS_ D3DXHANDLE parameter, const char *string) PURE;
363  STDMETHOD(GetString)(THIS_ D3DXHANDLE parameter, const char **string) PURE;
364  STDMETHOD(SetTexture)(THIS_ D3DXHANDLE parameter, struct IDirect3DBaseTexture9 *texture) PURE;
365  STDMETHOD(GetTexture)(THIS_ D3DXHANDLE parameter, struct IDirect3DBaseTexture9 **texture) PURE;
366  STDMETHOD(GetPixelShader)(THIS_ D3DXHANDLE parameter, struct IDirect3DPixelShader9 **shader) PURE;
367  STDMETHOD(GetVertexShader)(THIS_ D3DXHANDLE parameter, struct IDirect3DVertexShader9 **shader) PURE;
368  STDMETHOD(SetArrayRange)(THIS_ D3DXHANDLE parameter, UINT start, UINT end) PURE;
369  /*** ID3DXEffectCompiler methods ***/
370  STDMETHOD(SetLiteral)(THIS_ D3DXHANDLE parameter, BOOL literal) PURE;
371  STDMETHOD(GetLiteral)(THIS_ D3DXHANDLE parameter, BOOL* literal) PURE;
372  STDMETHOD(CompileEffect)(THIS_ DWORD flags, ID3DXBuffer **effect, ID3DXBuffer **error_msgs) PURE;
373  STDMETHOD(CompileShader)(THIS_ D3DXHANDLE function, const char *target, DWORD flags,
374  ID3DXBuffer **shader, ID3DXBuffer **error_msgs, ID3DXConstantTable **constant_table) PURE;
375 };
#define REFIID
Definition: guiddef.h:118
#define THIS_
Definition: basetyps.h:65
static TCHAR * GetParameter(TCHAR **pPointer)
Definition: start.c:20
_In_ BOOLEAN Release
Definition: classpnp.h:1122
const char * D3DXHANDLE
Definition: d3dx9shader.h:48
#define THIS
Definition: basetyps.h:66
REFIID riid
Definition: precomp.h:44
GLuint GLenum matrix
Definition: glext.h:9407
GLuint GLuint GLsizei count
Definition: gl.h:1545
static HRESULT QueryInterface(REFIID, void **)
Definition: events.c:2587
GLdouble n
Definition: glext.h:7729
GLuint GLuint end
Definition: gl.h:1545
int32_t INT
Definition: typedefs.h:58
#define STDMETHOD(m)
Definition: basetyps.h:62
pass
Definition: typegen.h:24
static unsigned char bytes[4]
Definition: adnsresfilter.c:74
unsigned int BOOL
Definition: ntddk_ex.h:94
static const WCHAR desc[]
Definition: protectdata.c:36
struct ID3DXBuffer ID3DXBuffer
Definition: d3dx8core.h:51
#define b
Definition: ke_i.h:79
GLuint shader
Definition: glext.h:6030
GLenum GLuint texture
Definition: glext.h:6295
static FILE * out
Definition: regtests2xml.c:44
unsigned long DWORD
Definition: ntddk_ex.h:95
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
GLbitfield flags
Definition: glext.h:7161
#define index(s, c)
Definition: various.h:29
char string[160]
Definition: util.h:11
char * GetPass(const char *const prompt)
Definition: util.c:186
GLuint start
Definition: gl.h:1545
#define f
Definition: ke_i.h:83
#define PURE
Definition: basetyps.h:64
unsigned int UINT
Definition: ndis.h:50
static ULONG WINAPI AddRef(IStream *iface)
Definition: clist.c:90
float FLOAT
Definition: typedefs.h:69
unsigned int ULONG
Definition: retypes.h:1
GLenum target
Definition: glext.h:7315
#define STDMETHOD_(t, m)
Definition: basetyps.h:63
MATRIX * GetMatrix(HWND hwnd)
Definition: matrix.c:289
void * object
Definition: jmemsys.h:48
GLuint const GLchar * name
Definition: glext.h:6031

◆ DEFINE_GUID() [1/5]

DEFINE_GUID ( IID_ID3DXEffectPool  ,
0x9537ab04  ,
0x3250  ,
0x412e  ,
0x82  ,
0x13  ,
0xfc  ,
0xd2  ,
0xf8  ,
0x67  ,
0x79  ,
0x33   
)

◆ DEFINE_GUID() [2/5]

DEFINE_GUID ( IID_ID3DXBaseEffect  ,
0x17c18ac  ,
0x103f  ,
0x4417  ,
0x8c  ,
0x51  ,
0x6b  ,
0xf6  ,
0xef  ,
0x1e  ,
0x56  ,
0xbe   
)

◆ DEFINE_GUID() [3/5]

DEFINE_GUID ( IID_ID3DXEffectStateManager  ,
0x79aab587  ,
0x6dbc  ,
0x4fa7  ,
0x82  ,
0xde  ,
0x37  ,
0xfa  ,
0x17  ,
0x81  ,
0xc5  ,
0xce   
)

◆ DEFINE_GUID() [4/5]

DEFINE_GUID ( IID_ID3DXEffect  ,
0xf6ceb4b3  ,
0x4e4c  ,
0x40dd  ,
0xb8  ,
0x83  ,
0x8d  ,
0x8d  ,
0xe5  ,
0xea  ,
0x0c  ,
0xd5   
)

◆ DEFINE_GUID() [5/5]

DEFINE_GUID ( IID_ID3DXEffectCompiler  ,
0x51b8a949  ,
0x1a31  ,
0x47e6  ,
0xbe  ,
0xa0  ,
0x4b  ,
0x30  ,
0xdb  ,
0x53  ,
0xf1  ,
0xe0   
)