Hi,
I'm trying to extrude a path in 3d. Nothing fancy yet, just following some points and using a regular polygon for 'tubing'. I'm using Processing for now to quickly prototype, but will later turn the code into OpenGL.
My problem is rotating the 'joints' at the right angles. I think I have a rough idea how to get the angles, not sure...
I have the following C++ matrix class:
transform.h transform.cpp
I am using this coupled with a renderer, for which there is an opengl and a directx implementation.
I have a test example where the coordinates of the mouse within the window are used to position a graphic under the cursor. This works as expected under OpenGL.
Because d...
I am building a 3d game from scratch in C++ using OpenGL and SDL on linux as a hobby and to learn more about this area of programming.
Wondering about the best way to simulate time while the game is running. Obviously I have a loop that looks something like:
void main_loop()
{
while(!quit)
{
handle_events();
D...
I'm making a renderer using OpenGL. I have textured models in Blender / Sketchup (I can exchange between the two easily), and I'd like to be able to export those files into my renderer. My initial idea was to simply export the raw faces and render those triangles, but I'd like to easily slice my texture files into texture coordinates as ...
I have a windows program with directx/opengl renderers, and a custom mouse rendered as a quad. The program currently runs windowed.
The problem is the standard windows mouse is overlaid ontop of my custom cursor. How do I hide it when its inside my window?
...
I'm working on a 3d globe application written in java using java3d for the rendering. I've got a windows installer that basically copies files from a development snapshot to the program files directory. It runs fine from the devel snapshot, but when running after an install it does this:
Java 3D ERROR : OpenGL 1.2 or better is require...
I'm looking for some kind of OpenSource library that allows me to make OpenGL GUIs on the iPhone ( for example the game menu , and some in-game pieces of interface like a player inventory ).
Does anyone know if some sort of library/middleware exists for this ?
A very big commercial example of this ( not for the iPhone ) would be: Scal...
...frustration. I want my game to be run only in landscape mode. I have added the appropriate key/value to the Info.plist file that forces the device orientation to be correct at launch.
I'm now trying to rotate the OpenGL coordinate space to match that of the device. I'm trying to use the code I found here, but it's not working. My...
I am developing a 2D game for the iPhone and iPod Touch using OpenGL ES 1.1. Everything works ok on the iPhone, iPhone 3G and all iPod Touch models. The game usually renders the scenes at ~60 FPS.
This happens on the iPhone 3GS also, but sometimes (it's completely random) the 3GS drops the framerate to around 40 FPS and the animation se...
Hi all,
with a few friends we started this amateur platform-independent java-based project for a space combat simulator game (something like the long dead saga of wing commander). None of us though is a 3D programmer, so the road is gonna be long.
My question is: in our place would you start learning OpenGL (maybe via GLUT) or is there...
I'm currently calling Trace (method below) from a game loop. Right now all I'm trying to do is get the world coordinates from the screen mouse so I can move objects around in the world space. The values I'm getting from gluUnProject are however; puzzling me.
I was using glReadPixel(...) to get the Z value but that produced little to n...
I'm trying to use 'glimagesink' element with python.
The element (which is GObject inside) has client-draw-callback property which should (in C++ at least) contain a function (bool func(uint t, uint w, uint h)) pointer.
I've tried element.set_property('client-draw-callback', myfunc), and creating function pointer with ctypes, but every t...
I'm trying to draw grayscale image in color as texture in OpenGL using two colors. Black goes to color1 and white goes to color2. Texture is loaded using GL_RGBA.
I have tried two solutions:
1)
Load image as texture
Draw image on screen
Enable blending
glBlendFunc(GL_ONE_MINUS_DST_COLOR, GL_ZERO); and draw rectangle with color1
glBle...
I have the following OpenGL code in the display function:
glLoadIdentity();
gluLookAt(eyex, eyey, eyez, atx, aty, atz, upx, upy, upz);
// called as: gluLookAt(20, 5, 5, -20, 5, 5, 0, 1, 0);
axis();
glutWireCube (1.);
glFlush ();
axis() draws lines from (0,0,0) to (10,0,0), (0,10,0) and (0,10,0), plus a line from (1,0,0) to (1,3,0).
...
In my 2D game I need textures that may be arbitrarily large, can be NPOT and nonsquare.
They are only ever mapped to one kind of primitive: rectangles via GL_QUADS (the four QUAD corners are mapped to the four texture corners). Sometimes the texture matrix has been scaled before drawing.
I want my game to work everywhere, even on old/ch...
Hello,
I wrote an OpenGL app in C++ a while ago, back when my operating system was Windows XP.
I used GLUT (plane ol' version) to show the window and also used full screen mode.
There are times when I displayed a message box (MessageBoxA method, using the MB_TASKMODAL modifier).
In windows XP the message box was being displayed nicel...
Hi everyone,
I'm trying to get JOGL running in Eclipse 3.5 on a MacbookPro 64bit Snow Leopard with Java 1.6.
The code runs on my XP machine, however, when I try to run it on my macBook, I get this error in Eclipse's console:
Invalid memory access of location 00000000 eip=8fe11f32
And thats it.
I've tried a few different codes, ...
Hi ,
In my didactic openGL appl , I have some objects on the scene, and when I click on one of them I want my camera to look at that object. For that after I determine the clicked object , I compute the up , front and right vectors of the camera and then I need to be able to calculate the pitch, yaw, roll angles of the camera. However...
Can I have 2 full-screen EAGLView-s (the OpenGL layer implementation from Apple's sample code), stack them on top of each other, draw on them independently and then see both images?
(I suppose the top one will need a glClearColor(0, 0, 0, 0) to be transparent -- does that even work?!)
In my initial experiments, the 2nd EAGLView complai...
I'm playing with shaders in openGL using Processing. I'm pretty noob at this and a bit lost.
I found this thread that has an example on how to use GLSL shaders in Processing.
I'm just trying to the change LightPosition parameter in the shader I'm using. I don't know how to access it though.
Here's my code so far:
import processing.o...