Category "opengl"

Order of vertex for drawing quad

I need to draw n planes in 3D space. The quads are planes created from two points, and with an algorithm I get 4 vertex for drawing the quad. The problem I have

How to create QT Window and use pure OpenGL core profile inside?

I don't want to use QOpenGLWidget, because of the old version of OpenGL inside. I don't understand what is the difference between getting QOpengGLFunctions from

egui glow image black screen

pub struct FrameBuffer { renderer_id: glow::Framebuffer, color_attachment: glow::Texture, //depth_attachment: glow::Texture, width: u32, hei

glsl arithmetic operator

Why does this line: float x = 1 - gl_Color.x; give: (26): error: Could not implicitly convert operands to arithmetic operator

OpenGL, diffuse shader

I'm trying to implement very simple diffuse shader in GLSL/openGL. Here's what I got: Vertex shader: #version 130 in vec3 vertPos3D; in vec3 vertNormal3D; un

Displaying FPS in GLFW window title?

Im trying to get my FPS to display in the window title but my program is just not having it. my FPS code void showFPS() { // Measure speed doubl

Draw the midpoint lines between points

I am making generated shapes in a fragment shader and part of it involves drawing the border between objects ie the dividing line between them. Currently I have