Android Player Intents

From VideoLAN Wiki
Revision as of 16:03, 1 June 2015 by Dekans (talk | contribs) (Page creation, intents definition)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Since version 1.4.1, Android VLC application returns an intent when closing.

Here is the description of this intent:

Intent action: "org.videolan.vlc.player.result"

Result code:

Result Value (int) Description
RESULT_OK -1 Video finished or user ended playback
RESULT_CANCELED 0 No compatible cpu, incorrect VLC abi variant installed
RESULT_CONNECTION_FAILED 2 Connection failed to audio service
RESULT_PLAYBACK_ERROR 3 VLC is not able to play this file, it could be incorrect path/uri, not supported codec or broken file
RESULT_HARDWARE_ACCELERATION_ERROR 4 Error with hardware acceleration, user refused to switch to software decoding
RESULT_VIDEO_TRACK_LOST 5 VLC continues playback, but for audio track only. (Audio file detected or user chose to)

Data: media Uri

Extras:

  • "extra_position": position in the media, in ms (type long)
  • "extra_duration": media duration

You can check the source http://git.videolan.org/?p=vlc-ports/android.git;a=blob;f=vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java;hb=HEAD