From: Phlip Date: 2001-11-30T00:14:31+09:00 Subject: [ruby-talk:26908] Re: FXGLViewer - rotate a primitive? Phlip wrote: > void FXGLCylinder::drawshape(FXGLViewer*){ .... > glPushMatrix(); > glRotatef(-90,1,0,0); gluCylinder(quad,radius,radius,height,FXGLCYLINDER_SLICES_NUMBER,FXGLCYLIND ER_STACKS_NUMBER); .... > } > > Observe that we push the matrix, add a hard-coded rotation to the current > matrix, paint the cylinder, and pop the matrix. The library therefor > disables end-programmer control over the orientation of the cylinders > available. > > Also observe this is on the FOX side, not the FXRuby side. One Jeroen from FOX-land states: > The "shape" classes are really just examples. I expect people who're more > serious to derive from FXGLObject. Then the issue would be A> FXRuby took them seriously, B> I don't want to ship a FOX patch, or any C++ source, with my project, and C> I don't know how to derive from FXGLObject within Ruby yet. But the last option would appear to be the best. Lyle - can I inherit from FXGLObject thru Ruby? I'm asking you first to avoid trying and getting all tangled up. Recall that "inherit" imlies I can override the draw() methods. -- Phlip http://www.greencheese.org/HatTrick