mirror of https://github.com/CGAL/cgal
rename add_in_graphic_buffer into add_in_graphic_storage
This commit is contained in:
parent
b04d7a6b71
commit
519c7cc1a5
|
|
@ -119,7 +119,7 @@ void compute_elements(const FG &fg,
|
||||||
} // draw_function_for_FG
|
} // draw_function_for_FG
|
||||||
|
|
||||||
template <typename BufferType=float, class FG, class DrawingFunctor>
|
template <typename BufferType=float, class FG, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer_for_fg(const FG &fg,
|
void add_in_graphic_storage_for_fg(const FG &fg,
|
||||||
CGAL::Graphic_storage<BufferType> &graphic_buffer,
|
CGAL::Graphic_storage<BufferType> &graphic_buffer,
|
||||||
const DrawingFunctor &drawing_functor)
|
const DrawingFunctor &drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -127,7 +127,7 @@ void add_in_graphic_buffer_for_fg(const FG &fg,
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename BufferType=float, class FG>
|
template <typename BufferType=float, class FG>
|
||||||
void add_in_graphic_buffer_for_fg(const FG &fg,
|
void add_in_graphic_storage_for_fg(const FG &fg,
|
||||||
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
||||||
{
|
{
|
||||||
Drawing_functor<FG,
|
Drawing_functor<FG,
|
||||||
|
|
@ -151,7 +151,7 @@ void add_in_graphic_buffer_for_fg(const FG &fg,
|
||||||
return get_random_color(CGAL::get_default_random());
|
return get_random_color(CGAL::get_default_random());
|
||||||
};
|
};
|
||||||
|
|
||||||
add_in_graphic_buffer_for_fg(fg, graphic_buffer, drawing_functor);
|
add_in_graphic_storage_for_fg(fg, graphic_buffer, drawing_functor);
|
||||||
}
|
}
|
||||||
|
|
||||||
} // End namespace CGAL
|
} // End namespace CGAL
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,37 @@ namespace CGAL {
|
||||||
\cgalAutoToc
|
\cgalAutoToc
|
||||||
\author Guillaume Damiand, Mostafa Ashraf
|
\author Guillaume Damiand, Mostafa Ashraf
|
||||||
|
|
||||||
|
Two main use:
|
||||||
|
|
||||||
|
1) draw
|
||||||
|
draw(XXX)
|
||||||
|
|
||||||
|
2) through graphic storage
|
||||||
|
|
||||||
|
Graohic_storage gs;
|
||||||
|
add_in_graphic_storage(XXX, gs);
|
||||||
|
draw_graphic_storage(gs);
|
||||||
|
|
||||||
|
3) basic interactions
|
||||||
|
|
||||||
|
introduce qapplication and basic viewer class
|
||||||
|
|
||||||
|
4) advanced interactions
|
||||||
|
|
||||||
|
introduce basic viewer class
|
||||||
|
|
||||||
|
5) examples
|
||||||
|
|
||||||
|
5.1) simple draw
|
||||||
|
|
||||||
|
5.2) draw with drawing functor
|
||||||
|
|
||||||
|
5.3) draw 2 different DS in a same viewer
|
||||||
|
|
||||||
|
5.4) interaction with qapplication and basic viewer
|
||||||
|
|
||||||
|
5.5) mix different basic viewer in a same window (code laurent ?)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -56,8 +56,8 @@ int main(void)
|
||||||
{ point_set.insert(it.first); }
|
{ point_set.insert(it.first); }
|
||||||
|
|
||||||
CGAL::Graphic_storage<float> graphic_buffer;
|
CGAL::Graphic_storage<float> graphic_buffer;
|
||||||
CGAL::add_in_graphic_buffer(point_set, graphic_buffer, Drawing_functor_green_points());
|
CGAL::add_in_graphic_storage(point_set, graphic_buffer, Drawing_functor_green_points());
|
||||||
CGAL::add_in_graphic_buffer(output_mesh, graphic_buffer);
|
CGAL::add_in_graphic_storage(output_mesh, graphic_buffer);
|
||||||
CGAL::draw_graphic_storage(graphic_buffer);
|
CGAL::draw_graphic_storage(graphic_buffer);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -102,7 +102,7 @@ int main(int argc, char* argv[])
|
||||||
Drawing_functor_small_faces df(sm);
|
Drawing_functor_small_faces df(sm);
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
|
|
||||||
add_in_graphic_buffer(sm, buffer, df);
|
add_in_graphic_storage(sm, buffer, df);
|
||||||
CGAL::QApplication_and_basic_viewer app(buffer, "Small faces");
|
CGAL::QApplication_and_basic_viewer app(buffer, "Small faces");
|
||||||
if(app)
|
if(app)
|
||||||
{
|
{
|
||||||
|
|
@ -118,7 +118,7 @@ int main(int argc, char* argv[])
|
||||||
(QString("Small faces threshold=%1.").arg(df.m_threshold));
|
(QString("Small faces threshold=%1.").arg(df.m_threshold));
|
||||||
|
|
||||||
basic_viewer->clear();
|
basic_viewer->clear();
|
||||||
add_in_graphic_buffer(sm, buffer, df);
|
add_in_graphic_storage(sm, buffer, df);
|
||||||
basic_viewer->redraw();
|
basic_viewer->redraw();
|
||||||
}
|
}
|
||||||
else if ((e->key() == ::Qt::Key_D) && (modifiers == ::Qt::NoButton))
|
else if ((e->key() == ::Qt::Key_D) && (modifiers == ::Qt::NoButton))
|
||||||
|
|
@ -129,7 +129,7 @@ int main(int argc, char* argv[])
|
||||||
(QString("Small faces threshold=%1.").arg(df.m_threshold));
|
(QString("Small faces threshold=%1.").arg(df.m_threshold));
|
||||||
|
|
||||||
basic_viewer->clear();
|
basic_viewer->clear();
|
||||||
add_in_graphic_buffer(sm, buffer, df);
|
add_in_graphic_storage(sm, buffer, df);
|
||||||
basic_viewer->redraw();
|
basic_viewer->redraw();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -53,7 +53,7 @@ void Viewer::setScene(Scene *scene_, bool doredraw)
|
||||||
scene = scene_;
|
scene = scene_;
|
||||||
|
|
||||||
if (scene->lcc!=nullptr)
|
if (scene->lcc!=nullptr)
|
||||||
{ CGAL::add_in_graphic_buffer(*scene->lcc, gBuffer, m_drawing_functor); }
|
{ CGAL::add_in_graphic_storage(*scene->lcc, gBuffer, m_drawing_functor); }
|
||||||
|
|
||||||
if (doredraw)
|
if (doredraw)
|
||||||
{ Base::redraw(); }
|
{ Base::redraw(); }
|
||||||
|
|
@ -62,7 +62,7 @@ void Viewer::setScene(Scene *scene_, bool doredraw)
|
||||||
void Viewer::sceneChanged()
|
void Viewer::sceneChanged()
|
||||||
{
|
{
|
||||||
gBuffer.clear();
|
gBuffer.clear();
|
||||||
CGAL::add_in_graphic_buffer(*scene->lcc, gBuffer, m_drawing_functor);
|
CGAL::add_in_graphic_storage(*scene->lcc, gBuffer, m_drawing_functor);
|
||||||
|
|
||||||
this->camera()->setSceneBoundingBox(
|
this->camera()->setSceneBoundingBox(
|
||||||
CGAL::qglviewer::Vec(gBuffer.get_bounding_box().xmin(),
|
CGAL::qglviewer::Vec(gBuffer.get_bounding_box().xmin(),
|
||||||
|
|
|
||||||
|
|
@ -232,14 +232,14 @@ void compute_elements(const LCC& lcc,
|
||||||
CGAL::Linear_cell_complex_base<d_, ambient_dim, Traits_, Items_, Alloc_, \
|
CGAL::Linear_cell_complex_base<d_, ambient_dim, Traits_, Items_, Alloc_, \
|
||||||
Map, Refs, Storage_>
|
Map, Refs, Storage_>
|
||||||
|
|
||||||
// add_in_graphic_buffer: to add a LCC in the given graphic buffer, with a
|
// add_in_graphic_storage: to add a LCC in the given graphic buffer, with a
|
||||||
// drawing functor.
|
// drawing functor.
|
||||||
template<unsigned int d_, unsigned int ambient_dim, class Traits_,
|
template<unsigned int d_, unsigned int ambient_dim, class Traits_,
|
||||||
class Items_, class Alloc_,
|
class Items_, class Alloc_,
|
||||||
template <unsigned int, class, class, class, class> class Map,
|
template <unsigned int, class, class, class, class> class Map,
|
||||||
class Refs, class Storage_,
|
class Refs, class Storage_,
|
||||||
typename BufferType=float, class DrawingFunctor>
|
typename BufferType=float, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_LCC_TYPE& alcc,
|
void add_in_graphic_storage(const CGAL_LCC_TYPE& alcc,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor& drawing_functor)
|
const DrawingFunctor& drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -247,13 +247,13 @@ void add_in_graphic_buffer(const CGAL_LCC_TYPE& alcc,
|
||||||
graphic_buffer, drawing_functor);
|
graphic_buffer, drawing_functor);
|
||||||
}
|
}
|
||||||
|
|
||||||
// add_in_graphic_buffer: to add a LCC in the given graphic buffer, without a
|
// add_in_graphic_storage: to add a LCC in the given graphic buffer, without a
|
||||||
// drawing functor. Use default drawing values.
|
// drawing functor. Use default drawing values.
|
||||||
template<unsigned int d_, unsigned int ambient_dim, class Traits_,
|
template<unsigned int d_, unsigned int ambient_dim, class Traits_,
|
||||||
class Items_, class Alloc_,
|
class Items_, class Alloc_,
|
||||||
template <unsigned int, class, class, class, class> class Map,
|
template <unsigned int, class, class, class, class> class Map,
|
||||||
class Refs, class Storage_, typename BufferType=float>
|
class Refs, class Storage_, typename BufferType=float>
|
||||||
void add_in_graphic_buffer(const CGAL_LCC_TYPE& alcc,
|
void add_in_graphic_storage(const CGAL_LCC_TYPE& alcc,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
||||||
{
|
{
|
||||||
CGAL::Drawing_functor_with_volume<CGAL_LCC_TYPE,
|
CGAL::Drawing_functor_with_volume<CGAL_LCC_TYPE,
|
||||||
|
|
@ -274,7 +274,7 @@ void add_in_graphic_buffer(const CGAL_LCC_TYPE& alcc,
|
||||||
return get_random_color(random);
|
return get_random_color(random);
|
||||||
};
|
};
|
||||||
|
|
||||||
add_in_graphic_buffer(alcc, graphic_buffer, drawing_functor_with_volume);
|
add_in_graphic_storage(alcc, graphic_buffer, drawing_functor_with_volume);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -289,7 +289,7 @@ void draw(const CGAL_LCC_TYPE& alcc, const DrawingFunctor& drawing_functor,
|
||||||
const char *title="LCC Basic Viewer")
|
const char *title="LCC Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(alcc, buffer, drawing_functor);
|
add_in_graphic_storage(alcc, buffer, drawing_functor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -301,7 +301,7 @@ template<unsigned int d_, unsigned int ambient_dim, class Traits_,
|
||||||
void draw(const CGAL_LCC_TYPE& alcc, const char *title="LCC Basic Viewer")
|
void draw(const CGAL_LCC_TYPE& alcc, const char *title="LCC Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(alcc, buffer);
|
add_in_graphic_storage(alcc, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -236,10 +236,10 @@ void compute_elements(const Nef_Polyhedron &nef,
|
||||||
|
|
||||||
#define CGAL_NEF3_TYPE Nef_polyhedron_3<Kernel_, Items_, Mark_>
|
#define CGAL_NEF3_TYPE Nef_polyhedron_3<Kernel_, Items_, Mark_>
|
||||||
|
|
||||||
// add_in_graphic_buffer
|
// add_in_graphic_storage
|
||||||
template <typename Kernel_, typename Items_, typename Mark_,
|
template <typename Kernel_, typename Items_, typename Mark_,
|
||||||
typename BufferType=float, class DrawingFunctor>
|
typename BufferType=float, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_NEF3_TYPE &anef,
|
void add_in_graphic_storage(const CGAL_NEF3_TYPE &anef,
|
||||||
CGAL::Graphic_storage<BufferType> &graphic_buffer,
|
CGAL::Graphic_storage<BufferType> &graphic_buffer,
|
||||||
const DrawingFunctor &drawing_functor)
|
const DrawingFunctor &drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -250,7 +250,7 @@ void add_in_graphic_buffer(const CGAL_NEF3_TYPE &anef,
|
||||||
|
|
||||||
template <typename Kernel_, typename Items_, typename Mark_,
|
template <typename Kernel_, typename Items_, typename Mark_,
|
||||||
typename BufferType=float>
|
typename BufferType=float>
|
||||||
void add_in_graphic_buffer(const CGAL_NEF3_TYPE &anef,
|
void add_in_graphic_storage(const CGAL_NEF3_TYPE &anef,
|
||||||
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
||||||
{
|
{
|
||||||
// Default functor; user can add his own functor.
|
// Default functor; user can add his own functor.
|
||||||
|
|
@ -274,7 +274,7 @@ void add_in_graphic_buffer(const CGAL_NEF3_TYPE &anef,
|
||||||
return get_random_color(random);
|
return get_random_color(random);
|
||||||
};
|
};
|
||||||
|
|
||||||
add_in_graphic_buffer(anef, graphic_buffer, drawing_functor);
|
add_in_graphic_storage(anef, graphic_buffer, drawing_functor);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -287,7 +287,7 @@ void draw(const CGAL_NEF3_TYPE &anef,
|
||||||
const char *title="Nef Polyhedron Viewer")
|
const char *title="Nef Polyhedron Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer(anef, buffer, drawing_functor);
|
add_in_graphic_storage(anef, buffer, drawing_functor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -297,7 +297,7 @@ void draw(const CGAL_NEF3_TYPE &anef,
|
||||||
const char *title="Nef Polyhedron Viewer")
|
const char *title="Nef Polyhedron Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer(anef, buffer);
|
add_in_graphic_storage(anef, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -197,7 +197,7 @@ void compute_elements(const P2T2& p2t2,
|
||||||
#define CGAL_P2T2_TYPE CGAL::Periodic_2_triangulation_2<Gt, Tds >
|
#define CGAL_P2T2_TYPE CGAL::Periodic_2_triangulation_2<Gt, Tds >
|
||||||
|
|
||||||
template <typename BufferType=float, class Gt, class Tds, class DrawingFunctor>
|
template <typename BufferType=float, class Gt, class Tds, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_P2T2_TYPE& p2t2,
|
void add_in_graphic_storage(const CGAL_P2T2_TYPE& p2t2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor& drawing_functor)
|
const DrawingFunctor& drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -205,7 +205,7 @@ void add_in_graphic_buffer(const CGAL_P2T2_TYPE& p2t2,
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename BufferType=float, class Gt, class Tds>
|
template <typename BufferType=float, class Gt, class Tds>
|
||||||
void add_in_graphic_buffer(const CGAL_P2T2_TYPE& p2t2,
|
void add_in_graphic_storage(const CGAL_P2T2_TYPE& p2t2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
||||||
{
|
{
|
||||||
CGAL::Drawing_functor_periodic_2_triangulation_2
|
CGAL::Drawing_functor_periodic_2_triangulation_2
|
||||||
|
|
@ -214,7 +214,7 @@ void add_in_graphic_buffer(const CGAL_P2T2_TYPE& p2t2,
|
||||||
typename CGAL_P2T2_TYPE::Periodic_segment_iterator,
|
typename CGAL_P2T2_TYPE::Periodic_segment_iterator,
|
||||||
typename CGAL_P2T2_TYPE::Periodic_triangle_iterator> drawing_functor;
|
typename CGAL_P2T2_TYPE::Periodic_triangle_iterator> drawing_functor;
|
||||||
|
|
||||||
add_in_graphic_buffer(p2t2, graphic_buffer, drawing_functor);
|
add_in_graphic_storage(p2t2, graphic_buffer, drawing_functor);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -226,7 +226,7 @@ void draw(const CGAL_P2T2_TYPE& ap2t2,
|
||||||
const char* title="2D Periodic Triangulation Viewer")
|
const char* title="2D Periodic Triangulation Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer(ap2t2, buffer, drawing_functor);
|
add_in_graphic_storage(ap2t2, buffer, drawing_functor);
|
||||||
draw_graphic_storage(buffer);
|
draw_graphic_storage(buffer);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -241,7 +241,7 @@ void draw(const CGAL_P2T2_TYPE& ap2t2,
|
||||||
typename CGAL_P2T2_TYPE::Periodic_segment_iterator,
|
typename CGAL_P2T2_TYPE::Periodic_segment_iterator,
|
||||||
typename CGAL_P2T2_TYPE::Periodic_triangle_iterator> drawing_functor;
|
typename CGAL_P2T2_TYPE::Periodic_triangle_iterator> drawing_functor;
|
||||||
|
|
||||||
add_in_graphic_buffer(ap2t2, buffer, drawing_functor);
|
add_in_graphic_storage(ap2t2, buffer, drawing_functor);
|
||||||
QApplication_and_basic_viewer app(buffer, title);
|
QApplication_and_basic_viewer app(buffer, title);
|
||||||
if(app)
|
if(app)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -69,7 +69,7 @@ void compute_elements(const PointSet& pointset,
|
||||||
} // namespace draw_function_for_PointSet
|
} // namespace draw_function_for_PointSet
|
||||||
|
|
||||||
template <class P, class V, typename BufferType=float, class DrawingFunctor>
|
template <class P, class V, typename BufferType=float, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const Point_set_3<P, V>& apointset,
|
void add_in_graphic_storage(const Point_set_3<P, V>& apointset,
|
||||||
Graphic_storage<BufferType>& graphic_buffer,
|
Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor& drawing_functor)
|
const DrawingFunctor& drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -79,13 +79,13 @@ void add_in_graphic_buffer(const Point_set_3<P, V>& apointset,
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class P, class V, typename BufferType=float>
|
template <class P, class V, typename BufferType=float>
|
||||||
void add_in_graphic_buffer(const Point_set_3<P, V>& apointset,
|
void add_in_graphic_storage(const Point_set_3<P, V>& apointset,
|
||||||
Graphic_storage<BufferType>& graphic_buffer)
|
Graphic_storage<BufferType>& graphic_buffer)
|
||||||
{
|
{
|
||||||
CGAL::Drawing_functor<Point_set_3<P, V>,
|
CGAL::Drawing_functor<Point_set_3<P, V>,
|
||||||
typename Point_set_3<P, V>::const_iterator,
|
typename Point_set_3<P, V>::const_iterator,
|
||||||
int, int> drawing_functor;
|
int, int> drawing_functor;
|
||||||
add_in_graphic_buffer(apointset, graphic_buffer, drawing_functor);
|
add_in_graphic_storage(apointset, graphic_buffer, drawing_functor);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -97,7 +97,7 @@ void draw(const Point_set_3<P, V>& apointset,
|
||||||
const char *title="Point_set_3 Basic Viewer")
|
const char *title="Point_set_3 Basic Viewer")
|
||||||
{
|
{
|
||||||
Graphic_storage<float> buffer;
|
Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(apointset, buffer, drawing_functor);
|
add_in_graphic_storage(apointset, buffer, drawing_functor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -106,7 +106,7 @@ void draw(const Point_set_3<P, V>& apointset,
|
||||||
const char *title="Point_set_3 Basic Viewer")
|
const char *title="Point_set_3 Basic Viewer")
|
||||||
{
|
{
|
||||||
Graphic_storage<float> buffer;
|
Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(apointset, buffer);
|
add_in_graphic_storage(apointset, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -99,16 +99,16 @@ void compute_elements(const P2& p2,
|
||||||
|
|
||||||
#define CGAL_P2_TYPE CGAL::Polygon_2<T, C>
|
#define CGAL_P2_TYPE CGAL::Polygon_2<T, C>
|
||||||
|
|
||||||
// Specializations of add_in_graphic_buffer function
|
// Specializations of add_in_graphic_storage function
|
||||||
|
|
||||||
template<typename BufferType=float, class T, class C, class DrawingFunctor>
|
template<typename BufferType=float, class T, class C, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_P2_TYPE& ap2,
|
void add_in_graphic_storage(const CGAL_P2_TYPE& ap2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor& drawingfunctor)
|
const DrawingFunctor& drawingfunctor)
|
||||||
{ draw_function_for_p2::compute_elements(ap2, graphic_buffer, drawingfunctor); }
|
{ draw_function_for_p2::compute_elements(ap2, graphic_buffer, drawingfunctor); }
|
||||||
|
|
||||||
template<typename BufferType=float, class T, class C>
|
template<typename BufferType=float, class T, class C>
|
||||||
void add_in_graphic_buffer(const CGAL_P2_TYPE& ap2,
|
void add_in_graphic_storage(const CGAL_P2_TYPE& ap2,
|
||||||
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
||||||
{
|
{
|
||||||
CGAL::Drawing_functor<CGAL_P2_TYPE,
|
CGAL::Drawing_functor<CGAL_P2_TYPE,
|
||||||
|
|
@ -127,7 +127,7 @@ void draw(const CGAL_P2_TYPE &ap2,
|
||||||
const char *title="Polygon_2 Basic Viewer")
|
const char *title="Polygon_2 Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(ap2, buffer);
|
add_in_graphic_storage(ap2, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -137,7 +137,7 @@ void draw(const CGAL_P2_TYPE &ap2,
|
||||||
const char *title="Polygon_2 Basic Viewer")
|
const char *title="Polygon_2 Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(ap2, buffer, drawingfunctor);
|
add_in_graphic_storage(ap2, buffer, drawingfunctor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -127,7 +127,7 @@ void compute_elements(const P2& p2, Graphic_storage<BufferType> &graphic_buffer,
|
||||||
#define CGAL_P2_WITH_HOLES_TYPE CGAL::Polygon_with_holes_2<T, C>
|
#define CGAL_P2_WITH_HOLES_TYPE CGAL::Polygon_with_holes_2<T, C>
|
||||||
|
|
||||||
template <class T, class C, typename BufferType=float, class DrawingFunctor>
|
template <class T, class C, typename BufferType=float, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_P2_WITH_HOLES_TYPE& p2,
|
void add_in_graphic_storage(const CGAL_P2_WITH_HOLES_TYPE& p2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor &drawing_functor)
|
const DrawingFunctor &drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -136,7 +136,7 @@ void add_in_graphic_buffer(const CGAL_P2_WITH_HOLES_TYPE& p2,
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class T, class C, typename BufferType=float>
|
template <class T, class C, typename BufferType=float>
|
||||||
void add_in_graphic_buffer(const CGAL_P2_WITH_HOLES_TYPE& p2,
|
void add_in_graphic_storage(const CGAL_P2_WITH_HOLES_TYPE& p2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
||||||
{
|
{
|
||||||
Drawing_functor<CGAL_P2_WITH_HOLES_TYPE,
|
Drawing_functor<CGAL_P2_WITH_HOLES_TYPE,
|
||||||
|
|
@ -144,7 +144,7 @@ void add_in_graphic_buffer(const CGAL_P2_WITH_HOLES_TYPE& p2,
|
||||||
typename CGAL_P2_WITH_HOLES_TYPE::General_polygon_2::Vertex_const_iterator,
|
typename CGAL_P2_WITH_HOLES_TYPE::General_polygon_2::Vertex_const_iterator,
|
||||||
void*> drawing_functor;
|
void*> drawing_functor;
|
||||||
|
|
||||||
add_in_graphic_buffer(p2, graphic_buffer, drawing_functor);
|
add_in_graphic_storage(p2, graphic_buffer, drawing_functor);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -155,7 +155,7 @@ void draw(const CGAL_P2_WITH_HOLES_TYPE& ap2, const DrawingFunctor &drawing_func
|
||||||
const char* title="Polygon with Holes Basic Viewer")
|
const char* title="Polygon with Holes Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer(ap2, buffer, drawing_functor);
|
add_in_graphic_storage(ap2, buffer, drawing_functor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -164,7 +164,7 @@ void draw(const CGAL_P2_WITH_HOLES_TYPE& ap2,
|
||||||
const char* title="Polygon with Holes Basic Viewer")
|
const char* title="Polygon with Holes Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer(ap2, buffer);
|
add_in_graphic_storage(ap2, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ namespace CGAL
|
||||||
#define CGAL_POLY_TYPE CGAL::Polyhedron_3 \
|
#define CGAL_POLY_TYPE CGAL::Polyhedron_3 \
|
||||||
<PolyhedronTraits_3, PolyhedronItems_3, T_HDS, Alloc>
|
<PolyhedronTraits_3, PolyhedronItems_3, T_HDS, Alloc>
|
||||||
|
|
||||||
// Specialization of add_in_graphic_buffer function.
|
// Specialization of add_in_graphic_storage function.
|
||||||
template<class PolyhedronTraits_3,
|
template<class PolyhedronTraits_3,
|
||||||
class PolyhedronItems_3,
|
class PolyhedronItems_3,
|
||||||
template < class T, class I, class A>
|
template < class T, class I, class A>
|
||||||
|
|
@ -34,10 +34,10 @@ template<class PolyhedronTraits_3,
|
||||||
class Alloc,
|
class Alloc,
|
||||||
typename BufferType=float,
|
typename BufferType=float,
|
||||||
class DrawingFunctor>
|
class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_POLY_TYPE& apoly,
|
void add_in_graphic_storage(const CGAL_POLY_TYPE& apoly,
|
||||||
CGAL::Graphic_storage<BufferType> &graphic_buffer,
|
CGAL::Graphic_storage<BufferType> &graphic_buffer,
|
||||||
const DrawingFunctor &drawing_functor)
|
const DrawingFunctor &drawing_functor)
|
||||||
{ add_in_graphic_buffer_for_fg(apoly, graphic_buffer, drawing_functor); }
|
{ add_in_graphic_storage_for_fg(apoly, graphic_buffer, drawing_functor); }
|
||||||
|
|
||||||
template<class PolyhedronTraits_3,
|
template<class PolyhedronTraits_3,
|
||||||
class PolyhedronItems_3,
|
class PolyhedronItems_3,
|
||||||
|
|
@ -45,9 +45,9 @@ template<class PolyhedronTraits_3,
|
||||||
class T_HDS,
|
class T_HDS,
|
||||||
class Alloc,
|
class Alloc,
|
||||||
typename BufferType=float>
|
typename BufferType=float>
|
||||||
void add_in_graphic_buffer(const CGAL_POLY_TYPE& apoly,
|
void add_in_graphic_storage(const CGAL_POLY_TYPE& apoly,
|
||||||
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
||||||
{ add_in_graphic_buffer_for_fg(apoly, graphic_buffer); }
|
{ add_in_graphic_storage_for_fg(apoly, graphic_buffer); }
|
||||||
|
|
||||||
// Specialization of draw function: require Qt and the CGAL basic viewer.
|
// Specialization of draw function: require Qt and the CGAL basic viewer.
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -62,7 +62,7 @@ void draw(const CGAL_POLY_TYPE& apoly,
|
||||||
const char* title="Polyhedron Basic Viewer")
|
const char* title="Polyhedron Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer_for_fg(apoly, buffer);
|
add_in_graphic_storage_for_fg(apoly, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -78,7 +78,7 @@ void draw(const CGAL_POLY_TYPE& apoly,
|
||||||
const char* title="Polyhedron Basic Viewer")
|
const char* title="Polyhedron Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer_for_fg(apoly, buffer, drawing_functor);
|
add_in_graphic_storage_for_fg(apoly, buffer, drawing_functor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
#endif // CGAL_USE_BASIC_VIEWER
|
#endif // CGAL_USE_BASIC_VIEWER
|
||||||
|
|
|
||||||
|
|
@ -130,7 +130,7 @@ void compute_elements(const SS2& ss2,
|
||||||
#define CGAL_SS_TYPE CGAL::Straight_skeleton_2<K>
|
#define CGAL_SS_TYPE CGAL::Straight_skeleton_2<K>
|
||||||
|
|
||||||
template <typename BufferType=float, class K, class DrawingFunctor>
|
template <typename BufferType=float, class K, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_SS_TYPE &ass2,
|
void add_in_graphic_storage(const CGAL_SS_TYPE &ass2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor& drawing_functor)
|
const DrawingFunctor& drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -139,7 +139,7 @@ void add_in_graphic_buffer(const CGAL_SS_TYPE &ass2,
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename BufferType=float, class K>
|
template <typename BufferType=float, class K>
|
||||||
void add_in_graphic_buffer(const CGAL_SS_TYPE& ass2,
|
void add_in_graphic_storage(const CGAL_SS_TYPE& ass2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
||||||
{
|
{
|
||||||
Drawing_functor<CGAL_SS_TYPE,
|
Drawing_functor<CGAL_SS_TYPE,
|
||||||
|
|
@ -176,7 +176,7 @@ void add_in_graphic_buffer(const CGAL_SS_TYPE& ass2,
|
||||||
return CGAL::IO::Color(10, 180, 10); // green, but not flashy
|
return CGAL::IO::Color(10, 180, 10); // green, but not flashy
|
||||||
};
|
};
|
||||||
|
|
||||||
add_in_graphic_buffer(ass2, graphic_buffer, drawingFunctor);
|
add_in_graphic_storage(ass2, graphic_buffer, drawingFunctor);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Specialization of draw function.
|
// Specialization of draw function.
|
||||||
|
|
@ -187,7 +187,7 @@ void draw(const CGAL_SS_TYPE &ass2, const DrawingFunctor &drawingfunctor,
|
||||||
const char *title="Straight Skeleton Basic Viewer")
|
const char *title="Straight Skeleton Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(ass2, buffer, drawingfunctor);
|
add_in_graphic_storage(ass2, buffer, drawingfunctor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -196,7 +196,7 @@ void draw(const CGAL_SS_TYPE &ass2,
|
||||||
const char *title="Straight Skeleton Basic Viewer")
|
const char *title="Straight Skeleton Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(ass2, buffer);
|
add_in_graphic_storage(ass2, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -40,15 +40,15 @@ namespace CGAL
|
||||||
{
|
{
|
||||||
|
|
||||||
template<class K, typename BufferType=float, class DrawingFunctor>
|
template<class K, typename BufferType=float, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const Surface_mesh<K>& amesh,
|
void add_in_graphic_storage(const Surface_mesh<K>& amesh,
|
||||||
CGAL::Graphic_storage<BufferType> &graphic_buffer,
|
CGAL::Graphic_storage<BufferType> &graphic_buffer,
|
||||||
const DrawingFunctor &drawing_functor)
|
const DrawingFunctor &drawing_functor)
|
||||||
{ add_in_graphic_buffer_for_fg(amesh, graphic_buffer, drawing_functor); }
|
{ add_in_graphic_storage_for_fg(amesh, graphic_buffer, drawing_functor); }
|
||||||
|
|
||||||
template<class K, typename BufferType=float>
|
template<class K, typename BufferType=float>
|
||||||
void add_in_graphic_buffer(const Surface_mesh<K>& amesh,
|
void add_in_graphic_storage(const Surface_mesh<K>& amesh,
|
||||||
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
CGAL::Graphic_storage<BufferType> &graphic_buffer)
|
||||||
{ add_in_graphic_buffer_for_fg(amesh, graphic_buffer); }
|
{ add_in_graphic_storage_for_fg(amesh, graphic_buffer); }
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
||||||
|
|
@ -58,7 +58,7 @@ void draw(const Surface_mesh<K>& amesh,
|
||||||
const char* title="Surface_mesh Basic Viewer")
|
const char* title="Surface_mesh Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer_for_fg(amesh, buffer);
|
add_in_graphic_storage_for_fg(amesh, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -68,7 +68,7 @@ void draw(const Surface_mesh<K>& amesh,
|
||||||
const char* title="Surface_mesh Basic Viewer")
|
const char* title="Surface_mesh Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer_for_fg(amesh, buffer, drawing_functor);
|
add_in_graphic_storage_for_fg(amesh, buffer, drawing_functor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -370,7 +370,7 @@ void compute_elements(const Mesh &mesh,
|
||||||
} // namespace draw_function_for_face_graph_with_paths
|
} // namespace draw_function_for_face_graph_with_paths
|
||||||
|
|
||||||
template <typename BufferType=float, class Mesh, class DrawingFunctor>
|
template <typename BufferType=float, class Mesh, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const Mesh& mesh,
|
void add_in_graphic_storage(const Mesh& mesh,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const std::vector<Surface_mesh_topology::Path_on_surface<Mesh>>* paths,
|
const std::vector<Surface_mesh_topology::Path_on_surface<Mesh>>* paths,
|
||||||
const DrawingFunctor& drawing_functor,
|
const DrawingFunctor& drawing_functor,
|
||||||
|
|
@ -384,7 +384,7 @@ void add_in_graphic_buffer(const Mesh& mesh,
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename BufferType = float, class Mesh>
|
template <typename BufferType = float, class Mesh>
|
||||||
void add_in_graphic_buffer(const Mesh& mesh,
|
void add_in_graphic_storage(const Mesh& mesh,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const std::vector<Surface_mesh_topology::Path_on_surface<Mesh>>* paths,
|
const std::vector<Surface_mesh_topology::Path_on_surface<Mesh>>* paths,
|
||||||
typename Get_map<Mesh, Mesh>::type::size_type amark=
|
typename Get_map<Mesh, Mesh>::type::size_type amark=
|
||||||
|
|
@ -397,7 +397,7 @@ void add_in_graphic_buffer(const Mesh& mesh,
|
||||||
typename Get_map<Mesh, Mesh>::type::Dart_const_descriptor /*fh*/>
|
typename Get_map<Mesh, Mesh>::type::Dart_const_descriptor /*fh*/>
|
||||||
drawing_functor;
|
drawing_functor;
|
||||||
|
|
||||||
add_in_graphic_buffer(mesh, graphic_buffer, drawing_functor, paths, amark);
|
add_in_graphic_storage(mesh, graphic_buffer, drawing_functor, paths, amark);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -410,7 +410,7 @@ void draw(const Mesh& mesh,
|
||||||
const char* title="Mesh Viewer With Path")
|
const char* title="Mesh Viewer With Path")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer(mesh, buffer, &paths, amark);
|
add_in_graphic_storage(mesh, buffer, &paths, amark);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -423,7 +423,7 @@ void draw(const Mesh& mesh,
|
||||||
const char* title="Mesh Viewer With Path")
|
const char* title="Mesh Viewer With Path")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer(mesh, buffer, drawing_functor, &paths, amark);
|
add_in_graphic_storage(mesh, buffer, drawing_functor, &paths, amark);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -436,7 +436,7 @@ void draw(const Mesh& mesh,
|
||||||
{
|
{
|
||||||
std::vector<Surface_mesh_topology::Path_on_surface<Mesh>> paths=l;
|
std::vector<Surface_mesh_topology::Path_on_surface<Mesh>> paths=l;
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer(mesh, buffer, &paths, amark);
|
add_in_graphic_storage(mesh, buffer, &paths, amark);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -60,7 +60,7 @@ struct Polygon_triangulation_drawing_functor :
|
||||||
|
|
||||||
template <class K, class TDS, typename Itag,
|
template <class K, class TDS, typename Itag,
|
||||||
typename BufferType=float, class DrawingFunctor>
|
typename BufferType=float, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_CT2_TYPE& ct2,
|
void add_in_graphic_storage(const CGAL_CT2_TYPE& ct2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor& drawing_functor)
|
const DrawingFunctor& drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -75,7 +75,7 @@ void draw(const CGAL_CT2_TYPE &ct2, const DrawingFunctor &drawingfunctor,
|
||||||
const char *title="Constrained Triangulation_2 Basic Viewer")
|
const char *title="Constrained Triangulation_2 Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(ct2, buffer, drawingfunctor);
|
add_in_graphic_storage(ct2, buffer, drawingfunctor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -118,7 +118,7 @@ void compute_elements(const T2& t2,
|
||||||
#define CGAL_T2_TYPE CGAL::Triangulation_2<Gt, Tds>
|
#define CGAL_T2_TYPE CGAL::Triangulation_2<Gt, Tds>
|
||||||
|
|
||||||
template <class Gt, class Tds, typename BufferType=float, class DrawingFunctor>
|
template <class Gt, class Tds, typename BufferType=float, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_T2_TYPE& at2,
|
void add_in_graphic_storage(const CGAL_T2_TYPE& at2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor& drawing_functor)
|
const DrawingFunctor& drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -126,7 +126,7 @@ void add_in_graphic_buffer(const CGAL_T2_TYPE& at2,
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class Gt, class Tds, typename BufferType=float>
|
template <class Gt, class Tds, typename BufferType=float>
|
||||||
void add_in_graphic_buffer(const CGAL_T2_TYPE& at2,
|
void add_in_graphic_storage(const CGAL_T2_TYPE& at2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
|
|
@ -147,7 +147,7 @@ void add_in_graphic_buffer(const CGAL_T2_TYPE& at2,
|
||||||
return get_random_color(random);
|
return get_random_color(random);
|
||||||
};
|
};
|
||||||
|
|
||||||
add_in_graphic_buffer(at2, graphic_buffer, drawingFunctor);
|
add_in_graphic_storage(at2, graphic_buffer, drawingFunctor);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -158,7 +158,7 @@ void draw(const CGAL_T2_TYPE &at2, const DrawingFunctor &drawingfunctor,
|
||||||
const char *title="Triangulation_2 Basic Viewer")
|
const char *title="Triangulation_2 Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(at2, buffer, drawingfunctor);
|
add_in_graphic_storage(at2, buffer, drawingfunctor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -167,7 +167,7 @@ void draw(const CGAL_T2_TYPE& at2,
|
||||||
const char *title="Triangulation_2 Basic Viewer")
|
const char *title="Triangulation_2 Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(at2, buffer);
|
add_in_graphic_storage(at2, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -117,7 +117,7 @@ void compute_elements(const T3* t3,
|
||||||
|
|
||||||
template <class Gt, class Tds, class Lock_data_structure,
|
template <class Gt, class Tds, class Lock_data_structure,
|
||||||
typename BufferType=float, class DrawingFunctor>
|
typename BufferType=float, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_T3_TYPE& at3,
|
void add_in_graphic_storage(const CGAL_T3_TYPE& at3,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor& drawing_functor)
|
const DrawingFunctor& drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -126,7 +126,7 @@ void add_in_graphic_buffer(const CGAL_T3_TYPE& at3,
|
||||||
|
|
||||||
template <class Gt, class Tds, class Lock_data_structure,
|
template <class Gt, class Tds, class Lock_data_structure,
|
||||||
typename BufferType=float>
|
typename BufferType=float>
|
||||||
void add_in_graphic_buffer(const CGAL_T3_TYPE& at3,
|
void add_in_graphic_storage(const CGAL_T3_TYPE& at3,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
||||||
{
|
{
|
||||||
CGAL::Drawing_functor<CGAL_T3_TYPE,
|
CGAL::Drawing_functor<CGAL_T3_TYPE,
|
||||||
|
|
@ -151,7 +151,7 @@ void add_in_graphic_buffer(const CGAL_T3_TYPE& at3,
|
||||||
return get_random_color(random);
|
return get_random_color(random);
|
||||||
};
|
};
|
||||||
|
|
||||||
add_in_graphic_buffer(at3, graphic_buffer, drawing_functor);
|
add_in_graphic_storage(at3, graphic_buffer, drawing_functor);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -162,7 +162,7 @@ void draw(const CGAL_T3_TYPE &at3, const DrawingFunctor &drawingfunctor,
|
||||||
const char *title="T3 Basic Viewer")
|
const char *title="T3 Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(at3, buffer, drawingfunctor);
|
add_in_graphic_storage(at3, buffer, drawingfunctor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -170,7 +170,7 @@ template <class Gt, class Tds, class Lock_data_structure>
|
||||||
void draw(const CGAL_T3_TYPE &at3, const char *title="T3 Basic Viewer")
|
void draw(const CGAL_T3_TYPE &at3, const char *title="T3 Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<float> buffer;
|
CGAL::Graphic_storage<float> buffer;
|
||||||
add_in_graphic_buffer(at3, buffer);
|
add_in_graphic_storage(at3, buffer);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -337,7 +337,7 @@ void compute_elements(const V2& v2,
|
||||||
|
|
||||||
template <class DG, class AT, class AP,
|
template <class DG, class AT, class AP,
|
||||||
typename BufferType=float, class DrawingFunctor>
|
typename BufferType=float, class DrawingFunctor>
|
||||||
void add_in_graphic_buffer(const CGAL_VORONOI_TYPE &v2,
|
void add_in_graphic_storage(const CGAL_VORONOI_TYPE &v2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
CGAL::Graphic_storage<BufferType>& graphic_buffer,
|
||||||
const DrawingFunctor& m_drawing_functor)
|
const DrawingFunctor& m_drawing_functor)
|
||||||
{
|
{
|
||||||
|
|
@ -345,7 +345,7 @@ void add_in_graphic_buffer(const CGAL_VORONOI_TYPE &v2,
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class DG, class AT, class AP, typename BufferType=float>
|
template <class DG, class AT, class AP, typename BufferType=float>
|
||||||
void add_in_graphic_buffer(const CGAL_VORONOI_TYPE& v2,
|
void add_in_graphic_storage(const CGAL_VORONOI_TYPE& v2,
|
||||||
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
CGAL::Graphic_storage<BufferType>& graphic_buffer)
|
||||||
{
|
{
|
||||||
// Default functor; user can add his own functor.
|
// Default functor; user can add his own functor.
|
||||||
|
|
@ -355,7 +355,7 @@ void add_in_graphic_buffer(const CGAL_VORONOI_TYPE& v2,
|
||||||
typename CGAL_VORONOI_TYPE::Face_iterator>
|
typename CGAL_VORONOI_TYPE::Face_iterator>
|
||||||
drawing_functor;
|
drawing_functor;
|
||||||
|
|
||||||
add_in_graphic_buffer(v2, graphic_buffer, drawing_functor);
|
add_in_graphic_storage(v2, graphic_buffer, drawing_functor);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CGAL_USE_BASIC_VIEWER
|
#ifdef CGAL_USE_BASIC_VIEWER
|
||||||
|
|
@ -368,7 +368,7 @@ void draw(const CGAL_VORONOI_TYPE& av2,
|
||||||
const char *title="2D Voronoi Diagram Basic Viewer")
|
const char *title="2D Voronoi Diagram Basic Viewer")
|
||||||
{
|
{
|
||||||
CGAL::Graphic_storage<BufferType> buffer;
|
CGAL::Graphic_storage<BufferType> buffer;
|
||||||
add_in_graphic_buffer(av2, buffer, drawing_functor);
|
add_in_graphic_storage(av2, buffer, drawing_functor);
|
||||||
draw_graphic_storage(buffer, title);
|
draw_graphic_storage(buffer, title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -384,7 +384,7 @@ void draw(const CGAL_VORONOI_TYPE& av2,
|
||||||
typename CGAL_VORONOI_TYPE::Face_iterator>
|
typename CGAL_VORONOI_TYPE::Face_iterator>
|
||||||
drawing_functor;
|
drawing_functor;
|
||||||
|
|
||||||
add_in_graphic_buffer(av2, buffer, drawing_functor);
|
add_in_graphic_storage(av2, buffer, drawing_functor);
|
||||||
|
|
||||||
QApplication_and_basic_viewer app(buffer, title);
|
QApplication_and_basic_viewer app(buffer, title);
|
||||||
if(app)
|
if(app)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue