Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
55 views

I have recently moved on newer hardware (laptop with rtx 5070) and so with new nvdia driver (version 575). I am now using OpenGL 4.6 rather than 3.3 I used before and now I am struggling ...
Sofiane Benzait's user avatar
0 votes
0 answers
97 views

I'm developing a desktop program based on imgui docking branch on ubuntu 22.04 to add an image into background window and center it always while the window is being resized: (Also note, get arbitrary ...
Mr. Frog's user avatar
0 votes
1 answer
66 views

I am rendering a rectangle using a mesh class to encapsulate the vertex and index data, as well as handle rendering. However, I've encountered an issue where the mesh object does not render, and I'm ...
Luka's user avatar
  • 27
0 votes
1 answer
64 views

Problem I am rendering a 3D cube, and this works fine. Afterwards, I render particles as an array of points, which a geometry shader transforms to quads (2 triangles). The problem I have is that the ...
Raphael Schmitz's user avatar
2 votes
1 answer
388 views

just started learning openGL and, as usual, trying to understand what every bit of code i write does and why it is there, but i could not understand the stride argument is. according to the ...
octopus's user avatar
  • 43
1 vote
1 answer
290 views

I have some vertex data that changes every frame, but because I don't know the (max) number of vertices ahead of time, I have to use glBufferData every frame, instead of using glBufferSubData. I'm ...
Jason C's user avatar
  • 40.6k
0 votes
0 answers
55 views

