Commit Graph

714 Commits

Author SHA1 Message Date
Henri Verbeet fbfc7c9742 wined3d: Remove the width and height fields from IWineD3DTextureImpl. 2009-03-13 11:28:55 +01:00
Henri Verbeet a139683a60 wined3d: Eliminate the heightscale field from IWineD3DSurfaceImpl. 2009-03-13 11:28:45 +01:00
Henri Verbeet e3bcc7544c wined3d: Remove the shader_color_fixup field from IWineD3DBaseTextureClass.
This is redundant now.
2009-03-12 13:09:55 +01:00
Henri Verbeet 38178541b0 wined3d: Store a pointer to the format description in the resource.
The goal is to eventually use a pointer to the format description in most
places where we currently use WINED3DFORMAT. IWineD3DSurfaceImpl for example
has copies of several fields from the format description, but also needs to
lookup the format description itself in several places.
2009-03-12 13:09:55 +01:00
Henri Verbeet e4ea7976a5 wined3d: Remove an unused field. 2009-03-12 13:09:55 +01:00
Henri Verbeet 2cc43393f0 wined3d: The adapters array should be owned by IWineD3DImpl. 2009-03-11 13:03:32 +01:00
Henri Verbeet 67da604eca wined3d: Get rid of a few stack buffers. 2009-03-10 12:07:02 +01:00
Henri Verbeet 695c69f6a0 wined3d: Use shader_glsl_get_write_mask_size() to calculate the write mask size. 2009-03-09 14:39:48 +01:00
Henri Verbeet 362bc0d694 wined3d: Don't compare const_num against -1. 2009-03-09 14:39:39 +01:00
Henri Verbeet 4ff5736edf wined3d: Don't compare texUnitMap entries to -1. 2009-03-09 14:39:34 +01:00
Henri Verbeet aa3027a604 wined3d: Merge IWineD3DVertexBuffer with IWineD3DBuffer.
That still leaves IWineD3DIndexBuffer, but that code is also mostly similar,
except for the conversion code (which will be unused there).
2009-03-06 15:35:58 +01:00
Henri Verbeet 702eeb6b0c wined3d: Add separate methods for setting the primitive type. 2009-03-05 16:16:25 +01:00
Henri Verbeet 17e12611b8 wined3d: Fix some prototypes. 2009-03-05 16:16:24 +01:00
Henri Verbeet 602bb1f551 wined3d: Pass the vertex count rather than the primitive count to wined3d draw methods. 2009-03-05 16:16:24 +01:00
Stefan Dösinger 5cf764aec2 wined3d: Put the color_correction calls into the instruction handlers.
The color correction cannot be done behind the back of the individual
instruction handlers because it might conflict with the instruction's
color modifications and the D3D provided writemask.
2009-02-27 13:14:23 +01:00
Henri Verbeet c796f76483 wined3d: Add IWineD3DRendertargetView. 2009-02-24 16:57:29 +01:00
Henri Verbeet 399d992a07 wined3d: Add IWineD3DBuffer, use it in d3d10core. 2009-02-23 12:20:45 +01:00
Francois Gouget 5b60258f0d wined3d: Make debug{fixup_channel_source,yuv_fixup}() static. 2009-02-18 12:17:38 +01:00
Stefan Dösinger 4386a827e9 wined3d: Pass the requested srgb flag to PreLoad.
Add a new wined3d-internal PreLoad function to textures and surfaces
that takes a parameter specifying wether the rgb or srgb texture
should be loaded.
2009-02-17 12:51:36 +01:00
Stefan Dösinger 68c251f327 wined3d: Add a debug function for surface locations. 2009-02-17 12:51:17 +01:00
Stefan Dösinger c585b4de99 wined3d: Duplicate GL textures for srgb switching.
This reduces the number of srgb switching reloads quite a lot. The only
situation in which a reload is needed is if the rgb copy is modified on the GL
side and the srgb copy is needed.
2009-02-17 12:48:05 +01:00
Stefan Dösinger 8dcd51286d WineD3D: Put vertex shader duplication infrastructure in place. 2009-02-11 12:21:25 +01:00
Stefan Dösinger 50109aa969 wined3d: Get rid of last_was_foggy_shader & friends.
The fog settings do not depend on wether the shader writes to oFog or not,
instead they depend on the FOGVERTEXMODE and FOGTABLEMODE settings, and if a
vertex shader is bound at all.

It works the same way as with the fixed function, and having a vertex shader
is the same as using pretransformed vertices, just that the fog coord comes
from the shader instead of the specular color:

