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
de108f65
Commit
de108f65
authored
Oct 31, 2006
by
Ivan Gyurdiev
Committed by
Alexandre Julliard
Oct 31, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Add D3DTSS_TCI codes to the WINED3D namespace.
parent
875a1eb0
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
8 deletions
+14
-8
cubetexture.c
dlls/wined3d/cubetexture.c
+1
-1
device.c
dlls/wined3d/device.c
+6
-6
texture.c
dlls/wined3d/texture.c
+1
-1
wined3d_types.h
include/wine/wined3d_types.h
+6
-0
No files found.
dlls/wined3d/cubetexture.c
View file @
de108f65
...
...
@@ -232,7 +232,7 @@ static void WINAPI IWineD3DCubeTextureImpl_ApplyStateChanges(IWineD3DCubeTexture
/* Apply non-power2 mappings and texture offsets so long as the texture coords aren't projected or generated */
if
(
This
->
pow2scalingFactor
!=
1
.
0
f
)
{
if
((
textureStates
[
WINED3DTSS_TEXCOORDINDEX
]
&
0xFFFF0000
)
==
D3DTSS_TCI_PASSTHRU
&&
if
((
textureStates
[
WINED3DTSS_TEXCOORDINDEX
]
&
0xFFFF0000
)
==
WINE
D3DTSS_TCI_PASSTHRU
&&
(
~
textureStates
[
WINED3DTSS_TEXTURETRANSFORMFLAGS
]
&
WINED3DTTFF_PROJECTED
))
{
glMatrixMode
(
GL_TEXTURE
);
...
...
dlls/wined3d/device.c
View file @
de108f65
...
...
@@ -5530,7 +5530,7 @@ static void WINAPI IWineD3DDeviceImpl_ApplyTextureUnitState(IWineD3DDevice *ifac
/* FIXME: From MSDN: The WINED3DTSS_TCI_* flags are mutually exclusive. If you include
one flag, you can still specify an index value, which the system uses to
determine the texture wrapping mode.
eg. SetTextureStageState( 0, WINED3DTSS_TEXCOORDINDEX, D3DTSS_TCI_CAMERASPACEPOSITION | 1 );
eg. SetTextureStageState( 0, WINED3DTSS_TEXCOORDINDEX,
WINE
D3DTSS_TCI_CAMERASPACEPOSITION | 1 );
means use the vertex position (camera-space) as the input texture coordinates
for this texture stage, and the wrap mode set in the WINED3DRS_WRAP1 render
state. We do not (yet) support the WINED3DRENDERSTATE_WRAPx values, nor tie them up
...
...
@@ -5540,7 +5540,7 @@ static void WINAPI IWineD3DDeviceImpl_ApplyTextureUnitState(IWineD3DDevice *ifac
* Be careful the value of the mask 0xF0000 come from d3d8types.h infos
*/
switch
(
Value
&
0xFFFF0000
)
{
case
D3DTSS_TCI_PASSTHRU
:
case
WINE
D3DTSS_TCI_PASSTHRU
:
/*Use the specified texture coordinates contained within the vertex format. This value resolves to zero.*/
glDisable
(
GL_TEXTURE_GEN_S
);
glDisable
(
GL_TEXTURE_GEN_T
);
...
...
@@ -5549,7 +5549,7 @@ static void WINAPI IWineD3DDeviceImpl_ApplyTextureUnitState(IWineD3DDevice *ifac
checkGLcall
(
"glDisable(GL_TEXTURE_GEN_S,T,R,Q)"
);
break
;
case
D3DTSS_TCI_CAMERASPACEPOSITION
:
case
WINE
D3DTSS_TCI_CAMERASPACEPOSITION
:
/* CameraSpacePosition means use the vertex position, transformed to camera space,
as the input texture coordinates for this stage's texture transformation. This
equates roughly to EYE_LINEAR */
...
...
@@ -5585,7 +5585,7 @@ static void WINAPI IWineD3DDeviceImpl_ApplyTextureUnitState(IWineD3DDevice *ifac
}
break
;
case
D3DTSS_TCI_CAMERASPACENORMAL
:
case
WINE
D3DTSS_TCI_CAMERASPACENORMAL
:
{
if
(
GL_SUPPORT
(
NV_TEXGEN_REFLECTION
))
{
float
s_plane
[]
=
{
1
.
0
,
0
.
0
,
0
.
0
,
0
.
0
};
...
...
@@ -5619,7 +5619,7 @@ static void WINAPI IWineD3DDeviceImpl_ApplyTextureUnitState(IWineD3DDevice *ifac
}
break
;
case
D3DTSS_TCI_CAMERASPACEREFLECTIONVECTOR
:
case
WINE
D3DTSS_TCI_CAMERASPACEREFLECTIONVECTOR
:
{
if
(
GL_SUPPORT
(
NV_TEXGEN_REFLECTION
))
{
float
s_plane
[]
=
{
1
.
0
,
0
.
0
,
0
.
0
,
0
.
0
};
...
...
@@ -5669,7 +5669,7 @@ static void WINAPI IWineD3DDeviceImpl_ApplyTextureUnitState(IWineD3DDevice *ifac
/* Unhandled */
case
WINED3DTSS_TEXTURETRANSFORMFLAGS
:
set_texture_matrix
((
float
*
)
&
This
->
stateBlock
->
transforms
[
WINED3DTS_TEXTURE0
+
Stage
].
u
.
m
[
0
][
0
],
Value
,
(
This
->
stateBlock
->
textureState
[
Stage
][
WINED3DTSS_TEXCOORDINDEX
]
&
0xFFFF0000
)
!=
D3DTSS_TCI_PASSTHRU
);
set_texture_matrix
((
float
*
)
&
This
->
stateBlock
->
transforms
[
WINED3DTS_TEXTURE0
+
Stage
].
u
.
m
[
0
][
0
],
Value
,
(
This
->
stateBlock
->
textureState
[
Stage
][
WINED3DTSS_TEXCOORDINDEX
]
&
0xFFFF0000
)
!=
WINE
D3DTSS_TCI_PASSTHRU
);
break
;
case
WINED3DTSS_BUMPENVMAT00
:
...
...
dlls/wined3d/texture.c
View file @
de108f65
...
...
@@ -215,7 +215,7 @@ static void WINAPI IWineD3DTextureImpl_ApplyStateChanges(IWineD3DTexture *iface,
/** non-power2 fixups using texture matrix **/
if
(
This
->
pow2scalingFactorX
!=
1
.
0
f
||
This
->
pow2scalingFactorY
!=
1
.
0
f
)
{
/* Apply non-power2 mappings and texture offsets so long as the texture coords aren't projected or generated */
if
(((
textureStates
[
WINED3DTSS_TEXCOORDINDEX
]
&
0xFFFF0000
)
==
D3DTSS_TCI_PASSTHRU
)
&&
if
(((
textureStates
[
WINED3DTSS_TEXCOORDINDEX
]
&
0xFFFF0000
)
==
WINE
D3DTSS_TCI_PASSTHRU
)
&&
(
~
textureStates
[
WINED3DTSS_TEXTURETRANSFORMFLAGS
]
&
WINED3DTTFF_PROJECTED
))
{
glMatrixMode
(
GL_TEXTURE
);
memset
(
matrix
,
0
,
sizeof
(
matrix
));
...
...
include/wine/wined3d_types.h
View file @
de108f65
...
...
@@ -653,6 +653,12 @@ typedef enum _WINED3DTEXTURESTAGESTATETYPE {
WINED3DTSS_FORCE_DWORD
=
0x7fffffff
}
WINED3DTEXTURESTAGESTATETYPE
;
#define WINED3DTSS_TCI_PASSTHRU 0x00000
#define WINED3DTSS_TCI_CAMERASPACENORMAL 0x10000
#define WINED3DTSS_TCI_CAMERASPACEPOSITION 0x20000
#define WINED3DTSS_TCI_CAMERASPACEREFLECTIONVECTOR 0x30000
#define WINED3DTSS_TCI_SPHEREMAP 0x40000
#define WINED3D_HIGHEST_TEXTURE_STATE WINED3DTSS_CONSTANT
typedef
enum
_WINED3DTEXTURETRANSFORMFLAGS
{
...
...
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