IOQ3 commit 2311

This commit is contained in:
Richard Allen 2012-10-04 16:03:14 +00:00
parent dcde1e2712
commit 661298c948
2 changed files with 18 additions and 6 deletions

View File

@ -273,6 +273,8 @@ New cvars
captured using screenshotJPEG
r_aviMotionJpegQuality - Controls quality of video capture when
cl_aviMotionJpeg is enabled
r_mode -2 - This new video mode automatically uses the
desktop resolution.
New commands
video [filename] - start video capture (use with demo command)

View File

@ -250,13 +250,23 @@ static int GLimp_SetMode(int mode, qboolean fullscreen, qboolean noborder)
ri.Printf (PRINT_ALL, "...setting mode %d:", mode );
if (mode == -2)
if (mode == -2)
{
glConfig.vidWidth = videoInfo->current_w;
glConfig.vidHeight = videoInfo->current_h;
glConfig.windowAspect = displayAspect;
fullscreen = qtrue;
noborder = qtrue;
// use desktop video resolution
if( videoInfo->current_h > 0 )
{
glConfig.vidWidth = videoInfo->current_w;
glConfig.vidHeight = videoInfo->current_h;
}
else
{
glConfig.vidWidth = 480;
glConfig.vidHeight = 640;
ri.Printf( PRINT_ALL,
"Cannot determine display resolution, assuming 640x480\n" );
}
glConfig.windowAspect = (float)glConfig.vidWidth / (float)glConfig.vidHeight;
}
else if ( !R_GetModeInfo( &glConfig.vidWidth, &glConfig.vidHeight, &glConfig.windowAspect, mode ) )
{