Package apple.gamecontroller.protocol
Interface GCRelativeInput
-
public interface GCRelativeInputAn object conforming to \c GCRelativeInput represents an input that reports its change in position along an axis (delta) since the previous event. Relative inputs have no fixed origin from which a coordinate syatem can be defined. API-Since: 16.0
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceGCRelativeInput.Block_deltaDidChangeHandler_retstatic interfaceGCRelativeInput.Block_setDeltaDidChangeHandler
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description floatdelta()The last reported delta for the input.@Nullable GCRelativeInput.Block_deltaDidChangeHandler_retdeltaDidChangeHandler()Set this block to be notified when the delta of the input changes.booleanisAnalog()Check if the input can support more than just digital values.doublelastDeltaLatency()The interval (in seconds) between the timestamp of the last change and the current time.doublelastDeltaTimestamp()The timestamp of the last change.voidsetDeltaDidChangeHandler(@Nullable GCRelativeInput.Block_setDeltaDidChangeHandler value)Set this block to be notified when the delta of the input changes.@NotNull NSSet<?>sources()An object describing the physical action(s) the user performs to manipulate this input.
-
-
-
Method Detail
-
delta
float delta()
The last reported delta for the input.
-
deltaDidChangeHandler
@Nullable @Nullable GCRelativeInput.Block_deltaDidChangeHandler_ret deltaDidChangeHandler()
Set this block to be notified when the delta of the input changes.- Parameters:
delta- The amount that the input has changed since the last time \c deltaDidChangeHandler fired.
-
isAnalog
boolean isAnalog()
Check if the input can support more than just digital values. Defaults to \c YES for most relative inputs.
-
lastDeltaLatency
double lastDeltaLatency()
The interval (in seconds) between the timestamp of the last change and the current time. This should be treated as a lower bound of the event latency. It may not include (wired or wireless) transmission latency, or latency accrued on the device before the event was transmitted to the host.
-
lastDeltaTimestamp
double lastDeltaTimestamp()
The timestamp of the last change. This time interval is not relative to any specific point in time. You can subtract a previous timestamp from the current timestamp to determine the time (in seconds) between changes to the value.
-
setDeltaDidChangeHandler
void setDeltaDidChangeHandler(@Nullable @Nullable GCRelativeInput.Block_setDeltaDidChangeHandler value)Set this block to be notified when the delta of the input changes.- Parameters:
delta- The amount that the input has changed since the last time \c deltaDidChangeHandler fired.
-
sources
@NotNull @NotNull NSSet<?> sources()
An object describing the physical action(s) the user performs to manipulate this input. API-Since: 17.0
-
-