Changeset View
Changeset View
Standalone View
Standalone View
source/gui/ObjectTypes/CChart.cpp
Show First 20 Lines • Show All 80 Lines • ▼ Show 20 Lines | |||||
} | } | ||||
void CChart::DrawLine(const CShaderProgramPtr& shader, const CGUIColor& color, const std::vector<float>& vertices) const | void CChart::DrawLine(const CShaderProgramPtr& shader, const CGUIColor& color, const std::vector<float>& vertices) const | ||||
{ | { | ||||
shader->Uniform(str_color, color); | shader->Uniform(str_color, color); | ||||
shader->VertexPointer(3, GL_FLOAT, 0, &vertices[0]); | shader->VertexPointer(3, GL_FLOAT, 0, &vertices[0]); | ||||
shader->AssertPointersBound(); | shader->AssertPointersBound(); | ||||
#if !CONFIG2_GLES | |||||
glEnable(GL_LINE_SMOOTH); | glEnable(GL_LINE_SMOOTH); | ||||
#endif | |||||
glLineWidth(1.1f); | glLineWidth(1.1f); | ||||
if (!g_Renderer.m_SkipSubmit) | if (!g_Renderer.m_SkipSubmit) | ||||
glDrawArrays(GL_LINE_STRIP, 0, vertices.size() / 3); | glDrawArrays(GL_LINE_STRIP, 0, vertices.size() / 3); | ||||
glLineWidth(1.0f); | glLineWidth(1.0f); | ||||
#if !CONFIG2_GLES | |||||
glDisable(GL_LINE_SMOOTH); | glDisable(GL_LINE_SMOOTH); | ||||
#endif | |||||
} | } | ||||
void CChart::DrawTriangleStrip(const CShaderProgramPtr& shader, const CGUIColor& color, const std::vector<float>& vertices) const | void CChart::DrawTriangleStrip(const CShaderProgramPtr& shader, const CGUIColor& color, const std::vector<float>& vertices) const | ||||
{ | { | ||||
shader->Uniform(str_color, color); | shader->Uniform(str_color, color); | ||||
shader->VertexPointer(3, GL_FLOAT, 0, &vertices[0]); | shader->VertexPointer(3, GL_FLOAT, 0, &vertices[0]); | ||||
shader->AssertPointersBound(); | shader->AssertPointersBound(); | ||||
▲ Show 20 Lines • Show All 216 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator