2023-11-19 09:38:07 -05:00
|
|
|
#include "viewroi.h"
|
|
|
|
|
2023-12-11 16:33:46 -05:00
|
|
|
#include "decomp.h"
|
2023-11-19 09:38:07 -05:00
|
|
|
|
2024-01-12 19:34:38 -05:00
|
|
|
#include <vec.h>
|
|
|
|
|
2023-11-19 09:38:07 -05:00
|
|
|
DECOMP_SIZE_ASSERT(ViewROI, 0xe0)
|
|
|
|
|
2024-01-01 19:17:38 -05:00
|
|
|
// GLOBAL: LEGO1 0x101013d8
|
|
|
|
undefined g_unk101013d8 = 0;
|
|
|
|
|
2023-12-06 07:10:45 -05:00
|
|
|
// FUNCTION: LEGO1 0x100a9eb0
|
2023-11-19 09:38:07 -05:00
|
|
|
float ViewROI::IntrinsicImportance() const
|
|
|
|
{
|
|
|
|
return .5;
|
|
|
|
} // for now
|
|
|
|
|
2023-12-06 07:10:45 -05:00
|
|
|
// FUNCTION: LEGO1 0x100a9ec0
|
2023-11-19 09:38:07 -05:00
|
|
|
const Tgl::Group* ViewROI::GetGeometry() const
|
|
|
|
{
|
|
|
|
return geometry;
|
|
|
|
}
|
|
|
|
|
2023-12-06 07:10:45 -05:00
|
|
|
// FUNCTION: LEGO1 0x100a9ed0
|
2023-11-19 09:38:07 -05:00
|
|
|
Tgl::Group* ViewROI::GetGeometry()
|
|
|
|
{
|
|
|
|
return geometry;
|
|
|
|
}
|
|
|
|
|
2023-12-06 07:10:45 -05:00
|
|
|
// FUNCTION: LEGO1 0x100a9ee0
|
2024-01-12 19:34:38 -05:00
|
|
|
void ViewROI::UpdateWorldData(const MxMatrix& parent2world)
|
2023-11-19 09:38:07 -05:00
|
|
|
{
|
|
|
|
OrientableROI::UpdateWorldData(parent2world);
|
2024-01-12 19:34:38 -05:00
|
|
|
|
2023-11-19 09:38:07 -05:00
|
|
|
if (geometry) {
|
2024-01-12 19:34:38 -05:00
|
|
|
Tgl::FloatMatrix4 matrix;
|
|
|
|
Matrix4 in(matrix);
|
|
|
|
SETMAT4(in, m_local2world);
|
|
|
|
Tgl::Result result = geometry->SetTransformation(matrix);
|
2023-11-19 09:38:07 -05:00
|
|
|
// assert(Tgl::Succeeded(result));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2024-01-01 19:17:38 -05:00
|
|
|
// FUNCTION: LEGO1 0x100aa500
|
|
|
|
undefined ViewROI::SetUnk101013d8(undefined p_flag)
|
2023-11-19 09:38:07 -05:00
|
|
|
{
|
2024-01-01 19:17:38 -05:00
|
|
|
undefined oldFlag = g_unk101013d8;
|
|
|
|
g_unk101013d8 = p_flag;
|
|
|
|
return oldFlag;
|
2023-11-19 09:38:07 -05:00
|
|
|
}
|