Skip to main content

NSDataFromGCGamepadSnapShotDataV100

Function NSDataFromGCGamepadSnapShotDataV100 

Source
pub unsafe extern "C-unwind" fn NSDataFromGCGamepadSnapShotDataV100(
    snapshot_data: *mut GCGamepadSnapShotDataV100,
) -> Option<Retained<NSData>>
๐Ÿ‘ŽDeprecated:

Use GCExtendedGamepad instead

Available on crate feature GCGamepadSnapshot only.
Expand description

Creates an NSData object from a v100 snapshot. If the version and size is not set in the snapshot the data will automatically have version 0x100 and sizeof(GCGamepadSnapShotDataV100) set as the values implicitly.

Returns: nil if the snapshot is NULL, otherwise an NSData instance compatible with GCGamepadSnapshot.snapshotData

ยงSafety

snapshot_data must be a valid pointer or null.