I have to port some legacy OpenGL code to the 3.3+ core profile (which I'm only somewhat familiar with) but there's a specific section I'm having some trouble with because the only way I can think to ...
Jason C's user avatar
  • 40.6k
0 votes
1 answer
2k views

my problem is that while loading any type of image with the library STB image I get the next error: BAD PNG SIG, even if It's not even a PNG, all the code worked before I tried making an OBJECT class ...
Nico Cano's user avatar
2 votes
1 answer
304 views

I have some previous experience with OpenGL3 from following the tutorials on learnopengl.com and have recently been learning how WebGL2 compares. I'm still a n00b, so excuse any misunderstandings. One ...
fields's user avatar
  • 35
0 votes
0 answers
202 views

In theory, if I enable the vertical sync option with setSwapInterval(1), the time interval between the emissions of these two signals should be at least the refresh period of the display. However, in ...
qssh's user avatar
  • 11
0 votes
0 answers
642 views

I need to pass two textures of 65536x1024 pixels each to the shader program. I can't do this via the standard glTexImage2D() method because there is a limitation on the OpenGL side on the height and ...
Fabalo Asdimov's user avatar
1 vote
2 answers
86 views

I've started my learning of LWJGL3 and OpenGL 3.2+ with a triangle demo. The program seems to run well and I'm not getting any OpenGL errors, but the triangle does not show up on screen. I've looked ...
part1kl's user avatar
  • 57
1 vote
1 answer
109 views

I am trying to render a square from a single point, here is my geometry shader code: #version 330 core layout (points) in; layout(triangle_strip, max_vertices=4) out; void main(){ vec4 pos=gl_in[...
BackSpace7777777's user avatar
2 votes
1 answer
613 views

I have an object, which needs to be rotate by two axis (for simplicity, let's call them the X and Y axis, but understand that they can be completely arbitrary). So, something like this: Matrix aMat; ...
KiraHoneybee's user avatar
0 votes
1 answer
144 views

I have just started using OpenGl in visual studio. I used the drawsquare() and drawRoundRect () to draw multiple shapes in seperate void functions which I called seperately in an another function ...
Wiki's user avatar
  • 1
0 votes
1 answer
142 views

I have a problem with rendering 3D models in OpenGL - The problem is that I can't implement rendering by single index buffers (I mean rendering: vertex by vertex indices, normals by normal indices, ...
izzy and simple's user avatar
2 votes
2 answers
2k views

This is my code written in C++ that is supposed to produce 2 triangles, however I am getting a blank screen. Is there something I am missing? #include <GL/glew.h> #include <GLFW/glfw3.h> #...
Elen Mouradian's user avatar
3 votes
1 answer
398 views

Allo! I've been trying to compile an OpenGL example here and so far I've been porting the examples for the newest package versions. After I've finally got the compiler to shut up and compile, it... ...
inzig0's user avatar
  • 81
2 votes
2 answers
295 views

Problem I am trying to write a simple program in C, using OpenGL, that would allow "drawing" a 2D C array (int **, 32-bit integers) according to a color palette. For the moment (I am not ...
Ramiro Magno's user avatar
  • 3,195
3 votes
0 answers
275 views

I don't have access to direct buffer access, so I need to bind my buffers to upload data to them. Normally I bound them to the target they're used for, but I recently learned that ...
Anne Quinn's user avatar
  • 13.1k
-1 votes
1 answer
167 views

I have looked up almost all related questions regarding flickering in opengl. They all mostly have something to do with z-buffer or perspective projection. However, I'm rendering a single quad on ...
Monu Yadav's user avatar
3 votes
1 answer
1k views

The documentation for glMapBuffer says it can only use the enum access specifiers of GL_READ_ONLY, GL_WRITE_ONLY, or GL_READ_WRITE. The documentation for glMapBufferRange says it uses bitflag access ...
Anne Quinn's user avatar
  • 13.1k
2 votes
1 answer
5k views

My code is giving me this error: Exception thrown at 0x00007FFCF428A6CF (nvoglv64.dll) in program.exe: 0xC0000005: Access violation reading location 0x000001D6B603F000. In the debug output window of ...
Jakkkub's user avatar
  • 65
0 votes
0 answers
141 views

I'm building a heightmap out of a 2D array of shorts. The code to generate the vertices is MeshVertex v; // has position, normal, and texCoord fields v.position = glm::vec3( (float) x * 150, ...
Goldentoa11's user avatar
  • 1,770
1 vote
1 answer
461 views

I'm currently learning OpenGL, but I'm having some problems understanding how the different buffers relate to the VAO. In my following code, I'm creating one VAO and two buffers (VBO for the vertex ...
TomPeterson's user avatar
2 votes
1 answer
135 views

I have the following code: #include <glad/glad.h> #include <GLFW/glfw3.h> #define GLFW_INCLUDE_NONE #include <stdio.h> #include <stdlib.h> static void error_callback(int ...
violin21's user avatar
1 vote
0 answers
169 views

everybody. So I am using LWJGL to learn OpenGL. So I am trying to apply texture that is located in a folder called textures (full path -> src/textures/texture.png). However all I am getting is ...
mitas1c's user avatar
  • 335
1 vote
0 answers
185 views

As seen in the picture we have a rectangle which is 2 Dimensional in a 3D space. When I rotate said rectangle (Slightly rotated) so that the normal of this plate is perpendicular to the camera, it ...
Hendrik's user avatar
  • 11
0 votes
1 answer
319 views

I have a game that outputs color value of type ABGR1555 to a frame buffer, and uptill now I was using SDL2 for the graphics(draws a texture) and it conveniently had an option to deal with the color ...
JerSci's user avatar
  • 197
1 vote
0 answers
412 views

I have been wanting to make edit menu using framebuffers in opengl(with c++). I then render some buttons in the menu space and then render the framebuffer. So while creating the framebuffer I just ...
Anirudh's user avatar
  • 11
1 vote
1 answer
1k views

I'm starting to learn openGL (working with version 3.3) with intent to get a small 3d falling sand simulation up, akin to this: https://www.youtube.com/watch?v=R3Ji8J2Kprw&t=41s I have a little ...
Will Mungas's user avatar
0 votes
1 answer
235 views

I am trying to abstract OpenGL shader but shader compilation fails even though it is a tutorial shader. The main problem is that when I run it shader compilation fails and it shoots out arbitrary text ...
Darshan Panzade's user avatar
0 votes
1 answer
91 views

I am learning OpenGL and I am trying to abstract it to make it convenient for me to use it. but I am getting access violations when I use my IndexBuffer class while rendering. this is my code for ...
Darshan Panzade's user avatar
1 vote
1 answer
208 views

I am trying to get a direction vector to where my cursor is on the screen, however it gives me large values instead of the actual values. When doing mouse picking I am getting extremely small numbers ...
rial's user avatar
  • 1,085
0 votes
1 answer
1k views

I would like my window contents to stay centered when my window resizes. OpenGL (or GLFW) - I'm not sure which - does give this desired effect when resizing horizontally, however when i resize the ...
rial's user avatar
  • 1,085
3 votes
1 answer
624 views

I am trying to get a simple demo of OpenGL working with SDL2. I am using MacOS Big Sur 11.3.1, my SDL version is 2.0.16, and my attempted OpenGL version is 3.1. Everything seems to work fine at first, ...
Caspian Ahlberg's user avatar
0 votes
1 answer
455 views

I'm pretty new to 3D programming. I'm trying to learn OpenGL from this site. During the reading I couldn't really understand how the layout (location = 0) line really operates. I've tried to search ...
Luke__'s user avatar
  • 255
0 votes
0 answers
299 views

Let's assume we have a texture like this and an array of vertices like this: float vertices[]{ //Pos //TexCoor 0 , 0, 1,0, 0.5, 0, 1,0, 0.5, ...
TinCan's user avatar
  • 13
1 vote
1 answer
856 views

I am making a game in OpenGL and C++ and I want to add a little red tint to everything. I decided to do this by clearing the screen red after rendering everything but making the alpha channel a low ...
ChandraGupta's user avatar
1 vote
0 answers
149 views

I'm having some memory leak issues with my draw line function. I'm using windows task manager to see that there is a problem. When I start the application it uses around 200MB and after running it for ...
MegaMagnum's user avatar
0 votes
0 answers
198 views

I have been using glBitmap for quite a long time and I need to scale according to the Windows Display settings. For me, performance is key and I can't afford texture spriting or any other stuff. ...
Miral's user avatar
  • 65
1 vote
1 answer
448 views

I have a VBO that contains multiple 3d models stored one after another with the intention of drawing the models conditionally with multiple calls to functions like glDrawElements. Each model is meant ...
user3124047's user avatar
1 vote
1 answer
579 views

The code is building successfully but when I run the code I have the following error - The following is a new check for GLUT 3.0; update your code. GLUT: Fatal Error in D:\6th Sem\4. CG UCS505\...
Purnima Lal's user avatar
0 votes
0 answers
82 views

I have an object which I'm trying to apply some transformation. For example, with something like an airplane. If I translate the object, it translates normally. However, if I try rotating it at its ...
Oracle247's user avatar
0 votes
1 answer
148 views

I am currently writing my own game engine and I am having trouble properly implementing quaternions. My current quaternion implementation looks like this: /* CybRender - Quaternion API */ #include &...
DylanCheetah's user avatar
1 vote
1 answer
78 views

this is the code i know is making the errors self.scale_loc = glGetUniformLocation(shader, b"scale") self.rotate_loc = glGetUniformLocation(shader, b"rotate") self....
AwesomeNoob999's user avatar
1 vote
1 answer
83 views

this code doesn't allow me to use it position_loc = glGetAttribLocation(shader, "position") color_loc = glGetAttribLocation(shader, "color") the full code near it shader = ...
AwesomeNoob999's user avatar
1 vote
1 answer
3k views

I am creating a 3D game using LWJGL3, and I want the window loaded in the background and hidden, wait for my game setup and only than showing up. My problem is even if I call GLFW.glfwHideWindow(...
Programmer's user avatar
0 votes
1 answer
511 views

I'm trying to code a simple triangle. However glGenVertexArrays(1, &VertexArrayID) casues a segmentation fault whenever I run it. SDL_Init(SDL_INIT_VIDEO); SDL_GL_SetAttribute(...
Xantium's user avatar
  • 11.7k
2 votes
1 answer
328 views

I am pulling 12 bit data from a camera which is packed, so that 3 bytes define 2 consecutive pixels. Is there a way to decompress these into two 16 bit values before passing the data to the vertex ...
Johann Horvat's user avatar

1
2 3 4 5
16