From 77a4319ad054a0de39d37d2c49b462dbbb3b6c8b Mon Sep 17 00:00:00 2001 From: Yakim3396 Date: Tue, 8 Dec 2020 20:46:25 +0300 Subject: [PATCH] Fix face mirroring use std::swap --- src/model/model.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/model/model.cpp b/src/model/model.cpp index 54a9897..1d0f307 100644 --- a/src/model/model.cpp +++ b/src/model/model.cpp @@ -140,12 +140,8 @@ void vertex::load(const buffer &b, uint32_t flags) void face::load(const buffer &b) { - uint16_t lvertex_list[3]; - READ(b, lvertex_list); - - vertex_list[2] = lvertex_list[0]; - vertex_list[1] = lvertex_list[1]; - vertex_list[0] = lvertex_list[2]; + READ(b, vertex_list); + std::swap(vertex_list[0], vertex_list[2]); } static String print_float(double v)