-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Changelog: - Resend of last Jason texture work - Jason begin mipmaping so declare it in caps Raphael -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (GNU/Linux) iD8DBQE+IEGkp7NA3AmQTU4RAs4LAJ0RwcJj/O0z0dRbH/PNNFjbrJOugwCaA73p 34ze9WqVmdDGtrZVrcLkzrA= =vQtN -----END PGP SIGNATURE-----
Index: dlls/d3d8/device.c =================================================================== RCS file: /home/wine/wine/dlls/d3d8/device.c,v retrieving revision 1.23 diff -u -r1.23 device.c --- dlls/d3d8/device.c 9 Jan 2003 06:02:39 -0000 1.23 +++ dlls/d3d8/device.c 10 Jan 2003 23:43:33 -0000 @@ -3455,22 +3631,71 @@ break; } + case D3DTSS_ADDRESSU : + case D3DTSS_ADDRESSV : + case D3DTSS_ADDRESSW : + { + GLint wrapParm = GL_REPEAT; + switch (Value) { + case D3DTADDRESS_WRAP: wrapParm = GL_REPEAT; break; + case D3DTADDRESS_CLAMP: wrapParm = GL_CLAMP; break; + case D3DTADDRESS_BORDER: wrapParm = GL_CLAMP_TO_EDGE; break; + + case D3DTADDRESS_MIRROR: /* Unsupported in OpenGL? */ + case D3DTADDRESS_MIRRORONCE: /* Unsupported in OpenGL? */ + default: + FIXME("Unrecognized or unsupported D3DTADDRESS_* value %ld, state %d\n", Value, Type); + wrapParm = GL_REPEAT; + } + + switch (Type) { + case D3DTSS_ADDRESSU: + TRACE("Setting WRAP_S to %d for %x\n", wrapParm, This->StateBlock.textureDimensions[Stage]); + glTexParameteri(This->StateBlock.textureDimensions[Stage], GL_TEXTURE_WRAP_S, wrapParm); + checkGLcall("glTexParameteri(..., GL_TEXTURE_WRAP_S, wrapParm)"); + break; + case D3DTSS_ADDRESSV: + TRACE("Setting WRAP_T to %d for %x\n", wrapParm, This->StateBlock.textureDimensions[Stage]); + glTexParameteri(This->StateBlock.textureDimensions[Stage], GL_TEXTURE_WRAP_T, wrapParm); + checkGLcall("glTexParameteri(..., GL_TEXTURE_WRAP_T, wrapParm)"); + break; + case D3DTSS_ADDRESSW: + TRACE("Setting WRAP_R to %d for %x\n", wrapParm, This->StateBlock.textureDimensions[Stage]); + glTexParameteri(This->StateBlock.textureDimensions[Stage], GL_TEXTURE_WRAP_R, wrapParm); + checkGLcall("glTexParameteri(..., GL_TEXTURE_WRAP_R, wrapParm)"); + break; + default: /* nop */ + break; /** stupic compilator */ + } + } + break; + + case D3DTSS_BORDERCOLOR : + { + float col[4]; + col[0] = ((Value >> 16) & 0xFF) / 255.0; + col[1] = ((Value >> 8) & 0xFF) / 255.0; + col[2] = ((Value >> 0) & 0xFF) / 255.0; + col[3] = ((Value >> 24) & 0xFF) / 255.0; + + TRACE("Setting border color for %x to %lx\n", This->StateBlock.textureDimensions[Stage], Value); + glTexParameterfv(This->StateBlock.textureDimensions[Stage], GL_TEXTURE_BORDER_COLOR, &col[0]); + checkGLcall("glTexParameteri(..., GL_TEXTURE_BORDER_COLOR, ...)"); + } + break; + /* Unhandled */ case D3DTSS_BUMPENVMAT00 : case D3DTSS_BUMPENVMAT01 : case D3DTSS_BUMPENVMAT10 : case D3DTSS_BUMPENVMAT11 : case D3DTSS_TEXCOORDINDEX : - case D3DTSS_ADDRESSU : - case D3DTSS_ADDRESSV : - case D3DTSS_BORDERCOLOR : case D3DTSS_MIPMAPLODBIAS : case D3DTSS_MAXMIPLEVEL : case D3DTSS_MAXANISOTROPY : case D3DTSS_BUMPENVLSCALE : case D3DTSS_BUMPENVLOFFSET : case D3DTSS_TEXTURETRANSFORMFLAGS : - case D3DTSS_ADDRESSW : case D3DTSS_RESULTARG : default: /* Put back later: FIXME("(%p) : stub, Stage=%ld, Type=%d, Value =%ld\n", This, Stage, Type, Value); */ Index: dlls/d3d8/directx.c =================================================================== RCS file: /home/wine/wine/dlls/d3d8/directx.c,v retrieving revision 1.11 diff -u -r1.11 directx.c --- dlls/d3d8/directx.c 7 Jan 2003 20:36:30 -0000 1.11 +++ dlls/d3d8/directx.c 10 Jan 2003 23:43:50 -0000 @@ -316,8 +326,8 @@ pCaps->DestBlendCaps = 0; pCaps->AlphaCmpCaps = 0; pCaps->ShadeCaps = D3DPSHADECAPS_SPECULARGOURAUDRGB | D3DPSHADECAPS_COLORGOURAUDRGB ; - pCaps->TextureCaps = D3DPTEXTURECAPS_ALPHA | D3DPTEXTURECAPS_ALPHAPALETTE | D3DPTEXTURECAPS_CUBEMAP | D3DPTEXTURECAPS_POW2 | D3DPTEXTURECAPS_VOLUMEMAP; + pCaps->TextureCaps = D3DPTEXTURECAPS_ALPHA | D3DPTEXTURECAPS_ALPHAPALETTE | D3DPTEXTURECAPS_CUBEMAP | D3DPTEXTURECAPS_POW2 | D3DPTEXTURECAPS_VOLUMEMAP | D3DPTEXTURECAPS_MIPMAP; pCaps->TextureFilterCaps = 0; pCaps->CubeTextureFilterCaps = 0; pCaps->VolumeTextureFilterCaps = 0;