Commit Graph

201 Commits

Author SHA1 Message Date
Henri Verbeet 3b07e7059e wined3d: Add d3d10 primitive types. 2009-03-05 16:16:24 +01:00
Henri Verbeet b4830feb34 wined3d: Accept WINED3DFMT_R8G8B8A8_UNORM in getColorBits(). 2009-02-25 12:37:06 +01:00
Henri Verbeet 399d992a07 wined3d: Add IWineD3DBuffer, use it in d3d10core. 2009-02-23 12:20:45 +01:00
Henri Verbeet 8cefc47d81 wined3d: Add DXGI formats to WINED3DFORMAT. 2009-02-20 11:10:37 +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 68c251f327 wined3d: Add a debug function for surface locations. 2009-02-17 12:51:17 +01:00
Michael Stefaniuc 118c75a8c7 wined3d: Remove superfluous pointer casts. 2009-02-03 12:40:14 +01:00
Michael Stefaniuc cc6b283d3a wined3d: Remove some unused defines. 2009-02-03 12:40:12 +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
Henri Verbeet 5d875906c1 wined3d: Remove some superfluous pointer casts. 2009-01-20 12:34:05 +01:00
Henri Verbeet 45a61d1ac4 wined3d: Enable GL_HALF_FLOAT_NV when NV_HALF_FLOAT is supported.
This makes more sense than the other way around.
2009-01-08 13:21:56 +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 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 e8ba733706 wined3d: Remove unused enum elements from WINED3DTEXTURESTAGESTATETYPE. 2009-01-05 12:41:31 +01:00
Henri Verbeet 39909f2a06 wined3d: Handle WINED3DFVF_XYZW in get_flexible_vertex_size().
Spotted by Chris Robinson.
2009-01-03 14:55:31 +01:00
Andrew Talbot f9762d6082 wined3d: Remove superfluous semicolons. 2008-12-24 19:59:14 +01:00
Henri Verbeet 4a19d893e5 wined3d: Only apply shader constants that changed.
This improves performance a bit for applications that use a lot of
shaders with a lot of constants.
2008-12-20 11:11:45 +01:00
Roderick Colenbrander 086d949877 wined3d: Add GL_RG16F / GL_RG32F support using ARB_texture_rg. 2008-12-19 17:49:20 +01:00
Roderick Colenbrander 331fe08b54 wined3d: Add R32F using ARB_texture_rg. 2008-12-19 17:49:08 +01:00
Roderick Colenbrander 8cb84458d3 wined3d: Add R16F using ARB_texture_rg. 2008-12-19 17:49:02 +01:00
Henri Verbeet 7d29aecd6f wined3d: Use a simpler way to calculate the number of texture levels.
It's probably slightly faster too.
2008-12-12 11:40:39 +01:00
Henri Verbeet 70ed814b95 wined3d: Get rid of the textureDimensions field in the state block. 2008-12-12 11:40:32 +01:00
Stefan Dösinger f2f90b6965 wined3d: Fix ARG_UNUSED and use it properly.
That bug was uncovered by Henri's change of the bitfield sizes.
2008-12-11 14:07:31 +01:00
Henri Verbeet 4aa00e8a21 wined3d: Rename texture_stage_op.color_correction to texture_stage_op.color_fixup.
This is consistent with other uses of struct color_fixup_desc.
2008-12-10 10:50:24 +01:00
Stefan Dösinger e04556bb16 wined3d: Fix D3DFMT_R32F, R16F, G16R16F, ... in the pixel shader.
This allows us to drop the load time conversion and the clear
readback hack and replaces it with a color fixup in the fixed
function pipeline replacement.
2008-12-04 12:00:15 +01:00
Henri Verbeet 89139b7589 wined3d: Make shader texture format fixups more generic.
Based on a patch by Stefan Dösinger. This is more flexible, and allows
the shader backend implementation to be simpler, since it doesn't have
to know about specific formats. The next patch makes use of this.
2008-12-04 11:59:58 +01:00
Henri Verbeet b451048eb7 wined3d: Move GlPixelFormatDesc to wined3d_private.h where it belongs.
Also remove the silly typedef.
2008-12-04 11:59:06 +01:00
Henri Verbeet 5532c990b6 wined3d: Const correctness fixes. 2008-12-02 14:04:15 +01:00
Henri Verbeet eb78c2a082 wined3d: Const correctness fixes for utils.c. 2008-11-26 12:04:56 +01:00
Stefan Dösinger 33482a732e wined3d: Enable blue = 1.0 fixup for D3DFMT_V8U8.
The dx7 sdk demos need this.
2008-11-25 13:07:14 +01:00
Stefan Dösinger 5c79a9f437 wined3d: Rename the fragment ffp desc structures.
This reflects the fact that they describe the fragment pipeline.
The vertex pipeline will use its own structures.
2008-11-20 12:17:45 +01:00
Stefan Dösinger 620a423b22 wined3d: Kill the GL_ATI_envmap_bumpmap code.
GL_ATI_envmap_bumpmap provides two things: Signed V8U8 pixel formats,
and bump mapping. The extension is only supported on fglrx, and this
driver also supports GL_ARB_fragment_program.  Thus the bump mapping
code is never used on any driver out there.  Furthermore, if it is
used, it tends to crash the driver

