MCPcopy Create free account
hub / github.com/RevoSucks/BM64Recomp / get_resolution_scale

Method get_resolution_scale

src/main/rt64_render_context.cpp:370–386  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

368}
369
370float zelda64::renderer::RT64Context::get_resolution_scale() const {
371 constexpr int ReferenceHeight = 240;
372 switch (app->userConfig.resolution) {
373 case RT64::UserConfiguration::Resolution::WindowIntegerScale:
374 if (app->sharedQueueResources->swapChainHeight > 0) {
375 return std::max(float((app->sharedQueueResources->swapChainHeight + ReferenceHeight - 1) / ReferenceHeight), 1.0f);
376 }
377 else {
378 return 1.0f;
379 }
380 case RT64::UserConfiguration::Resolution::Manual:
381 return float(app->userConfig.resolutionMultiplier);
382 case RT64::UserConfiguration::Resolution::Original:
383 default:
384 return 1.0f;
385 }
386}
387
388void zelda64::renderer::RT64Context::check_texture_pack_actions() {
389 bool packs_changed = false;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected