|
|
@@ -208,7 +208,8 @@ void GpuEasyMeshData::AddGpuData(GpuShaderData* gpudata, EasyMesh* src_mesh) |
|
|
|
BUILD_VFLAG(has_color, VertexUsage::Color, vflags); |
|
|
|
BUILD_VFLAG(has_texcoord, VertexUsage::TexCoord, vflags); |
|
|
|
BUILD_VFLAG_OR(has_texcoord, VertexUsage::TexCoordExt, vflags); |
|
|
|
ASSERT(!vflags, String("Vertex Useage setup is not implemented for : ") + VertexUsage::GetNameList(vflags) + String(", feel free to do so.")); |
|
|
|
ASSERT(!vflags, "Vertex Usage setup is not implemented for %s, feel free to do so.", |
|
|
|
VertexUsage::GetNameList(vflags).C()); |
|
|
|
|
|
|
|
if (has_position) gpudata->AddAttribute(gpudata->GetInVertexName(), VertexUsage::Position, 0); |
|
|
|
if (has_normal) gpudata->AddAttribute(gpudata->GetInNormalName(), VertexUsage::Normal, 0); |
|
|
@@ -270,7 +271,8 @@ void GpuEasyMeshData::SetupVertexData(uint16_t vflags, EasyMesh* src_mesh) |
|
|
|
BUILD_VFLAG_COUNT(has_color, VertexUsage::Color, saveflags, flagnb); |
|
|
|
BUILD_VFLAG_COUNT(has_texcoord, VertexUsage::TexCoord, saveflags, flagnb); |
|
|
|
BUILD_VFLAG_COUNT(has_texcoordExt,VertexUsage::TexCoordExt, saveflags, flagnb); |
|
|
|
ASSERT(!saveflags, String("Vertex Declaration setup is not implemented for : ") + VertexUsage::GetNameList(vflags) + String(", feel free to do so.")); |
|
|
|
ASSERT(!vflags, "Vertex Declaration setup is not implemented for %s, feel free to do so.", |
|
|
|
VertexUsage::GetNameList(vflags).C()); |
|
|
|
|
|
|
|
if (has_position && has_normal && has_color && has_texcoord && has_texcoordExt && flagnb == 5) |
|
|
|
{ |
|
|
@@ -396,7 +398,8 @@ void GpuEasyMeshData::RenderMeshData(mat4 const &model) |
|
|
|
BUILD_VFLAG(has_color, VertexUsage::Color, vflags); |
|
|
|
BUILD_VFLAG(has_texcoord, VertexUsage::TexCoord, vflags); |
|
|
|
BUILD_VFLAG_OR(has_texcoord,VertexUsage::TexCoordExt, vflags); |
|
|
|
ASSERT(!vflags, String("Vertex Stream setup is not implemented for : ") + VertexUsage::GetNameList(vflags) + String(", feel free to do so.")); |
|
|
|
ASSERT(!vflags, "Vertex Streamsetup is not implemented for %s, feel free to do so.", |
|
|
|
VertexUsage::GetNameList(vflags).C()); |
|
|
|
|
|
|
|
int idx = 0; |
|
|
|
ShaderAttrib Attribs[4] = { lol::ShaderAttrib(), lol::ShaderAttrib(), lol::ShaderAttrib(), lol::ShaderAttrib() }; |
|
|
|