Hello all -
I’m having an issue where I’m getting reversed ascii codes for the BS and DEL keys. I have a simple command-line-interface built into my GLUT window where I frequently use the BS & DEL to edit the typed commands.
To help debug the problem, I am displaying the ascii code in my “keys” function that is registered with GLUT:
glutKeyboardFunc( keys );
I have tested this on 5 builds and the only problems (to my understanding) are with the Apple Frameworks for GLUT and OpenGL.
The 5 builds are:
- Codewarrior Mac “Carbon” using a downloaded GLUT SDK library
- Codewarrior Mac “Mach-O” using the Frameworks
- Scons (Mac) linking in the frameworks
- XCode, also linking in the frameworks
- also, a Linux(mesa?) build using SCons
CW Carbon & Linux yield the expected resulta:
BS → int 8, hex 8
DEL → int 127, hex 7f
However, on the builds using the Frameworks (CW Mach, SCons, XCode), the results are reversed
BS → int 127, hex 7f
DEL → int 8, hex 8
I work in an environment where multi-platform-compatible code is required (Mac, Windows, SGI, Sun, Linux, etc), thus I need to understand what’s happening, so I can put in any “fixes” if there is a problem using the frameworks. I use a G5(2x2.0) with an upgraded ATI graphics card.
I have not tested this on any other platforms as of yet. So, any comments/thoughts would be much appreciated…
Thanks,
ATG