Skip to content

Commit

Permalink
https://github.com/KhronosGroup/glTF/issues/187
Browse files Browse the repository at this point in the history
  • Loading branch information
fabrobinet committed Jun 9, 2014
1 parent a61cc17 commit 9520d77
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
6 changes: 6 additions & 0 deletions converter/COLLADA2GLTF/GLTF/GLTFTypesAndConstants.h
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,12 @@ const std::string kLights = "lights";
const std::string kLight = "light";
const std::string kSemantic = "semantic";

const std::string MODELVIEW = "MODELVIEW";
const std::string MODELVIEWINVERSETRANSPOSE = "MODELVIEWINVERSETRANSPOSE";
const std::string MODELVIEWINVERSE = "MODELVIEWINVERSE";
const std::string PROJECTION = "PROJECTION";
const std::string JOINTMATRIX = "JOINTMATRIX";

namespace GLTF
{
class JSONObject;
Expand Down
9 changes: 2 additions & 7 deletions converter/COLLADA2GLTF/shaders/commonProfileShaders.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -212,11 +212,6 @@ namespace GLTF
*/


static std::string MODELVIEW = "MODELVIEW";
static std::string MODELVIEWINVERSETRANSPOSE = "MODELVIEWINVERSETRANSPOSE";
static std::string MODELVIEWINVERSE = "MODELVIEWINVERSE";
static std::string PROJECTION = "PROJECTION";

/* uniform types, derived from
GL_INT
GL_INT_VEC2
Expand Down Expand Up @@ -601,7 +596,7 @@ namespace GLTF
typeForSemanticUniform[MODELVIEWINVERSE] = _GL(FLOAT_MAT4);
typeForSemanticUniform[MODELVIEW] = _GL(FLOAT_MAT4);
typeForSemanticUniform[PROJECTION] = _GL(FLOAT_MAT4);
typeForSemanticUniform["JOINT_MATRIX"] = _GL(FLOAT_MAT4);
typeForSemanticUniform[JOINTMATRIX] = _GL(FLOAT_MAT4);
}
return typeForSemanticUniform[semantic];
}
Expand Down Expand Up @@ -767,7 +762,7 @@ namespace GLTF

assert(techniqueExtras != nullptr);
addSemantic("vs", "uniform",
"JOINT_MATRIX", "jointMat", jointsCount, false, true /* force as an array */);
JOINTMATRIX, "jointMat", jointsCount, false, true /* force as an array */);
}

if (hasNormals) {
Expand Down

0 comments on commit 9520d77

Please sign in to comment.