engine/video_draw.c
/*	Draws the little blue disc in the corner of the screen.
	Call before beginning any disc IO.
*/
Draws the little blue disc in the corner of the screen.
Call before beginning any disc IO.
Draws the little blue disc in the corner of the screen . Call before beginning any disc IO .
void Draw_BeginDisc(void)
{
	int	iViewport[4]; 
	VideoCanvasType_t oldcanvas; 
	if (!Video.bInitialized || (cls.state == ca_dedicated))
		return;
	 -- canvas and matrix stuff
	glGetIntegerv(GL_VIEWPORT,iViewport);
	glMatrixMode(GL_PROJECTION);
	glPushMatrix();
	glMatrixMode(GL_MODELVIEW);
	glPushMatrix();
	oldcanvas = (VideoCanvasType_t)currentcanvas;
	GL_SetCanvas (CANVAS_TOPRIGHT);
	currentcanvas = oldcanvas; 
	glDrawBuffer(GL_FRONT);
	Draw_MaterialSurface(g_mHDAccess, 0, 320 - 74, 10, 64, 64, 1);
	glDrawBuffer(GL_BACK);
	 -- restore everything so that 3d rendering isn't fucked up
	glMatrixMode(GL_PROJECTION);
	glPopMatrix();
	glMatrixMode(GL_MODELVIEW);
	glPopMatrix();
	glViewport(iViewport[0],iViewport[1],iViewport[2],iViewport[3]);
}
void Draw_BeginDisc ( void ) { int iViewport [ 4 ] ; VideoCanvasType_t oldcanvas ; if ( ! Video . bInitialized || ( cls . state == ca_dedicated ) ) return ; glGetIntegerv ( GL_VIEWPORT , iViewport ) ; glMatrixMode ( GL_PROJECTION ) ; glPushMatrix ( ) ; glMatrixMode ( GL_MODELVIEW ) ; glPushMatrix ( ) ; oldcanvas = ( VideoCanvasType_t ) currentcanvas ; GL_SetCanvas ( CANVAS_TOPRIGHT ) ; currentcanvas = oldcanvas ; glDrawBuffer ( GL_FRONT ) ; Draw_MaterialSurface ( g_mHDAccess , 0 , 320 - 74 , 10 , 64 , 64 , 1 ) ; glDrawBuffer ( GL_BACK ) ; glMatrixMode ( GL_PROJECTION ) ; glPopMatrix ( ) ; glMatrixMode ( GL_MODELVIEW ) ; glPopMatrix ( ) ; glViewport ( iViewport [ 0 ] , iViewport [ 1 ] , iViewport [ 2 ] , iViewport [ 3 ] ) ; }
Draws the little blue disc in the corner of the screen.
Draws the little blue disc in the corner of the screen .
//static float fDiscRotation = 0; //johnfitz //johnfitz // Don't draw if it's dedicated. //johnfitz -- canvas and matrix stuff // a bit of a hack, since GL_SetCanvas doesn't know we are going to pop the stack //johnfitz //johnfitz -- restore everything so that 3d rendering isn't fucked up //johnfitz