metaforce/Runtime/MP1/CSlideShow.hpp

108 lines
2.4 KiB
C++
Raw Permalink Normal View History

2018-10-06 20:42:33 -07:00
#pragma once
2016-09-16 13:18:03 -07:00
#include <optional>
#include <string>
#include <vector>
2020-04-19 18:09:30 -07:00
#include "Runtime/CDependencyGroup.hpp"
#include "Runtime/CIOWin.hpp"
#include "Runtime/CToken.hpp"
#include "Runtime/RetroTypes.hpp"
#include "Runtime/Audio/CSfxManager.hpp"
#include "Runtime/Camera/CCameraFilter.hpp"
#include "Runtime/GuiSys/CGuiTextSupport.hpp"
#include <zeus/CColor.hpp>
#include <zeus/CVector2f.hpp>
2016-09-16 13:18:03 -07:00
2021-04-10 01:42:06 -07:00
namespace metaforce {
class CTexture;
2016-09-16 13:18:03 -07:00
2018-12-07 21:30:43 -08:00
class CSlideShow : public CIOWin {
public:
2018-12-07 21:30:43 -08:00
enum class Phase { Zero, One, Two, Three, Four, Five };
struct SSlideData {
CSlideShow& x0_parent;
u32 x4_ = -1;
u32 x8_ = -1;
2018-12-07 21:30:43 -08:00
zeus::CVector2f x18_vpOffset;
zeus::CVector2f x20_vpSize;
zeus::CVector2f x28_canvasSize;
zeus::CColor x30_mulColor = zeus::skWhite;
explicit SSlideData(CSlideShow& parent) : x0_parent(parent) { x30_mulColor.a() = 0.f; }
void Draw();
2018-12-07 21:30:43 -08:00
};
private:
2018-12-07 21:30:43 -08:00
Phase x14_phase = Phase::Zero;
std::vector<TLockedToken<CDependencyGroup>> x18_galleryTXTRDeps;
/*
u32 x2c_ = 0;
u32 x30_ = 0;
u32 x34_ = 0;
u32 x38_ = 0;
u32 x3c_ = 0;
u32 x40_ = 0;
u32 x44_ = 0;
u32 x48_ = -1;
float x4c_ = 0.f;
float x50_ = 0.f;
float x54_ = 0.f;
float x58_ = 0.f;
*/
2016-09-16 13:18:03 -07:00
SSlideData x5c_slideA{*this};
SSlideData x90_slideB{*this};
2018-12-07 21:30:43 -08:00
std::unique_ptr<CGuiTextSupport> xc4_textA;
std::unique_ptr<CGuiTextSupport> xc8_textB;
/*
u32 xcc_ = 0;
u32 xd4_ = 0;
u32 xd8_ = 0;
u32 xdc_ = 0;
u32 xe0_ = 0;
*/
CSfxHandle xe4_;
/*
u32 xe8_ = 0;
u32 xec_ = 0;
u32 xf0_ = 0;
u32 xf4_ = 0;
*/
std::vector<TLockedToken<CTexture>> xf8_stickTextures; /* (9 LStick, 9 CStick) */
std::vector<CToken> x108_buttonTextures; /* (2L, 2R, 2B, 2Y) */
/*
u32 x11c_ = 0;
u32 x120_ = 0;
u32 x124_ = 0;
float x128_ = 32.f;
float x12c_ = 32.f;
*/
float x130_;
bool x134_24_ : 1 = true;
bool x134_25_ : 1 = false;
bool x134_26_ : 1 = false;
bool x134_27_ : 1 = false;
bool x134_28_disableInput : 1 = false;
bool x134_29_ : 1 = false;
bool x134_30_ : 1 = true;
bool x134_31_ : 1 = false;
bool x135_24_ : 1 = true;
2016-09-24 18:58:20 -07:00
2018-12-07 21:30:43 -08:00
bool LoadTXTRDep(std::string_view name);
2016-09-24 18:58:20 -07:00
2016-09-16 13:18:03 -07:00
public:
2018-12-07 21:30:43 -08:00
CSlideShow();
EMessageReturn OnMessage(const CArchitectureMessage&, CArchitectureQueue&) override;
bool GetIsContinueDraw() const override { return false; }
void Draw() override;
2016-12-16 15:05:29 -08:00
2018-12-07 21:30:43 -08:00
static u32 SlideShowGalleryFlags();
2016-09-16 13:18:03 -07:00
};
2021-04-10 01:42:06 -07:00
} // namespace metaforce