mirror of https://github.com/CGAL/cgal
Fix warning about discarding return type of function with [[nodiscard]] (#9127)
## Summary of Changes
```
Building CXX object test/Generator_Demo/CMakeFiles/Generator_2.dir/Generator_2.cpp.o
cd /home/cgal_tester/build/src/cmake/platforms/ArchLinux-clang/test/Generator_Demo && /bin/clang++ -DCGAL_TEST_SUITE=1 -DCGAL_USE_GMPXX=1 -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NO_KEYWORDS -DQT_OPENGLWIDGETS_LIB -DQT_OPENGL_LIB -DQT_WIDGETS_LIB -I/home/cgal_tester/build/src/cmake/platforms/ArchLinux-clang/test/Generator_Demo -I/mnt/testsuite/test/Generator_Demo -I/home/cgal_tester/build/src/cmake/platforms/ArchLinux-clang/include -I/mnt/testsuite/include -I/home/cgal_tester/build/src/cmake/platforms/ArchLinux-clang/test/AABB_tree_Demo -isystem /home/cgal_tester/build/src/cmake/platforms/ArchLinux-clang/test/Generator_Demo/Generator_2_autogen/include -isystem /usr/include/qt6/QtCore -isystem /usr/include/qt6 -isystem /usr/lib/qt6/mkspecs/linux-g++ -isystem /usr/include/qt6/QtOpenGLWidgets -isystem /usr/include/qt6/QtOpenGL -isystem /usr/include/qt6/QtGui -isystem /usr/include/qt6/QtWidgets -Wall -fno-direct-access-external-data -MD -MT test/Generator_Demo/CMakeFiles/Generator_2.dir/Generator_2.cpp.o -MF CMakeFiles/Generator_2.dir/Generator_2.cpp.o.d -o CMakeFiles/Generator_2.dir/Generator_2.cpp.o -c /mnt/testsuite/test/Generator_Demo/Generator_2.cpp
In file included from /mnt/testsuite/test/Generator_Demo/Generator_2.cpp:27:
In file included from /mnt/testsuite/include/CGAL/Qt/DemosMainWindow.h:130:
/mnt/testsuite/include/CGAL/Qt/DemosMainWindow_impl.h:224:3: warning: ignoring return value of function declared with 'nodiscard' attribute [-Wunused-result]
224 | about_CGAL.open(QIODevice::ReadOnly);
| ^~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~
1 warning generated.
```
https://cgal.geometryfactory.com/CGAL/testsuite/CGAL-6.2-Ic-36/Generator_Demo/TestReport_gimeno_ArchLinux-clang.gz
## Release Management
* Affected package(s): `GraphicsView`
* Issue(s) solved (if any): n/a
* Feature/Small Feature (if any): n/a
* License and copyright ownership: no change
This commit is contained in:
commit
2f9854b422
|
|
@ -221,7 +221,10 @@ void
|
||||||
DemosMainWindow::popupAboutBox(QString title, QString html_resource_name)
|
DemosMainWindow::popupAboutBox(QString title, QString html_resource_name)
|
||||||
{
|
{
|
||||||
QFile about_CGAL(html_resource_name);
|
QFile about_CGAL(html_resource_name);
|
||||||
about_CGAL.open(QIODevice::ReadOnly);
|
if (!about_CGAL.open(QIODevice::ReadOnly)) {
|
||||||
|
QMessageBox::warning(this, tr("Error"), tr("Could not open resource file: %1").arg(html_resource_name));
|
||||||
|
return;
|
||||||
|
}
|
||||||
QString about_CGAL_txt = QTextStream(&about_CGAL).readAll();
|
QString about_CGAL_txt = QTextStream(&about_CGAL).readAll();
|
||||||
#ifdef CGAL_VERSION_STR
|
#ifdef CGAL_VERSION_STR
|
||||||
QString cgal_version(CGAL_VERSION_STR);
|
QString cgal_version(CGAL_VERSION_STR);
|
||||||
|
|
|
||||||
|
|
@ -63,9 +63,6 @@ if(CGAL_Qt6_FOUND AND Qt6_FOUND)
|
||||||
include(${CGAL_MODULES_DIR}/CGAL_add_test.cmake)
|
include(${CGAL_MODULES_DIR}/CGAL_add_test.cmake)
|
||||||
cgal_add_compilation_test(T3_demo)
|
cgal_add_compilation_test(T3_demo)
|
||||||
|
|
||||||
include(${CGAL_MODULES_DIR}/CGAL_add_test.cmake)
|
|
||||||
cgal_add_compilation_test(T3_demo)
|
|
||||||
|
|
||||||
else(CGAL_Qt6_FOUND AND Qt6_FOUND)
|
else(CGAL_Qt6_FOUND AND Qt6_FOUND)
|
||||||
|
|
||||||
set(TRIANGULATION_3_MISSING_DEPS "")
|
set(TRIANGULATION_3_MISSING_DEPS "")
|
||||||
|
|
|
||||||
|
|
@ -209,31 +209,3 @@ void MainWindow::on_actionClear_Scene_triggered()
|
||||||
// update viewer
|
// update viewer
|
||||||
Q_EMIT( sceneChanged() );
|
Q_EMIT( sceneChanged() );
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::popupAboutCGAL()
|
|
||||||
{
|
|
||||||
// read contents from .html file
|
|
||||||
QFile about_CGAL(":/documentation/documentation/about_CGAL.html");
|
|
||||||
about_CGAL.open(QIODevice::ReadOnly|QIODevice::Text);
|
|
||||||
QString about_CGAL_txt = QTextStream(&about_CGAL).readAll();
|
|
||||||
|
|
||||||
// popup a message box
|
|
||||||
QMessageBox mb(QMessageBox::NoIcon,
|
|
||||||
tr("About CGAL..."),
|
|
||||||
about_CGAL_txt,
|
|
||||||
QMessageBox::Ok,
|
|
||||||
this);
|
|
||||||
|
|
||||||
// set links to be accessible by mouse or keyboard
|
|
||||||
QLabel* mb_label = mb.findChild<QLabel*>("qt_msgbox_label");
|
|
||||||
if(mb_label) {
|
|
||||||
mb_label->setTextInteractionFlags(mb_label->textInteractionFlags() |
|
|
||||||
::Qt::LinksAccessibleByMouse |
|
|
||||||
::Qt::LinksAccessibleByKeyboard);
|
|
||||||
} else {
|
|
||||||
std::cerr << "Cannot find child \"qt_msgbox_label\" in QMessageBox\n"
|
|
||||||
<< " with Qt version " << QT_VERSION_STR << "!\n";
|
|
||||||
}
|
|
||||||
|
|
||||||
mb.exec();
|
|
||||||
}
|
|
||||||
|
|
|
||||||
|
|
@ -36,9 +36,6 @@ public Q_SLOTS:
|
||||||
// show menu
|
// show menu
|
||||||
void on_actionClear_Scene_triggered();
|
void on_actionClear_Scene_triggered();
|
||||||
|
|
||||||
// about menu
|
|
||||||
void popupAboutCGAL();
|
|
||||||
|
|
||||||
Q_SIGNALS:
|
Q_SIGNALS:
|
||||||
void sceneChanged();
|
void sceneChanged();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -25,6 +25,9 @@ int main(int argc, char** argv)
|
||||||
app.setOrganizationName("INRIA");
|
app.setOrganizationName("INRIA");
|
||||||
app.setApplicationName("3D Triangulation Demo");
|
app.setApplicationName("3D Triangulation Demo");
|
||||||
|
|
||||||
|
// Import resources from libCGALQt (Qt6).
|
||||||
|
CGAL_QT_INIT_RESOURCES;
|
||||||
|
|
||||||
MainWindow mw;
|
MainWindow mw;
|
||||||
mw.show();
|
mw.show();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -183,13 +183,13 @@ void Viewer::compile_shaders()
|
||||||
"} \n"
|
"} \n"
|
||||||
"\n"
|
"\n"
|
||||||
};
|
};
|
||||||
QOpenGLShader *vertex_shader = new QOpenGLShader(QOpenGLShader::Vertex);
|
QOpenGLShader *vertex_shader = new QOpenGLShader(QOpenGLShader::Vertex, this);
|
||||||
if(!vertex_shader->compileSourceCode(vertex_source))
|
if(!vertex_shader->compileSourceCode(vertex_source))
|
||||||
{
|
{
|
||||||
std::cerr<<"Compiling vertex source FAILED"<<std::endl;
|
std::cerr<<"Compiling vertex source FAILED"<<std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
QOpenGLShader *fragment_shader= new QOpenGLShader(QOpenGLShader::Fragment);
|
QOpenGLShader *fragment_shader= new QOpenGLShader(QOpenGLShader::Fragment, this);
|
||||||
if(!fragment_shader->compileSourceCode(fragment_source))
|
if(!fragment_shader->compileSourceCode(fragment_source))
|
||||||
{
|
{
|
||||||
std::cerr<<"Compiling fragmentsource FAILED"<<std::endl;
|
std::cerr<<"Compiling fragmentsource FAILED"<<std::endl;
|
||||||
|
|
@ -258,14 +258,14 @@ void Viewer::compile_shaders()
|
||||||
"} \n"
|
"} \n"
|
||||||
"\n"
|
"\n"
|
||||||
};
|
};
|
||||||
QOpenGLShader *vertex_shader_spheres = new QOpenGLShader(QOpenGLShader::Vertex);
|
QOpenGLShader *vertex_shader_spheres = new QOpenGLShader(QOpenGLShader::Vertex, this);
|
||||||
if(!vertex_shader_spheres->compileSourceCode(vertex_source_spheres))
|
if(!vertex_shader_spheres->compileSourceCode(vertex_source_spheres))
|
||||||
{
|
{
|
||||||
std::cerr<<"Compiling vertex source FAILED"<<std::endl;
|
std::cerr<<"Compiling vertex source FAILED"<<std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
QOpenGLShader *fragment_shader_spheres= new QOpenGLShader(QOpenGLShader::Fragment);
|
QOpenGLShader *fragment_shader_spheres= new QOpenGLShader(QOpenGLShader::Fragment, this);
|
||||||
if(!fragment_shader_spheres->compileSourceCode(fragment_source_spheres))
|
if(!fragment_shader_spheres->compileSourceCode(fragment_source_spheres))
|
||||||
{
|
{
|
||||||
std::cerr<<"Compiling fragmentsource FAILED"<<std::endl;
|
std::cerr<<"Compiling fragmentsource FAILED"<<std::endl;
|
||||||
|
|
@ -312,7 +312,7 @@ void Viewer::compile_shaders()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
QOpenGLShader *vertex_shader_cylinders = new QOpenGLShader(QOpenGLShader::Vertex);
|
QOpenGLShader *vertex_shader_cylinders = new QOpenGLShader(QOpenGLShader::Vertex, this);
|
||||||
if(!vertex_shader_cylinders->compileSourceCode(vertex_source_cylinders))
|
if(!vertex_shader_cylinders->compileSourceCode(vertex_source_cylinders))
|
||||||
{
|
{
|
||||||
std::cerr<<"Compiling vertex source FAILED"<<std::endl;
|
std::cerr<<"Compiling vertex source FAILED"<<std::endl;
|
||||||
|
|
@ -1628,7 +1628,7 @@ void Viewer::draw()
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Viewer::drawVertex(const Point_3& p, std::vector<float> *vertices)
|
void Viewer::drawVertex(const Point_3& p, Coords_ptr& vertices)
|
||||||
{
|
{
|
||||||
|
|
||||||
vertices->push_back(p.x()); vertices->push_back(p.y()); vertices->push_back(p.z());
|
vertices->push_back(p.x()); vertices->push_back(p.y()); vertices->push_back(p.z());
|
||||||
|
|
@ -1636,13 +1636,13 @@ void Viewer::drawVertex(const Point_3& p, std::vector<float> *vertices)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Viewer::drawEdge(const Point_3& from, const Point_3& to, std::vector<float> *vertices)
|
void Viewer::drawEdge(const Point_3& from, const Point_3& to, Coords_ptr& vertices)
|
||||||
{
|
{
|
||||||
vertices->push_back( from.x()); vertices->push_back(from.y()); vertices->push_back(from.z());
|
vertices->push_back( from.x()); vertices->push_back(from.y()); vertices->push_back(from.z());
|
||||||
vertices->push_back( to.x()); vertices->push_back(to.y()); vertices->push_back(to.z());
|
vertices->push_back( to.x()); vertices->push_back(to.y()); vertices->push_back(to.z());
|
||||||
}
|
}
|
||||||
|
|
||||||
void Viewer::drawFacet(const Triangle_3& t, std::vector<float> *vertices)
|
void Viewer::drawFacet(const Triangle_3& t, Coords_ptr& vertices)
|
||||||
{
|
{
|
||||||
Point_3 p0 = t.vertex(0);
|
Point_3 p0 = t.vertex(0);
|
||||||
Point_3 p1 = t.vertex(1);
|
Point_3 p1 = t.vertex(1);
|
||||||
|
|
@ -2482,7 +2482,7 @@ void Viewer::incremental_insert() {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Viewer::draw_cylinder(float R, int prec, std::vector<float> *vertices, std::vector<float> *normals)
|
void Viewer::draw_cylinder(float R, int prec, Coords_ptr& vertices, Coords_ptr& normals)
|
||||||
{
|
{
|
||||||
vertices->resize(0);
|
vertices->resize(0);
|
||||||
normals->resize(0);
|
normals->resize(0);
|
||||||
|
|
@ -2551,7 +2551,7 @@ void Viewer::draw_cylinder(float R, int prec, std::vector<float> *vertices, std:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Viewer::draw_sphere(float R, int prec, std::vector<float> *vertices, std::vector<float> *normals)
|
void Viewer::draw_sphere(float R, int prec, Coords_ptr& vertices, Coords_ptr& normals)
|
||||||
{
|
{
|
||||||
vertices->resize(0);
|
vertices->resize(0);
|
||||||
normals->resize(0);
|
normals->resize(0);
|
||||||
|
|
|
||||||
|
|
@ -42,42 +42,41 @@ public:
|
||||||
, m_hasEmptyS(false)
|
, m_hasEmptyS(false)
|
||||||
, m_showTrackball(true)
|
, m_showTrackball(true)
|
||||||
, m_pDlgPrefer(nullptr)
|
, m_pDlgPrefer(nullptr)
|
||||||
{
|
, pos_emptyFacet{new Coords}
|
||||||
pos_emptyFacet = new std::vector<float>();
|
, pos_emptySphere{new Coords}
|
||||||
pos_emptySphere= new std::vector<float>();
|
, points_emptySphere{new Coords}
|
||||||
points_emptySphere = new std::vector<float>();
|
, pos_points{new Coords}
|
||||||
pos_points = new std::vector<float>();
|
, pos_newPoint{new Coords}
|
||||||
pos_newPoint = new std::vector<float>();
|
, pos_selectedVertex{new Coords}
|
||||||
pos_selectedVertex = new std::vector<float>();
|
, pos_movingPoint{new Coords}
|
||||||
pos_movingPoint = new std::vector<float>();
|
, pos_queryPoint{new Coords}
|
||||||
pos_queryPoint = new std::vector<float>();
|
, pos_trackBall{ new Coords}
|
||||||
pos_trackBall = new std::vector<float>();
|
, pos_voronoi{new Coords}
|
||||||
pos_voronoi = new std::vector<float>();
|
, pos_delaunay{new Coords}
|
||||||
pos_delaunay = new std::vector<float>();
|
, pos_facets{new Coords}
|
||||||
pos_facets = new std::vector<float>();
|
, pos_newFacet{new Coords}
|
||||||
pos_newFacet = new std::vector<float>();
|
, pos_nearest_neighbor{new Coords}
|
||||||
pos_nearest_neighbor = new std::vector<float>();
|
, points_locationSphere{new Coords}
|
||||||
points_locationSphere = new std::vector<float>();
|
, points_cylinder{new Coords}
|
||||||
points_cylinder = new std::vector<float>();
|
, normals_cylinder{new Coords}
|
||||||
normals_cylinder = new std::vector<float>();
|
, points_sphere{new Coords}
|
||||||
points_sphere = new std::vector<float>();
|
, points_trackBall{new Coords}
|
||||||
points_trackBall = new std::vector<float>();
|
, normals_sphere{new Coords}
|
||||||
normals_sphere = new std::vector<float>();
|
, normals_emptySphere{new Coords}
|
||||||
normals_emptySphere = new std::vector<float>();
|
, normals_trackBall{new Coords}
|
||||||
normals_trackBall= new std::vector<float>();
|
, transfo1_voronoi{new Coords}
|
||||||
transfo1_voronoi = new std::vector<float>();
|
, transfo2_voronoi{new Coords}
|
||||||
transfo2_voronoi = new std::vector<float>();
|
, transfo3_voronoi{new Coords}
|
||||||
transfo3_voronoi = new std::vector<float>();
|
, transfo4_voronoi{new Coords}
|
||||||
transfo4_voronoi = new std::vector<float>();
|
, transfo1_delaunay{new Coords}
|
||||||
transfo1_delaunay = new std::vector<float>();
|
, transfo2_delaunay{new Coords}
|
||||||
transfo2_delaunay = new std::vector<float>();
|
, transfo3_delaunay{new Coords}
|
||||||
transfo3_delaunay = new std::vector<float>();
|
, transfo4_delaunay{new Coords}
|
||||||
transfo4_delaunay = new std::vector<float>();
|
, incremental_points{new Coords}
|
||||||
incremental_points = new std::vector<float>();
|
, incremental_next_point{new Coords}
|
||||||
incremental_next_point = new std::vector<float>();
|
, incremental_facet{new Coords}
|
||||||
incremental_facet = new std::vector<float>();
|
, incremental_conflict{new Coords}
|
||||||
incremental_conflict = new std::vector<float>();
|
{}
|
||||||
}
|
|
||||||
|
|
||||||
~Viewer()
|
~Viewer()
|
||||||
{
|
{
|
||||||
|
|
@ -269,12 +268,15 @@ protected:
|
||||||
QString helpString() const;
|
QString helpString() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
using Coords = std::vector<float>;
|
||||||
|
using Coords_ptr = std::unique_ptr<std::vector<float>>;
|
||||||
|
|
||||||
// draw a 3d effect vertex
|
// draw a 3d effect vertex
|
||||||
void drawVertex(const Point_3& p, std::vector<float> *vertices);
|
void drawVertex(const Point_3& p, Coords_ptr& vertices);
|
||||||
// draw a 3d effect edge
|
// draw a 3d effect edge
|
||||||
void drawEdge(const Point_3& from, const Point_3 &to, std::vector<float> *vertices);
|
void drawEdge(const Point_3& from, const Point_3 &to, Coords_ptr& vertices);
|
||||||
// draw a facet
|
// draw a facet
|
||||||
void drawFacet(const Triangle_3& t, std::vector<float> *vertices);
|
void drawFacet(const Triangle_3& t, Coords_ptr& vertices);
|
||||||
// test whether the give 3D point is on the sphere
|
// test whether the give 3D point is on the sphere
|
||||||
inline bool isOnSphere( const Point_3 & pt ) {
|
inline bool isOnSphere( const Point_3 & pt ) {
|
||||||
return ( (pt.x()*pt.x() + pt.y()*pt.y() + pt.z()*pt.z()) == (m_fRadius*m_fRadius) );
|
return ( (pt.x()*pt.x() + pt.y()*pt.y() + pt.z()*pt.z()) == (m_fRadius*m_fRadius) );
|
||||||
|
|
@ -347,75 +349,74 @@ private:
|
||||||
static const int vaoSize = 29;
|
static const int vaoSize = 29;
|
||||||
static const int vboSize = 34;
|
static const int vboSize = 34;
|
||||||
// define material
|
// define material
|
||||||
QVector4D ambient;
|
QVector4D ambient;
|
||||||
QVector4D diffuse;
|
QVector4D diffuse;
|
||||||
QVector4D specular;
|
QVector4D specular;
|
||||||
GLfloat shininess ;
|
GLfloat shininess ;
|
||||||
int poly_vertexLocation[3];
|
int poly_vertexLocation[3];
|
||||||
int normalsLocation[3];
|
int normalsLocation[3];
|
||||||
int mvpLocation[3];
|
int mvpLocation[3];
|
||||||
int mvLocation[2];
|
int mvLocation[2];
|
||||||
int centerLocation[5];
|
int centerLocation[5];
|
||||||
int colorLocation[3];
|
int colorLocation[3];
|
||||||
int lightLocation[5*2];
|
int lightLocation[5*2];
|
||||||
|
|
||||||
bool are_buffers_initialized;
|
bool are_buffers_initialized;
|
||||||
bool extension_is_found;
|
bool extension_is_found;
|
||||||
|
|
||||||
std::vector<float> *pos_emptyFacet;
|
Coords_ptr pos_emptyFacet;
|
||||||
std::vector<float> *pos_emptySphere;
|
Coords_ptr pos_emptySphere;
|
||||||
std::vector<float> *points_emptySphere;
|
Coords_ptr points_emptySphere;
|
||||||
std::vector<float> *pos_points;
|
Coords_ptr pos_points;
|
||||||
std::vector<float> *pos_newPoint;
|
Coords_ptr pos_newPoint;
|
||||||
std::vector<float> *pos_selectedVertex;
|
Coords_ptr pos_selectedVertex;
|
||||||
std::vector<float> *pos_movingPoint;
|
Coords_ptr pos_movingPoint;
|
||||||
std::vector<float> *pos_queryPoint;
|
Coords_ptr pos_queryPoint;
|
||||||
std::vector<float> *pos_trackBall;
|
Coords_ptr pos_trackBall;
|
||||||
std::vector<float> *points_trackBall;
|
Coords_ptr pos_voronoi;
|
||||||
std::vector<float> *pos_voronoi;
|
Coords_ptr pos_delaunay;
|
||||||
std::vector<float> *pos_delaunay;
|
Coords_ptr pos_facets;
|
||||||
std::vector<float> *pos_facets;
|
Coords_ptr pos_newFacet;
|
||||||
std::vector<float> *pos_newFacet;
|
Coords_ptr pos_nearest_neighbor;
|
||||||
std::vector<float> *pos_nearest_neighbor;
|
Coords_ptr points_locationSphere;
|
||||||
std::vector<float> *points_locationSphere;
|
Coords_ptr points_cylinder;
|
||||||
std::vector<float> *points_cylinder;
|
Coords_ptr normals_cylinder;
|
||||||
std::vector<float> *normals_cylinder;
|
Coords_ptr points_sphere;
|
||||||
std::vector<float> *points_sphere;
|
Coords_ptr points_trackBall;
|
||||||
std::vector<float> *normals_sphere;
|
Coords_ptr normals_sphere;
|
||||||
std::vector<float> *normals_emptySphere;
|
Coords_ptr normals_emptySphere;
|
||||||
std::vector<float> *normals_trackBall;
|
Coords_ptr normals_trackBall;
|
||||||
std::vector<float> *transfo1_voronoi;
|
Coords_ptr transfo1_voronoi;
|
||||||
std::vector<float> *transfo2_voronoi;
|
Coords_ptr transfo2_voronoi;
|
||||||
std::vector<float> *transfo3_voronoi;
|
Coords_ptr transfo3_voronoi;
|
||||||
std::vector<float> *transfo4_voronoi;
|
Coords_ptr transfo4_voronoi;
|
||||||
std::vector<float> *transfo1_delaunay;
|
Coords_ptr transfo1_delaunay;
|
||||||
std::vector<float> *transfo2_delaunay;
|
Coords_ptr transfo2_delaunay;
|
||||||
std::vector<float> *transfo3_delaunay;
|
Coords_ptr transfo3_delaunay;
|
||||||
std::vector<float> *transfo4_delaunay;
|
Coords_ptr transfo4_delaunay;
|
||||||
std::vector<float> *incremental_points;
|
Coords_ptr incremental_points;
|
||||||
std::vector<float> *incremental_next_point;
|
Coords_ptr incremental_next_point;
|
||||||
std::vector<float> *incremental_facet;
|
Coords_ptr incremental_facet;
|
||||||
std::vector<float> *incremental_conflict;
|
Coords_ptr incremental_conflict;
|
||||||
|
//pickin
|
||||||
|
QMap<float, int> picked_IDs;
|
||||||
|
QPoint picking_pos;
|
||||||
|
|
||||||
//picking
|
QOpenGLBuffer buffers[vboSize];
|
||||||
QMap<float, int> picked_IDs;
|
QOpenGLVertexArrayObject vao[vaoSize];
|
||||||
QPoint picking_pos;
|
QOpenGLShaderProgram rendering_program;
|
||||||
|
QOpenGLShaderProgram rendering_program_spheres;
|
||||||
QOpenGLBuffer buffers[vboSize];
|
QOpenGLShaderProgram rendering_program_cylinders;
|
||||||
QOpenGLVertexArrayObject vao[vaoSize];
|
typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDARBPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount);
|
||||||
QOpenGLShaderProgram rendering_program;
|
typedef void (APIENTRYP PFNGLVERTEXATTRIBDIVISORARBPROC) (GLuint index, GLuint divisor);
|
||||||
QOpenGLShaderProgram rendering_program_spheres;
|
PFNGLDRAWARRAYSINSTANCEDARBPROC glDrawArraysInstanced;
|
||||||
QOpenGLShaderProgram rendering_program_cylinders;
|
PFNGLVERTEXATTRIBDIVISORARBPROC glVertexAttribDivisor;
|
||||||
typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDARBPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount);
|
void initialize_buffers();
|
||||||
typedef void (APIENTRYP PFNGLVERTEXATTRIBDIVISORARBPROC) (GLuint index, GLuint divisor);
|
void compute_elements();
|
||||||
PFNGLDRAWARRAYSINSTANCEDARBPROC glDrawArraysInstanced;
|
void attrib_buffers(CGAL::QGLViewer*);
|
||||||
PFNGLVERTEXATTRIBDIVISORARBPROC glVertexAttribDivisor;
|
void compile_shaders();
|
||||||
void initialize_buffers();
|
void draw_cylinder(float R, int prec, Coords_ptr& vertices, Coords_ptr& normals);
|
||||||
void compute_elements();
|
void draw_sphere(float R, int prec, Coords_ptr& vertices, Coords_ptr& normals);
|
||||||
void attrib_buffers(CGAL::QGLViewer*);
|
|
||||||
void compile_shaders();
|
|
||||||
void draw_cylinder(float R, int prec, std::vector<float> *vertices, std::vector<float> *normals);
|
|
||||||
void draw_sphere(float R, int prec, std::vector<float> *vertices, std::vector<float> *normals);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue