glPointSize(20.0f); must be placed before glBegin() , otherwise it will have no effect. Do it like this:
glPointSize(20.0f); glBegin(GL_POINTS); glColor3f (a, b, c); glVertex2i(px, py); glEnd();
In the OpenGL documentation, you can read that:
For glBegin and glEnd, only a subset of GL commands can be used. Commands: glVertex, glColor, glIndex, glNormal, glTexCoord, glEvalCoord, glEvalPoint, glArrayElement, glMaterial and glEdgeFlag. In addition, it is acceptable to use glCallList or glCallLists to execute display lists containing only previous commands. If any other GL command is executed between glBegin and glEnd, the error flag is set and the command is ignored.
source share