AppPlayerController<T> constructor

AppPlayerController<T>({
  1. StateChangeCallback<T>? changeCallback,
  2. T? userData,
})

Implementation

AppPlayerController({this.changeCallback, this.userData}) {
  // _subscription = _eventStream.listen(progressListener);
  appPlayerSetScale = playerLib
      .lookup<
          NativeFunction<
              Void Function(Int64, Double, Double, Uint8, Uint8, Int8,
                  Double)>>("app_player_set_scale")
      .asFunction();
  appPlayerSetScaleCenter = playerLib
      .lookup<
          NativeFunction<
              Void Function(Int64, Double, Double, Uint8, Uint8, Int8, Double,
                  Double, Double)>>("app_player_set_scale_center")
      .asFunction();

  appPlayerSetChannel = playerLib
      .lookup<NativeFunction<Void Function(Int64, Int32, Int32)>>(
          "app_player_set_channel")
      .asFunction();
  AppDart().addListener(progressListener);
}