mirror of
https://github.com/zeldaret/tww.git
synced 2026-08-21 14:07:29 -04:00
Implement cM3d_Len3dSqPntAndSegLine
Fix cM3d_Len2dSqPntAndSegLine
This commit is contained in:
@@ -78,6 +78,7 @@ bool cM3d_Cross_TriTri(const cM3dGTri&, const cM3dGTri&, Vec*);
|
||||
bool cM3d_Cross_CpsTri(const cM3dGCps&, cM3dGTri, Vec*);
|
||||
void cM3d_CalcVecAngle(const Vec&, short*, short*);
|
||||
void cM3d_CalcVecZAngle(const Vec&, csXyz*);
|
||||
bool cM3d_NearPos_Cps(const cM3dGCps&, const Vec&, Vec*);
|
||||
void cM3d_PlaneCrossLineProcWork(f32, f32, f32, f32, f32, f32, f32, f32*, f32*);
|
||||
int cM3d_2PlaneCrossLine(const cM3dGPla&, const cM3dGPla&, cM3dGLin*);
|
||||
bool cM3d_3PlaneCrossPos(const cM3dGPla&, const cM3dGPla&, const cM3dGPla&, Vec*);
|
||||
|
||||
@@ -36,7 +36,9 @@ public:
|
||||
f32 GetR() const { return mRadius; }
|
||||
void SetR(f32 r) { mRadius = r; }
|
||||
|
||||
void NearPos(cXyz, cXyz*) const {}
|
||||
bool NearPos(const cXyz& pos, cXyz* outPos) {
|
||||
return cM3d_NearPos_Cps(*this, pos, outPos);
|
||||
}
|
||||
}; // Size = 0x20
|
||||
|
||||
STATIC_ASSERT(0x20 == sizeof(cM3dGCps));
|
||||
|
||||
@@ -28,7 +28,10 @@ public:
|
||||
SetC(src.mCenter);
|
||||
SetR(src.mRadius);
|
||||
}
|
||||
void Set(const cXyz&, f32) {}
|
||||
void Set(const cXyz& srcCenter, f32 srcRadius) {
|
||||
SetC(srcCenter);
|
||||
SetR(srcRadius);
|
||||
}
|
||||
bool Cross(const cM3dGCps* cps, cXyz* dst) const {
|
||||
return cM3d_Cross_CpsSph(*cps, *this, dst);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user