The signed pixel format is used, as it can be used by pixel shaders or
the ARBfp replacement. However, the format is broken in fglrx, and
negative values are clamped to 0.0. This results in test
failures. WineD3D has an alternative codepath using scale+bias to
enable V8U8 using a standard signed RGB which works correctly on
fglrx.
2008-11-04 11:41:14 +01:00
Vitaliy Margolen a2b2a4cf79 wined3d: Add one more FBO error status code. 2008-10-18 19:35:20 +02:00
Alexandre Julliard 6cfef95ce7 wined3d: Convert source files to utf-8. 2008-10-18 19:21:20 +02:00
Stefan Dösinger 3b48660f43 wined3d: Implement YV12 support for emulated overlays.
This is the prefered format of many codecs, and for some codecs this
is the only supported output format. As usual I try to handle all the
conversion in the GPU and keep the CPU involvement minimal to gain the
full performance of PBO transfers.
2008-09-02 14:55:50 +02:00
Henri Verbeet b4f43e372e wined3d: Remove useless hash_table_t typedef. 2008-08-29 12:26:55 +02:00
Stefan Dösinger af8d268a39 wined3d: Handle projected textures properly in arbfp and atifs.
GL_ARB_fragment_program and GL_ATI_fragment_shader can disable
projected textures properly, and they can also handle
D3DTTFF_PROJECTED | D3DTTFF_COUNT3 properly.
2008-08-28 11:24:49 +02:00
Stefan Dösinger ec4955630e wined3d: Silence some format spam. 2008-08-28 11:24:49 +02:00
Stefan Dösinger 4635315655 wined3d: Replace a #if 0 with if(0). 2008-08-28 11:24:49 +02:00
Stefan Dösinger b294e43206 wined3d: D3DTOP_DOTPRODUCT3 colorop overrides the alphaop.
Note that the fix is only implemented in the arbfp and atifs fragment
pipeline. Unfortunately nvrc doesn't support dot3 as alpha operation.
2008-08-27 13:21:24 +02:00
Stefan Dösinger f39e122477 wined3d: Add fixed function sRGB write correction. 2008-08-25 12:25:13 +02:00
Chris Robinson 9f82368908 wined3d: Use the proper internal type for some formats. 2008-08-25 12:23:00 +02:00
H. Verbeet b917bdaa52 wined3d: Remove useless hash_table_entry_t typedef.
It doesn't add much.
2008-08-22 10:39:08 +02:00
Stefan Dösinger 46109da87d wined3d: Don't skip applying texdims with shaders.
There's no need to do that with the nvts and opengl ffp fixed function
fragment pipeline, it's perfectly well defined in GL which one takes
effect. This removes a few more troubles when switching between
shaders and arbfp.
2008-08-21 13:33:30 +02:00
Stefan Dösinger 8fe6bf0bad wined3d: Fix the unused arg marker. 2008-08-20 12:34:44 +02:00
Stefan Dösinger bfe7067973 wined3d: Ask the ffp/shader/blit implementation about format support.
If a format is not supported natively by opengl, a shader may be able
to convert it. Up to now, CheckDeviceFormat had magic knowldge which
GL extensions lead to which supported format. This patch adds
functions that allow CheckDeviceFormat to ask the actual
implementation for its capabilities.
2008-08-20 12:26:02 +02:00
Stefan Dösinger 6a24b28b75 wined3d: Support YUV formats with GL_APPLE_ycbcr_422. 2008-08-20 12:25:00 +02:00
Stefan Dösinger 228f2cf3c2 wined3d: Initialize the texture op function properly. 2008-08-04 13:07:26 +02:00
Stefan Dösinger bc4435e406 wined3d: Use a hashmap to store the ffp shaders. 2008-07-31 13:01:50 +02:00
Stefan Dösinger d4d133f032 wined3d: Use C bitfields to compact the ffp description. 2008-07-31 13:01:36 +02:00