renderer: add zoom with detached camera (#12548)

This commit is contained in:
jmanc3 2025-12-14 13:42:02 -06:00 committed by GitHub
parent 6535ff07c9
commit e4a8f2b14f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 129 additions and 15 deletions

View file

@ -0,0 +1,19 @@
#pragma once
#include "./math/Math.hpp"
struct SCurrentRenderData;
class CMonitorZoomController {
public:
bool m_resetCameraState = true;
void applyZoomTransform(CBox& monbox, const SCurrentRenderData& m_renderData);
private:
void zoomWithDetachedCamera(CBox& result, const SCurrentRenderData& m_renderData);
CBox m_camera;
float m_lastZoomLevel = 1.0f;
bool m_padCamEdges = true;
};