Esempio n. 1
0
rt_centroid_sphere::rt_centroid_sphere(const rt_point& p)
    : rt_sphere(p.dim(),
        new double[rt_centroid_sphere::dim2size(p.dim())/sizeof(double)]),
      rank(p.dim(), coord + (rt_sphere::dim2size(p.dim())/sizeof(double)))
{
    dealloc = true;
    _init(p, 0.0, 1.0);
}
Esempio n. 2
0
rt_rrect::rt_rrect(const rt_point& p)
    : rt_rect(p.dim(),
	new double[rt_rrect::dim2size(p.dim())/sizeof(double)]),
      rank(p.dim(), coord + (rt_rect::dim2size(p.dim())/sizeof(double)))
{
    dealloc = true;
    for (int i = 0; i < dimension; i++) {
        hi(i) = lo(i) = p.co(i);
    }
    rank.nrec() = 1;
}