7 #pragma warning(disable : 4251 4100)
68 SphericalGrid(
const size_t bs[3],
const size_t min[3],
const size_t max[3],
const double extents[6],
const size_t permutation[3],
const bool periodic[3],
float **blks);
82 SphericalGrid(
const size_t bs[3],
const size_t min[3],
const size_t max[3],
const double extents[6],
const size_t permutation[3],
const bool periodic[3],
float **blks,
float missing_value);
86 float GetValue(
double x,
double y,
double z)
const;
94 for (
int i = 0; i < 6; i++) extents[i] = _extentsC[i];
99 virtual void GetBoundingBox(
const size_t min[3],
const size_t max[3],
double extents[6])
const;
107 void GetIJKIndex(
double x,
double y,
double z,
size_t *i,
size_t *j,
size_t *k)
const;
111 void GetIJKIndexFloor(
double x,
double y,
double z,
size_t *i,
size_t *j,
size_t *k)
const;
128 static inline void CartToSph(
double x,
double y,
double z,
double *phi,
double *theta,
double *r);
130 static inline void SphToCart(
double phi,
double theta,
double r,
double *x,
double *y,
double *z);
134 std::vector<long> _permutation;
136 void _GetUserExtents(
double extents[6])
const;
138 void _permute(
const std::vector<long> &permutation,
double result[3],
double x,
double y,
double z)
const;
This class implements a 2D or 3D regular grid.
This class implements a 2D or 3D spherical grid.
static void CartToSph(double x, double y, double z, double *phi, double *theta, double *r)
virtual void GetBoundingBox(const size_t min[3], const size_t max[3], double extents[6]) const
virtual void GetUserExtents(double extents[6]) const
int GetUserCoordinates(size_t i, size_t j, size_t k, double *x, double *y, double *z) const
SphericalGrid(const size_t bs[3], const size_t min[3], const size_t max[3], const double extents[6], const size_t permutation[3], const bool periodic[3], float **blks)
float GetValue(double x, double y, double z) const
static void SphToCart(double phi, double theta, double r, double *x, double *y, double *z)
void GetIJKIndex(double x, double y, double z, size_t *i, size_t *j, size_t *k) const
SphericalGrid(const size_t bs[3], const size_t min[3], const size_t max[3], const double extents[6], const size_t permutation[3], const bool periodic[3], float **blks, float missing_value)
bool InsideGrid(double x, double y, double z) const
void GetIJKIndexFloor(double x, double y, double z, size_t *i, size_t *j, size_t *k) const