Skip to content

libvlc_media: add a way to save/restore options

See vlc-android#2572

The Android ports (and all others ports) are not keeping the original libvlc_media while browsing or playing. Mainly for memory optimization: you don't want to hold a Media Java class, holding, the jni wrapper, holding the libvlc_media when parsing a big folder.

The main issue with dropping the libvlc_media is that VLC options are not saved.

I propose to add 2 functions:

  • libvlc_media_serialize_options()
  • libvlc_media_unserialize_options()

The VLC ports will only have to keep the serialized data of VLC options and will be able to restore them before playing or before saving a media in the medialibrary.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information