What's the deal with Deno? We talk with a major contributor to find out. Listen now.

Questions tagged [opengl]

OpenGL is a graphics standard and API which targets the desktop and workstation markets. It is designed to be easy to accelerate with dedicated computer hardware, and hence most implementations give greatly improved performance over traditional software rendering. Currently, OpenGL is used for applications like CAD software and computer games. It is also cross-platform. The OpenGL standard is controlled by the Khronos group, which also controls OpenGL ES.

Filter by
Sorted by
Tagged with
0
votes
1answer
68 views

How do I calculate the bounding box for an ortho matrix for Cascaded shadow mapping?

I've been trying to get a cascaded shadow mapping system implemented on my engine, though it appears to be that the bounding boxes for the cascades aren't correct. The part I'm interested in can be ...
1
vote
1answer
106 views

Model gets distorted when rotating the camera

I'm currently developing my own 3d graphics engine and I'm having a hard time figuring out why my 3D models gets distorted when rotating the camera around. This is my projection matrix. I'm following ...
0
votes
0answers
13 views

Constant size geometries for glDrawArraysInstanced calls

In my application I can keep the objects constant sized ...
1
vote
1answer
17 views

Bind render result to texture id

I want to save the result screen of the rendering and then apply another shader on that result, the typical way is to read the screen using glReadPixels and then buffer that image to gpu and then ...
0
votes
0answers
60 views

LibGDX 2D Silhouette

recently I decided to implement in my game the drawing of a silhouette of the player when he is behind objects (the top layer of the map). Found a similar question here, but it doesn't matter to me to ...
0
votes
1answer
54 views

when to unbind vao in drawing loops

I am very new to open gl and am struggling to understand relation between vaos vbos and ibos like how is currently bound vao related to currently bound ibo? now i am trying to render 4 triangles with ...
0
votes
0answers
22 views

GLFW Problem “The driver does not appear to support OpenGL”

i'am trying to learn OpenGL & GLFW , when i run this simple project i get error ID : "65542" with Message : "The driver does not appear to support OpenGL". my Graphics Card ...
0
votes
1answer
25 views

Does swap buffer with vsynch guarantee synchronization?

I was wondering if I could assume that all buffer related GPU operations such as: glDrawElements glBufferData glSubBufferData glUnmapBuffer are guaranteed to be completed after swap buffer is ...
0
votes
1answer
113 views

Graphic render speed in libgdx using many sprite sheets

I am currently working on a customizable Player-character for my top down view 2D pixel game. I am using libgdx and aiming for android devices as well as desktop applications. I am wondering about an ...
0
votes
1answer
89 views

How can I render a font in C with OpenGL?

What I tried: I was testing some things in order to render text with stb_truetype.h and OpenGL in C. I took as a reference the example that appears here. Basically, this example, loads a .ttf file and ...
0
votes
1answer
139 views

Porting C# OpenGL rendering code to C++ DirectX

I have the following rendering method written in C# and apparently using OpenGL immediate mode, and i'm trying to port it to C++ and DirectX: ...
0
votes
0answers
21 views

Is it appropriate approach to simulate shadowing via occlusion culling of lights?

I have own deferred renderer and a scene with both closed and open spaces. I want to prevent light passing though solid objects. For example, there can be a house with a lot of point lights inside. I ...
0
votes
0answers
20 views

Why does this order of Quaternion multiplication not introduce roll into my fps-style character controller?

I'm working on an OpenGL based project (in C#), employing Quaternions to rotate my camera I first tried to: ...
0
votes
0answers
19 views
0
votes
0answers
29 views

OpenGL Drawing triangles at given world coordinates in modern opengl

It's my first time I am asking a question here so I apologize in advance for any mistake. In the past two days, I decided to work on a 2D lighting system for my game and I came across a youtube ...
2
votes
1answer
21 views

How does re-glBufferData()'ing interact with glVertexAttribPointer?

