MCPcopy Create free account
hub / github.com/diasurgical/DevilutionX / ReinitializeTexture

Function ReinitializeTexture

Source/utils/display.cpp:376–388  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

374
375#ifndef USE_SDL1
376void ReinitializeTexture()
377{
378 if (texture)
379 texture.reset();
380
381 if (renderer == nullptr)
382 return;
383
384 auto quality = StrCat(static_cast<int>(*sgOptions.Graphics.scaleQuality));
385 SDL_SetHint(SDL_HINT_RENDER_SCALE_QUALITY, quality.c_str());
386
387 texture = SDLWrap::CreateTexture(renderer, DEVILUTIONX_DISPLAY_TEXTURE_FORMAT, SDL_TEXTUREACCESS_STREAMING, gnScreenWidth, gnScreenHeight);
388}
389
390void ReinitializeIntegerScale()
391{

Callers 1

ReinitializeRendererFunction · 0.85

Calls 3

StrCatFunction · 0.85
CreateTextureFunction · 0.85
resetMethod · 0.45

Tested by

no test coverage detected