wined3d: Check for float texture formats correctly.

Dmitry Timoshkov dmitry at codeweavers.com
Tue Mar 20 22:05:57 CDT 2007


"Vitaly Budovski" <vbudovski at gmail.com> wrote:

> @@ -1662,6 +1662,20 @@ static HRESULT WINAPI IWineD3DImpl_Check
>             case WINED3DFMT_P8:
>                 TRACE_(d3d_caps)("[OK]\n");
>                 return WINED3D_OK;
> +            case WINED3DFMT_R16F:
> +            case WINED3DFMT_A16B16G16R16F:
> +                if (!GL_SUPPORT(ARB_HALF_FLOAT_PIXEL)) {
> +                    TRACE_(d3d_caps)("[FAILED]\n");
> +                    return WINED3DERR_NOTAVAILABLE;
> +                }

I realize that in the original chunk of code there is no a comment
/* fall through */ either, but if it's really an intent please add it.

> +            case WINED3DFMT_R32F:
> +            case WINED3DFMT_A32B32G32R32F:
> +                if (!GL_SUPPORT(ARB_TEXTURE_FLOAT)) {
> +                    TRACE_(d3d_caps)("[FAILED]\n");
> +                    return WINED3DERR_NOTAVAILABLE;
> +                }
> +                TRACE_(d3d_caps)("[OK]\n");
> +                return WINED3D_OK;


-- 
Dmitry.



More information about the wine-devel mailing list