Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
a7cf4d16
Commit
a7cf4d16
authored
Nov 01, 2010
by
Rico Schüller
Committed by
Alexandre Julliard
Nov 02, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dcompiler: Add stub ID3D11ShaderReflection interface.
parent
257c4b68
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
269 additions
and
1 deletion
+269
-1
Makefile.in
dlls/d3dcompiler_43/Makefile.in
+1
-0
d3dcompiler_43_main.c
dlls/d3dcompiler_43/d3dcompiler_43_main.c
+17
-1
d3dcompiler_private.h
dlls/d3dcompiler_43/d3dcompiler_private.h
+8
-0
reflection.c
dlls/d3dcompiler_43/reflection.c
+243
-0
No files found.
dlls/d3dcompiler_43/Makefile.in
View file @
a7cf4d16
...
...
@@ -9,6 +9,7 @@ C_SRCS = \
bytecodewriter.c
\
compiler.c
\
d3dcompiler_43_main.c
\
reflection.c
\
utils.c
LEX_SRCS
=
asmshader.l
...
...
dlls/d3dcompiler_43/d3dcompiler_43_main.c
View file @
a7cf4d16
...
...
@@ -126,7 +126,23 @@ HRESULT WINAPI D3DStripShader(const void *data, SIZE_T data_size, UINT flags, ID
HRESULT
WINAPI
D3DReflect
(
const
void
*
data
,
SIZE_T
data_size
,
REFIID
riid
,
void
**
reflector
)
{
struct
d3dcompiler_shader_reflection
*
object
;
FIXME
(
"data %p, data_size %lu, riid %s, blob %p stub!
\n
"
,
data
,
data_size
,
debugstr_guid
(
riid
),
reflector
);
return
E_NOTIMPL
;
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
!
object
)
{
ERR
(
"Failed to allocate D3D compiler shader reflection object memory
\n
"
);
return
E_OUTOFMEMORY
;
}
object
->
vtbl
=
&
d3dcompiler_shader_reflection_vtbl
;
object
->
refcount
=
1
;
*
reflector
=
(
ID3D11ShaderReflection
*
)
object
;
TRACE
(
"Created ID3D11ShaderReflection %p
\n
"
,
object
);
return
S_OK
;
}
dlls/d3dcompiler_43/d3dcompiler_private.h
View file @
a7cf4d16
...
...
@@ -57,6 +57,14 @@ HRESULT d3dcompiler_blob_init(struct d3dcompiler_blob *blob, SIZE_T data_size) D
HRESULT
d3dcompiler_get_blob_part
(
const
void
*
data
,
SIZE_T
data_size
,
D3D_BLOB_PART
part
,
UINT
flags
,
ID3DBlob
**
blob
)
DECLSPEC_HIDDEN
;
HRESULT
d3dcompiler_strip_shader
(
const
void
*
data
,
SIZE_T
data_size
,
UINT
flags
,
ID3DBlob
**
blob
)
DECLSPEC_HIDDEN
;
/* ID3D11ShaderReflection */
extern
const
struct
ID3D11ShaderReflectionVtbl
d3dcompiler_shader_reflection_vtbl
DECLSPEC_HIDDEN
;
struct
d3dcompiler_shader_reflection
{
const
struct
ID3D11ShaderReflectionVtbl
*
vtbl
;
LONG
refcount
;
};
/* Shader assembler definitions */
typedef
enum
_shader_type
{
ST_VERTEX
,
...
...
dlls/d3dcompiler_43/reflection.c
0 → 100644
View file @
a7cf4d16
/*
* Copyright 2009 Henri Verbeet for CodeWeavers
* Copyright 2010 Rico Schüller
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*
*/
#include "config.h"
#include "wine/port.h"
#include "d3dcompiler_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3dcompiler
);
/* IUnknown methods */
static
HRESULT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_QueryInterface
(
ID3D11ShaderReflection
*
iface
,
REFIID
riid
,
void
**
object
)
{
TRACE
(
"iface %p, riid %s, object %p
\n
"
,
iface
,
debugstr_guid
(
riid
),
object
);
if
(
IsEqualGUID
(
riid
,
&
IID_ID3D11ShaderReflection
)
||
IsEqualGUID
(
riid
,
&
IID_IUnknown
))
{
IUnknown_AddRef
(
iface
);
*
object
=
iface
;
return
S_OK
;
}
WARN
(
"%s not implemented, returning E_NOINTERFACE
\n
"
,
debugstr_guid
(
riid
));
*
object
=
NULL
;
return
E_NOINTERFACE
;
}
static
ULONG
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_AddRef
(
ID3D11ShaderReflection
*
iface
)
{
struct
d3dcompiler_shader_reflection
*
This
=
(
struct
d3dcompiler_shader_reflection
*
)
iface
;
ULONG
refcount
=
InterlockedIncrement
(
&
This
->
refcount
);
TRACE
(
"%p increasing refcount to %u
\n
"
,
This
,
refcount
);
return
refcount
;
}
static
ULONG
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_Release
(
ID3D11ShaderReflection
*
iface
)
{
struct
d3dcompiler_shader_reflection
*
This
=
(
struct
d3dcompiler_shader_reflection
*
)
iface
;
ULONG
refcount
=
InterlockedDecrement
(
&
This
->
refcount
);
TRACE
(
"%p decreasing refcount to %u
\n
"
,
This
,
refcount
);
if
(
!
refcount
)
{
HeapFree
(
GetProcessHeap
(),
0
,
This
);
}
return
refcount
;
}
/* ID3D11ShaderReflection methods */
static
HRESULT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetDesc
(
ID3D11ShaderReflection
*
iface
,
D3D11_SHADER_DESC
*
desc
)
{
FIXME
(
"iface %p, desc %p stub!
\n
"
,
iface
,
desc
);
return
E_NOTIMPL
;
}
static
struct
ID3D11ShaderReflectionConstantBuffer
*
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetConstantBufferByIndex
(
ID3D11ShaderReflection
*
iface
,
UINT
index
)
{
FIXME
(
"iface %p, index %u stub!
\n
"
,
iface
,
index
);
return
NULL
;
}
static
struct
ID3D11ShaderReflectionConstantBuffer
*
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetConstantBufferByName
(
ID3D11ShaderReflection
*
iface
,
LPCSTR
name
)
{
FIXME
(
"iface %p, name
\"
%s
\"
stub!
\n
"
,
iface
,
name
);
return
NULL
;
}
static
HRESULT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetResourceBindingDesc
(
ID3D11ShaderReflection
*
iface
,
UINT
index
,
D3D11_SHADER_INPUT_BIND_DESC
*
desc
)
{
FIXME
(
"iface %p, index %u, desc %p stub!
\n
"
,
iface
,
index
,
desc
);
return
E_NOTIMPL
;
}
static
HRESULT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetInputParameterDesc
(
ID3D11ShaderReflection
*
iface
,
UINT
index
,
D3D11_SIGNATURE_PARAMETER_DESC
*
desc
)
{
FIXME
(
"iface %p, index %u, desc %p stub!
\n
"
,
iface
,
index
,
desc
);
return
E_NOTIMPL
;
}
static
HRESULT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetOutputParameterDesc
(
ID3D11ShaderReflection
*
iface
,
UINT
index
,
D3D11_SIGNATURE_PARAMETER_DESC
*
desc
)
{
FIXME
(
"iface %p, index %u, desc %p stub!
\n
"
,
iface
,
index
,
desc
);
return
E_NOTIMPL
;
}
static
HRESULT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetPatchConstantParameterDesc
(
ID3D11ShaderReflection
*
iface
,
UINT
index
,
D3D11_SIGNATURE_PARAMETER_DESC
*
desc
)
{
FIXME
(
"iface %p, index %u, desc %p stub!
\n
"
,
iface
,
index
,
desc
);
return
E_NOTIMPL
;
}
static
struct
ID3D11ShaderReflectionVariable
*
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetVariableByName
(
ID3D11ShaderReflection
*
iface
,
LPCSTR
name
)
{
FIXME
(
"iface %p, name %s stub!
\n
"
,
iface
,
name
);
return
NULL
;
}
static
HRESULT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetResourceBindingDescByName
(
ID3D11ShaderReflection
*
iface
,
LPCSTR
name
,
D3D11_SHADER_INPUT_BIND_DESC
*
desc
)
{
FIXME
(
"iface %p, name %s, desc %p stub!
\n
"
,
iface
,
name
,
desc
);
return
E_NOTIMPL
;
}
static
UINT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetMovInstructionCount
(
ID3D11ShaderReflection
*
iface
)
{
FIXME
(
"iface %p stub!
\n
"
,
iface
);
return
0
;
}
static
UINT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetMovcInstructionCount
(
ID3D11ShaderReflection
*
iface
)
{
FIXME
(
"iface %p stub!
\n
"
,
iface
);
return
0
;
}
static
UINT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetConversionInstructionCount
(
ID3D11ShaderReflection
*
iface
)
{
FIXME
(
"iface %p stub!
\n
"
,
iface
);
return
0
;
}
static
UINT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetBitwiseInstructionCount
(
ID3D11ShaderReflection
*
iface
)
{
FIXME
(
"iface %p stub!
\n
"
,
iface
);
return
0
;
}
static
D3D_PRIMITIVE
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetGSInputPrimitive
(
ID3D11ShaderReflection
*
iface
)
{
FIXME
(
"iface %p stub!
\n
"
,
iface
);
return
0
;
}
static
BOOL
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_IsSampleFrequencyShader
(
ID3D11ShaderReflection
*
iface
)
{
FIXME
(
"iface %p stub!
\n
"
,
iface
);
return
0
;
}
static
UINT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetNumInterfaceSlots
(
ID3D11ShaderReflection
*
iface
)
{
FIXME
(
"iface %p stub!
\n
"
,
iface
);
return
0
;
}
static
HRESULT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetMinFeatureLevel
(
ID3D11ShaderReflection
*
iface
,
D3D_FEATURE_LEVEL
*
level
)
{
FIXME
(
"iface %p, level %p stub!
\n
"
,
iface
,
level
);
return
E_NOTIMPL
;
}
static
UINT
STDMETHODCALLTYPE
d3dcompiler_shader_reflection_GetThreadGroupSize
(
ID3D11ShaderReflection
*
iface
,
UINT
*
sizex
,
UINT
*
sizey
,
UINT
*
sizez
)
{
FIXME
(
"iface %p, sizex %p, sizey %p, sizez %p stub!
\n
"
,
iface
,
sizex
,
sizey
,
sizez
);
return
0
;
}
const
struct
ID3D11ShaderReflectionVtbl
d3dcompiler_shader_reflection_vtbl
=
{
/* IUnknown methods */
d3dcompiler_shader_reflection_QueryInterface
,
d3dcompiler_shader_reflection_AddRef
,
d3dcompiler_shader_reflection_Release
,
/* ID3D11ShaderReflection methods */
d3dcompiler_shader_reflection_GetDesc
,
d3dcompiler_shader_reflection_GetConstantBufferByIndex
,
d3dcompiler_shader_reflection_GetConstantBufferByName
,
d3dcompiler_shader_reflection_GetResourceBindingDesc
,
d3dcompiler_shader_reflection_GetInputParameterDesc
,
d3dcompiler_shader_reflection_GetOutputParameterDesc
,
d3dcompiler_shader_reflection_GetPatchConstantParameterDesc
,
d3dcompiler_shader_reflection_GetVariableByName
,
d3dcompiler_shader_reflection_GetResourceBindingDescByName
,
d3dcompiler_shader_reflection_GetMovInstructionCount
,
d3dcompiler_shader_reflection_GetMovcInstructionCount
,
d3dcompiler_shader_reflection_GetConversionInstructionCount
,
d3dcompiler_shader_reflection_GetBitwiseInstructionCount
,
d3dcompiler_shader_reflection_GetGSInputPrimitive
,
d3dcompiler_shader_reflection_IsSampleFrequencyShader
,
d3dcompiler_shader_reflection_GetNumInterfaceSlots
,
d3dcompiler_shader_reflection_GetMinFeatureLevel
,
d3dcompiler_shader_reflection_GetThreadGroupSize
,
};
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment