#ifndef VIEW_SOLUTION_GEOMETRY_HPP
#define VIEW_SOLUTION_GEOMETRY_HPP

#include <QWidget>
#include <QPainter>
#include <QOpenGLWidget>
#include <QMouseEvent>
#include <GL/glut.h>
#include "kernel.hpp"


class QtViewSolutionGeometry:public QOpenGLWidget{
private:
  Kernel* kernel;
  size_t step;
public:
  QtViewSolutionGeometry(Kernel* kernel);
  void initializeGL();
  void resizeGL(int x,int h);
  void paintGL();
  /*  void paintEvent(QPaintEvent* event);*/
  void draw(size_t t);
  void drawTriangle(size_t ix1,size_t iz1,size_t ix2,size_t iz2,size_t ix3,size_t iz3);
  void mousePressEvent(QMouseEvent* event);
  void displayInfos(double x,double y);
};
#endif
