wined3d: Add GL_RG16F / GL_RG32F support using ARB_texture_rg.

This commit is contained in:
Roderick Colenbrander 2008-12-18 23:00:02 +01:00 committed by Alexandre Julliard
parent 331fe08b54
commit 086d949877
2 changed files with 6 additions and 2 deletions

View File

@ -2361,6 +2361,10 @@ static BOOL CheckTextureCapability(UINT Adapter, WINED3DDEVTYPE DeviceType, WINE
case WINED3DFMT_G16R16F:
case WINED3DFMT_G32R32F:
if(GL_SUPPORT(ARB_TEXTURE_RG)) {
TRACE_(d3d_caps)("[OK]\n");
return TRUE;
}
TRACE_(d3d_caps)("[FAILED]\n");
return FALSE;

View File

@ -167,7 +167,7 @@ static const GlPixelFormatDescTemplate gl_formats_template[] = {
/* IEEE formats */
{WINED3DFMT_R32F ,GL_RGB32F_ARB ,GL_RGB32F_ARB , 0, GL_RED ,GL_FLOAT
,WINED3DFMT_FLAG_RENDERTARGET },
{WINED3DFMT_G32R32F ,0 ,0 , 0, 0 ,0
{WINED3DFMT_G32R32F ,GL_RG32F ,GL_RG32F , 0, GL_RG ,GL_FLOAT
,WINED3DFMT_FLAG_RENDERTARGET },
{WINED3DFMT_A32B32G32R32F ,GL_RGBA32F_ARB ,GL_RGBA32F_ARB , 0, GL_RGBA ,GL_FLOAT
,WINED3DFMT_FLAG_RENDERTARGET },
@ -177,7 +177,7 @@ static const GlPixelFormatDescTemplate gl_formats_template[] = {
/* Float */
{WINED3DFMT_R16F ,GL_RGB16F_ARB ,GL_RGB16F_ARB , 0, GL_RED ,GL_HALF_FLOAT_ARB
,WINED3DFMT_FLAG_FILTERING | WINED3DFMT_FLAG_RENDERTARGET },
{WINED3DFMT_G16R16F ,0 ,0 , 0, 0 ,0
{WINED3DFMT_G16R16F ,GL_RG16F ,GL_RG16F , 0, GL_RG ,GL_HALF_FLOAT_ARB
,WINED3DFMT_FLAG_FILTERING | WINED3DFMT_FLAG_RENDERTARGET },
{WINED3DFMT_A16B16G16R16F ,GL_RGBA16F_ARB ,GL_RGBA16F_ARB , 0, GL_RGBA ,GL_HALF_FLOAT_ARB
,WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING | WINED3DFMT_FLAG_FILTERING | WINED3DFMT_FLAG_RENDERTARGET },