View Full Version : filled quadric problem
08-01-2010, 04:40 PM
I'm trying to draw a filled cylinder, but it doesn't seem to be working. Here's what I have:
GLUquadricObj *quad = gluNewQuadric();
then, a little bit later,
gluCylinder(quad, 1, 1, 2, 10, 10);
It's drawing a cylinder, but it's not filled in. Is there something I'm missing here?
08-03-2010, 08:42 PM
Does anyone have any ideas? I'm considering just drawing circles, at this point, to cap the cylinders, but I'd rather just use GLU_FILL.
08-03-2010, 10:34 PM
I did a quick example which worked and I find it weird yours that it doesn't fill. By default the quadric should be GLU_FILL so there should be no need to call it.
did you make a glPolygonMode(GL_FRONT_AND_BACK, GL_LINE) call if not you could try and use glPolygonMode(GL_FRONT_AND_BACK, GL_FILL)
try commenting out gluQuadricDrawStyle(quad, GLU_FILL) and see if it works.
08-04-2010, 01:36 AM
I tried commenting it out, but that didn't make a difference. I also tried adding in the glPolygonMode call, but that didn't work either. I really have no idea what's going on...
I put gluDisks on the top of the cylinders, which at least makes it look right, but it's still very strange that the fill isn't working.
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.