This commit is contained in:
Jack Andersen 2016-02-11 12:43:04 -10:00
commit b801bc5744
6 changed files with 68 additions and 2 deletions

View File

@ -6,7 +6,10 @@
namespace Retro namespace Retro
{ {
const char* DecodeARAMFile(const char* name); static const char* DecodeARAMFile(const char* name)
{
return (strncmp(name, "aram:", 5) == 0 ? name + 5 : name);
}
enum class ESeekOrigin enum class ESeekOrigin
{ {
@ -44,7 +47,6 @@ public:
static void ARAMARAMXferCallback(u32) {} static void ARAMARAMXferCallback(u32) {}
static void DVDARAMXferCallback(s32, DVDFileInfo*) {} static void DVDARAMXferCallback(s32, DVDFileInfo*) {}
}; };
} }
#endif // __RETRO_CDVDFILE_HPP__ #endif // __RETRO_CDVDFILE_HPP__

View File

@ -896,6 +896,35 @@ void CElementGen::BuildParticleSystemBounds()
x2c4_systemBounds.accumulateBounds(aabb); x2c4_systemBounds.accumulateBounds(aabb);
} }
u32 CElementGen::GetSystemCount()
{
u32 ret = 0;
for (const CElementGen& child : x234_children)
ret += child.GetSystemCount();
for (const CElementGen& child : x248_children)
ret += child.GetSystemCount();
return (ret + (x208_activeParticleCount != 0));
}
u32 CElementGen::GetParticleCountAll()
{
return x20c;
}
u32 CElementGen::GetParticleCountAllInternal()
{
u32 ret = x208_activeParticleCount;
for (const CElementGen& child : x234_children)
ret += child.GetParticleCountAll();
for (const CElementGen& child : x248_children)
ret += child.GetParticleCountAll();
return ret;
}
void CElementGen::Render() void CElementGen::Render()
{ {
} }
@ -934,10 +963,12 @@ void CElementGen::SetModulationColor(const Zeus::CColor&)
const Zeus::CTransform& CElementGen::GetOrientation() const const Zeus::CTransform& CElementGen::GetOrientation() const
{ {
return x178_orientation;
} }
const Zeus::CVector3f& CElementGen::GetTranslation() const const Zeus::CVector3f& CElementGen::GetTranslation() const
{ {
return x7c_translation;
} }
const Zeus::CVector3f& CElementGen::GetGlobalScale() const const Zeus::CVector3f& CElementGen::GetGlobalScale() const

View File

@ -177,6 +177,7 @@ public:
CElementGen* ConstructChildParticleSystem(const TToken<CGenDescription>&); CElementGen* ConstructChildParticleSystem(const TToken<CGenDescription>&);
void UpdateLightParameters(); void UpdateLightParameters();
void BuildParticleSystemBounds(); void BuildParticleSystemBounds();
u32 GetSystemCount();
u32 GetParticleCountAllInternal() const; u32 GetParticleCountAllInternal() const;
u32 GetParticleCountAll() const {return x20c_recursiveParticleCount;} u32 GetParticleCountAll() const {return x20c_recursiveParticleCount;}

View File

@ -207,6 +207,18 @@ bool CIEGTCP::GetValue(int frame, int& valOut) const
return false; return false;
} }
bool CIEGAPC::GetValue(int frame, int &valOut) const
{
/* TODO: Do */
return false;
}
bool CIEGEMT::GetValue(int frame, int &valOut) const
{
/* TODO: Do */
return false;
}
bool CIEModulo::GetValue(int frame, int& valOut) const bool CIEModulo::GetValue(int frame, int& valOut) const
{ {
int a, b; int a, b;

View File

@ -158,6 +158,18 @@ public:
bool GetValue(int frame, int& valOut) const; bool GetValue(int frame, int& valOut) const;
}; };
class CIEGAPC : public CIntElement
{
public:
bool GetValue(int frame, int &valOut) const;
};
class CIEGEMT : public CIntElement
{
public:
bool GetValue(int frame, int &valOut) const;
};
class CIEModulo : public CIntElement class CIEModulo : public CIntElement
{ {
std::unique_ptr<CIntElement> x4_a; std::unique_ptr<CIntElement> x4_a;

View File

@ -739,10 +739,18 @@ CIntElement* CParticleDataFactory::GetIntElement(CInputStream& in)
CRealElement* a = GetRealElement(in); CRealElement* a = GetRealElement(in);
return new CIETimeScale(a); return new CIETimeScale(a);
} }
case SBIG('GAPC'):
{
return new CIEGAPC;
}
case SBIG('GTCP'): case SBIG('GTCP'):
{ {
return new CIEGTCP; return new CIEGTCP;
} }
case SBIG('GEMT'):
{
return new GIEGEMT;
}
case SBIG('MODU'): case SBIG('MODU'):
{ {
CIntElement* a = GetIntElement(in); CIntElement* a = GetIntElement(in);