mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-02-21 20:39:08 -06:00
glDrawElement issues
This commit is contained in:
@@ -666,12 +666,12 @@ void RenderableSatellites::render(const RenderData& data, RendererTasks&) {
|
||||
// Crashes in here
|
||||
glBindVertexArray(_vertexArray);
|
||||
//glDrawElements(GL_LINES,
|
||||
// static_cast<GLsizei>(_indexBufferData.size()),
|
||||
// GL_UNSIGNED_INT,
|
||||
// 0);
|
||||
//static_cast<unsigned int>(_indexBufferData.size()),
|
||||
//GL_UNSIGNED_INT,
|
||||
//0);
|
||||
glDrawArrays(GL_LINES,
|
||||
0,
|
||||
static_cast<unsigned int>(_indexBufferData.size()));
|
||||
20); //static_cast<unsigned int>(_indexBufferData.size()));
|
||||
glBindVertexArray(0);
|
||||
|
||||
_programObject->deactivate();
|
||||
@@ -716,7 +716,7 @@ void RenderableSatellites::updateBuffers() {
|
||||
}
|
||||
++orbitindex;
|
||||
}
|
||||
|
||||
|
||||
glBindVertexArray(_vertexArray);
|
||||
|
||||
glBindBuffer(GL_ARRAY_BUFFER, _vertexBuffer);
|
||||
|
||||
@@ -34,7 +34,7 @@ in vec4 viewSpacePosition;
|
||||
|
||||
Fragment getFragment() {
|
||||
Fragment frag;
|
||||
frag.color = vec4(color, opacity);
|
||||
frag.color = vec4(0.0, 0.0, 0.5, opacity);
|
||||
frag.depth = safeLength(viewSpacePosition);
|
||||
frag.blend = BLEND_MODE_ADDITIVE;
|
||||
frag.gPosition = viewSpacePosition;
|
||||
|
||||
Reference in New Issue
Block a user