Browse Source

GameUI: avoid const modifier loss

pull/2/head
Alibek Omarov 6 years ago
parent
commit
b60b3f7d18
  1. 8
      engine/client/cl_gameui.c

8
engine/client/cl_gameui.c

@ -715,15 +715,19 @@ for drawing playermodel previews @@ -715,15 +715,19 @@ for drawing playermodel previews
*/
static void pfnRenderScene( const ref_viewpass_t *rvp )
{
ref_viewpass_t copy;
// to avoid division by zero
if( !rvp || rvp->fov_x <= 0.0f || rvp->fov_y <= 0.0f )
return;
copy = *rvp;
// don't allow special modes from menu
((ref_viewpass_t *)&rvp)->flags = 0;
copy.flags = 0;
R_Set2DMode( false );
R_RenderFrame( rvp );
R_RenderFrame( &copy );
R_Set2DMode( true );
R_PopScene();
}

Loading…
Cancel
Save