Stefan Dösinger : wined3d: Store the pixel format in the texture.

Alexandre Julliard julliard at wine.codeweavers.com
Wed Mar 21 17:02:50 CDT 2007


Module: wine
Branch: master
Commit: 2cdbd9a53d378e7253fbb54002ed056c59e171e4
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=2cdbd9a53d378e7253fbb54002ed056c59e171e4

Author: Stefan Dösinger <stefan at codeweavers.com>
Date:   Tue Mar 20 23:01:15 2007 +0100

wined3d: Store the pixel format in the texture.

---

 dlls/wined3d/device.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
index da1b8c9..7863714 100644
--- a/dlls/wined3d/device.c
+++ b/dlls/wined3d/device.c
@@ -823,6 +823,8 @@ 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);
@@ -896,6 +898,7 @@ 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) {
@@ -1011,6 +1014,7 @@ 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) {




More information about the wine-cvs mailing list