opengl

C++ / openGL: Rotating a QUAD toward a point using quaternions (updated)

When I have a QUAD at a certain position, how can I rotate it in such a way that its normal points toward a given point? Imagine the colored blocks are just rectangular quads, then this image shows a bit what I mean. The quads are all oriented in such a way they point toward the center of the sphere. Maybe this second image shows a bi...

Make a List<Point3D> , add points and draw using glDrawArrays.

Hey guys, This is a follow up question from http://stackoverflow.com/questions/3204189/add-contents-to-the-end-of-a-float-array-like-this . I'm looking to dynamically create 3D boxes. Here's my Questions I want to add a box to the list e.g add.... // FRONT -2.0f, -1.5f, -6.0f, 2.0f, -1.5f, -6.0f, -2.0f, ...

Draw a texture in OpenGL while ignoring it's alpha channel.

I have a texture loaded into memory that is of RGBA format with various alpha values. The image is loaded as so: GLuint texture = 0; glGenTextures(1, &texture); glBindTexture(GL_TEXTURE_2D, texture); self.texNum = texture; glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER,GL_LINEAR); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE...

OpenGL like library for 3D Vector Graphics?

Hi! I'm familiar with OpenGL. I want something like OpenGL, except with the final output as a vector image rather than a bitmap image. Is there anything like this? Thanks! EDIT clarifications: I have a picure rendered in OpenGL. I want to render it as an image in a paper. I want the image to be vector rather than bitmap. ...

Where can I learn more on xcode OpenGL ?

Where can I learn more on xcode OpenGL ? ...

Open format for 3d models in an OpenGL application?

Hi, I am looking to develop a game for opengl and wondering what format you recommend for using internally. The idea being to open up for contributions so some format with a lot of features, open, available and quite possibly also sample loading/rendering. Platform is java and lwjgl.org I've been looking at collada but not sure it's su...

Image Processing on GPU- sucessive shaders for filters - FBO

Hi all, I'm currently trying to implement in OpenGL image processing algorithms. I would like to successively use several shaders in order to perform several filters (Sobel Gaussian,...). I understood that to do thius I had to render to texture thanks to a FBO. I read a lot of things about that, and wrote a code. But I'm not getting th...

Why is this array selection causing such a glitchy phenomenon?

I was loading a image in openGl with the Glaux library when I came across a very strange phenomenon with a array. Some example of what I tried and if they succeeded or not are below. The curFreeId variable is global. The extra variables I created to test with are local to the function. Since when does this effect the flow of code. ...

OpenGl VBO technicalities in C++

I'm a little confused as to the proper usage of VBOs in an OpenGL program. I want to create a terrain paging algorithm, using a map called from a 4096x4096 greyscale heightmap as the "whole" map. From what I've read, each vertex stored in the VBO will take up 64 bytes. The problem I have is that most sources state that a single VBO sh...

Writing cross-platforms application with a complex GUI

Hi! I'd like develop an application with a complex GUI (combobox with animation, charts with spline, transparent layers, ...). I've good experience with C# 2.0 and I'm studying WPF, but unfortunately I read that there is no plan to port WPF on Mono. I was thinking about creating my custom GUI control using OpenGL (with OpenTK)... But I...

QGLWidget::renderText bounding box

Is it possible to get the bounding box of the output of QGLWidget::renderText() in logical or window coordinates? How? ...

Learning OpenGL while practicing TDD (unit testing)

I have started a new game project, and have decided to learn and use OpenGL for it (project is being simultaneously developed on Windows and Linux). At the same time, I am also very interested in Test Driven Development, and am trying to put my best effort into writing my unit tests to lead design before any actual code. However, I thin...

3d Drawing in Python with OpenGL

I need to: draw 3d models with specific 3ds textures have the models be moving (just position) have a camera viewer which is easily maneuverable (ideally in real time) I would like to accomplish this with Python and OpenGL. What would be the best libraries to accomplish this and what are some good resources to read up on? Thanks in ...

Passing a variable to a OpenGL GLSL shader

Hello! I'm writing an iPhone app which uses GLSL shaders to preform transformations on textures, but one point that I'm having a little hard time with is passing variables to my GLSL shader. I've read that it's possible to have a shader read part of the OpenGL state (and I would only need read-only access to this variable), but I'm not...

Alternative to GLUTesselator?

I was wondering if there was a library or another way to produce multi contour polygons in OpenGL. I did code profiling and the GLUTesselator is killing my loop. Thanks ...

Is there any difference in the end contents in these 2 different ways of populating arrays?

Hey Guys, assume variables and the numbers in the 2 examples have the same numbers... Is there any difference in the end contents in these 2 different ways of populating arrays? am I wrong assuming it's the same? Basically I'm trying to render graphics with OpenGL the first example doesn't work but the second does. Example 1... The g...

Is there a way to do this?

Here is my issue. I have a std::vector<POINTFLOAT> Which stores verticies. The issue is that Vertex buffer objects take in a pointer to an array of float. Therein lies my problem. I cannot give it an array of pointfloat. Is there a way that I could instead push pointers to the individual components of each vertex without pushing in copie...

What package should I be using for 2d animation?

I am working with a client on a 2d map. The map is centered on the user's position and marks various headings and points of interest. As the user moves, the headings change and the points of interest move. My client is insistent on using OpenGL for this, but this seems like overkill. He has mentioned he thinks GDI+ and SDL are too slow...

How to tell whether an OpenGL context is hardware accelerated?

I know that if the openGl implementation does not find a suitable driver it happily falls back and render everything in software mode. It's good for graphics applications but it is not acceptable for computer games. I know many users using Windows XP and if the user does not install the video card driver for his GPU then the OpenGL won'...

Open-source OpenGL profiler for Linux

The title sums my question up pretty well: are there any open source OpenGL profilers for Linux? The only thing I could find was gDEBugger, but it only comes with a 7 day trial and is very much closed source. I would use this for free (as in freedom) software development so paying is not an option, though I might consider accept answers...