FOGTABLEMODE != NONE: The Z coord is used, oFog is ignored
FOGTABLEMODE == NONE, with VS: oFog is used
FOGTABLEMODE == NONE, no VS, XYZ: Z is used
FOGTABLEMODE == NONE, no VS, XYZRHW: diffuse color is used
2009-01-20 12:45:40 +01:00
Stefan Dösinger 3c3272dc41 wined3d: Don't single-allocate new gl shaders. 2009-01-20 12:45:09 +01:00
Henri Verbeet a966293f59 wined3d: Add an IWineD3DDeviceParent interface.
Other than being a bit nicer than passing function pointers all over the
place, this helps dxgi/d3d10. While the swapchain itself is created in dxgi,
its surfaces are constructed in d3d10core, which makes it impractical for dxgi
to pass the appropriate function pointers.
2009-01-16 13:29:32 +01:00
Henri Verbeet 9440dfedf4 wined3d: Remove AddDirtyRect() from the public interface. 2009-01-14 13:51:00 +01:00
Henri Verbeet fd90021666 wined3d: Remove AddDirtyBox() from the public interface.
This is an internal wined3d function.
2009-01-14 13:51:00 +01:00
Henri Verbeet e4cfbdd4f7 wined3d: Get rid of D3DCREATERESOURCEOBJECTINSTANCE. 2009-01-13 15:20:28 +01:00
Henri Verbeet 894edc49cc wined3d: Get rid of D3DCREATESHADEROBJECTINSTANCE. 2009-01-12 13:22:02 +01:00
Henri Verbeet 87627c811e wined3d: Get rid of D3DINITIALIZEBASETEXTURE. 2009-01-12 13:21:56 +01:00
Stefan Dösinger 1deafcb5a7 wined3d: Split the remains of state_fog. 2009-01-12 13:02:49 +01:00
Stefan Dösinger 2dd18635c9 wined3d: Move fogdensity and fogcolor to the fragment pipeline. 2009-01-12 13:02:29 +01:00
Allan Tong 29dd286d79 wined3d: Add code to cleanup device multistate_funcs. 2009-01-10 17:43:11 +01:00
Henri Verbeet b1812c690c wined3d: Add support for EXT_vertex_array_bgra.
This allows us to skip BGRA->RGBA color conversion for vertex attributes if
this extension is present.
2009-01-08 13:21:51 +01:00
Henri Verbeet 6791e6b752 wined3d: Simplify handling of swizzled attributes.
This should also be a little bit faster.
2009-01-08 13:21:43 +01:00
Henri Verbeet cc447eac55 wined3d: Move position_transformed out of u.s in struct WineDirect3DVertexStridedData. 2009-01-08 13:21:31 +01:00
Henri Verbeet 5f8c62e45d wined3d: Remove a redundant parameter to drawPrimitive().
startIdx should be the first index to draw, either from the vertex
array or the index array, depending on if the draw is indexed or
not. Having both at the same time wouldn't make sense.
2009-01-07 12:22:12 +01:00
Henri Verbeet bddf5e76ea wined3d: Convert textureState to a bitmap in struct SAVEDSTATES. 2009-01-06 12:45:52 +01:00
Henri Verbeet a8697d90e4 wined3d: Renumber WINED3DTEXTURESTAGESTATETYPE enum elements.
Saves some space by not having unused entries is the arrays tracking these
states.
2009-01-06 12:45:43 +01:00
Henri Verbeet fd33f0f97f wined3d: Convert samplerState to a bitmap in struct SAVEDSTATES. 2009-01-05 12:41:17 +01:00
Henri Verbeet c33b38117e wined3d: Convert renderState to a bitmap in struct SAVEDSTATES. 2009-01-05 12:41:08 +01:00
Henri Verbeet fc39831e4c wined3d: Convert transform to a bitmap in struct SAVEDSTATES. 2009-01-05 12:40:57 +01:00
Henri Verbeet 9a889f6b0b wined3d: Convert textures to a bitmap in struct SAVEDSTATES. 2009-01-03 14:55:31 +01:00
Henri Verbeet 3b5c75d991 wined3d: Convert clipplane to a bitmap in struct SAVEDSTATES. 2009-01-02 11:53:04 +01:00
Henri Verbeet 52a900d4e8 wined3d: Convert streamSource and streamFreq to bitmaps in struct SAVEDSTATES. 2009-01-02 11:52:34 +01:00
Henri Verbeet 457037f4de wined3d: Fix the value of HIGHEST_TRANSFORMSTATE.
The highest transform state should be 511.
2009-01-02 11:52:02 +01:00
Henri Verbeet 3920d42f71 wined3d: Convert some BOOLs to bitfields in struct SAVEDSTATES. 2008-12-31 12:26:57 +01:00
Henri Verbeet 29a0d06518 wined3d: Convert some BOOLs to bitfields in struct IWineD3DDeviceImpl.
Also fills a 3 byte hole.
2008-12-31 12:26:33 +01:00
Henri Verbeet 3f12f59aa4 wined3d: Convert some BOOLs to bitfields in struct WineD3DContext.
Also happens to fill two 3 byte holes.
2008-12-31 12:26:23 +01:00
Henri Verbeet 813c7ed202 wined3d: Remove an unused field from the device. 2008-12-31 12:26:02 +01:00