|
|
@ -21,6 +21,8 @@ GLWidget::GLWidget(Simulation * simulation) : simulation(simulation) { |
|
|
|
void GLWidget::initializeGL() { |
|
|
|
void GLWidget::initializeGL() { |
|
|
|
initializeOpenGLFunctions(); |
|
|
|
initializeOpenGLFunctions(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
std::cout << "OpenGL Version: " << format().majorVersion() << "." << format().minorVersion() << std::endl; |
|
|
|
|
|
|
|
|
|
|
|
pendulaProgram = new QOpenGLShaderProgram; |
|
|
|
pendulaProgram = new QOpenGLShaderProgram; |
|
|
|
pendulaProgram->addShaderFromSourceFile(QOpenGLShader::Vertex, ":/shaders/vertex_pendula.glsl"); |
|
|
|
pendulaProgram->addShaderFromSourceFile(QOpenGLShader::Vertex, ":/shaders/vertex_pendula.glsl"); |
|
|
|
pendulaProgram->addShaderFromSourceFile(QOpenGLShader::Fragment, ":/shaders/fragment_pendula.glsl"); |
|
|
|
pendulaProgram->addShaderFromSourceFile(QOpenGLShader::Fragment, ":/shaders/fragment_pendula.glsl"); |
|
|
|