Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Code off

Name: Anonymous 2009-07-28 13:59

Welcome to the first annual /prog/ Code off !

The language will be C.

Compeptitors include (in no particular order):

Mr. Ribs
Xarn
FV
Anonymous
W. T. Snacks

Rumor has it, that there may be a special guest appearance from either The Sussman or
Leah Culver.

What's the point of this, you ask?

It's to determine who is an EXPERT PROGRAMMER.

Marking criteria:

Optimization
Elegance

Bonus marks:
indentation

Good luck!

Name: Anonymous 2009-07-30 12:47

ed(1) to the rescue!
104a
    glGenBuffers(1, &vbo);
    glBindBuffer(GL_ARRAY_BUFFER, vbo);
    glBufferData(GL_ARRAY_BUFFER, sizeof(GLfloat) * 16 * MAX_SQUARE, NULL, GL_STATIC_DRAW);

.
85c
    glutInitDisplayMode(GLUT_DOUBLE);
.
81a
    GLuint vbo;
.
40c
    glBufferSubData(GL_ARRAY_BUFFER, square_count++ * sizeof(GLfloat) * 16, sizeof(GLfloat) * 16, data);
.
21c
    glVertexPointer(4, GL_FLOAT, 0, NULL);
.
9,11d

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List