wined3d: GL_SRC_ALPHA_SATURATE is supported as src blend param only.

This commit is contained in:
Stefan Dösinger 2007-08-12 21:38:24 +02:00 committed by Alexandre Julliard
parent 581664c006
commit 06cc0fa95f
2 changed files with 8 additions and 2 deletions

View File

@ -1945,9 +1945,11 @@ static HRESULT WINAPI IWineD3DImpl_GetDeviceCaps(IWineD3D *iface, UINT Adapter,
WINED3DPBLENDCAPS_INVSRCCOLOR | WINED3DPBLENDCAPS_INVSRCCOLOR |
WINED3DPBLENDCAPS_ONE | WINED3DPBLENDCAPS_ONE |
WINED3DPBLENDCAPS_SRCALPHA | WINED3DPBLENDCAPS_SRCALPHA |
WINED3DPBLENDCAPS_SRCALPHASAT |
WINED3DPBLENDCAPS_SRCCOLOR | WINED3DPBLENDCAPS_SRCCOLOR |
WINED3DPBLENDCAPS_ZERO; WINED3DPBLENDCAPS_ZERO;
/* NOTE: WINED3DPBLENDCAPS_SRCALPHASAT is not supported as dest blend factor,
* according to the glBlendFunc manpage
*/
*pCaps->AlphaCmpCaps = WINED3DPCMPCAPS_ALWAYS | *pCaps->AlphaCmpCaps = WINED3DPCMPCAPS_ALWAYS |
WINED3DPCMPCAPS_EQUAL | WINED3DPCMPCAPS_EQUAL |

View File

@ -285,7 +285,11 @@ static void state_blend(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3D
case WINED3DBLEND_INVDESTALPHA : dstBlend = GL_ONE_MINUS_DST_ALPHA; break; case WINED3DBLEND_INVDESTALPHA : dstBlend = GL_ONE_MINUS_DST_ALPHA; break;
case WINED3DBLEND_DESTCOLOR : dstBlend = GL_DST_COLOR; break; case WINED3DBLEND_DESTCOLOR : dstBlend = GL_DST_COLOR; break;
case WINED3DBLEND_INVDESTCOLOR : dstBlend = GL_ONE_MINUS_DST_COLOR; break; case WINED3DBLEND_INVDESTCOLOR : dstBlend = GL_ONE_MINUS_DST_COLOR; break;
case WINED3DBLEND_SRCALPHASAT : dstBlend = GL_SRC_ALPHA_SATURATE; break;
case WINED3DBLEND_SRCALPHASAT :
dstBlend = GL_SRC_ALPHA_SATURATE;
WARN("Application uses SRCALPHASAT as dest blend factor, expect problems\n");
break;
case WINED3DBLEND_BOTHSRCALPHA : dstBlend = GL_SRC_ALPHA; case WINED3DBLEND_BOTHSRCALPHA : dstBlend = GL_SRC_ALPHA;
srcBlend = GL_SRC_ALPHA; srcBlend = GL_SRC_ALPHA;