pfuInput

New Message Reply Date view Thread view Subject view Author view

John C Vanderburgh (jvanderb++at++afit.af.mil)
Mon, 24 Oct 1994 13:23:09 -0400


I'm trying to use the Performer utilities to process GL-input.
Using the processing loop below in my APP thread, I can
handle "normal" keyboard events as well as the
function keys with no problems. However, I would like to
use the keypad keys as input and it doesn't look like the pfu* calls
support this. (e.g. PAD4 for left-arrow, PAD6 for right-arrow, etc.)
Is this true?

   .
   .
   .
  pfuEvent *User_Input;
  int Device;
  int Value;

  //----------------------
  // Process user-input:
  //----------------------
  pfuGetEvents (User_Input);

  for (i = 0; i < User_Input->numDevs; i++)
  {
    Device = User_Input->devQ[i];
    Value = User_Input->devVal[i];
    switch (Device)
    {
       case PFUDEV_F1KEY:
         printf ("F1KEY\n");
         if (Value);
            Do_Something();
         break;
       case PFUDEV_F2KEY:
         printf ("F2KEY\n");
         break;
        .
        .
        .
       default:
         break;
    }
  }

Thanks,

John Vanderburgh
AF Institute of Technology
Wright-Patterson AFB, OH


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:50:36 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.