I understand the basic sequence: glGenBuffers() creates a "buffer object name," glBindBuffer() creates the actual buffer object (as well as binding the name), glBufferData() "creates ...
0
votes
0answers
35 views

C++ Help with Separating Axis Theorem

I am trying to detect collision between two triangles using Separating Axis Theorem however I am unaware what is wrong with my code. The CollisionHelper::isTriangleIntersectingTriangle is called every ...
0
votes
1answer
145 views

TBN matrix for normal and parallax mapping

I'd like to refer to this question because I didn't completely answer to my problem. I've implemented normal and parallax mapping but because of some assumptions I have to use two different TBN ...
0
votes
1answer
16 views

glfw resizing causing image scaling

I have a quad rendered that extends from the top left of the window to with width of the window that is also 64 pixels high. When I resize the window, from its initial size, the quad and text scales ...
0
votes
0answers
27 views

coloured 3d models rendering issue while running on android

I am using Godot 3.2.2 stable (GLES2) along with kenney 3d nature asset pack (glb) for prototyping a 3d game. Everything works just fine on my desktop computer, but when I deploy the game to my ...
2
votes
2answers
482 views

C++ Mouse picking for ray to plane intersection

I'm making a C++/OpenGL application (decidedly without GLM), and I'd like to understand how to create a ray from the camera eye to the mouse pointer, as well as detect an intersection point from the ...
0
votes
1answer
122 views

I can't make the cube map to use shadow mapping - or it seems so

Basically, I'm following tutorials as I'm very new to OpenGL. I managed to perform shadow mapping towards just one direction, meaning I created 2D texture depth map. Now with omnidirectional shadow ...
1
vote
0answers
27 views

Shadowmapping with multiple light sources

I am using shadow-mapping to add shadows to my world. Currently, I use one lightsource, which means I have to draw my world twice: once in the lightview, once in the camera view. I want to add more ...
0
votes
1answer
3k views

GluUnproject works, but only when the camera is not rotated

I am working on a very basic 3D program, my first one using OpenGL. What I am trying to do is trace a ray from the mouse's location on click which works, but only when the camera is not rotated. When ...
0
votes
1answer
49 views

Parts of OpenGL rendering area missing/transparent until resize

I am having a weird transparency issue when running my game in windowed mode. Parts of the window, left and top parts in normal window mode, right and bottom when in maximised window, become ...
0
votes
2answers
45 views

How to make player seem bigger / world smaller, without changing world coordinates

I am making a voxel game with OpenGl, I've got the major parts working, except the camera seems small compared to the the blocks. How do I make the camera bigger? Do I do a scaling on the model ...
0
votes
0answers
54 views

How to load a PNG in pure C

PNG loading: I've been creating a game engine for almost a year, and since the start of the development, I have been using stb_image for loading images. It ...
5
votes
1answer
777 views

How to make Volume Heat Distortion effect in OpenGL?

I'm working on adding volume effects to an existent, open-source game engine. At the moment, the engine only supports two dimensional "thruster" bitmaps with a planar heat distortion drawn over the ...
13
votes
4answers
9k views

Why does clip space in OpenGL have 4 dimensions?

I will use this as a generic reference, but the more i browser online docs and books, the less i understand about this. ...
0
votes
1answer
59 views
0
votes
1answer
154 views

Animate some tiles of tile map

I have a game where each "tile" of the terrain is a triangle (Settlers 2). Those are placed next to each other and in way creating an infinite world (right/bottom jumps back to left/top). There is a ...
1
vote
1answer
58 views

OpenGL approach to depth-testing-like combination of a large buffer of fragments

I have a depth buffer and color buffer created by another effect. The buffer is more than double my screen size. It is not rendered from geometry, but as a whole it resembles a rendered scene with an ...
11
votes
3answers
837 views

How to hide a post-processed mesh outline when/where the mesh is hidden

