[HOpenGL] GL utilities, toolkits, and questions..

Sven Panne Sven.Panne@informatik.uni-muenchen.de
Sun, 21 Jul 2002 20:10:05 +0200


C.Reinke wrote:
 > * oh, and why is the default stroke font size so huge? I have
 > * to scale it down by a factor of 100, it seems, to get into
 > * natural proportions..

Well, I guess the size itself is not a bug, but a feature of GLUT. But
there is an inconsistency: The spec for glutStrokeCharacter

    http://www.opengl.org/developers/documentation/glut/spec3/node78.html

talks about "units" (of magnitude 100, as you've already noticed),
while the spec for glutStrokeWidth

    http://www.opengl.org/developers/documentation/glut/spec3/node79.html

talks about "pixels". The latter is probably a cut-n-paste bug from
the spec for glutBitmapWidth.

 > [...] Binding to one of those would be of general interest (just as
 > fonts..) and might make the file manager problem easier:
 >
 >   http://www.sjbaker.org/steve/omniv/mui_pui_glui.html
 >   http://www.cs.unc.edu/~rademach/glui/

The latter is already on my (rather long :-} TODO list, but things are
complicated by the fact that no Linux distribution or any other OS I
know of comes with a pre-installed GLUI. Requiring a potential UI
programmer to download and install it first would vastly lower the
acceptance of the binding. Consequently the way to go is to ship the
Haskell binding with the library itself. This is not such a big deal
as it might sound, the object files on Linux are about 260kB,
i.e. almost nothing compared to the probable size of the Haskell part.

 > [...] If we believe the marketing hype, ghc-5.04.1 will have what it
 > takes,

The just released GHC 5.04 has spec-conforming FFI support, as does
the CVS version of Hugs. NHC98 almost has it IIRC, but I'm not sure
about this. Simply ask Malcolm about this.

 > and the FFI spec is stable (they say..).

Apart from some esoteric features and occasional clarifications the
spec is indeed very stable.

Cheers,
    S.