GL: Fixed depth/stencil attachemnt logic.
This commit is contained in:
parent
8725acb200
commit
d0b4657e15
@ -1051,18 +1051,18 @@ namespace bgfx { namespace gl
|
||||
if (isDepth(_format) )
|
||||
{
|
||||
const ImageBlockInfo& info = getBlockInfo(_format);
|
||||
if (0 < info.stencilBits)
|
||||
{
|
||||
attachment = GL_DEPTH_STENCIL_ATTACHMENT;
|
||||
}
|
||||
else if (0 == info.depthBits)
|
||||
if (0 == info.depthBits)
|
||||
{
|
||||
attachment = GL_STENCIL_ATTACHMENT;
|
||||
}
|
||||
else
|
||||
else if (0 == info.stencilBits)
|
||||
{
|
||||
attachment = GL_DEPTH_ATTACHMENT;
|
||||
}
|
||||
else
|
||||
{
|
||||
attachment = GL_DEPTH_STENCIL_ATTACHMENT;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user