2022-09-29 23:55:38 +00:00
|
|
|
#ifndef _CSPHERE_HPP
|
|
|
|
#define _CSPHERE_HPP
|
|
|
|
|
|
|
|
#include "types.h"
|
|
|
|
|
|
|
|
#include "Kyoto/Math/CVector3f.hpp"
|
2022-10-05 23:45:48 +00:00
|
|
|
#include "Kyoto/Math/CUnitVector3f.hpp"
|
2022-09-29 23:55:38 +00:00
|
|
|
|
|
|
|
class CSphere {
|
|
|
|
public:
|
|
|
|
CSphere(const CVector3f& pos, f32 radius) : x0_pos(pos), xc_radius(radius) {}
|
|
|
|
|
2022-10-05 23:45:48 +00:00
|
|
|
CUnitVector3f GetSurfaceNormal(const CVector3f& v) const;
|
2022-09-29 23:55:38 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
CVector3f x0_pos;
|
|
|
|
f32 xc_radius;
|
|
|
|
};
|
|
|
|
CHECK_SIZEOF(CSphere, 0x10)
|
|
|
|
|
|
|
|
#endif
|