a word
All checks were successful
Run ReCI Build Test / Explore-Gitea-Actions (push) Successful in 1m47s
All checks were successful
Run ReCI Build Test / Explore-Gitea-Actions (push) Successful in 1m47s
This commit is contained in:
@@ -322,6 +322,7 @@ namespace JGL {
|
||||
void DrawLine(const Color4& color, const Vector3& A, const Vector3& B, float thickness = 1.f);
|
||||
|
||||
|
||||
/// Render a wireframe sphere.
|
||||
void WireframeSphere(const Color4& color, const Vector3& position, float radius, unsigned int lats, unsigned int longs, float thickness = 1.f);
|
||||
void WireframeSphere(const Color4& color, const Sphere& sphere, float thickness = 1.f);
|
||||
void WireframeIcosphere(const Color4& color, const Vector3& position, float radius, float thickness = 1.f);
|
||||
|
@@ -1069,7 +1069,7 @@ namespace JGL {
|
||||
glColor4ubv(color.ptr());
|
||||
|
||||
float r = radius;
|
||||
std::vector<Vector3> vertices(2 + (lats + 1) * (longs + 1));
|
||||
std::vector<Vector3> vertices((lats + 1) * (longs + 1));
|
||||
|
||||
int index = 0;
|
||||
for (int i = 0; i <= lats; i++) {
|
||||
@@ -1097,7 +1097,7 @@ namespace JGL {
|
||||
glLineWidth(thickness);
|
||||
glColor4ubv(color.ptr());
|
||||
glVertexPointer(3, GL_FLOAT, sizeof(Vector3), vertices.data());
|
||||
glDrawArrays(GL_LINE_LOOP, 0, vertices.size() -1);
|
||||
glDrawArrays(GL_LINE_LOOP, 0, vertices.size());
|
||||
glColor4fv(baseColor);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user