One thing that I've noticed OpenGL has issues with is drawing line specific to the pixel.

This function should draw a line exactly from X1,Y1 to X2,Y2 this would include the pixels at the two points I specified. Unfortunately this does not happen. I think it may, in part have to do with the last position sent to OpenGL and when it changes states for the next drawing.

[pascal]procedure DrawLine(X1, Y1, X2, Y2: Integer; ColorR, ColorG, ColorB: GLfloat);
begin
glDisable(GL_TEXTURE_2D); //Disable Textures, as we're drawing lines
glColor3f(ColorR, ColorG, ColorB); //Set the new color!

BeginOrtho; //Switch to 2D mode
glPushMatrix; //Save Current Matrix
glTranslatef(X1, Y1, 0);
glBegin(GL_LINES); //Draw Using Lines
glVertex2f(0, 0);
glVertex2f(X2 - X1, Y2 - Y1);
glEnd;
glPopMatrix; //Reload Old Matrix
EndOrtho;
end;[/pascal]

Yes, it uses the same methods as Kas posted above. [size=9px](same codebase after all )[/size]