- fix wrong attribute count passed to SetFormat

- fix missing include statement
This commit is contained in:
Magnus Norddahl 2018-11-23 12:09:36 +01:00
parent e02367dd09
commit ac62088690
2 changed files with 2 additions and 1 deletions

View file

@ -38,6 +38,7 @@
#include <string.h> #include <string.h>
#include <stdio.h> #include <stdio.h>
#include <exception> #include <exception>
#include <stdexcept>
#define MAX_ERRORTEXT 1024 #define MAX_ERRORTEXT 1024

View file

@ -147,7 +147,7 @@ FModelVertexBuffer::FModelVertexBuffer(bool needindex, bool singleframe)
{ 1, VATTR_VERTEX2, VFmt_Float3, (int)myoffsetof(FModelVertex, x) }, { 1, VATTR_VERTEX2, VFmt_Float3, (int)myoffsetof(FModelVertex, x) },
{ 1, VATTR_NORMAL2, VFmt_Packed_A2R10G10B10, (int)myoffsetof(FModelVertex, packedNormal) } { 1, VATTR_NORMAL2, VFmt_Packed_A2R10G10B10, (int)myoffsetof(FModelVertex, packedNormal) }
}; };
mVertexBuffer->SetFormat(2, 4, sizeof(FModelVertex), format); mVertexBuffer->SetFormat(2, 5, sizeof(FModelVertex), format);
} }
//=========================================================================== //===========================================================================