Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions assets/shaders/PBRClusteredShader.frag
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,9 @@ void main(){
//Adding any emissive if there is an assigned map
radianceOut += emissive;

if(slices){
FragColor = vec4(colors[uint(mod(zTile, 8.0))], 1.0);
if(slices)
{
FragColor = vec4(colors[uint(mod(float(zTile), 8.0))], 1.0);
}
else{
FragColor = vec4(radianceOut, 1.0);
Expand Down
4 changes: 2 additions & 2 deletions src/scene.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -394,8 +394,8 @@ void Scene::loadSceneModels(const json &sceneConfigJson ){
for (unsigned int i = 0; i < modelCount; ++i){
//get model mesh and material info
json currentModel = sceneConfigJson["models"][i];
modelMesh = currentModel["mesh"];
IBL = currentModel["IBL"];
modelMesh = currentModel["mesh"].get<std::string>();
IBL = currentModel["IBL"].get<bool>();

modelName = modelMesh.substr(0, modelMesh.find_last_of('.'));

Expand Down
4 changes: 2 additions & 2 deletions src/shader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ bool Shader::setup(const std::string vertexPath, const std::string fragmentPath,
glGetShaderiv(vertexShader, GL_COMPILE_STATUS, &success);
if(!success){
glGetShaderInfoLog(vertexShader, 512, NULL, infoLog);
printf("Vertex shader compilation failed %s\n", infoLog );
printf("Vertex shader compilation failed at %s: %s\n", vertexPath.c_str(), infoLog );
return false;
}

Expand All @@ -77,7 +77,7 @@ bool Shader::setup(const std::string vertexPath, const std::string fragmentPath,
glGetShaderiv(fragmentShader, GL_COMPILE_STATUS, &success);
if(!success){
glGetShaderInfoLog(fragmentShader, 512, NULL, infoLog);
printf("Fragment shader compilation failed %s\n", infoLog );
printf("Fragment shader compilation failed at %s: %s\n", fragmentPath.c_str(), infoLog);
return false;
}

Expand Down