Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
f7214ada
Commit
f7214ada
authored
Jun 03, 2011
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Jun 03, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d10: COM cleanup for the ID3D10EffectTechnique iface.
parent
c412353a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
14 deletions
+21
-14
d3d10_private.h
dlls/d3d10/d3d10_private.h
+1
-1
effect.c
dlls/d3d10/effect.c
+20
-13
No files found.
dlls/d3d10/d3d10_private.h
View file @
f7214ada
...
@@ -160,7 +160,7 @@ struct d3d10_effect_pass
...
@@ -160,7 +160,7 @@ struct d3d10_effect_pass
/* ID3D10EffectTechnique */
/* ID3D10EffectTechnique */
struct
d3d10_effect_technique
struct
d3d10_effect_technique
{
{
const
struct
ID3D10EffectTechniqueVtbl
*
vtbl
;
ID3D10EffectTechnique
ID3D10EffectTechnique_iface
;
struct
d3d10_effect
*
effect
;
struct
d3d10_effect
*
effect
;
char
*
name
;
char
*
name
;
...
...
dlls/d3d10/effect.c
View file @
f7214ada
...
@@ -58,7 +58,7 @@ static const struct ID3D10EffectSamplerVariableVtbl d3d10_effect_sampler_variabl
...
@@ -58,7 +58,7 @@ static const struct ID3D10EffectSamplerVariableVtbl d3d10_effect_sampler_variabl
static
const
struct
ID3D10EffectTypeVtbl
d3d10_effect_type_vtbl
;
static
const
struct
ID3D10EffectTypeVtbl
d3d10_effect_type_vtbl
;
/* null objects - needed for invalid calls */
/* null objects - needed for invalid calls */
static
struct
d3d10_effect_technique
null_technique
=
{
&
d3d10_effect_technique_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_pass
null_pass
=
{{
&
d3d10_effect_pass_vtbl
}};
static
struct
d3d10_effect_type
null_type
=
{{
&
d3d10_effect_type_vtbl
}};
static
struct
d3d10_effect_type
null_type
=
{{
&
d3d10_effect_type_vtbl
}};
static
struct
d3d10_effect_variable
null_local_buffer
=
{(
const
ID3D10EffectVariableVtbl
*
)
&
d3d10_effect_constant_buffer_vtbl
,
static
struct
d3d10_effect_variable
null_local_buffer
=
{(
const
ID3D10EffectVariableVtbl
*
)
&
d3d10_effect_constant_buffer_vtbl
,
...
@@ -1618,7 +1618,7 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d
...
@@ -1618,7 +1618,7 @@ static HRESULT parse_fx10_body(struct d3d10_effect *e, const char *data, DWORD d
{
{
struct
d3d10_effect_technique
*
t
=
&
e
->
techniques
[
i
];
struct
d3d10_effect_technique
*
t
=
&
e
->
techniques
[
i
];
t
->
v
tbl
=
&
d3d10_effect_technique_vtbl
;
t
->
ID3D10EffectTechnique_iface
.
lpV
tbl
=
&
d3d10_effect_technique_vtbl
;
t
->
effect
=
e
;
t
->
effect
=
e
;
hr
=
parse_fx10_technique
(
t
,
&
ptr
,
data
);
hr
=
parse_fx10_technique
(
t
,
&
ptr
,
data
);
...
@@ -2190,14 +2190,14 @@ static struct ID3D10EffectTechnique * STDMETHODCALLTYPE d3d10_effect_GetTechniqu
...
@@ -2190,14 +2190,14 @@ static struct ID3D10EffectTechnique * STDMETHODCALLTYPE d3d10_effect_GetTechniqu
if
(
index
>=
This
->
technique_count
)
if
(
index
>=
This
->
technique_count
)
{
{
WARN
(
"Invalid index specified
\n
"
);
WARN
(
"Invalid index specified
\n
"
);
return
(
ID3D10EffectTechnique
*
)
&
null_techniqu
e
;
return
&
null_technique
.
ID3D10EffectTechnique_ifac
e
;
}
}
t
=
&
This
->
techniques
[
index
];
t
=
&
This
->
techniques
[
index
];
TRACE
(
"Returning technique %p, %s.
\n
"
,
t
,
debugstr_a
(
t
->
name
));
TRACE
(
"Returning technique %p, %s.
\n
"
,
t
,
debugstr_a
(
t
->
name
));
return
(
ID3D10EffectTechnique
*
)
t
;
return
&
t
->
ID3D10EffectTechnique_iface
;
}
}
static
struct
ID3D10EffectTechnique
*
STDMETHODCALLTYPE
d3d10_effect_GetTechniqueByName
(
ID3D10Effect
*
iface
,
static
struct
ID3D10EffectTechnique
*
STDMETHODCALLTYPE
d3d10_effect_GetTechniqueByName
(
ID3D10Effect
*
iface
,
...
@@ -2211,7 +2211,7 @@ static struct ID3D10EffectTechnique * STDMETHODCALLTYPE d3d10_effect_GetTechniqu
...
@@ -2211,7 +2211,7 @@ static struct ID3D10EffectTechnique * STDMETHODCALLTYPE d3d10_effect_GetTechniqu
if
(
!
name
)
if
(
!
name
)
{
{
WARN
(
"Invalid name specified
\n
"
);
WARN
(
"Invalid name specified
\n
"
);
return
(
ID3D10EffectTechnique
*
)
&
null_techniqu
e
;
return
&
null_technique
.
ID3D10EffectTechnique_ifac
e
;
}
}
for
(
i
=
0
;
i
<
This
->
technique_count
;
++
i
)
for
(
i
=
0
;
i
<
This
->
technique_count
;
++
i
)
...
@@ -2220,13 +2220,13 @@ static struct ID3D10EffectTechnique * STDMETHODCALLTYPE d3d10_effect_GetTechniqu
...
@@ -2220,13 +2220,13 @@ static struct ID3D10EffectTechnique * STDMETHODCALLTYPE d3d10_effect_GetTechniqu
if
(
!
strcmp
(
t
->
name
,
name
))
if
(
!
strcmp
(
t
->
name
,
name
))
{
{
TRACE
(
"Returning technique %p
\n
"
,
t
);
TRACE
(
"Returning technique %p
\n
"
,
t
);
return
(
ID3D10EffectTechnique
*
)
t
;
return
&
t
->
ID3D10EffectTechnique_iface
;
}
}
}
}
WARN
(
"Invalid name specified
\n
"
);
WARN
(
"Invalid name specified
\n
"
);
return
(
ID3D10EffectTechnique
*
)
&
null_techniqu
e
;
return
&
null_technique
.
ID3D10EffectTechnique_ifac
e
;
}
}
static
HRESULT
STDMETHODCALLTYPE
d3d10_effect_Optimize
(
ID3D10Effect
*
iface
)
static
HRESULT
STDMETHODCALLTYPE
d3d10_effect_Optimize
(
ID3D10Effect
*
iface
)
...
@@ -2267,17 +2267,24 @@ const struct ID3D10EffectVtbl d3d10_effect_vtbl =
...
@@ -2267,17 +2267,24 @@ const struct ID3D10EffectVtbl d3d10_effect_vtbl =
/* ID3D10EffectTechnique methods */
/* ID3D10EffectTechnique methods */
static
inline
struct
d3d10_effect_technique
*
impl_from_ID3D10EffectTechnique
(
ID3D10EffectTechnique
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
struct
d3d10_effect_technique
,
ID3D10EffectTechnique_iface
);
}
static
BOOL
STDMETHODCALLTYPE
d3d10_effect_technique_IsValid
(
ID3D10EffectTechnique
*
iface
)
static
BOOL
STDMETHODCALLTYPE
d3d10_effect_technique_IsValid
(
ID3D10EffectTechnique
*
iface
)
{
{
struct
d3d10_effect_technique
*
This
=
impl_from_ID3D10EffectTechnique
(
iface
);
TRACE
(
"iface %p
\n
"
,
iface
);
TRACE
(
"iface %p
\n
"
,
iface
);
return
(
struct
d3d10_effect_technique
*
)
iface
!=
&
null_technique
;
return
This
!=
&
null_technique
;
}
}
static
HRESULT
STDMETHODCALLTYPE
d3d10_effect_technique_GetDesc
(
ID3D10EffectTechnique
*
iface
,
static
HRESULT
STDMETHODCALLTYPE
d3d10_effect_technique_GetDesc
(
ID3D10EffectTechnique
*
iface
,
D3D10_TECHNIQUE_DESC
*
desc
)
D3D10_TECHNIQUE_DESC
*
desc
)
{
{
struct
d3d10_effect_technique
*
This
=
(
struct
d3d10_effect_technique
*
)
iface
;
struct
d3d10_effect_technique
*
This
=
impl_from_ID3D10EffectTechnique
(
iface
)
;
TRACE
(
"iface %p, desc %p
\n
"
,
iface
,
desc
);
TRACE
(
"iface %p, desc %p
\n
"
,
iface
,
desc
);
...
@@ -2303,7 +2310,7 @@ static HRESULT STDMETHODCALLTYPE d3d10_effect_technique_GetDesc(ID3D10EffectTech
...
@@ -2303,7 +2310,7 @@ static HRESULT STDMETHODCALLTYPE d3d10_effect_technique_GetDesc(ID3D10EffectTech
static
struct
ID3D10EffectVariable
*
STDMETHODCALLTYPE
d3d10_effect_technique_GetAnnotationByIndex
(
static
struct
ID3D10EffectVariable
*
STDMETHODCALLTYPE
d3d10_effect_technique_GetAnnotationByIndex
(
ID3D10EffectTechnique
*
iface
,
UINT
index
)
ID3D10EffectTechnique
*
iface
,
UINT
index
)
{
{
struct
d3d10_effect_technique
*
This
=
(
struct
d3d10_effect_technique
*
)
iface
;
struct
d3d10_effect_technique
*
This
=
impl_from_ID3D10EffectTechnique
(
iface
)
;
struct
d3d10_effect_variable
*
a
;
struct
d3d10_effect_variable
*
a
;
TRACE
(
"iface %p, index %u
\n
"
,
iface
,
index
);
TRACE
(
"iface %p, index %u
\n
"
,
iface
,
index
);
...
@@ -2324,7 +2331,7 @@ static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_technique_Ge
...
@@ -2324,7 +2331,7 @@ static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_technique_Ge
static
struct
ID3D10EffectVariable
*
STDMETHODCALLTYPE
d3d10_effect_technique_GetAnnotationByName
(
static
struct
ID3D10EffectVariable
*
STDMETHODCALLTYPE
d3d10_effect_technique_GetAnnotationByName
(
ID3D10EffectTechnique
*
iface
,
LPCSTR
name
)
ID3D10EffectTechnique
*
iface
,
LPCSTR
name
)
{
{
struct
d3d10_effect_technique
*
This
=
(
struct
d3d10_effect_technique
*
)
iface
;
struct
d3d10_effect_technique
*
This
=
impl_from_ID3D10EffectTechnique
(
iface
)
;
unsigned
int
i
;
unsigned
int
i
;
TRACE
(
"iface %p, name %s.
\n
"
,
iface
,
debugstr_a
(
name
));
TRACE
(
"iface %p, name %s.
\n
"
,
iface
,
debugstr_a
(
name
));
...
@@ -2347,7 +2354,7 @@ static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_technique_Ge
...
@@ -2347,7 +2354,7 @@ static struct ID3D10EffectVariable * STDMETHODCALLTYPE d3d10_effect_technique_Ge
static
struct
ID3D10EffectPass
*
STDMETHODCALLTYPE
d3d10_effect_technique_GetPassByIndex
(
ID3D10EffectTechnique
*
iface
,
static
struct
ID3D10EffectPass
*
STDMETHODCALLTYPE
d3d10_effect_technique_GetPassByIndex
(
ID3D10EffectTechnique
*
iface
,
UINT
index
)
UINT
index
)
{
{
struct
d3d10_effect_technique
*
This
=
(
struct
d3d10_effect_technique
*
)
iface
;
struct
d3d10_effect_technique
*
This
=
impl_from_ID3D10EffectTechnique
(
iface
)
;
struct
d3d10_effect_pass
*
p
;
struct
d3d10_effect_pass
*
p
;
TRACE
(
"iface %p, index %u
\n
"
,
iface
,
index
);
TRACE
(
"iface %p, index %u
\n
"
,
iface
,
index
);
...
@@ -2368,7 +2375,7 @@ static struct ID3D10EffectPass * STDMETHODCALLTYPE d3d10_effect_technique_GetPas
...
@@ -2368,7 +2375,7 @@ static struct ID3D10EffectPass * STDMETHODCALLTYPE d3d10_effect_technique_GetPas
static
struct
ID3D10EffectPass
*
STDMETHODCALLTYPE
d3d10_effect_technique_GetPassByName
(
ID3D10EffectTechnique
*
iface
,
static
struct
ID3D10EffectPass
*
STDMETHODCALLTYPE
d3d10_effect_technique_GetPassByName
(
ID3D10EffectTechnique
*
iface
,
LPCSTR
name
)
LPCSTR
name
)
{
{
struct
d3d10_effect_technique
*
This
=
(
struct
d3d10_effect_technique
*
)
iface
;
struct
d3d10_effect_technique
*
This
=
impl_from_ID3D10EffectTechnique
(
iface
)
;
unsigned
int
i
;
unsigned
int
i
;
TRACE
(
"iface %p, name %s.
\n
"
,
iface
,
debugstr_a
(
name
));
TRACE
(
"iface %p, name %s.
\n
"
,
iface
,
debugstr_a
(
name
));
...
...
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