I'm working on setting up an active outline in my 3d engine, a highlight effect for selected 3d characters or scenery in the screen. After working with the stencil buffer and getting some ...
0
votes
0answers
22 views

Repeat/Scroll texture on CubeMap

I need a method to scroll an image across all sides of a cube map in a way similar to scrolling a UV texture across a water's texture to give the appearance of movement by shifting the normals. I want ...
1
vote
1answer
294 views

Show only some parts of a point cloud. OpenGl4

I am developing an opengl 4.0 app which is showing a point cloud. In the other hand, I have an array "pos" where I have some x,y,z positions: ...
0
votes
1answer
188 views

How to deal with VBO and obj files for physics simulation?

I'm having a hard time struggling with obj files and clothing simulations. I first made the obj file processor class that deals with the typical obj file problem: having multiple indices for vertex ...
0
votes
1answer
26 views

Texture flipping behaviour

I was having this problem with OpenGL where I'd have all my textures being rendered upside down. I did the most logical thing I could think of and tried reversing the order of the mapping and that ...
0
votes
1answer
719 views

LibGDX - Draw multiple textures with different positions with one shader?

currently I'm optimizing my render calls by drawing multiple textures with one shader. The background textures who all share the same position are no problem. But now I want to draw some Textures with ...
3
votes
1answer
646 views

Specular Light not working (Phong Lighting)

There seems to be a problem with my current Phong Shading implementation. I have been using the per fragment approach. The specular highlight aspect of the technique is not rendering as it should, as ...
0
votes
1answer
220 views

How can I access an OpenGl buffer from within a GLSL 330 shader?

I am currently attempting to create a simulation using OpenGl's GPU acceleration for both the simulation computations and rendering. The rendering portion of my simulation is complete and working, but ...
5
votes
1answer
3k views

Drawing fonts with LWJGL3 with OpenGL

I'm very sorry if this question has already been answered, but since I've been struggling with this for many days I thought I'd give it a shot here. My goal is to somehow render some text on the ...
4
votes
1answer
779 views

Render Stutter - OpenGL or loop timing?

For some time now i have no been able to pinpoint the nature of the rendering stutter shown above(by not clearing the screen, not using SwapBuffers and drawing only to the front buffer). See the big ...
3
votes
2answers
958 views

Why is enabling GL_FRAMEBUFFER_SRGB making the colours brighter?

My understanding of gamma correction is as follows: We want to do colour math in linear space so we can lerp etc. between colour values and get the results we expect. But human eyes don't have a ...
0
votes
1answer
189 views

OpenGL Parallax Displacement Mapping Not Working

I am attempting to implement parallax displacement mapping into my OpenGL code but it is not working as it should. https://imgur.com/a/9yIQL As I move around, double-lines moves around and if I am ...
4
votes
1answer
1k views

Why is my model rotating opposite direction around the Y axis?

I have a simple scenario. I have a simple scene, and in it I'm drawing a grid and a model, with some axis for orientation. I noticed when I rotate the model about it's local Y axis, if I rotate the ...
0
votes
1answer
205 views

Offset on camera following object that accelerates

I have camera a that is actively following an object (a plane) from behind. This object can accelerate or decelerate. I would like to have a camera offset when I move the plane, so it doesn't look so ...
10
votes
2answers
16k views

Taking advantage of multithreading between game loop and openGL

Talking in context of a game based on openGL renderer : Let's assume there are two threads : Updates the game logic and physics etc. for the in game objects Makes openGL draw calls for each game ...
1
vote
3answers
324 views

Where did I lose vertex binding?

I make OpenGL render framework for my bachelor graduate work. I created simple Model and Shader classes. But when I tried to render some vertices, they do not render. I saw with an OpenGL profiler, ...
0
votes
2answers
225 views

How can I represent a 2d UI?

So, I wanted to start building a desktop application, which is of course with an interface, and I thought that OpenGL would be best. The problem is, once I started following TheChernoProject's ...

1
2 3 4 5
81