Skip to content

Commit

Permalink
clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
L4ZZA committed Apr 17, 2020
1 parent 87358f3 commit d1f4acd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 10 deletions.
2 changes: 2 additions & 0 deletions pyro/src/platform/opengl/gl_buffer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ pyro::gl_index_buffer::gl_index_buffer(const uint32_t* vertices, uint32_t count)
{
PYRO_PROFILE_FUNCTION();
glGenBuffers(1, &m_id);
// GL_ELEMENT_ARRAY_BUFFER is not valid without an actively bound VAO
// Binding with GL_ARRAY_BUFFER allows the data to be loaded regardless of VAO state.
glBindBuffer(GL_ARRAY_BUFFER, m_id);
glBufferData(GL_ARRAY_BUFFER, count * sizeof(uint32_t), vertices, GL_STATIC_DRAW);
}
Expand Down
10 changes: 0 additions & 10 deletions pyro/src/pyro/renderer/renderer_2d.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,16 +142,6 @@ void pyro::renderer_2d::draw_quad(quad_properties const& props)
reset_render_data();
}

//constexpr glm::vec4 color = { 1.0f, 1.0f, 1.0f, 1.0f };

// if texture is passed as parameter

// go through all current textures
// if texture is found
// store index
// quit loop
//

// TODO - textures are added even if already present in s_data.texture_slots!
float tex_index = 0.0f;
auto tex_param = props.texture.get();
Expand Down

0 comments on commit d1f4acd

Please sign in to comment.