Skip to main content

NSDataFromGCMicroGamepadSnapShotDataV100

Function NSDataFromGCMicroGamepadSnapShotDataV100 

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

Use the -[GCController controllerWithMicroGamepad] method instead

Available on crate feature GCMicroGamepadSnapshot 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(GCMicroGamepadSnapShotDataV100) 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.