ODK support for AXIS_L2 and AXIS_R2

I'm trying to use only the OuyaController class in the ODK to map controller interactions.  This has worked out ok except in the case of AXIS_L2 and AXIS_R2.  These are arriving as events to dispatchGenericMotionEvent, but do not get processed by OuyaController.  Peeking into the source for OuyaController (at least the best I could, using DJ... is it up on git somewhere?) I found that the map (ouyaAxisMap I believe?) that converts android axes to ouya only includes the X and Y axis of the thumbsticks - it is missing the left and right triggers.  In the meantime, I know I can intercept and store those events outside the ODK, but can we get that fixed for the next ODK release?  (If I am wrong about the above, please correct me. :) )

Comments

  • RenanseRenanse Posts: 4Member
    It seems also that BUTTON_L1 L2 R1 and R2 are missing from the ouyaButtonMap.  Am I missing something, or are most people rolling their own controller code and ignoring OuyaController?
  • newmessagenewmessage Posts: 42Member
    Well, if you meant control handler for Joystick on OUYA. Perhaps these line will help you :

    public boolean onGenericMotionEvent(final MotionEvent event) {
    float LS_X = event.getAxisValue(OuyaController.AXIS_LS_X); 
    float LS_Y = event.getAxisValue(OuyaController.AXIS_LS_Y); 
    ..
    ..
    }
    many thanks
    -sb

Sign In or Register to comment.