MCPcopy Create free account
hub / github.com/SpartanJ/eepp / createContextSettings

Method createContextSettings

src/eepp/window/engine.cpp:330–349  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

328}
329
330ContextSettings Engine::createContextSettings( IniFile* ini, std::string iniKeyName,
331 bool vsyncEnabledByDefault ) {
332 eeASSERT( NULL != ini );
333
334 ini->readFile();
335
336 bool VSync = ini->getValueB( iniKeyName, "vsync", vsyncEnabledByDefault );
337 std::string GLVersion = ini->getValue( iniKeyName, "glversion", "0" );
338 int depthBufferSize = ini->getValueI( iniKeyName, "depthbuffersize", 24 );
339 int stencilBufferSize = ini->getValueI( iniKeyName, "stencilbuffersize", 1 );
340 int multisamples = ini->getValueI( iniKeyName, "multisamples", 0 );
341 int frameRateLimit = ini->getValueI( iniKeyName, "frameratelimit",
342 ContextSettings::FrameRateLimitScreenRefreshRate );
343 bool doubleBuffering = ini->getValueB( iniKeyName, "doublebuffering", true );
344 bool sharedGLContext = ini->getValueB( iniKeyName, "sharedglcontext", false );
345
346 return ContextSettings( VSync, frameRateLimit, multisamples,
347 Renderer::glVersionFromString( GLVersion ), sharedGLContext,
348 doubleBuffering, depthBufferSize, stencilBufferSize );
349}
350
351ContextSettings Engine::createContextSettings( std::string iniPath, std::string iniKeyName ) {
352 IniFile Ini( iniPath );

Callers 2

initMethod · 0.80
initMethod · 0.80

Calls 5

ContextSettingsClass · 0.85
readFileMethod · 0.80
getValueBMethod · 0.80
getValueIMethod · 0.80
getValueMethod · 0.45

Tested by 1

initMethod · 0.64