Henri Verbeet
048c9450d9
wined3d: Use the actual array sizes to determine the number of the various pixel/vertex states.
2009-10-02 11:53:09 +02:00
Henri Verbeet
8b3f868774
wined3d: Move the pixel/vertex states arrays to stateblock.c.
2009-10-02 11:53:03 +02:00
Henri Verbeet
a84974e2ea
wined3d: Fix the values of NUM_SAVEDPIXELSTATES_T and NUM_SAVEDVERTEXSTATES_R.
2009-10-02 11:52:54 +02:00
Henri Verbeet
15d4eee58b
wined3d: Use stateblock_init_contained_states() for WINED3DSBT_VERTEXSTATE stateblocks.
2009-10-02 11:52:49 +02:00
Henri Verbeet
d500c9b795
wined3d: Add a separate function to initialize the saved states for WINED3DSBT_VERTEXSTATE.
2009-10-02 11:52:43 +02:00
Stefan Dösinger
c749debec6
wined3d: Fix an error string.
2009-10-01 12:10:35 +02:00
Henri Verbeet
93c949eba5
wined3d: Use stateblock_init_contained_states() for WINED3DSBT_PIXELSTATE stateblocks.
2009-10-01 12:03:55 +02:00
Henri Verbeet
5a01619d31
wined3d: Add a separate function to initialize the saved states for WINED3DSBT_PIXELSTATE.
2009-10-01 12:03:49 +02:00
Henri Verbeet
841afe485e
wined3d: Use stateblock_init_contained_states() for WINED3DSBT_ALL stateblocks.
2009-10-01 12:03:34 +02:00
Henri Verbeet
c5029f83ec
wined3d: Simplify stateblock_savedstates_set().
...
We only need to handle the case where "value" is TRUE, since the stateblock
data will be filled with zeroes by default.
2009-10-01 12:03:28 +02:00
Henri Verbeet
75fe879c76
wined3d: Get rid of stateblock_savedstates_copy().
...
This is redundant because we call stateblock_savedstates_set() further down.
2009-10-01 12:03:21 +02:00
Henri Verbeet
be0b7355fc
wined3d: Add a separate function for initializing the "contained_*" fields from the "changed" field.
2009-09-30 14:31:59 +02:00
Henri Verbeet
5f3425b89b
wined3d: Get rid of stateblock_copy().
2009-09-30 14:31:59 +02:00
Henri Verbeet
345b329217
wined3d: Add a separate function for copying stateblock values.
2009-09-30 14:31:58 +02:00
Henri Verbeet
844dda20ff
wined3d: Make some internal stateblock function arguments const.
2009-09-30 14:31:58 +02:00
Henri Verbeet
5737efe71a
wined3d: Explicitly pass gl_info to stateblock_savedstates_set().
2009-09-30 14:31:58 +02:00
Henri Verbeet
49f712beff
wined3d: Explicitly pass gl_info to stateblock_savedstates_copy().
2009-09-29 14:22:34 +02:00
Henri Verbeet
6d3e5a9cce
wined3d: Pass IWineD3DStateBlockImpl pointers to stateblock_copy().
2009-09-29 14:22:34 +02:00
Henri Verbeet
4ed126f5dc
wined3d: Clear the correct "activeLights" array in stateblock_copy().
2009-09-29 14:22:34 +02:00
Henri Verbeet
664057ce6a
wined3d: Add a separate function for state block initialization.
2009-09-29 14:22:34 +02:00
Henri Verbeet
6a7b97b617
wined3d: Fix a typo.
2009-09-29 14:22:34 +02:00
Stefan Dösinger
404aecb8da
wined3d: Test if result.clip[] works correctly.
...
The Mac Nvidia driver doesn't implement the result.clip part of
GL_NV_vertex_program2_option correctly. It complains about a syntax
error if "result.clip[0]" is used. "result.clip" compiles correctly, but
supports only one clipplane, and running the shader results in severe
rendering bugs.
2009-09-28 17:33:07 +02:00
Stefan Dösinger
77a83aee79
wined3d: Don't use GL_NV_texture_shader on OSX.
2009-09-28 17:32:54 +02:00
Henri Verbeet
f9786d7eda
wined3d: Just use the actual array size as argument to memcpy() in stateblock_copy().
2009-09-28 12:38:39 +02:00
Henri Verbeet
26db0be136
wined3d: Cleanup IWineD3DDeviceImpl_SetTexture() a bit.
2009-09-28 12:38:32 +02:00
Henri Verbeet
f6bf219013
wined3d: Remove some redundant code in IWineD3DVertexDeclarationImpl_Release().
...
The situation the code tests for should never happen because either the
stateblock will still have a reference to the vertex declaration, or the
stateblock itself will be released.
2009-09-28 12:38:25 +02:00
Henri Verbeet
dca3c6e7c6
wined3d: Keep vertex declaration references in the stateblock.
2009-09-28 12:38:18 +02:00
Henri Verbeet
709aedf5f9
wined3d: Properly keep texture references in the stateblock.
2009-09-28 12:38:12 +02:00
Henri Verbeet
cd96c6e355
wined3d: Release the stateblock before destroying the GL context.
2009-09-25 15:15:49 +02:00
Henri Verbeet
47c84f4f7f
wined3d: Use the DXGI naming convention for all formats.
2009-09-25 15:15:44 +02:00
Henri Verbeet
a25ac586c6
wined3d: Add a state handler for WINED3DRS_SOFTWAREVERTEXPROCESSING.
2009-09-25 15:15:08 +02:00
Henri Verbeet
c64da00de7
wined3d: Rename IWineD3DDevice::GetIndices() to IWineD3DDevice::GetIndexBuffer().
2009-09-25 15:14:52 +02:00
Henri Verbeet
60e32659a7
wined3d: Rename IWineD3DDevice::SetIndices() to IWineD3DDevice::SetIndexBuffer().
2009-09-25 15:14:44 +02:00
Henri Verbeet
f88c6e5ce5
wined3d: Move common shader fields to IWineD3DBaseShaderClass.
2009-09-25 15:14:35 +02:00
Henri Verbeet
77086e8e84
wined3d: Remove SetFunction() from the public shader interface.
2009-09-25 15:14:26 +02:00
Henri Verbeet
d76c7a8521
wined3d: Move some common shader functions to the IWineD3DBaseShader interface.
2009-09-25 15:14:17 +02:00
Austin English
5d15da6df5
wined3d: Recognize DRI R300 drivers as Mesa.
2009-09-25 13:15:48 +02:00
Henri Verbeet
789372afa8
wined3d: Don't free D3D pixel shaders until the wined3d pixel shader is destroyed.
2009-09-24 13:24:53 +02:00
Henri Verbeet
8aea1b1302
wined3d: Add a separate function for pixel shader initialization.
2009-09-24 13:24:27 +02:00
Henri Verbeet
ca05ef5dd0
wined3d: Don't free D3D vertex shaders until the wined3d vertex shader is destroyed.
2009-09-24 13:24:19 +02:00
Henri Verbeet
462decdfb9
wined3d: Add a separate function for vertex shader initialization.
2009-09-24 13:23:51 +02:00
Henri Verbeet
5ac3ed7f73
wined3d: Remove unused IWineD3DVertexShaderImpl fields.
2009-09-24 13:23:44 +02:00
Stefan Dösinger
4fe014cb54
wined3d: Fix sRGB->RGB copy condition.
...
The old condition happened to work, because SFLAG_INTEXTURE was not
set(we're loading it), and neither was SFLAG_INDRAWABLE(otherwise
INTEXTURE would be set too). If the fbo INDRAWABLE == INTEXTURE is
replaced by INDRAWABLE == INSRGBTEX this doesn't hold true any longer
because SFLAG_INDRAWABLE is set, but not used because the drawable
readback is never used for fbos.
2009-09-23 13:25:33 +02:00
Stefan Dösinger
33ca3c0207
wined3d: Don't mark SFLAG_INTEXTURE up to date with fbo stretchrect.
...
FBO stretchrect marks SFLAG_INDRAWABLE up to date, which currently
also marks SFLAG_INTEXTURE up to date. However, this will change when
we enable rendering to the srgb copy, in which case the drawable could
be equal to the srgb copy, not the rgb copy.
2009-09-23 13:25:21 +02:00
Stefan Dösinger
ba6fac697a
wined3d: Create a separate function for deleting GL textures.
2009-09-23 13:25:02 +02:00
Stefan Dösinger
529e6737d3
wined3d: Use the correct enum.
2009-09-23 13:24:25 +02:00
Stefan Dösinger
5b5e3bd0d2
wined3d: Track GL texture states in a separate structure.
2009-09-23 13:24:16 +02:00
Henri Verbeet
1c93ab1ee0
wined3d: Cleanup after wglMakeCurrent() failures in context_set_current().
...
The D3D context is potentially destroyed, so we need to clear the thread's
current D3D context. Found by Rico Schüller.
2009-09-23 12:37:25 +02:00
Henri Verbeet
eca28c942d
wined3d: Add support for ARB_provoking_vertex.
...
This is just EXT_provoking_vertex promoted to ARB.
2009-09-23 12:37:18 +02:00
Henri Verbeet
a0de42db13
wined3d: Fix a typo.
2009-09-23 12:37:12 +02:00