Go to the documentation of this file.
14 #ifndef _SCL_SECURE_NO_WARNINGS
15 #define _SCL_SECURE_NO_WARNINGS
21 #include <QStringList>
24 #ifndef Q_MOC_RUN // MT : very important to avoid the error : ' Parse error at
40 #endif // FEVV_USE_CGAL
41 #ifdef FEVV_USE_OPENMESH
43 #endif // FEVV_USE_OPENMESH
46 #endif // FEVV_USE_AIF
57 #if(FEVV_USE_QT5) // see at the end of .cpp for QT4
58 Q_PLUGIN_METADATA(IID
"HelloworldPlugin")
70 void init(
double _x,
double _y,
double _z)
89 std::cerr <<
"BaseWindow is null or not initialized." << std::endl;
94 template<
typename HalfedgeGraph >
97 std::cout <<
"Asking to Helloworld mesh ! " << std::endl;
100 using VertexColorMap =
102 HalfedgeGraph >::pmap_type;
106 std::cout <<
"use existing vertex-color map" << std::endl;
111 std::cout <<
"create vertex-color map" << std::endl;
118 using VertexNormalMap =
120 HalfedgeGraph >::pmap_type;
121 VertexNormalMap v_nm;
124 std::cout <<
"use existing vertex-normal map" << std::endl;
129 std::cout <<
"create vertex-normal map" << std::endl;
136 auto pm =
get(boost::vertex_point, *_mesh);
142 std::cout <<
"Helloworld mesh of " <<
value_x <<
";" <<
value_y <<
";"
143 <<
value_z <<
"." << std::endl;
147 template<
typename HalfedgeGraph >
149 HalfedgeGraph *_mesh,
155 if(dialog.exec() == QDialog::Accepted)
180 #ifdef FEVV_USE_OPENMESH
185 applyHG< MeshOpenMesh >(_adapter, _mesh, pmaps_bag);
190 void apply(BaseAdapterVisu *_adapter,
194 applyHG< MeshLCC >(_adapter, _mesh, pmaps_bag);
197 void apply(BaseAdapterVisu *_adapter,
201 applyHG< MeshSurface >(_adapter, _mesh, pmaps_bag);
204 void apply(BaseAdapterVisu *_adapter,
208 applyHG< MeshPolyhedron >(_adapter, _mesh, pmaps_bag);
213 void apply(BaseAdapterVisu *_adapter,
217 applyHG< MeshAIF >(_adapter, _mesh, pmaps_bag);
224 return QStringList() <<
"HelloworldPlugin";
virtual bool isInit() const
void put_property_map(PropertyT p, const MeshT &, PMapsContainer &pmaps, const typename PMap_traits< PropertyT, MeshT >::pmap_type &pmap)
PMap_traits< PropertyT, MeshT >::pmap_type get_property_map(PropertyT p, const MeshT &, const PMapsContainer &pmaps)
void getParameters(double &x, double &y, double &z)
CGAL::Linear_cell_complex_for_combinatorial_map< 2, 3, CGALLCCTraits, CGALItem > MeshLCC
bool has_map(const PMapsContainer &pmaps, const std::string &map_name)
(refer to Property Maps API)
This class is intended to provide some standard message boxes to all plugins.
virtual Viewer * getViewer()
CGAL::Surface_mesh< CGALPoint > MeshSurface
SimpleWindow is a specialization of QMainWindow. This class the Main Window.
std::map< std::string, boost::any > PMapsContainer
void draw_or_redraw_mesh(HalfedgeGraph *_g, PMapsContainer *_pmaps, bool _redraw=false, bool _recomputeNT_if_redraw=false, std::string _mesh_filename=std::string(""), bool _recreateOSGobj_if_redraw=true, float _step=0.)
QStringList Generic_plugins() const override
FEVV::PCLPointCloudPointMap::value_type get(const FEVV::PCLPointCloudPointMap &pm, FEVV::PCLPointCloudPointMap::key_type key)
Specialization of get(point_map, key) for PCLPointCloud.
SimpleViewer is a specialization of osgViewer::CompositeViewer. This class is a widget where we are a...
void onModificationParam(std::string _pluginName, BasePlugin *_plugin)
Interfaces for plugins These interfaces will be used for different plugins.
void helloworld_filter(const HalfedgeGraph &g, PointMap &pm, VertexColorMap &v_cm, VertexNormalMap &v_nm, const GeometryTraits >)
Refer here for a detailed presentation of that filter example, what it does and how to use it.
void addParameters(BaseWindow *_window) override
void process(HalfedgeGraph *_mesh, FEVV::PMapsContainer *pmaps_bag)
void init(double _x, double _y, double _z)
OpenMesh::PolyMesh_ArrayKernelT< MyTraits > MeshOpenMesh
~HelloworldPlugin()=default
virtual void apply(BaseAdapterVisu *, void *, FEVV::PMapsContainer *) override
HelloworldPlugin()=default
void applyHG(BaseAdapterVisu *_adapter, HalfedgeGraph *_mesh, FEVV::PMapsContainer *pmaps_bag)
bool Generic_plugin(const QString &) override
CGAL::Polyhedron_3< CGALKernel, CGAL::Polyhedron_items_with_id_3 > MeshPolyhedron
PMap_traits< PropertyT, MeshT >::pmap_type make_property_map(PropertyT, const MeshT &m)
FEVV::DataStructures::AIF::AIFMesh MeshAIF
void setParameters(double x, double y, double z)