@@ -158,7 +158,8 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
158
158
cvar_t *r_replaceMaterialMinDimensionIfPresentWithMaxDimension;
159
159
Cvar::Range<Cvar::Cvar<int >> r_imageFitScreen (" r_imageFitScreen" , " downscale “fitscreen” images to fit the screen size: 0: disable, 1: downscale as much as possible without being smaller than screen size (default), 2: downscale to never be larger then screen size" , Cvar::NONE, 1 , 0 , 2 );
160
160
cvar_t *r_finish;
161
- cvar_t *r_textureMode;
161
+ Cvar::Modified<Cvar::Cvar<std::string>> r_textureMode (
162
+ " r_textureMode" , " default texture filter mode" , Cvar::NONE, " GL_LINEAR_MIPMAP_LINEAR" );
162
163
cvar_t *r_offsetFactor;
163
164
cvar_t *r_offsetUnits;
164
165
@@ -830,8 +831,8 @@ ScreenshotCmd screenshotPNGRegistration("screenshotPNG", ssFormat_t::SSF_PNG, "p
830
831
831
832
tr.currenttextures .resize ( glConfig2.maxTextureUnits );
832
833
833
- GL_TextureMode ( r_textureMode-> string );
834
- r_textureMode-> modified = false ;
834
+ GL_TextureMode ( r_textureMode. Get (). c_str () );
835
+ r_textureMode. GetModifiedValue () ;
835
836
836
837
GL_DepthFunc ( GL_LEQUAL );
837
838
@@ -1067,7 +1068,7 @@ ScreenshotCmd screenshotPNGRegistration("screenshotPNG", ssFormat_t::SSF_PNG, "p
1067
1068
Log::Notice (" Forcing glFinish." );
1068
1069
}
1069
1070
1070
- Log::Debug (" texturemode: %s" , r_textureMode-> string );
1071
+ Log::Debug (" texturemode: %s" , r_textureMode. Get () );
1071
1072
Log::Debug (" picmip: %d" , r_picMip->integer );
1072
1073
Log::Debug (" imageMaxDimension: %d" , r_imageMaxDimension->integer );
1073
1074
Log::Debug (" ignoreMaterialMinDimension: %d" , r_ignoreMaterialMinDimension->integer );
@@ -1169,7 +1170,6 @@ ScreenshotCmd screenshotPNGRegistration("screenshotPNG", ssFormat_t::SSF_PNG, "p
1169
1170
r_zfar = Cvar_Get ( " r_zfar" , " 0" , CVAR_CHEAT );
1170
1171
r_checkGLErrors = Cvar_Get ( " r_checkGLErrors" , " -1" , 0 );
1171
1172
r_finish = Cvar_Get ( " r_finish" , " 0" , CVAR_CHEAT );
1172
- r_textureMode = Cvar_Get ( " r_textureMode" , " GL_LINEAR_MIPMAP_LINEAR" , CVAR_ARCHIVE );
1173
1173
r_gamma = Cvar_Get ( " r_gamma" , " 1.0" , CVAR_ARCHIVE );
1174
1174
r_facePlaneCull = Cvar_Get ( " r_facePlaneCull" , " 1" , 0 );
1175
1175
0 commit comments