wined3d: Remove some redundant fields from IWineD3DBaseTextureImpl.
This commit is contained in:
parent
0b9808761f
commit
5d00923017
|
@ -419,7 +419,7 @@ static void shader_hw_sample(SHADER_OPCODE_ARG* arg, DWORD sampler_idx, const ch
|
|||
|
||||
/* Signedness correction */
|
||||
if(!GL_SUPPORT(NV_TEXTURE_SHADER3) /* Provides signed formats */ && texture) {
|
||||
WINED3DFORMAT format = texture->baseTexture.format;
|
||||
WINED3DFORMAT format = texture->resource.format;
|
||||
|
||||
if((format == WINED3DFMT_V8U8 && !GL_SUPPORT(ATI_ENVMAP_BUMPMAP)) ||
|
||||
format == WINED3DFMT_Q8W8V8U8 ||
|
||||
|
|
|
@ -191,7 +191,7 @@ DWORD WINAPI IWineD3DBaseTextureImpl_GetLevelCount(IWineD3DBaseTexture *iface) {
|
|||
HRESULT WINAPI IWineD3DBaseTextureImpl_SetAutoGenFilterType(IWineD3DBaseTexture *iface, WINED3DTEXTUREFILTERTYPE FilterType) {
|
||||
IWineD3DBaseTextureImpl *This = (IWineD3DBaseTextureImpl *)iface;
|
||||
|
||||
if (!(This->baseTexture.usage & WINED3DUSAGE_AUTOGENMIPMAP)) {
|
||||
if (!(This->resource.usage & WINED3DUSAGE_AUTOGENMIPMAP)) {
|
||||
TRACE("(%p) : returning invalid call\n", This);
|
||||
return WINED3DERR_INVALIDCALL;
|
||||
}
|
||||
|
@ -203,7 +203,7 @@ HRESULT WINAPI IWineD3DBaseTextureImpl_SetAutoGenFilterType(IWineD3DBaseTexture
|
|||
WINED3DTEXTUREFILTERTYPE WINAPI IWineD3DBaseTextureImpl_GetAutoGenFilterType(IWineD3DBaseTexture *iface) {
|
||||
IWineD3DBaseTextureImpl *This = (IWineD3DBaseTextureImpl *)iface;
|
||||
FIXME("(%p) : stub\n", This);
|
||||
if (!(This->baseTexture.usage & WINED3DUSAGE_AUTOGENMIPMAP)) {
|
||||
if (!(This->resource.usage & WINED3DUSAGE_AUTOGENMIPMAP)) {
|
||||
return WINED3DTEXF_NONE;
|
||||
}
|
||||
return This->baseTexture.filterType;
|
||||
|
|
|
@ -829,8 +829,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateTexture(IWineD3DDevice *iface, U
|
|||
object->pow2scalingFactorY = (((float)Height) / ((float)pow2Height));
|
||||
TRACE(" xf(%f) yf(%f)\n", object->pow2scalingFactorX, object->pow2scalingFactorY);
|
||||
|
||||
object->baseTexture.format = Format;
|
||||
|
||||
/* Calculate levels for mip mapping */
|
||||
if (Levels == 0) {
|
||||
TRACE("calculating levels %d\n", object->baseTexture.levels);
|
||||
|
@ -904,7 +902,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateVolumeTexture(IWineD3DDevice *ifa
|
|||
object->width = Width;
|
||||
object->height = Height;
|
||||
object->depth = Depth;
|
||||
object->baseTexture.format = Format;
|
||||
|
||||
/* Calculate levels for mip mapping */
|
||||
if (Levels == 0) {
|
||||
|
@ -1025,7 +1022,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateCubeTexture(IWineD3DDevice *iface
|
|||
/* TODO: support for native non-power 2 */
|
||||
/* Precalculated scaling for 'faked' non power of two texture coords */
|
||||
object->pow2scalingFactor = ((float)EdgeLength) / ((float)pow2EdgeLength);
|
||||
object->baseTexture.format = Format;
|
||||
|
||||
/* Calculate levels for mip mapping */
|
||||
if (Levels == 0) {
|
||||
|
|
|
@ -874,8 +874,6 @@ typedef struct IWineD3DBaseTextureClass
|
|||
{
|
||||
UINT levels;
|
||||
BOOL dirty;
|
||||
WINED3DFORMAT format;
|
||||
DWORD usage;
|
||||
UINT textureName;
|
||||
UINT LOD;
|
||||
WINED3DTEXTUREFILTERTYPE filterType;
|
||||
|
|
Loading…
Reference in New Issue