Renderer.h 925 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. #ifndef RENDERER_H
  2. #define RENDERER_H
  3. #include "client/rendering/wrapper/Shader.h"
  4. #include "client/math/MatrixStack.h"
  5. #include "client/math/Vector.h"
  6. #include "client/math/Quaternion.h"
  7. class Renderer final {
  8. public:
  9. Renderer(Shader& shader, MatrixStack& stack, Matrix& view);
  10. void pop();
  11. void push();
  12. Renderer& update();
  13. Renderer& update(const Vector& pos, const Quaternion& rotation);
  14. Renderer& scale(float sx, float sy, float sz);
  15. Renderer& scale(float s);
  16. Renderer& translate(float tx, float ty, float tz);
  17. Renderer& translateX(float tx);
  18. Renderer& translateY(float ty);
  19. Renderer& translateZ(float tz);
  20. Renderer& translateTo(float tx, float ty, float tz);
  21. Renderer& rotateX(float degrees);
  22. Renderer& rotateY(float degrees);
  23. Renderer& rotateZ(float degrees);
  24. private:
  25. Shader& shader;
  26. MatrixStack& stack;
  27. Matrix& view;
  28. };
  29. #endif