mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-05 11:35:05 +08:00
GameUI: avoid const modifier loss
This commit is contained in:
@@ -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( © );
|
||||
R_Set2DMode( true );
|
||||
R_PopScene();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user