diff options
author | SmileTheory <SmileTheory@gmail.com> | 2015-12-23 09:58:11 -0800 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2016-04-07 11:46:05 +0100 |
commit | cedfa02c6b3b17cda26202abf5e4dd32f9720cb5 (patch) | |
tree | fe92a0b799820983f70cfd5e09c939755124bbe4 /src/renderergl2/tr_init.c | |
parent | 19c44d9c50d6a3057e79007c779552d0eb7fe4ef (diff) |
OpenGL2: Replace r_exportCubemaps cvar with exportCubemaps command.
Diffstat (limited to 'src/renderergl2/tr_init.c')
-rw-r--r-- | src/renderergl2/tr_init.c | 33 |
1 files changed, 31 insertions, 2 deletions
diff --git a/src/renderergl2/tr_init.c b/src/renderergl2/tr_init.c index 44808639..8a84c1f8 100644 --- a/src/renderergl2/tr_init.c +++ b/src/renderergl2/tr_init.c @@ -141,7 +141,6 @@ cvar_t *r_specularMapping; cvar_t *r_deluxeMapping; cvar_t *r_parallaxMapping; cvar_t *r_cubeMapping; -cvar_t *r_exportCubemaps; cvar_t *r_specularIsMetallic; cvar_t *r_glossIsRoughness; cvar_t *r_baseNormalX; @@ -762,6 +761,35 @@ void R_ScreenShotJPEG_f (void) { /* ================== +R_ExportCubemaps +================== +*/ +void R_ExportCubemaps() +{ + exportCubemapsCommand_t *cmd; + + cmd = R_GetCommandBuffer(sizeof(*cmd)); + if (!cmd) { + return; + } + cmd->commandId = RC_EXPORT_CUBEMAPS; +} + + +/* +================== +R_ExportCubemaps_f +================== +*/ +void R_ExportCubemaps_f(void) +{ + R_ExportCubemaps(); +} + +//============================================================================ + +/* +================== RB_TakeVideoFrameCmd ================== */ @@ -1143,7 +1171,6 @@ void R_Register( void ) r_deluxeMapping = ri.Cvar_Get( "r_deluxeMapping", "1", CVAR_ARCHIVE | CVAR_LATCH ); r_parallaxMapping = ri.Cvar_Get( "r_parallaxMapping", "0", CVAR_ARCHIVE | CVAR_LATCH ); r_cubeMapping = ri.Cvar_Get( "r_cubeMapping", "0", CVAR_ARCHIVE | CVAR_LATCH ); - r_exportCubemaps = ri.Cvar_Get("r_exportCubemaps", "0", 0); r_specularIsMetallic = ri.Cvar_Get( "r_specularIsMetallic", "0", CVAR_ARCHIVE | CVAR_LATCH ); r_glossIsRoughness = ri.Cvar_Get("r_glossIsRoughness", "0", CVAR_ARCHIVE | CVAR_LATCH); r_baseNormalX = ri.Cvar_Get( "r_baseNormalX", "1.0", CVAR_ARCHIVE | CVAR_LATCH ); @@ -1280,6 +1307,7 @@ void R_Register( void ) ri.Cmd_AddCommand( "gfxinfo", GfxInfo_f ); ri.Cmd_AddCommand( "minimize", GLimp_Minimize ); ri.Cmd_AddCommand( "gfxmeminfo", GfxMemInfo_f ); + ri.Cmd_AddCommand( "exportCubemaps", R_ExportCubemaps_f ); } void R_InitQueries(void) @@ -1421,6 +1449,7 @@ void RE_Shutdown( qboolean destroyWindow ) { ri.Cmd_RemoveCommand("minimize"); ri.Cmd_RemoveCommand( "shaderstate" ); ri.Cmd_RemoveCommand( "gfxmeminfo" ); + ri.Cmd_RemoveCommand( "exportCubemaps" ); if ( tr.registered ) { |