Skip to content

Monoscopic 360° video support

Pre-release
Pre-release
Compare
Choose a tag to compare
@defagos defagos released this 09 Jan 12:28
· 215 commits to main since this release
0.9.0
c7285ee

This release adds support for monoscopic 360° video and further improves Picture in Picture behavior.

360° video support

  • Add support for monoscopic 360° videos to VideoView. Use the new VideoView/viewport(_:) modifier to enable 360° display and choose and set an orientation in space.
  • Orientation in space requires a quaternion. Two SCNQuaternionRotate(_:_:_:) and SCNQuaternionWithAngleAndAxis(_:_:_:_:) functions are provided to help build relevant quaternions, most notably for controlling the viewport through touch events. On iOS the SCNQuaternionForAttitude(_:) function makes it possible to bridge quaternions delivered by CoreMotion with SceneKit quaternions required used by Pillarbox.

Picture in Picture improvements

  • Improve Picture in Picture integration and overall behavior.
  • Introduce PictureInPicturePersistable that lets app locally respond to Picture in Picture life cycle events if needed.

Improvements

  • Add playback speed menu to the tvOS system player view layout.
  • Add AVPlayerItem/seek(_:) method to set a player item to start at a given time.
  • Add Player/isRunning property.
  • Improve documentation and tutorials.

Demo improvements

  • Greatly improve tvOS navigation user experience.
  • Improve Picture in Picture integration in demo examples.
  • Display Pillarbox web demo in a web browser. This feature is not intended to be easily accessible and requires a dedicated opt-in to be enabled in app system settings first.

Fixes

  • Update Swift package manifest version to 5.9.

Breaking changes

  • Prefix all frameworks with Pillarbox to avoid potential naming conflicts with packages providing frameworks having the same name.
  • Update in-app Picture in Picture in-app integration API. The View/enabledForInAppPictureInPictureWithCleanup(perform:) method has been replaced with the View/enabledForInAppPictureInPicture(persisting:) method which, instead of executing a closure to cleanup resources associated with a player (potentially after Picture in Picture ends), ensures a PictureInPicturePersistable object is kept alive during Picture in Picture playback. The PictureInPicturePersistable protocol can be optionally used to locally respond to Picture in Picture lifef cycle events as well.
  • Update VideoView and SystemVideoView APIs so that optional behaviors (gravity, Picture in Picture support) are configured with modifiers instead of parameters.

What's Changed

Full Changelog: 0.8.0...0.9.0