m2b-ar-tp2/fish_painter.h
2021-10-06 19:49:42 +02:00

27 lines
525 B
C++

#ifndef FISH_VIEWER_H
#define FISH_VIEWER_H
#include "fish.h"
#include <QOpenGLVertexArrayObject>
#include <QOpenGLBuffer>
#include <QOpenGLShaderProgram>
#include <QOpenGLExtraFunctions>
#include <QMatrix4x4>
class FishPainter {
QOpenGLVertexArrayObject vao;
QOpenGLBuffer vbo;
QOpenGLShaderProgram program;
public:
void create(QOpenGLExtraFunctions *glf);
void paint(QOpenGLExtraFunctions *glf,
const QMatrix4x4 &projection,
const QMatrix4x4 &view,
const std::vector<Fish> fishes);
};
#endif