pullSample method

Future<LSLSample<T>> pullSample({
  1. double timeout = 0.0,
})

Pulls a sample from the inlet.

Parameters:

  • timeout: Maximum wait time in seconds (0.0 = non-blocking)

Execution:

  • Isolated mode: Async message passing to worker isolate
  • Direct mode: Immediate FFI call wrapped in Future

Returns: A LSLSample containing the data, timestamp, and error code.

See also: pullSampleSync for zero-overhead direct calls

Implementation

Future<LSLSample<T>> pullSample({double timeout = 0.0}) => _useIsolates
    ? _pullSampleIsolated(timeout)
    : Future.value(_pullSampleDirect(timeout));