CAutoMapper: In-class initialize SAutoMapperRenderState member variables

Simplifies the parameterized constructor a little bit and provides a
consistent initial state for the default constructor.
This commit is contained in:
Lioncash 2020-01-28 13:29:56 -05:00
parent 50fbd2ad42
commit 88cecd80ec
1 changed files with 16 additions and 22 deletions

View File

@ -33,24 +33,24 @@ public:
enum class Ease { None, Linear, Out, In, InOut }; enum class Ease { None, Linear, Out, In, InOut };
using FGetViewportSize = zeus::CVector2i (*)(); using FGetViewportSize = zeus::CVector2i (*)();
FGetViewportSize m_getViewportSize; FGetViewportSize m_getViewportSize = nullptr;
zeus::CVector2i x0_viewportSize; zeus::CVector2i x0_viewportSize;
zeus::CQuaternion x8_camOrientation; zeus::CQuaternion x8_camOrientation;
float x18_camDist; float x18_camDist = 0.0f;
float x1c_camAngle; float x1c_camAngle = 0.0f;
zeus::CVector3f x20_areaPoint; zeus::CVector3f x20_areaPoint;
float x2c_drawDepth1; float x2c_drawDepth1 = 0.0f;
float x30_drawDepth2; float x30_drawDepth2 = 0.0f;
float x34_alphaSurfaceVisited; float x34_alphaSurfaceVisited = 0.0f;
float x38_alphaOutlineVisited; float x38_alphaOutlineVisited = 0.0f;
float x3c_alphaSurfaceUnvisited; float x3c_alphaSurfaceUnvisited = 0.0f;
float x40_alphaOutlineUnvisited; float x40_alphaOutlineUnvisited = 0.0f;
Ease x44_viewportEase; Ease x44_viewportEase = Ease::None;
Ease x48_camEase; Ease x48_camEase = Ease::None;
Ease x4c_pointEase; Ease x4c_pointEase = Ease::None;
Ease x50_depth1Ease; Ease x50_depth1Ease = Ease::None;
Ease x54_depth2Ease; Ease x54_depth2Ease = Ease::None;
Ease x58_alphaEase; Ease x58_alphaEase = Ease::None;
SAutoMapperRenderState() = default; SAutoMapperRenderState() = default;
SAutoMapperRenderState(FGetViewportSize getViewportSize, const zeus::CQuaternion& camOrientation, float camDist, SAutoMapperRenderState(FGetViewportSize getViewportSize, const zeus::CQuaternion& camOrientation, float camDist,
float camAngle, const zeus::CVector3f& areaPoint, float drawDepth1, float drawDepth2, float camAngle, const zeus::CVector3f& areaPoint, float drawDepth1, float drawDepth2,
@ -67,13 +67,7 @@ public:
, x34_alphaSurfaceVisited(alphaSurfaceVisited) , x34_alphaSurfaceVisited(alphaSurfaceVisited)
, x38_alphaOutlineVisited(alphaOutlineVisited) , x38_alphaOutlineVisited(alphaOutlineVisited)
, x3c_alphaSurfaceUnvisited(alphaSurfaceUnvisited) , x3c_alphaSurfaceUnvisited(alphaSurfaceUnvisited)
, x40_alphaOutlineUnvisited(alphaOutlineUnvisited) , x40_alphaOutlineUnvisited(alphaOutlineUnvisited) {}
, x44_viewportEase(Ease::None)
, x48_camEase(Ease::None)
, x4c_pointEase(Ease::None)
, x50_depth1Ease(Ease::None)
, x54_depth2Ease(Ease::None)
, x58_alphaEase(Ease::None) {}
static void InterpolateWithClamp(const SAutoMapperRenderState& a, SAutoMapperRenderState& out, static void InterpolateWithClamp(const SAutoMapperRenderState& a, SAutoMapperRenderState& out,
const SAutoMapperRenderState& b, float t); const SAutoMapperRenderState& b, float t);