diff --git a/Editor/ViewManager.hpp b/Editor/ViewManager.hpp index 62d5fe2f2..28bdbcbf6 100644 --- a/Editor/ViewManager.hpp +++ b/Editor/ViewManager.hpp @@ -45,7 +45,7 @@ class ViewManager : public Specter::IViewManager { m_vm.m_partGen->Update(1.0 / 60.0); pshag::CGraphics::SetModelMatrix(Zeus::CTransform::Identity()); - pshag::CGraphics::SetViewPointMatrix(Zeus::CTransform::Identity() + Zeus::CVector3f(0.f, 10.f, 0.f)); + pshag::CGraphics::SetViewPointMatrix(Zeus::CTransform::Identity() + Zeus::CVector3f(0.f, -10.f, 0.f)); boo::SWindowRect windowRect = m_vm.m_mainWindow->getWindowFrame(); float aspect = windowRect.size[0] / float(windowRect.size[1]); pshag::CGraphics::SetPerspective(55.0, aspect, 0.001f, 1000.f); diff --git a/Runtime/CGraphics.cpp b/Runtime/CGraphics.cpp index af0bdf375..aceec8425 100644 --- a/Runtime/CGraphics.cpp +++ b/Runtime/CGraphics.cpp @@ -65,8 +65,8 @@ void CGraphics::SetViewPointMatrix(const Zeus::CTransform& xf) { g_ViewMatrix = xf; g_ViewPoint = xf.m_origin; - g_GXViewPointMatrix.m_basis = g_ViewMatrix.m_basis.transposed(); - g_GXViewPointMatrix.m_origin = -g_ViewPoint; + Zeus::CMatrix3f tmp(xf.m_basis[0], xf.m_basis[2], -xf.m_basis[1]); + g_GXViewPointMatrix = Zeus::CTransform(tmp.transposed()); SetViewMatrix(); } diff --git a/Runtime/Particle/CElementGenShadersGLSL.cpp b/Runtime/Particle/CElementGenShadersGLSL.cpp index 5bc9f5af1..3454cc59d 100644 --- a/Runtime/Particle/CElementGenShadersGLSL.cpp +++ b/Runtime/Particle/CElementGenShadersGLSL.cpp @@ -29,7 +29,7 @@ static const char* VS_GLSL_TEX = " vtf.color = colorIn * moduColor;\n" " vtf.uv = uvsIn[gl_VertexID].xy;\n" " gl_Position = mvp * posIn[gl_VertexID];\n" -" gl_Position = vec4(posIn[gl_VertexID].x, posIn[gl_VertexID].z, 0.0, 1.0);\n" +" //gl_Position = vec4(posIn[gl_VertexID].x, posIn[gl_VertexID].z, 0.0, 1.0);\n" "}\n"; static const char* FS_GLSL_TEX =