Merge remote-tracking branch 'origin/master' into Shadows
# Conflicts: # include/Engine/Rendering/DrawFinalPass.h # include/Engine/Rendering/Renderer.h # resources/Shaders/ForwardPlus.vert.glsl # resources/Shaders/ForwardPlusSkinned.vert.glsl # src/Engine/Rendering/Renderer.cpp
This commit is contained in:
@@ -111,7 +111,7 @@ struct ModelJob : RenderJob
|
||||
Color = modelComponent["Color"];
|
||||
GlowIntensity = ((double)modelComponent["GlowIntensity"]);
|
||||
Entity = modelComponent.EntityID;
|
||||
glm::vec3 abspos = Transform::AbsolutePosition(world, modelComponent.EntityID);
|
||||
glm::vec3 abspos = glm::vec3(matrix[3][0], matrix[3][1], matrix[3][2]);
|
||||
glm::vec3 worldpos = glm::vec3(camera->ViewMatrix() * glm::vec4(abspos, 1));
|
||||
Depth = worldpos.z;
|
||||
World = world;
|
||||
@@ -167,7 +167,9 @@ struct ModelJob : RenderJob
|
||||
|
||||
void CalculateHash() override
|
||||
{
|
||||
Hash = ShaderID << 20 + ModelID << 10 + TextureID;
|
||||
Hash = TextureID;
|
||||
Hash += ModelID << 10;
|
||||
Hash += ShaderID << 20;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user