Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Icosahedron
static GLfloat const minor = 0.5257311f;
static GLfloat const major = 0.8506508f;
float const icosahedron_position[12][3] = {
{0.f, +minor, +major},
{0.f, +minor, -major},
{0.f, -minor, +major},
{0.f, -minor, -major},
{+major, 0.f, +minor},
{+major, 0.f, -minor},
{-major, 0.f, +minor},
{-major, 0.f, -minor},
{+minor, +major, 0.f},
{+minor, -major, 0.f},
{-minor, +major, 0.f},
{-minor, -major, 0.f},
};
int const icosahedron_index[20][3] = {
{8, 10, 0},
{9, 3, 5},
{0, 6, 2},
{3, 7, 1},
{1, 8, 5},
{7, 11, 6},
{8, 0, 4},
{11, 9, 2},
{6, 10, 7},
{2, 9, 4},
{10, 1, 7},
{9, 5, 4},
{10, 8, 1},
{3, 11, 7},
{8, 4, 5},
{11, 2, 6},
{4, 0, 2},
{5, 3, 1},
{0, 10, 6},
{9, 11, 3},
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.