summaryrefslogtreecommitdiffstats
path: root/src/rw/VisibilityPlugins.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/rw/VisibilityPlugins.cpp')
-rw-r--r--src/rw/VisibilityPlugins.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/rw/VisibilityPlugins.cpp b/src/rw/VisibilityPlugins.cpp
index cff1ff16..ac80eff0 100644
--- a/src/rw/VisibilityPlugins.cpp
+++ b/src/rw/VisibilityPlugins.cpp
@@ -626,6 +626,14 @@ CVisibilityPlugins::RenderPedCB(RpAtomic *atomic)
}
float
+CVisibilityPlugins::GetDistanceSquaredFromCamera(RwV3d *pos)
+{
+ RwV3d dist;
+ RwV3dSub(&dist, pos, ms_pCameraPosn);
+ return RwV3dDotProduct(&dist, &dist);
+}
+
+float
CVisibilityPlugins::GetDistanceSquaredFromCamera(RwFrame *frame)
{
RwMatrix *m;
@@ -835,12 +843,12 @@ CVisibilityPlugins::FrameCopyConstructor(void *dst, const void *src, int32, int3
}
void
-CVisibilityPlugins::SetFrameHierarchyId(RwFrame *frame, int32 id)
+CVisibilityPlugins::SetFrameHierarchyId(RwFrame *frame, uintptr id)
{
FRAMEEXT(frame)->id = id;
}
-int32
+uintptr
CVisibilityPlugins::GetFrameHierarchyId(RwFrame *frame)
{
return FRAMEEXT(frame)->id;