MediaStore

MediaStore peripheral interface for drones.

Aggregates information on all medias stored on a device, allowing the application to browse such media, to to download them locally on the device, ot to delete them physically from the drone where they are stored.

This peripheral can be obtained from a drone using: drone.getPeripheral(MediaStore::class.java)

See also

Drone.getPeripheral

Types

Link copied to clipboard

Media download type.

Link copied to clipboard

Indexing state of the media store.

Properties

Link copied to clipboard

Current indexing state.

Link copied to clipboard
@get:IntRange(from = 0)
abstract val photoMediaCount: Int

Total photo media count.

Link copied to clipboard
@get:IntRange(from = 0)
abstract val photoResourceCount: Int

Total photo resources count.

Link copied to clipboard
@get:IntRange(from = 0)
abstract val videoMediaCount: Int

Yotal video media count.

Link copied to clipboard
@get:IntRange(from = 0)
abstract val videoResourceCount: Int

Total video resource count.

Functions

Link copied to clipboard

Creates a new media list for browsing medias.

Link copied to clipboard

Deletes resources from the drone's storage.

Link copied to clipboard

Downloads media resources of a given type from the drone's storage.

Link copied to clipboard
abstract fun fetchThumbnailOf(media: MediaItem, observer: Ref.Observer<Bitmap>): Ref<Bitmap>

Retrieves a media thumbnail.

abstract fun fetchThumbnailOf(resource: MediaItem.Resource, observer: Ref.Observer<Bitmap>): Ref<Bitmap>

Retrieves a media resource thumbnail.

Link copied to clipboard
abstract fun upload(resources: Collection<File>, target: MediaItem, observer: Ref.Observer<ResourceUploader>): Ref<ResourceUploader>

Upload media resources to the drone's storage.

Link copied to clipboard

Wipes all media from the drone's storage.