hachem.wtf
aboutsummaryrefslogtreecommitdiff
path: root/src/platform/opengl/opengl_renderer_api.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/platform/opengl/opengl_renderer_api.cpp')
-rw-r--r--src/platform/opengl/opengl_renderer_api.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/platform/opengl/opengl_renderer_api.cpp b/src/platform/opengl/opengl_renderer_api.cpp
index 1d41735..4542231 100644
--- a/src/platform/opengl/opengl_renderer_api.cpp
+++ b/src/platform/opengl/opengl_renderer_api.cpp
@@ -1,7 +1,7 @@
#include "opengl_renderer_api.h"
+
#include <glad/glad.h>
#include <GLFW/glfw3.h>
-#include <iostream>
namespace Donut
{
@@ -9,13 +9,13 @@ namespace Donut
{
if (!glfwGetCurrentContext())
{
- std::cout << "No OpenGL context is current! Cannot initialize GLAD." << std::endl;
+ DONUT_ERROR("No OpenGL context is current! Cannot initialize GLAD.");
return;
}
if (!gladLoadGLLoader((GLADloadproc)glfwGetProcAddress))
{
- std::cout << "Failed to initialize GLAD!" << std::endl;
+ DONUT_ERROR("Failed to initialize GLAD!");
return;
}
@@ -61,7 +61,7 @@ namespace Donut
glDisable(GL_CULL_FACE);
}
- void OpenGLRendererAPI::draw_indexed(const std::shared_ptr<VertexArray>& vertex_array, uint32_t index_count)
+ void OpenGLRendererAPI::draw_indexed(const Ref<VertexArray>& vertex_array, uint32_t index_count)
{
uint32_t count = index_count ? index_count : vertex_array->get_index_buffer()->get_count();
glDrawElements(GL_TRIANGLES, count, GL_UNSIGNED_INT, nullptr);