Questions tagged [glu]

The OpenGL Utility Library

The OpenGL Utility Library (GLU) provides a number of higher level drawing routines and utility functions on top of OpenGL. As such it provides functionality for:

  • Mipmapping,
  • Matrix manipulation
  • Polygon tessellation
  • Quadrics
  • NURBS
  • Error handling

Version 1.3 of the GLU specification can be found on the OpenGL website (PDF).

Resources:

229 questions
4
votes
1 answer

Trying to implement a mouse look "camera" in OpenGL/SFML

I've been using OpenGL with SFML 1.6 for some time now, and it has been a blast! With one exception: I can't seem to implement a camera class correctly. You see, I am trying to create a C++ class called "Camera". Here are my…
Eyal Kalderon
  • 247
  • 1
  • 4
  • 10
4
votes
2 answers

How can I increase distance (zfar/gluPerspective) where openGL stops drawing objects?

I am learning OpenGL and having a problem with gluPerspective. Here is the code I use in Init() // Calculate The Aspect Ratio Of The Window // The parameters are: // (view angle, aspect ration of the width to the height, // The closest distance to…
Oscar Foley
  • 6,817
  • 8
  • 57
  • 90
4
votes
1 answer

GLU.gluLookAt in Java OpenGL bindings seems to do nothing

I've already checked the other questions on this topic and their solutions haven't worked for me. I'm at a bit of a loss. I have the following functions in my GLEventListener implementation. public void init(GLAutoDrawable gl) { GL2 gl2 =…
Joel
  • 1,437
  • 2
  • 18
  • 28
4
votes
1 answer

GLUTesselator for realtime tesselation?

I'm trying to make a vector drawing application using OpenGL which will allow the user to see the result in real time. The way I have it set up is with an edge flag callback so the glu tesselator only outputs triangles which I then pass to a VBO.…
jmasterx
  • 52,639
  • 96
  • 311
  • 557
4
votes
1 answer

How to know boundaries of the frustum in case of gluPerspective()?

I have been trying to understand the the coordinates of the frustum gluPerspective() creates. In case of glOrtho we explicitly define the coordinate space. for example: glOrtho(left, right,bottom,top,nearVal, farVal); tells me what my x,y,z…
Bounty Collector
  • 615
  • 7
  • 19
4
votes
1 answer

how do i get rid of these compiler errors in glu.h?

trying to use this tutorial on 64-bit windows 8 with netbeans and cygwin 4.8.1. i get many errors like this: /usr/include/w32api/GL/glu.h:68:79: error: expected ‘)’ before ‘*’ token. on statements like this: void APIENTRY…
Ray Tayek
  • 9,841
  • 8
  • 50
  • 90
4
votes
1 answer

Force GLUtesselator to generate only GL_TRIANGLES?

It's pretty hard to render the data I generate, if I want to use one vertex array format only. I tried to provide GLU_TESS_EDGE_FLAG_DATA callback, but it made my program crash. (also tried without "_DATA" in end, same effect). How can I get it to…
Rookie
  • 4,064
  • 6
  • 54
  • 86
3
votes
1 answer

Converting touch screen coordinates to 3d Opengl world coordinates on iphone

I want to be able to click the touch screen and use the point touched as the starting coordinate for a ray to be used for picking. How do I convert the point returned from touching the screen into something I can use in the GL world coordinates? A…
Dave
  • 161
  • 1
  • 4
  • 18
3
votes
2 answers

OpenGL 3.1 lighting messed up, using phong shading

After many painful hours of attempting to figure out why my lighting is messed up I am still at a loss. The OpenGL normals are correct (backface culling does not cause any of my triangles to disappear) I calculate my normals in order to interpolate…
Mike Casa
  • 451
  • 7
  • 14
3
votes
1 answer

IllegalArgumentException from gluUnProject

I get this error message 08-30 19:20:17.774: ERROR/AndroidRuntime(4681): FATAL EXCEPTION: GLThread 9 08-30 19:20:17.774: ERROR/AndroidRuntime(4681): java.lang.IllegalArgumentException: length - offset < n 08-30 19:20:17.774:…
Jack
  • 2,625
  • 5
  • 33
  • 56
3
votes
2 answers

Is there a way to force GLUtessellator to use GL_TRIANGLES only?

I'm trying to use GLUtesselator to produce 3D extruded text in OpenGL. Here is the relevant code: private boolean createText(final String displayText) { final Font font = new Font("Times New Roman", Font.TRUETYPE_FONT, 3); final float depth…
Sonoman
  • 3,379
  • 9
  • 45
  • 61
3
votes
1 answer

opengl rendering half a cylinder

ok so im new to opengl and im creating a pool game using only the core opengl and glut i am writing in c++ i know how to draw a cylinder: { GLUquadric *quadric = gluNewQuadric(); glBegin; gluCylinder(quadric, 0.5f, 0.5f, 5.0f, 40,…
DK10
  • 168
  • 1
  • 5
  • 19
3
votes
2 answers

iPhone OpenGL : Using gluUnProject (port) and detecting clicking on an object

please help, this is my 4th question about this, I trying so hard I tried everything! All I want to do is detect clicking on a object(cube) in a 3D World (3D world created). This does it…
Burf2000
  • 5,001
  • 14
  • 58
  • 117
3
votes
3 answers

Are gluTess* functions deprecated?

I'm working on an OpenGL project, and I'm looking for a triangulation/tessellation functionality. I see a lot of references to the GLUtessellator and related gluTess* functions (e.g., here). I'm also using GLFW, which repeats over and over again in…
Neal Kruis
  • 2,055
  • 3
  • 26
  • 49
3
votes
1 answer

Decomposition of glFrustum in openGL

I'm trying to understand the projection matrix created with glFrustum() in OpenGL, and the transformations that bring it into the Normalized Device Coordinates of x=[-1,1], y=[-1,1], and z=[-1,1] and the series of 4x4 matrix multiplications that…
WoodMath
  • 521
  • 2
  • 8
  • 14
1
2
3
15 16