mirror of
https://github.com/bkaradzic/bgfx.git
synced 2026-02-17 20:52:36 +01:00
Replaced strmb with strFindBlock.
This commit is contained in:
@@ -5463,8 +5463,8 @@ BX_TRACE("%d, %d, %d, %s", _array, _srgb, _mipAutogen, getName(_format) );
|
||||
bx::StringView brace = bx::strFind(entry, "{");
|
||||
if (!brace.isEmpty() )
|
||||
{
|
||||
const char* end = bx::strmb(brace.getPtr(), '{', '}');
|
||||
if (NULL != end)
|
||||
bx::StringView block = bx::strFindBlock(bx::StringView(brace.getPtr(), shader.getTerm() ), '{', '}');
|
||||
if (!block.isEmpty() )
|
||||
{
|
||||
strins(const_cast<char*>(brace.getPtr()+1), "\n float bgfx_FragDepth = 0.0;\n");
|
||||
}
|
||||
|
||||
@@ -1686,10 +1686,10 @@ namespace bgfx
|
||||
bx::StringView brace = bx::strFind(bx::StringView(entry.getPtr(), shader.getTerm() ), "{");
|
||||
if (!brace.isEmpty() )
|
||||
{
|
||||
const char* end = bx::strmb(brace.getPtr(), '{', '}');
|
||||
if (NULL != end)
|
||||
bx::StringView block = bx::strFindBlock(bx::StringView(brace.getPtr(), shader.getTerm() ), '{', '}');
|
||||
if (!block.isEmpty() )
|
||||
{
|
||||
strInsert(const_cast<char*>(end), "__RETURN__;\n");
|
||||
strInsert(const_cast<char*>(block.getTerm() ), "__RETURN__;\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user