2016-09-16 20:18:03 +00:00
|
|
|
#ifndef __URDE_MP1_CSLIDESHOW_HPP__
|
|
|
|
#define __URDE_MP1_CSLIDESHOW_HPP__
|
|
|
|
|
|
|
|
#include "RetroTypes.hpp"
|
|
|
|
#include "CIOWin.hpp"
|
|
|
|
#include "CToken.hpp"
|
2016-09-16 23:43:33 +00:00
|
|
|
#include "GuiSys/CGuiTextSupport.hpp"
|
|
|
|
#include "Graphics/Shaders/CTexturedQuadFilter.hpp"
|
2016-12-29 05:53:00 +00:00
|
|
|
#include "Audio/CSfxManager.hpp"
|
2016-09-16 20:18:03 +00:00
|
|
|
|
|
|
|
namespace urde
|
|
|
|
{
|
|
|
|
class CTexture;
|
2016-09-25 01:58:20 +00:00
|
|
|
class CDependencyGroup;
|
2016-09-16 20:18:03 +00:00
|
|
|
|
|
|
|
class CSlideShow : public CIOWin
|
|
|
|
{
|
2016-09-16 23:43:33 +00:00
|
|
|
public:
|
|
|
|
enum class Phase
|
|
|
|
{
|
|
|
|
Zero,
|
|
|
|
One,
|
|
|
|
Two,
|
|
|
|
Three,
|
|
|
|
Four,
|
|
|
|
Five
|
|
|
|
};
|
|
|
|
struct SSlideData
|
|
|
|
{
|
|
|
|
CSlideShow& x0_parent;
|
|
|
|
u32 x4_ = -1;
|
|
|
|
u32 x8_ = -1;
|
|
|
|
|
|
|
|
std::experimental::optional<CTexturedQuadFilterAlpha> m_texQuad;
|
|
|
|
zeus::CVector2f x18_vpOffset;
|
|
|
|
zeus::CVector2f x20_vpSize;
|
|
|
|
zeus::CVector2f x28_canvasSize;
|
|
|
|
zeus::CColor x30_mulColor = zeus::CColor::skWhite;
|
|
|
|
|
|
|
|
SSlideData(CSlideShow& parent) : x0_parent(parent)
|
|
|
|
{
|
|
|
|
x30_mulColor.a = 0.f;
|
|
|
|
}
|
|
|
|
|
|
|
|
void SetTexture(const TLockedToken<CTexture>& tex)
|
|
|
|
{
|
|
|
|
m_texQuad.emplace(CCameraFilterPass::EFilterType::Blend, tex);
|
|
|
|
}
|
|
|
|
bool IsLoaded() const
|
|
|
|
{
|
|
|
|
return m_texQuad && m_texQuad->GetTex().IsLoaded();
|
|
|
|
}
|
|
|
|
void Draw() const;
|
|
|
|
};
|
|
|
|
|
|
|
|
private:
|
|
|
|
Phase x14_phase = Phase::Zero;
|
2016-09-25 01:58:20 +00:00
|
|
|
std::vector<TLockedToken<CDependencyGroup>> x18_galleryTXTRDeps;
|
2016-09-16 20:18:03 +00:00
|
|
|
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 23:43:33 +00:00
|
|
|
SSlideData x5c_slideA;
|
|
|
|
SSlideData x90_slideB;
|
|
|
|
|
|
|
|
std::unique_ptr<CGuiTextSupport> xc4_textA;
|
|
|
|
std::unique_ptr<CGuiTextSupport> xc8_textB;
|
2016-09-16 20:18:03 +00:00
|
|
|
u32 xcc_ = 0;
|
|
|
|
u32 xd4_ = 0;
|
|
|
|
u32 xd8_ = 0;
|
|
|
|
u32 xdc_ = 0;
|
|
|
|
u32 xe0_ = 0;
|
2016-09-16 23:43:33 +00:00
|
|
|
CSfxHandle xe4_;
|
2016-09-16 20:18:03 +00:00
|
|
|
u32 xe8_ = 0;
|
|
|
|
u32 xec_ = 0;
|
|
|
|
u32 xf0_ = 0;
|
|
|
|
u32 xf4_ = 0;
|
2016-09-25 01:58:20 +00:00
|
|
|
std::vector<TLockedToken<CTexture>> xf8_stickTextures; /* (9 LStick, 9 CStick) */
|
|
|
|
std::vector<CToken> x108_buttonTextures; /* (2L, 2R, 2B, 2Y) */
|
2016-09-16 20:18:03 +00:00
|
|
|
u32 x11c_ = 0;
|
|
|
|
u32 x120_ = 0;
|
|
|
|
u32 x124_ = 0;
|
|
|
|
float x128_ = 32.f;
|
|
|
|
float x12c_ = 32.f;
|
2016-09-16 23:43:33 +00:00
|
|
|
float x130_;
|
2016-09-16 20:18:03 +00:00
|
|
|
|
|
|
|
union
|
|
|
|
{
|
|
|
|
struct
|
|
|
|
{
|
|
|
|
bool x134_24_ : 1;
|
|
|
|
bool x134_25_ : 1;
|
|
|
|
bool x134_26_ : 1;
|
|
|
|
bool x134_27_ : 1;
|
2016-09-16 23:43:33 +00:00
|
|
|
bool x134_28_disableInput : 1;
|
2016-09-16 20:18:03 +00:00
|
|
|
bool x134_29_ : 1;
|
|
|
|
bool x134_30_ : 1;
|
|
|
|
bool x134_31_ : 1;
|
|
|
|
bool x135_24_ : 1;
|
|
|
|
};
|
|
|
|
u32 dummy = 0;
|
|
|
|
};
|
2016-09-25 01:58:20 +00:00
|
|
|
|
|
|
|
bool LoadTXTRDep(const std::string& name);
|
|
|
|
static bool AreAllDepsLoaded(const std::vector<TLockedToken<CDependencyGroup>>& deps);
|
|
|
|
|
2016-09-16 20:18:03 +00:00
|
|
|
public:
|
|
|
|
CSlideShow();
|
|
|
|
EMessageReturn OnMessage(const CArchitectureMessage&, CArchitectureQueue&);
|
|
|
|
bool GetIsContinueDraw() const {return false;}
|
|
|
|
void Draw() const;
|
2016-12-16 23:05:29 +00:00
|
|
|
|
|
|
|
static u32 SlideShowGalleryFlags();
|
2016-09-16 20:18:03 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif // __URDE_MP1_CSLIDESHOW_HPP__
|