Commit graph

46 commits

Author SHA1 Message Date
Stefan Dösinger
851bdfb5e0 wined3d: Add D3DLOCK_* types to wined3d_types.h. 2006-03-08 11:33:35 +01:00
Stefan Dösinger
270afeb5e8 wined3d: Define D3D usage flags in wined3d_types.h. 2006-03-07 10:53:02 +01:00
Stefan Dösinger
2f0c781988 wined3d: Add device caps to wined3d_types.h. 2006-03-07 10:51:34 +01:00
H. Verbeet
f7356a34c3 wined3d: Fix the relation between surfaces and their container. 2006-03-06 20:08:22 +01:00
H. Verbeet
fd2739b023 wined3d: Don't call glCompressedTexImage2DARB without allocatedMemory.
Don't call glCompressedTexImage2DARB if we haven't got allocatedMemory (yet).
Fix a small typo.
2006-03-06 20:01:05 +01:00
H. Verbeet
7d97f29c24 wined3d: Don't use GetDevice in IWineD3DSurfaceImpl_GetContainer, as
it adds a reference to the device that shouldn't be there.
2006-02-27 12:20:09 +01:00
Stefan Dösinger
46e8d67787 wined3d: Update the glOrtho between 2 rhw draws if the viewport was changed. 2006-02-13 13:25:21 +01:00
H. Verbeet
7a4b59b0c2 wined3d: Don't keep a reference to the container, as it creates a
circular reference.
2006-02-13 13:23:58 +01:00
H. Verbeet
bac34c35aa wined3d: Release the container during surface / volume cleanup. 2006-02-10 14:52:20 +01:00
H. Verbeet
2200f3e2ca wined3d/d3d9: Cleanup GetContainer for surfaces. 2006-02-07 12:25:59 +01:00
Roderick Colenbrander
694efd7c6f wined3d: Texture fixes.
Set video memory capabilities, add some checks to SetTexture and
update some comments.
2006-02-06 20:57:42 +01:00
H. Verbeet
bd8db45e44 wined3d: Update the QueryInterface functions of IWineD3DBase subclasses. 2006-02-06 11:32:41 +01:00
H. Verbeet
e43cfb1a68 wined3d: Fix SetContainer.
Add/Release references to the container.
Change the type of the container from IUnknown to IWineD3DBase.
2006-02-06 11:30:48 +01:00
Raphael Junqueira
ee5d72b136 wined3d: Added support for WINED3DFMT_X4R4G4B4. 2005-12-31 13:13:34 +01:00
Francois Gouget
5127dc9f49 Assorted spelling fixes. 2005-12-02 16:15:09 +01:00
Francois Gouget
6d442aeb34 Assorted spelling fixes. 2005-11-23 20:14:43 +01:00
Francois Gouget
0edbaf7e80 Remove spaces before '\n' in traces. 2005-11-10 12:14:56 +00:00
Francois Gouget
f4c0524ec6 Assorted spelling and case fixes. 2005-11-10 11:39:07 +00:00
Oliver Stieber
d6fcc69ddb Implement D3DFMT_UNKNOWN surfaces, this seems to be used a lot in d3d8
but I haven't found any d3d9 application that uses D3DFMT_UNKNOWN
surfaces yet.
2005-11-02 20:01:54 +00:00
Oliver Stieber
effc262f9f Added support for backbuffer with the formats A1R5G5B5 and X1R5G5B5. 2005-09-29 10:31:43 +00:00
Oliver Stieber
c99a3fafef Change the format of surface_SaveSnapshot to TGA from PPM and add
support for compressed textures and an alpha channel.
2005-09-27 10:49:59 +00:00
Oliver Stieber
2b8a7dca38 Correct a problem with locking nonpower 2 back and front buffers. 2005-09-27 09:32:29 +00:00
Oliver Stieber
9e6957bbdc Optionally repack nonpower 2 textures to the expected span length when
a textures is locked. This is necessary for buggy games like Warhammer
40k that don't work with the odd span sizes produce by default
nonpower 2 support.
2005-09-23 11:08:03 +00:00
Karsten Elfenbein
13fc2f88d6 Added A2R10G10B10 and D3DFMT_D24FS8 modes to all other functions. 2005-09-07 09:25:26 +00:00
Oliver Stieber
33b2c1fd3c Added support for DXT2 and DXT4. 2005-08-29 12:20:02 +00:00
Oliver Stieber
6b91f5b31c Set the apha channel to opaque when locking X8R8G8B8 backbuffers. 2005-08-03 21:17:08 +00:00
Mike McCormack
c6602b406b Signed warning fixes. 2005-07-28 18:33:26 +00:00
Oliver Stieber
52b5842f70 Remove a load of IWineD3DSurface * casts that are no longer required. 2005-07-26 18:56:18 +00:00
Francois Gouget
bd19d67ad1 Assorted spelling fixes. 2005-07-22 09:06:03 +00:00
Oliver Stieber
9253e0e39c Tidy up some comments and formatting. 2005-07-13 14:15:54 +00:00
Oliver Stieber
6a032491d3 Added basic memory management and tracking to wined3d. 2005-07-13 11:34:55 +00:00
Oliver Stieber
9f7e794ca6 Implement UpdateTexture and UpdateSurface in wined3d.
Allow NULL members of WINED3DSURFACE_DESC to be set to Surface_GetDesc
so that the whole structure doesn't have to be filled just to get back
one value.
2005-07-12 17:02:47 +00:00
Oliver Stieber
13621056db Move parameters relating to opengl on the surface structure on to a
glDesciption member.
Removed Level and Target from LoadTexture, and reduced the dependency
on surface->device.
Fixed a couple of compiler warnings in d3d9.
2005-07-11 20:38:27 +00:00
Oliver Stieber
520c2f0870 Implemented basic non-power 2 texture in wined3d.
Also fixed a typo in drawprim that was causing vertex declarations to
crash.
2005-07-11 14:25:54 +00:00
Francois Gouget
28dc5a8afc Assorted spelling fixes. 2005-07-11 10:59:41 +00:00
Oliver Stieber
8a6799d47d Implement render targets using either textures, swapchains or
standalone surfaces.
2005-07-07 20:35:05 +00:00
Dmitry Timoshkov
eba47f1dfe Make remaining OLE interface vtables const. 2005-06-06 19:50:35 +00:00
Oliver Stieber
67f2ad4563 - Volume now inherits Resource. This isn't the way Microsoft implements
the interface but it is more correct way (Microsoft even have a
  resource type of volume).
