more fixes

This commit is contained in:
Maxime Gimeno 2020-04-22 11:02:16 +02:00
parent 1fe82bb713
commit 9bf61b7977
12 changed files with 31 additions and 31 deletions

View File

@ -135,8 +135,8 @@ void diagrammeIpelet::protected_run(int fn)
Kernel::FT incr_len=(fn<2)?50:75; Kernel::FT incr_len=(fn<2)?50:75;
//slightly increase the size of the Bbox //slightly increase the size of the Bbox
bbox=Iso_rectangle_2(bbox.min()+Kernel::Vector_2(-incr_len,-incr_len), bbox=Iso_rectangle_2((bbox.min)()+Kernel::Vector_2(-incr_len,-incr_len),
bbox.max()+Kernel::Vector_2(incr_len,incr_len)); (bbox.max)()+Kernel::Vector_2(incr_len,incr_len));

View File

@ -90,8 +90,8 @@ void IpeletMesh2::protected_run(int fn)
double alpha=0; double alpha=0;
int x=static_cast<int>( floor(bbox.max().x()-bbox.min().x()) ); int x=static_cast<int>( floor((bbox.max)().x()-(bbox.min)().x()) );
int y=static_cast<int>( floor(bbox.max().y()-bbox.min().y()) ); int y=static_cast<int>( floor((bbox.max)().y()-(bbox.min)().y()) );
int ret_val; int ret_val;
boost::tie(ret_val,alpha)=request_value_from_user<double>((boost::format("Max edge length (BBox %1%x%2%)") % x % y).str() ); boost::tie(ret_val,alpha)=request_value_from_user<double>((boost::format("Max edge length (BBox %1%x%2%)") % x % y).str() );

View File

@ -76,7 +76,7 @@ void SubSelectIpelet::protected_run(int fn)
for (std::list<Circle_2>::iterator it=cir_list.begin();it!=cir_list.end();++it) for (std::list<Circle_2>::iterator it=cir_list.begin();it!=cir_list.end();++it)
r_offsets.push_back(sqrt(CGAL::to_double(it->squared_radius()))); r_offsets.push_back(sqrt(CGAL::to_double(it->squared_radius())));
IpeMatrix tfm (1,0,0,1,-CGAL::to_double(bbox.min().x()),-CGAL::to_double(bbox.min().y())); IpeMatrix tfm (1,0,0,1,-CGAL::to_double((bbox.min)().x()),-CGAL::to_double((bbox.min)().y()));
for (std::list<Polygon_2>::iterator it=pol_list.begin();it!=pol_list.end();++it) for (std::list<Polygon_2>::iterator it=pol_list.begin();it!=pol_list.end();++it)
if(!it->is_simple()){ if(!it->is_simple()){

View File

@ -95,8 +95,8 @@ void MregularIpelet::protected_run(int fn)
draw_in_ipe(rt); draw_in_ipe(rt);
else{//Draw kth Power diagram else{//Draw kth Power diagram
double incr_len=75; double incr_len=75;
bbox=Iso_rectangle_2(bbox.min()+Kernel::Vector_2(-incr_len,-incr_len), bbox=Iso_rectangle_2((bbox.min)()+Kernel::Vector_2(-incr_len,-incr_len),
bbox.max()+Kernel::Vector_2(incr_len,incr_len)); (bbox.max)()+Kernel::Vector_2(incr_len,incr_len));
draw_dual_in_ipe(rt,bbox); //draw Voronoi Diagram draw_dual_in_ipe(rt,bbox); //draw Voronoi Diagram
} }
} }

View File

