Source/ThunderBeast/QuakeToonProto1/ref_gl/gl_rmain.c
void R_RenderView (refdef_t *fd)
{
	if (r_norefresh->value)
		return;

	r_newrefdef = *fd;

	if (!r_worldmodel && !( r_newrefdef.rdflags & RDF_NOWORLDMODEL ) )
		ri.Sys_Error (ERR_DROP, "R_RenderView: NULL worldmodel");

	if (r_speeds->value)
	{
		c_brush_polys = 0;
		c_alias_polys = 0;
	}

	R_PushDlights ();

	if (gl_finish->value)
		qglFinish ();

	R_SetupFrame ();

	R_SetFrustum ();

	R_SetupGL ();

	R_MarkLeaves ();	// done here so we know if we're in water

	R_DrawWorld ();

	R_DrawEntitiesOnList ();

	R_RenderDlights ();

	R_DrawParticles ();

	R_DrawAlphaSurfaces ();

	R_Flash();

	if (r_speeds->value)
	{
		ri.Con_Printf (PRINT_ALL, "%4i wpoly %4i epoly %i tex %i lmaps\n",
			c_brush_polys, 
			c_alias_polys, 
			c_visible_textures, 
			c_visible_lightmaps); 
	}
}
/*
================
R_RenderView

r_newrefdef must be set before the first call
================
*/
R_RenderView
r_newrefdef must be set before the first call
R_RenderView r_newrefdef must be set before the first call
void R_RenderView (refdef_t *fd)
{
	if (r_norefresh->value)
		return;
	r_newrefdef = *fd;
	if (!r_worldmodel && !( r_newrefdef.rdflags & RDF_NOWORLDMODEL ) )
		ri.Sys_Error (ERR_DROP, "R_RenderView: NULL worldmodel");
	if (r_speeds->value)
	{
		c_brush_polys = 0;
		c_alias_polys = 0;
	}
	R_PushDlights ();
	if (gl_finish->value)
		qglFinish ();
	R_SetupFrame ();
	R_SetFrustum ();
	R_SetupGL ();
	R_MarkLeaves ();	
	R_DrawWorld ();
	R_DrawEntitiesOnList ();
	R_RenderDlights ();
	R_DrawParticles ();
	R_DrawAlphaSurfaces ();
	R_Flash();
	if (r_speeds->value)
	{
		ri.Con_Printf (PRINT_ALL, "%4i wpoly %4i epoly %i tex %i lmaps\n",
			c_brush_polys, 
			c_alias_polys, 
			c_visible_textures, 
			c_visible_lightmaps); 
	}
}
void R_RenderView ( refdef_t * fd ) { if ( r_norefresh -> value ) return ; r_newrefdef = * fd ; if ( ! r_worldmodel && ! ( r_newrefdef . rdflags & RDF_NOWORLDMODEL ) ) ri . Sys_Error ( ERR_DROP , " " ) ; if ( r_speeds -> value ) { c_brush_polys = 0 ; c_alias_polys = 0 ; } R_PushDlights ( ) ; if ( gl_finish -> value ) qglFinish ( ) ; R_SetupFrame ( ) ; R_SetFrustum ( ) ; R_SetupGL ( ) ; R_MarkLeaves ( ) ; R_DrawWorld ( ) ; R_DrawEntitiesOnList ( ) ; R_RenderDlights ( ) ; R_DrawParticles ( ) ; R_DrawAlphaSurfaces ( ) ; R_Flash ( ) ; if ( r_speeds -> value ) { ri . Con_Printf ( PRINT_ALL , " \n " , c_brush_polys , c_alias_polys , c_visible_textures , c_visible_lightmaps ) ; } }
R_RenderView
r_newrefdef must be set before the first call
R_RenderView r_newrefdef must be set before the first call
// done here so we know if we're in water