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 ...
6
votes
4answers
2k views
Order independent transparency in particle system
I'm writing a particle system and would like to find a trick to achieve proper alpha blending without sorting particles because:
Each particle is a point sprite in a single mesh and I can't use ...
6
votes
2answers
582 views
OpenGL or OpenGL ES
What should I learn? OpenGL 4.1 or OpenGL ES 2.0?
I will be developing desktop applications using Qt but I may start developing mobile applications in a few months, too. I don't know anything about ...
6
votes
4answers
438 views
Generating triangles from a square grid
I have a 2D square grid of values representing terrain elevations, and I want to generate triangles from that grid to make a 3D view of the terrain. My first thought was to split each square ...
6
votes
1answer
324 views
Display Lists in OpenGL
I heard that there was a faster method of displaying vertices, rather than recreating the GL_TRIANGLES, each time the scene is drawn. I thought I read somewhere that this method was obselete. Why ...
6
votes
2answers
2k views
Why should I not use glTools/glut when developing complete applications?
I've started learning how to use OpenGL a while back, using the OpenGL SuperBible, Fifth Edition, and I've had people arguing about the fact that the book doesn't really teach how to use OpenGL but ...
6
votes
2answers
4k views
Most common 3D model format for opengl
I'm a novice that is starting to play with OpenGL ES on Android devices. To practice OpenGL I wanted to create a small game engine and so I was wondering what the best 3D model file format would be.
...
6
votes
4answers
358 views
How can I generate a view or projection matrix for OpenGL 3.+
I'm transitioning from OpenGL 2 to OpenGL 3.+ and to GLSL 1.5. I'm trying to avoid using the deprecated features.
My question how do we now generate the view or projection matrix. I was using the ...
6
votes
1answer
112 views
Get SFML to report the version of OpenGL that is being used
How can I get SFML to report the version of OpenGL that is being used by the render window?
6
votes
3answers
1k views
Direct3D and OpenGL Matrix representation
As I read in OpenGL matrices are column major. It means that if I create a 16 element array first four elements are the first column in matrix. Is it the same for Direct3D or any transformation's ...
6
votes
1answer
4k views
Help understanding gluLookAt()
I am fairly new to openGL( 3 months ) and am asking for assistance in understanding the fundamentals behind gluLookAt().
Currently I have spent most of my time with openGL modeling scenes with fixed ...
6
votes
2answers
582 views
How are dynamic blending shadows like this created?
I would like to know, how dynamic shadows, that 'blend' onto other objects, are created.
6
votes
1answer
906 views
Rendering 2D grass
My current project, using Java and OpenGL, has a fairly standard overhead tilemap in the style of the Zelda games.
I'd really like to add "real" grass to the grass tiles so that there are actually ...
6
votes
1answer
2k views
GLSL - Rewriting shaders from #330 to #130
I recently created a game (LD21) that uses a geometry shader to convert points into textured triangles/culling. Since I was under the impression that the support for #330 was widespread I only wrote ...
6
votes
1answer
600 views
Do I really have to write my own optimized model format?
So I'm a brand new noob to the world of game dev and I'm starting off by trying to write my own game using C++ and openGL. I'm getting into loading models etc and while searching around for "the best ...
6
votes
2answers
318 views
Changing player color without multiple player bitmaps [duplicate]
Possible Duplicate:
How to colorize certain parts of a model - like RTS games have those team colors?
Ok, so here is my current situation. I have a player model, fully UV mapped, and ...
6
votes
2answers
726 views
How do I apply skeletal animation from a .x (Direct X) file?
Using the .x format to export a model from Blender, I can load a mesh, armature and animation. I have no problems generating the mesh and viewing models in game. Additionally, I have animations and ...
6
votes
1answer
711 views
How is animation handled in non-immediate OpenGL?
I'm a newbie to modern OpenGL. I'm comfortable with the immediate OpenGL methodology, but I've never done any serious use of VBOs. My question is about animation. In immediate mode, to achieve ...
6
votes
2answers
476 views
Textures for an underwater environment?
I'm trying to build an underwater scene. I'm including my scene in a large cube, which I'm going to texture with images that resemble an underwater environment. Where can I get textures for something ...
6
votes
3answers
761 views
How can I get into opensource game development?
The short and sweet question
I'm new to game programming in general, so how do I go about making GOOD QUALITY opensource games?
What I have come across
There are a multitude of games that I have ...
6
votes
2answers
381 views
An odd performance problem rendering a simple scene (less than 14k vertices) in OpenGL using two vbos with LWJGL
Problem
I have been having a strange degrading performance issue rendering a simple scene containing two "chunks" of 4x4x4 cubes each.
Video of problem
This is a screen capture showing my console ...
6
votes
1answer
615 views
How can I organize render and transformation data in a scalable fashion?
I am writing for OpenGL 2.0 and in the future porting to OpenGL ES 2.0. I only use VBOs and shaders (no immediate mode, no vertex arrays).
I already have working solutions, they just... feel wrong. ...
6
votes
1answer
597 views
Using glReadBuffer/glReadPixels returns black image instead of the actual image only on Intel cards
I have this piece of code
glReadBuffer( GL_FRONT );
glReadPixels( 0, 0, width, height, GL_RGB, GL_UNSIGNED_BYTE, buffer );
Which works just perfectly in all the Nvidia and AMD GPUs I have tried, ...
6
votes
4answers
447 views
Impact of variable-length loops on GPU shaders
Its popular to render procedural content inside the GPU e.g. in the demoscene (drawing a single quad to fill the screen and letting the GPU compute the pixels).
Ray marching is popular:
This means ...
6
votes
1answer
144 views
Excluding Background from Color Picking
I've implemented picking based on color coding, but I don't want the background color to be pickable. Is there any way in openGL (2.x) to exclude the background color? For some reason, doing ...
6
votes
1answer
1k views
Atmospheric Scattering
I'm trying to implement atmospheric scattering based on Sean O`Neil algorithm that was published in GPU Gems 2. But I have some trouble getting the shader to work. My latest attempts resulted in: ...
6
votes
3answers
959 views
Common light map practices
My scene consists of individual meshes. At the moment each mesh has its associated light map texture, I was able to implement the light mapping using these many small textures.
1) Of course, I want ...
6
votes
0answers
74 views
Which is the best LOD method for planet rendering?
I'm currently working on my thesis, it is an engine to render terrains of planetary size.
I'm still finishing my research and I have encountered a lot of stuff about this subject, the problem is that ...
6
votes
1answer
174 views
Getting started to OpenGL - little question
Im starting to learn opengl, and after 2 days, searching and trying hard, i finally installed all the libraries i need (lol).
So, I'm following this tutorial, and it says to use glfwOpenWindowHint ...
5
votes
5answers
1k views
Is GLUT obsolete?
A question was asked about good, up-to date OpenGL resources, one of the answers was a link to a tutorial about modern OpenGL programming.
The tutorial in question uses GLUT and GLEW, but I have read ...
5
votes
3answers
944 views
What features does D3D have that OpenGL does not (and vice versa)?
Are there any feature comparisons on Direct3D 11 and the newest OpenGL versions?
Well, simply put, Direct3D 11 introduced three main features (taken from Wikipedia):
Tessellation
Multithreaded ...
5
votes
4answers
2k views
2D Platformer Collision Handling
I am trying to create a 2D platformer (Mario-type) game and I am some having some issues with handling collisions properly. I am writing this game in C++, using SDL for input, image loading, font ...
5
votes
3answers
600 views
Understanding how to create/use textures for games when limited by power of two sizes
I have some questions about the creating graphics for a game.
As an example. I want to create a motorbike. (1pixel = 1centimeter)
So my motorbike will have 200 width and 150 height. (200x150)
But the ...
5
votes
3answers
1k views
Draw contour around object in Opengl
I need to draw contour around 2d objects in 3d space. I tried drawing lines around object(+points to fill the gap), but due to line width, some part of it(~50%) was covering object. I tried to use ...
5
votes
2answers
1k views
Using HTML for interface?
The game I've been working on uses opengl/sfml for graphics. I'm currently working on the interface and I've found determining all the proper offsets/positioning etc. to be a pain. To make it ...
5
votes
5answers
751 views
What are some low-level performance tweaks for iPhone games written in c?
I'm interested in some performance tweaks for a relatively simple OpenGL ES based 2D iPhone game. What performance tweaks have you found? The performance of the game is pretty good on most devices ...
5
votes
3answers
3k views
How can I get started programming OpenGL on Mac OS X?
I'm trying to start OpenGL programming on a Mac, which brings me into unknown territory on a lot of things.
During the day, I'm a Web Developer, working in C# and before that in PHP and Delphi, all ...
5
votes
2answers
671 views
OpenGL 2 and back vs 3 and forward: What are the key differences for 2D graphics?
OpenGL contexts before and after OpenGL 3.0 are rather different. So far I've really only worked with buffers on either side anyway, I do know the most notable difference is lack of Immediate Mode.
...
5
votes
2answers
812 views
How to change the sprite colors
In my rhythm game, I have a note object which can be of different colors depending on the note chart. I could use a sprite sheet with all the different color variations I use, but I would prefer to ...
5
votes
2answers
421 views
GL_EXT_draw_instanced vs VBO's
I'm having trouble understanding the benefit of the newer GL_EXT_draw_instanced over traditional VBO's. Don't both keep geometry cached on the gpu for faster redrawing? VBO's seem much more ...
5
votes
2answers
642 views
Atmospheric Scattering
I want to add some nice atmospheric scattering to my 3D game engine but I am very concerned with conserving resources. I am not very familiar with how its done but can someone please give me some ...
5
votes
1answer
138 views
2-components color model
RGB is the natural color model for OpenGL. But a lot of other color models exist.
For example, CMY(K) for printers, YUV for JPEG, the little cousins YCbCr and YCoCg, HSL & HSV from the 70's, and ...
5
votes
1answer
324 views
Why would I support multiple rendering engines simultaneously?
I've seen some games from the early 2000s that had a launcher where you could select the rendering engine you wanted to use: DirectX or OpenGL.
Maybe I haven't looked hard enough, but I haven't seen ...
5
votes
2answers
415 views
Which are the most futureproof languages for graphics (shader) programming?
I have written some GLSL and Cg shaders a couple years back. I am starting another graphics engine project and I want to choose my technologies carefully so that my code will be accessible years down ...
5
votes
1answer
281 views
Is a 10 meg 2048x2048 bitmap too big a size texture to use in an OpenGL game?
This is a speed question, I have a texture, which is 2048 per 2048, the texture is designed to run in big resolutions (1920x1080 for example).
The problem is, that the texture have a size of 10MB in ...
5
votes
2answers
567 views
Best way to do buttons for an OpenGL ES iPhone game
I'm making a simple 2d game in OpenGL ES and I want to add movement buttons to it. What's the best way of going about this? In previous projects I've simply added UIButtons to the view but I hear ...
5
votes
2answers
725 views
What is causing these texture edge artifacts on some video cards?
I have a 2d heightfield converted into a very simple mesh and textured with tiles from a texture atlas. The tiles texture is drawn with:
glTexParameterf(GL_TEXTURE_2D,GL_TEXTURE_WRAP_S,GL_CLAMP);
...
5
votes
3answers
3k views
Open Source Engine for RTS [closed]
I must write a cross-platform real-time-strategy game within 2-3 months. I want use C++ and OpenGL and am looking for an engine.
The engine must be open source and work under both Linux and Windows. ...
5
votes
2answers
846 views
Generating geometry when using VBO
Currently I am working on a project in which I generate geometry based on the players movement. A glorified very long trail, composed of quads.
I am doing this by storing a STD::Vector, and removing ...
5
votes
1answer
364 views
GLSL subroutine not being used
I'm using a gaussian blur fragment shader. In it, I thought it would be concise to include 2 subroutines: one for selecting the horizontal texture coordinate offsets, and another for the vertical ...
5
votes
2answers
277 views
Should I batch up debug primitives for rendering in modern OpenGL?
I've recently started porting some old rendering demos I did to modern OpenGL. I had a debug drawing class in my old code which used immediate mode glBegin(), glEnd() etc. for rendering debug objects ...