[iortcw] 489/497: MP: Pillarbox map loading screen when using cg_fixedAspect on widescreens
Simon McVittie
smcv at debian.org
Fri Sep 8 10:38:03 UTC 2017
This is an automated email from the git hooks/post-receive script.
smcv pushed a commit to annotated tag 1.42d
in repository iortcw.
commit 561f1da8e03af25b975e811d18813c9e86b5078f
Author: MAN-AT-ARMS <M4N4T4RMS at gmail.com>
Date: Tue Dec 22 08:08:02 2015 -0500
MP: Pillarbox map loading screen when using cg_fixedAspect on widescreens
---
MP/code/cgame/cg_info.c | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/MP/code/cgame/cg_info.c b/MP/code/cgame/cg_info.c
index e92ba51..99b9e9a 100644
--- a/MP/code/cgame/cg_info.c
+++ b/MP/code/cgame/cg_info.c
@@ -260,6 +260,21 @@ void CG_DrawInformation( void ) {
levelshot = trap_R_RegisterShaderNoMip( "levelshots/unknownmap.jpg" );
}
trap_R_SetColor( NULL );
+
+ // Pillarboxes
+ if ( cg_fixedAspect.integer ) {
+ if ( cgs.glconfig.vidWidth * 480.0 > cgs.glconfig.vidHeight * 640.0 ) {
+ vec4_t col = { 0, 0, 0, 1 };
+ float pillar = 0.5 * ( ( cgs.glconfig.vidWidth - ( cgs.screenXScale * 640.0 ) ) / cgs.screenXScale );
+
+ CG_SetScreenPlacement( PLACE_LEFT, PLACE_CENTER );
+ CG_FillRect( 0, 0, pillar + 1, 480, col );
+ CG_SetScreenPlacement( PLACE_RIGHT, PLACE_CENTER );
+ CG_FillRect( 640 - pillar, 0, pillar + 1, 480, col );
+ CG_SetScreenPlacement( PLACE_CENTER, PLACE_CENTER );
+ }
+ }
+
CG_DrawPic( 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, levelshot );
// show the server motd
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/iortcw.git
More information about the Pkg-games-commits
mailing list