- Moved usage, format, allocatedMemory and size onto the resource
  class structure.
- Refactored Preload for classes that inherit BaseTexture, preload now
  binds the texture instead of bind texture calling preload, bindTexture
  allocated a glTexture if there isn't one.
- Added two new class static members BaseTexture_CleanUp and
  Resource_CleanUp that should be called by classes that implement
  BaseTexture or Resource.
2005-03-29 19:01:00 +00:00
Jakob Eriksson
9ed61de9a2 Get rid of HeapAlloc casts. 2005-03-24 21:01:35 +00:00
Oliver Stieber
ba5eb14768 Encapsulate texture, surface encapsulated.
Added BindTexture, GetTextureDimensions, UnBindTexture.
Proper GetContainer support for surface.
SetContainer added to surface and volume.
SetInPbufferState added to surface (until gl context management is
implemented).
Minor changes:
- BaseTexture no longer 'holds' a reference to IWineD3DDevice to
  prevent circular referencing.
- Better managment of referinging for texture.
- Some TODO's for implementing a context manager.
- Better preload implementation.
- Fix compile warning in device.c Set/GetSamplerState.
- Add QueryInterface support for surface.
- Format X8R8G8B8 added to locking.
2005-03-14 10:12:52 +00:00
Oliver Stieber
7b261656fd Added a stubbed out version of query to d3d9 and wined3d.
Update the d3d9 headers and creates wined3d types where d3d9 and d3d8
are incompatible.
2005-03-03 13:57:15 +00:00
Oliver Stieber
2121f7831e Put all the stubs in wined3d in place, with some functionality copied
across from d3d9.
Make sure all d3d9 device function call their wined3d counterpart (or
perform a function).
2005-03-02 12:16:10 +00:00
Joris Huizer
8a6295a057 Get rid of some TRACE(..., This->resource.ref). 2005-01-19 16:59:01 +00:00
Jason Edmeades
33025b203c - Handle failures to allocate storage more gracefully.
- Only prototype the interfaces which are subclassed (I overdid it
  last time!).
- Implement Get/Set Texture and GetBackBuffer, plus device's
  GetDisplayMode / GetDeviceCaps.
- Make some of the d3d9 skeleton code issue fixme's to highlight code
  which hasn't been migrated yet.
- Correct the d3d9 headers for D3DSURFACE_DESC which caused stack
  corruption in demos.
2005-01-18 11:42:29 +00:00
Jason Edmeades
bcecddc084 - Add texture support for all the texture types for d3d9->wined3d.
- Add prototypes for the COM interfaces.
- Fix some incorrect types from the last patch.
2005-01-17 13:44:57 +00:00
Jason Edmeades
41427857b1 Add render target support, and ensure there is a front and back buffer
created during device creation.
2005-01-09 17:37:02 +00:00