Commit 91c00c17 authored by Rico Schüller's avatar Rico Schüller Committed by Alexandre Julliard

d3d10: Add ID3D10EffectConstantBufferVtbl.

parent 033eb8d7
...@@ -70,6 +70,8 @@ struct d3d10_effect_variable ...@@ -70,6 +70,8 @@ struct d3d10_effect_variable
struct d3d10_effect_local_buffer struct d3d10_effect_local_buffer
{ {
const struct ID3D10EffectConstantBufferVtbl *vtbl;
char *name; char *name;
DWORD data_size; DWORD data_size;
DWORD variable_count; DWORD variable_count;
......
...@@ -34,6 +34,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d10); ...@@ -34,6 +34,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d10);
static const struct ID3D10EffectTechniqueVtbl d3d10_effect_technique_vtbl; static const struct ID3D10EffectTechniqueVtbl d3d10_effect_technique_vtbl;
static const struct ID3D10EffectPassVtbl d3d10_effect_pass_vtbl; static const struct ID3D10EffectPassVtbl d3d10_effect_pass_vtbl;
static const struct ID3D10EffectVariableVtbl d3d10_effect_variable_vtbl; static const struct ID3D10EffectVariableVtbl d3d10_effect_variable_vtbl;
static const struct ID3D10EffectConstantBufferVtbl d3d10_effect_constant_buffer_vtbl;
static inline void read_dword(const char **ptr, DWORD *d) static inline void read_dword(const char **ptr, DWORD *d)
{ {
...@@ -514,6 +515,7 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d ...@@ -514,6 +515,7 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d
for (i = 0; i < e->local_buffer_count; ++i) for (i = 0; i < e->local_buffer_count; ++i)
{ {
struct d3d10_effect_local_buffer *l = &e->local_buffers[i]; struct d3d10_effect_local_buffer *l = &e->local_buffers[i];
l->vtbl = &d3d10_effect_constant_buffer_vtbl;
hr = parse_fx10_local_buffer(l, &ptr, data); hr = parse_fx10_local_buffer(l, &ptr, data);
if (FAILED(hr)) return hr; if (FAILED(hr)) return hr;
...@@ -1406,3 +1408,269 @@ static const struct ID3D10EffectVariableVtbl d3d10_effect_variable_vtbl = ...@@ -1406,3 +1408,269 @@ static const struct ID3D10EffectVariableVtbl d3d10_effect_variable_vtbl =
d3d10_effect_variable_SetRawValue, d3d10_effect_variable_SetRawValue,
d3d10_effect_variable_GetRawValue, d3d10_effect_variable_GetRawValue,
}; };
/* ID3D10EffectVariable methods */
static BOOL STDMETHODCALLTYPE d3d10_effect_constant_buffer_IsValid(ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return FALSE;
}
static struct ID3D10EffectType * STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetType(ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetDesc(ID3D10EffectConstantBuffer *iface,
D3D10_EFFECT_VARIABLE_DESC *desc)
{
FIXME("iface %p, desc %p stub!\n", iface, desc);
return E_NOTIMPL;
}
static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetAnnotationByIndex(
ID3D10EffectConstantBuffer *iface, UINT index)
{
FIXME("iface %p, index %u stub!\n", iface, index);
return NULL;
}
static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetAnnotationByName(
ID3D10EffectConstantBuffer *iface, LPCSTR name)
{
FIXME("iface %p, name \"%s\" stub!\n", iface, name);
return NULL;
}
static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetMemberByIndex(
ID3D10EffectConstantBuffer *iface, UINT index)
{
FIXME("iface %p, index %u stub!\n", iface, index);
return NULL;
}
static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetMemberByName(
ID3D10EffectConstantBuffer *iface, LPCSTR name)
{
FIXME("iface %p, name \"%s\" stub!\n", iface, name);
return NULL;
}
static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetMemberBySemantic(
ID3D10EffectConstantBuffer *iface, LPCSTR semantic)
{
FIXME("iface %p, semantic \"%s\" stub!\n", iface, semantic);
return NULL;
}
static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetElement(
ID3D10EffectConstantBuffer *iface, UINT index)
{
FIXME("iface %p, index %u stub!\n", iface, index);
return NULL;
}
static struct ID3D10EffectConstantBuffer * STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetParentConstantBuffer(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectScalarVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsScalar(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectVectorVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsVector(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectMatrixVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsMatrix(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectStringVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsString(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectShaderResourceVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsShaderResource(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectRenderTargetViewVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsRenderTargetView(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectDepthStencilViewVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsDepthStencilView(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectConstantBuffer * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsConstantBuffer(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectShaderVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsShader(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectBlendVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsBlend(ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectDepthStencilVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsDepthStencil(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectRasterizerVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsRasterizer(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static struct ID3D10EffectSamplerVariable * STDMETHODCALLTYPE d3d10_effect_constant_buffer_AsSampler(
ID3D10EffectConstantBuffer *iface)
{
FIXME("iface %p stub!\n", iface);
return NULL;
}
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_SetRawValue(ID3D10EffectConstantBuffer *iface,
void *data, UINT offset, UINT count)
{
FIXME("iface %p, data %p, offset %u, count %u stub!\n", iface, data, offset, count);
return E_NOTIMPL;
}
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetRawValue(ID3D10EffectConstantBuffer *iface,
void *data, UINT offset, UINT count)
{
FIXME("iface %p, data %p, offset %u, count %u stub!\n", iface, data, offset, count);
return E_NOTIMPL;
}
/* ID3D10EffectConstantBuffer methods */
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_SetConstantBuffer(ID3D10EffectConstantBuffer *iface,
ID3D10Buffer *buffer)
{
FIXME("iface %p, buffer %p stub!\n", iface, buffer);
return E_NOTIMPL;
}
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetConstantBuffer(ID3D10EffectConstantBuffer *iface,
ID3D10Buffer **buffer)
{
FIXME("iface %p, buffer %p stub!\n", iface, buffer);
return E_NOTIMPL;
}
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_SetTextureBuffer(ID3D10EffectConstantBuffer *iface,
ID3D10ShaderResourceView *view)
{
FIXME("iface %p, view %p stub!\n", iface, view);
return E_NOTIMPL;
}
static HRESULT STDMETHODCALLTYPE d3d10_effect_constant_buffer_GetTextureBuffer(ID3D10EffectConstantBuffer *iface,
ID3D10ShaderResourceView **view)
{
FIXME("iface %p, view %p stub!\n", iface, view);
return E_NOTIMPL;
}
static const struct ID3D10EffectConstantBufferVtbl d3d10_effect_constant_buffer_vtbl =
{
/* ID3D10EffectVariable methods */
d3d10_effect_constant_buffer_IsValid,
d3d10_effect_constant_buffer_GetType,
d3d10_effect_constant_buffer_GetDesc,
d3d10_effect_constant_buffer_GetAnnotationByIndex,
d3d10_effect_constant_buffer_GetAnnotationByName,
d3d10_effect_constant_buffer_GetMemberByIndex,
d3d10_effect_constant_buffer_GetMemberByName,
d3d10_effect_constant_buffer_GetMemberBySemantic,
d3d10_effect_constant_buffer_GetElement,
d3d10_effect_constant_buffer_GetParentConstantBuffer,
d3d10_effect_constant_buffer_AsScalar,
d3d10_effect_constant_buffer_AsVector,
d3d10_effect_constant_buffer_AsMatrix,
d3d10_effect_constant_buffer_AsString,
d3d10_effect_constant_buffer_AsShaderResource,
d3d10_effect_constant_buffer_AsRenderTargetView,
d3d10_effect_constant_buffer_AsDepthStencilView,
d3d10_effect_constant_buffer_AsConstantBuffer,
d3d10_effect_constant_buffer_AsShader,
d3d10_effect_constant_buffer_AsBlend,
d3d10_effect_constant_buffer_AsDepthStencil,
d3d10_effect_constant_buffer_AsRasterizer,
d3d10_effect_constant_buffer_AsSampler,
d3d10_effect_constant_buffer_SetRawValue,
d3d10_effect_constant_buffer_GetRawValue,
/* ID3D10EffectConstantBuffer methods */
d3d10_effect_constant_buffer_SetConstantBuffer,
d3d10_effect_constant_buffer_GetConstantBuffer,
d3d10_effect_constant_buffer_SetTextureBuffer,
d3d10_effect_constant_buffer_GetTextureBuffer,
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment