Add an IsDepthFormat helper function

Trac #20875 Signed-off-by: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@1111 736b8ea6-26fd-11df-bfd4-992fa37f6226
parent 08bfcc47
...@@ -993,6 +993,16 @@ bool IsFloat16Format(D3DFORMAT surfaceFormat) ...@@ -993,6 +993,16 @@ bool IsFloat16Format(D3DFORMAT surfaceFormat)
return false; return false;
} }
bool IsDepthFormat(D3DFORMAT surfaceFormat)
{
return (surfaceFormat == D3DFMT_INTZ);
}
bool IsStencilFormat(D3DFORMAT surfaceFormat)
{
return (surfaceFormat == D3DFMT_INTZ);
}
GLsizei GetSamplesFromMultisampleType(D3DMULTISAMPLE_TYPE type) GLsizei GetSamplesFromMultisampleType(D3DMULTISAMPLE_TYPE type)
{ {
if (type == D3DMULTISAMPLE_NONMASKABLE) if (type == D3DMULTISAMPLE_NONMASKABLE)
......
...@@ -83,6 +83,8 @@ GLuint GetDepthSize(D3DFORMAT depthFormat); ...@@ -83,6 +83,8 @@ GLuint GetDepthSize(D3DFORMAT depthFormat);
GLuint GetStencilSize(D3DFORMAT stencilFormat); GLuint GetStencilSize(D3DFORMAT stencilFormat);
bool IsFloat32Format(D3DFORMAT surfaceFormat); bool IsFloat32Format(D3DFORMAT surfaceFormat);
bool IsFloat16Format(D3DFORMAT surfaceFormat); bool IsFloat16Format(D3DFORMAT surfaceFormat);
bool IsDepthFormat(D3DFORMAT surfaceFormat);
bool IsStencilFormat(D3DFORMAT surfaceFormat);
GLsizei GetSamplesFromMultisampleType(D3DMULTISAMPLE_TYPE type); GLsizei GetSamplesFromMultisampleType(D3DMULTISAMPLE_TYPE type);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment