WorldRenderer.h 505 B

12345678910111213141516171819202122
  1. #ifndef WORLDRENDERER_H
  2. #define WORLDRENDERER_H
  3. #include "client/rendering/Mesh.h"
  4. #include "client/rendering/ShaderMatrix.h"
  5. #include "common/world/World.h"
  6. #include "rendering/FileTexture.h"
  7. class WorldRenderer {
  8. const World& world;
  9. Mesh mesh;
  10. FileTexture texture;
  11. public:
  12. WorldRenderer(const World& world);
  13. void render(float lag, ShaderMatrix& sm);
  14. void addCube(TypedBuffer<Triangle>& buffer, float x, float y, float z);
  15. bool isAir(int x, int y, int z) const;
  16. };
  17. #endif