#pragma section-numbers off #pragma camelcase off || DRAFT|| = SDL_HapticCondition = A structure that contains a template for a condition effect. <> == Data Fields == ||||||''Header''|| ||Uint16||'''type'''||one of the effects handled by this structure; see [[#type|Remarks]] for details|| ||[[SDL_HapticDirection]]||'''direction'''||direction of the effect - not used at the moment; see [[#direction|Remarks]] for details|| ||||||''Replay''|| ||Uint32||'''length'''||duration of the effect|| ||Uint16||'''delay'''||delay before starting the effect|| ||||||''Trigger''|| ||Uint16||'''button'''||button that triggers the effect|| ||Uint16||'''interval'''||how soon it can be triggered again after button|| ||||||''Condition''|| ||Uint16||'''right_sat'''||level when joystick is to the positive side; max 0xFFFF|| ||Uint16||'''left_sat'''||level when joystick is to the negative side; max 0xFFFF|| ||Sint16||'''right_coeff'''||how fast to increase the force towards the positive side|| ||Sint16||'''left_coeff'''||how fast to increase the force towards the negative side|| ||Uint16||'''deadband'''||size of the dead zone; max 0xFFFF: whole axis-range when 0-centered /* (units)? */ || ||Sint16||'''center'''||position of the dead zone|| /* <> */ == Code Examples == {{{#!highlight cpp You can add your code example here }}} == Remarks == <>'''type''' may be one of the following: ||SDL_HAPTIC_SPRING||effect based on axis position /* axes positions? */ || ||SDL_HAPTIC_DAMPER||effect based on axis velocity /* axes velocities? */ || ||SDL_HAPTIC_INERTIA||effect based on axis acceleration /* axes acceleration? */ || ||SDL_HAPTIC_FRICTION||effect based on axis movement /* axes movement/movements? */ || <> '''direction''' is (currently) handled by condition internals instead of a direction member. The condition effect specific members have three parameters. The first refers to the X axis, the second refers to the Y axis and the third refers to the Z axis. The right terms refer to the positive side of the axis and the left terms refer to the negative side of the axis. Please refer to the [[SDL_HapticDirection]] diagram for which side is positive and which is negative. == Related Structures == .[[SDL_HapticDirection]] == Related Functions == .[[SDL_HapticNewEffect]] ---- [[CategoryStruct]], [[CategoryForceFeedback]]