tweak StringOutputStream use

auto str = StringOutputStream()(bla) use form was not doing copy elision or move, but copy
This commit is contained in:
Garux
2024-01-29 16:54:08 +06:00
parent b4e44bc8ed
commit df02774ff5
122 changed files with 984 additions and 1204 deletions

View File

@@ -250,9 +250,9 @@ void MD2Surface_read( Model& model, const byte* buffer, ArchiveFile& file ){
}
path[i] = '\0';
}
// globalErrorStream() << "modified skinname: " << path << " (path) and " << skinnameRelative << " (texture)" << "\n";
// globalErrorStream() << "modified skinname: " << path << " (path) and " << skinnameRelative << " (texture)" << '\n';
snprintf( skinname, MD2_MAX_SKINNAME, "%s%s", path, &skinnameRelative[1] );
// globalErrorStream() << skinname << "\n";
// globalErrorStream() << skinname << '\n';
}
else
{

View File

@@ -65,7 +65,7 @@ inline VertexPointer vertexpointer_arbitrarymeshvertex( const ArbitraryMeshVerte
}
inline void parseTextureName( CopiedString& name, const char* token ){
name = StringOutputStream( 256 )( PathCleaned( PathExtensionless( token ) ) ).c_str(); // remove extension
name = StringStream<64>( PathCleaned( PathExtensionless( token ) ) ); // remove extension
}
// generic renderable triangle surface