Tabnine Logo
Media.getDuration
Code IndexAdd Tabnine to your IDE (free)

How to use
getDuration
method
in
org.videolan.libvlc.Media

Best Java code snippets using org.videolan.libvlc.Media.getDuration (Showing top 3 results out of 315)

origin: tomahawk-player/tomahawk-android

parseCounter++;
if ((media.getDuration() == 0 || (media.getTrackCount() != 0
    && TextUtils.isEmpty(media.getTrack(0).codec)))
    && fileURI.endsWith(".mod")) {
origin: tomahawk-player/tomahawk-android

private void init(Media media) {
  mType = TYPE_ALL;
  if (media != null) {
    if (media.isParsed()) {
      mLength = media.getDuration();
      for (int i = 0; i < media.getTrackCount(); ++i) {
        final Media.Track track = media.getTrack(i);
        if (track == null)
          continue;
        if (track.type == Media.Track.Type.Video) {
          final Media.VideoTrack videoTrack = (VideoTrack) track;
          mType = TYPE_VIDEO;
          mWidth = videoTrack.width;
          mHeight = videoTrack.height;
        } else if (mType == TYPE_ALL && track.type == Media.Track.Type.Audio){
          mType = TYPE_AUDIO;
        }
      }
    }
    updateMeta(media);
    if (mType == TYPE_ALL && media.getType() == Media.Type.Directory)
      mType = TYPE_DIR;
  }
  defineType();
}
origin: ymcao/YaPlayer

mLength = media.getDuration();
org.videolan.libvlcMediagetDuration

Javadoc

Get the duration of the media.

Popular methods of Media

  • <init>
  • addOption
    Add an option to this Media. This Media should be alive (not released).
  • release
  • setHWDecoderEnabled
    Add or remove hw acceleration media options
  • parse
    Parse the media synchronously with a flag. This Media should be alive (not released).
  • parseAsync
    Parse the media asynchronously with a flag. This Media should be alive (not released). To track when
  • getMediaCodecModule
  • getTrack
    Get a Track The Track can be casted to AudioTrack, VideoTrack or SubtitleTrack in function of the Tr
  • getTrackCount
    Get the Track count.
  • getTracks
  • isReleased
  • nativeAddOption
  • isReleased,
  • nativeAddOption,
  • nativeAddSlave,
  • nativeClearSlaves,
  • nativeGetDuration,
  • nativeGetMeta,
  • nativeGetMrl,
  • nativeGetSlaves,
  • nativeGetState,
  • nativeGetTracks

Popular in Java

  • Finding current android device location
  • scheduleAtFixedRate (ScheduledExecutorService)
  • notifyDataSetChanged (ArrayAdapter)
  • findViewById (Activity)
  • File (java.io)
    An "abstract" representation of a file system entity identified by a pathname. The pathname may be a
  • BitSet (java.util)
    The BitSet class implements abit array [http://en.wikipedia.org/wiki/Bit_array]. Each element is eit
  • Stack (java.util)
    Stack is a Last-In/First-Out(LIFO) data structure which represents a stack of objects. It enables u
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • Table (org.hibernate.mapping)
    A relational table
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now