@ -96,8 +96,8 @@ namespace CGAL_svdlinf {
Kernel::FT incr_len = 75; Kernel::FT incr_len = 75;
// slightly increase the size of the bbox // slightly increase the size of the bbox
bbox = Iso_rectangle_2( bbox = Iso_rectangle_2(
bbox.min()+Kernel::Vector_2(-incr_len,-incr_len), (bbox.min)()+Kernel::Vector_2(-incr_len,-incr_len),
bbox.max()+Kernel::Vector_2(incr_len,incr_len)); (bbox.max)()+Kernel::Vector_2(incr_len,incr_len));
for (std::list<Segment_2>::iterator for (std::list<Segment_2>::iterator
sit = sg_list.begin(); sit = sg_list.begin();

View File

@ -256,8 +256,8 @@ public:
_page->DeselectAll(); _page->DeselectAll();
Iso_rectangle_2 bbox_cgal( Iso_rectangle_2 bbox_cgal(
static_cast<double>(bbox_ipe.Min().iX),static_cast<double>(bbox_ipe.Min().iY), static_cast<double>((bbox_ipe.Min)().iX),static_cast<double>((bbox_ipe.Min)().iY),
static_cast<double>(bbox_ipe.Max().iX),static_cast<double>(bbox_ipe.Max().iY) static_cast<double>((bbox_ipe.Max)().iX),static_cast<double>((bbox_ipe.Max)().iY)
); );
return bbox_cgal; return bbox_cgal;

View File

@ -57,8 +57,8 @@ template <typename K>
inline std::enable_if_t<std::is_same<typename K::Rep_tag, Cartesian_tag>::value, std::size_t> inline std::enable_if_t<std::is_same<typename K::Rep_tag, Cartesian_tag>::value, std::size_t>
hash_value (const Iso_rectangle_2<K>& iso_rectangle) hash_value (const Iso_rectangle_2<K>& iso_rectangle)
{ {
std::size_t result = hash_value(iso_rectangle.min()); std::size_t result = hash_value((iso_rectangle.min)());
boost::hash_combine(result, hash_value(iso_rectangle.max())); boost::hash_combine(result, hash_value((iso_rectangle.max)()));
return result; return result;
} }
@ -126,8 +126,8 @@ template <typename K>
inline std::enable_if_t<std::is_same<typename K::Rep_tag, Cartesian_tag>::value, std::size_t> inline std::enable_if_t<std::is_same<typename K::Rep_tag, Cartesian_tag>::value, std::size_t>
hash_value (const Iso_cuboid_3<K>& iso_cuboid) hash_value (const Iso_cuboid_3<K>& iso_cuboid)
{ {
std::size_t result = hash_value(iso_cuboid.min()); std::size_t result = hash_value((iso_cuboid.min)());
boost::hash_combine(result, hash_value(iso_cuboid.max())); boost::hash_combine(result, hash_value((iso_cuboid.max)()));
return result; return result;
} }

View File

@ -91,8 +91,8 @@ int main() {
assert(b1.bounded_side(qq1)==CGAL::ON_BOUNDARY); assert(b1.bounded_side(qq1)==CGAL::ON_BOUNDARY);
assert(b1.bounded_side(qq4)==CGAL::ON_UNBOUNDED_SIDE); assert(b1.bounded_side(qq4)==CGAL::ON_UNBOUNDED_SIDE);
assert(b1.bounded_side(mm1)==CGAL::ON_BOUNDED_SIDE); assert(b1.bounded_side(mm1)==CGAL::ON_BOUNDED_SIDE);
// std::cout << "b1.min()=" << b1.min() << std::endl; // std::cout << "(b1.min)()=" << (b1.min)() << std::endl;
// std::cout << "b1.max()=" << b1.max() << std::endl; // std::cout << "(b1.max)()=" << (b1.max)() << std::endl;
std::cout << "volume of b1=" << b1.volume() << std::endl; std::cout << "volume of b1=" << b1.volume() << std::endl;
std::cout << "volume of b4=" << b4.volume() << std::endl; std::cout << "volume of b4=" << b4.volume() << std::endl;
std::cout << "volume of b5=" << b5.volume() << std::endl; std::cout << "volume of b5=" << b5.volume() << std::endl;

View File

@ -94,8 +94,8 @@ int main() {
assert(b1.bounded_side(qq1)==CGAL::ON_BOUNDARY); assert(b1.bounded_side(qq1)==CGAL::ON_BOUNDARY);
assert(b1.bounded_side(qq4)==CGAL::ON_UNBOUNDED_SIDE); assert(b1.bounded_side(qq4)==CGAL::ON_UNBOUNDED_SIDE);
assert(b1.bounded_side(mm1)==CGAL::ON_BOUNDED_SIDE); assert(b1.bounded_side(mm1)==CGAL::ON_BOUNDED_SIDE);
// std::cout << "b1.min()=" << b1.min() << std::endl; // std::cout << "(b1.min)()=" << (b1.min)() << std::endl;
// std::cout << "b1.max()=" << b1.max() << std::endl; // std::cout << "(b1.max)()=" << (b1.max)() << std::endl;
std::cout << "volume of b1=" << b1.volume() << std::endl; std::cout << "volume of b1=" << b1.volume() << std::endl;
std::cout << "volume of b4=" << b4.volume() << std::endl; std::cout << "volume of b4=" << b4.volume() << std::endl;
std::cout << "volume of b5=" << b5.volume() << std::endl; std::cout << "volume of b5=" << b5.volume() << std::endl;

View File

@ -106,9 +106,9 @@ int main(int argc, char* argv[])
t.start(); t.start();
std::cerr << "bbox"<< std::endl; std::cerr << "bbox"<< std::endl;
Iso_cuboid_3 ic = CGAL::bounding_box(points(m).begin(), points(m).end()); Iso_cuboid_3 ic = CGAL::bounding_box(points(m).begin(), points(m).end());
Point_3 p = midpoint(ic.min(), ic.max()); Point_3 p = midpoint((ic.min)(), (ic.max)());
double zmin = ic.min().z(); double zmin = (ic.min)().z();
double zmax = ic.max().z(); double zmax = (ic.max)().z();
double delta = (zmax - zmin)/N; double delta = (zmax - zmin)/N;
std::cerr << "slicer"<< std::endl; std::cerr << "slicer"<< std::endl;

View File

@ -102,9 +102,9 @@ private Q_SLOTS:
connect(item, &Scene_surface_mesh_item::aboutToBeDestroyed, connect(item, &Scene_surface_mesh_item::aboutToBeDestroyed,
this, &DoTreesIntersectplugin::cleanup); this, &DoTreesIntersectplugin::cleanup);
CGAL::qglviewer::Vec pos((item->bbox().min(0) + item->bbox().max(0))/2.0, CGAL::qglviewer::Vec pos(((item->bbox().min)(0) + (item->bbox().max)(0))/2.0,
(item->bbox().min(1) + item->bbox().max(1))/2.0, ((item->bbox().min)(1) + (item->bbox().max)(1))/2.0,
(item->bbox().min(2) + item->bbox().max(2))/2.0); ((item->bbox().min)(2) + (item->bbox().max)(2))/2.0);
Scene_movable_sm_item* mov_item = new Scene_movable_sm_item(pos,item->face_graph(),""); Scene_movable_sm_item* mov_item = new Scene_movable_sm_item(pos,item->face_graph(),"");
connect(mov_item->manipulatedFrame(), &CGAL::qglviewer::ManipulatedFrame::modified, connect(mov_item->manipulatedFrame(), &CGAL::qglviewer::ManipulatedFrame::modified,

View File

@ -417,12 +417,12 @@ void Polyhedron_demo_affine_transform_plugin::grid()
Scene_item::Bbox b = item->bbox(); Scene_item::Bbox b = item->bbox();
double x_t(CGAL::sqrt(CGAL::squared_distance(Kernel::Point_3(b.min(0), b.min(1), b.min(2)), double x_t(CGAL::sqrt(CGAL::squared_distance(Kernel::Point_3((b.min)(0), (b.min)(1), (b.min)(2)),
Kernel::Point_3(b.max(0), b.min(1), b.min(2))))), Kernel::Point_3((b.max)(0), (b.min)(1), (b.min)(2))))),
y_t(CGAL::sqrt(CGAL::squared_distance(Kernel::Point_3(b.min(0), b.min(1), b.min(2)), y_t(CGAL::sqrt(CGAL::squared_distance(Kernel::Point_3((b.min)(0), (b.min)(1), (b.min)(2)),
Kernel::Point_3(b.min(0), b.max(1), b.min(2))))), Kernel::Point_3((b.min)(0), (b.max)(1), (b.min)(2))))),
z_t(CGAL::sqrt(CGAL::squared_distance(Kernel::Point_3(b.min(0), b.min(1), b.min(2)), z_t(CGAL::sqrt(CGAL::squared_distance(Kernel::Point_3((b.min)(0), (b.min)(1), (b.min)(2)),
Kernel::Point_3(b.min(0), b.min(1), b.max(2))))); Kernel::Point_3((b.min)(0), (b.min)(1), (b.max)(2)))));
GridDialog dialog(mw); GridDialog dialog(mw);
dialog.x_space_doubleSpinBox->setValue(x_t); dialog.x_space_doubleSpinBox->setValue(x_t);