2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-09 09:47:43 +00:00

Runtime: Collapse emplace_back() calls where applicable

Same behavior, but with less code.
This commit is contained in:
Lioncash
2020-03-13 16:32:24 -04:00
parent df4487bae8
commit 097d4a4422
18 changed files with 103 additions and 123 deletions

View File

@@ -205,8 +205,7 @@ CMoviePlayer::CMoviePlayer(const char* path, float preLoadSeconds, bool loop, bo
/* Allocate textures here (rather than at decode time) */
x80_textures.reserve(3);
for (int i = 0; i < 3; ++i) {
x80_textures.emplace_back();
CTHPTextureSet& set = x80_textures.back();
CTHPTextureSet& set = x80_textures.emplace_back();
if (deinterlace) {
/* urde addition: this way interlaced THPs don't look horrible */
set.Y[0] = ctx.newDynamicTexture(x6c_videoInfo.width, x6c_videoInfo.height / 2, boo::TextureFormat::I8,