mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-01-06 03:29:44 -06:00
Feature/matrix maintenance (#2875)
* Split RenderableSphere class into a local and an online sphere * Make the video sphere derive from the regular sphere * Make RenderableTimeVaryingSphere derive from RenderableSphere * Some clean up * Add general functions for renderable matrix calculations * Make RenderableSphere and Plane use them * Fix an issue with the RenderablePlane shader * Make one function that returns all three types of render matrices * Make more Renderables use the general matric calculation function * Make more Renderable use the general matrix function * Simplify alternative transforms for matrix calculations * Small clean-up * Update RenderableModel (again) to use new transform functions * Make calc all matrix function to return tuple * Update some more places
This commit is contained in:
@@ -125,10 +125,14 @@ void RenderablePlaneProjection::render(const RenderData& data, RendererTasks&) {
|
||||
glm::dmat4 modelTransform =
|
||||
glm::translate(glm::dmat4(1.0), data.modelTransform.translation) *
|
||||
glm::dmat4(_stateMatrix);
|
||||
glm::mat4 mvp = data.camera.projectionMatrix() *
|
||||
glm::mat4(data.camera.combinedViewMatrix() * modelTransform);
|
||||
|
||||
_shader->setUniform("modelViewProjectionTransform", mvp);
|
||||
const glm::dmat4 ModelViewProjectionTransform =
|
||||
calcModelViewProjectionTransform(data, modelTransform);
|
||||
|
||||
_shader->setUniform(
|
||||
"modelViewProjectionTransform",
|
||||
glm::mat4(ModelViewProjectionTransform)
|
||||
);
|
||||
|
||||
ghoul::opengl::TextureUnit unit;
|
||||
unit.activate();
|
||||
|
||||
Reference in New Issue
Block a user