diff --git a/apps/openmw_test_suite/nifosg/testnifloader.cpp b/apps/openmw_test_suite/nifosg/testnifloader.cpp index 3c13cb1f79..24b2de30ae 100644 --- a/apps/openmw_test_suite/nifosg/testnifloader.cpp +++ b/apps/openmw_test_suite/nifosg/testnifloader.cpp @@ -10,9 +10,6 @@ #include #include -#include -#include - #include #include @@ -55,7 +52,7 @@ namespace { if (line.starts_with('#')) continue; - boost::trim_right(line); + line.erase(line.find_last_not_of(" \t\n\r\f\v") + 1); result += line; result += '\n'; } @@ -113,7 +110,8 @@ osg::Group { std::string formatOsgNodeForShaderProperty(std::string_view shaderPrefix) { - static constexpr const char format[] = R"( + std::ostringstream oss; + oss << R"( osg::Group { UniqueID 1 DataVariance STATIC @@ -144,7 +142,8 @@ osg::Group { osg::StringValueObject { UniqueID 7 Name "shaderPrefix" - Value "%s" + Value ")" + << shaderPrefix << R"(" } osg::BoolValueObject { UniqueID 8 @@ -163,7 +162,7 @@ osg::Group { } } )"; - return (boost::format(format) % shaderPrefix).str(); + return oss.str(); } struct ShaderPrefixParams