Loading media/java/android/media/MediaCodec.java +47 −1 Original line number Diff line number Diff line Loading @@ -3188,9 +3188,55 @@ final public class MediaCodec { /** * Returns Analytics/Metrics data about the current content being * * @return a Bundle containint the set of attributes and values available * @return a Bundle containing the set of attributes and values available * for the media being handled by this instance of MediaCodec * * <table style="width: 0%"> * <thead> * <tr> * <th>Key</th> * <th>Type</th> * <th>Description</th> * </tr> * </thead> * <tbody> * <tr> * <td>{@code "codec"}</td> * <td>String</td> * <td>Identifies the particular codec in use</td> * </tr><tr> * <td>{@code "mime"}</td> * <td>String</td> * <td>Mime type of the media being encoded/decoded</td> * </tr><tr> * <td>{@code "mode"}</td> * <td>String</td> * <td>"Audio" or "Video"</td> * </tr><tr> * <td>{@code "secure"}</td> * <td>Integer</td> * <td>Indicates whether the code is operating on secure content and * may also use capabilities in android.media.MediaCrypto</td> * </tr><tr> * <td>{@code "height"}</td> * <td>Integer</td> * <td>Height (pixels); valid only when mode=video</td> * </tr><tr> * <td>{@code "width"}</td> * <td>Integer</td> * <td>Width (pixels); valid only when mode=video</td> * </tr><tr> * <td>{@code "rotation"}</td> * <td>Integer</td> * <td>rotation (degrees) to orient the video onto the target surface; * valid only when mode=video. Note there may be additional * rotations applied when the surface is mapped to the screen.</td> * </tr> * </tbody> * </table> * * Additional fields specific to individual codecs will also appear in * the return value. */ public native Bundle getMetrics(); Loading media/java/android/media/MediaExtractor.java +27 −0 Original line number Diff line number Diff line Loading @@ -656,6 +656,33 @@ final public class MediaExtractor { * @return the set of keys and values available for the media being * handled by this instance of MediaExtractor * * <table style="width: 0%"> * <thead> * <tr> * <th>Key</th> * <th>Type</th> * <th>Description</th> * </tr> * </thead> * <tbody> * <tr> * <td>{@code "fmt"}</td> * <td>String</td> * <td>The container format (which determines the handler)</td> * </tr><tr> * <td>{@code "mime"}</td> * <td>String</td> * <td>Mime type of the container.</td> * </tr><tr> * <td>{@code "ntrk"}</td> * <td>Integer</td> * <td>Number of tracks in the container</td> * </tr> * </tbody> * </table> * * Additional fields specific to individual codecs will also appear in * the return value. */ public native Bundle getMetrics(); Loading media/java/android/media/MediaPlayer.java +58 −0 Original line number Diff line number Diff line Loading @@ -1498,6 +1498,64 @@ public class MediaPlayer extends PlayerBase * * @return the a map of attributes and values available for this video * player or null if no metrics are available. * * <table style="width: 0%"> * <thead> * <tr> * <th>Key</th> * <th>Type</th> * <th>Description</th> * </tr> * </thead> * <tbody> * <tr> * <td>{@code "video/codec"}</td> * <td>String</td> * <td>Identifies the video codec in use</td> * </tr><tr> * <td>{@code "video/mime"}</td> * <td>String</td> * <td>Mime type of the video being encoded/decoded</td> * </tr><tr> * <td>{@code "audio/codec"}</td> * <td>String</td> * <td>Identifies the audio codec in use</td> * </tr><tr> * <td>{@code "audio/mime"}</td> * <td>String</td> * <td>Mime type of the audio being encoded/decoded</td> * </tr><tr> * <td>{@code "ht"}</td> * <td>Integer</td> * <td>Height (pixels); valid only when mode=video</td> * </tr><tr> * <td>{@code "wid"}</td> * <td>Integer</td> * <td>Width (pixels); valid only when mode=video</td> * </tr><tr> * <td>{@code "frame"}</td> * <td>Integer</td> * <td>Number of decoded video frames sent to the display</td> * </tr><tr> * <td>{@code "dropped"}</td> * <td>Integer</td> * <td>Number of decoded video frames that were not sent to display. * These frames were dropped by the player.</td> * </tr><tr> * <td>{@code "durationMs"}</td> * <td>Integer</td> * <td>The length of the media being played (in ms), e.g. "This video lasts for 30000 milliseconds". </td> * </tr><tr> * <td>{@code "playingMs"}</td> * <td>Integer</td> * <td>The time the media has been played (in ms). If you watch a * 30 second twice through, this will report 60000 ms.</td> * </tr> * </tbody> * </table> * * Additional fields specific to individual codecs will also appear in * the return value. */ public native Bundle getMetrics(); Loading Loading
media/java/android/media/MediaCodec.java +47 −1 Original line number Diff line number Diff line Loading @@ -3188,9 +3188,55 @@ final public class MediaCodec { /** * Returns Analytics/Metrics data about the current content being * * @return a Bundle containint the set of attributes and values available * @return a Bundle containing the set of attributes and values available * for the media being handled by this instance of MediaCodec * * <table style="width: 0%"> * <thead> * <tr> * <th>Key</th> * <th>Type</th> * <th>Description</th> * </tr> * </thead> * <tbody> * <tr> * <td>{@code "codec"}</td> * <td>String</td> * <td>Identifies the particular codec in use</td> * </tr><tr> * <td>{@code "mime"}</td> * <td>String</td> * <td>Mime type of the media being encoded/decoded</td> * </tr><tr> * <td>{@code "mode"}</td> * <td>String</td> * <td>"Audio" or "Video"</td> * </tr><tr> * <td>{@code "secure"}</td> * <td>Integer</td> * <td>Indicates whether the code is operating on secure content and * may also use capabilities in android.media.MediaCrypto</td> * </tr><tr> * <td>{@code "height"}</td> * <td>Integer</td> * <td>Height (pixels); valid only when mode=video</td> * </tr><tr> * <td>{@code "width"}</td> * <td>Integer</td> * <td>Width (pixels); valid only when mode=video</td> * </tr><tr> * <td>{@code "rotation"}</td> * <td>Integer</td> * <td>rotation (degrees) to orient the video onto the target surface; * valid only when mode=video. Note there may be additional * rotations applied when the surface is mapped to the screen.</td> * </tr> * </tbody> * </table> * * Additional fields specific to individual codecs will also appear in * the return value. */ public native Bundle getMetrics(); Loading
media/java/android/media/MediaExtractor.java +27 −0 Original line number Diff line number Diff line Loading @@ -656,6 +656,33 @@ final public class MediaExtractor { * @return the set of keys and values available for the media being * handled by this instance of MediaExtractor * * <table style="width: 0%"> * <thead> * <tr> * <th>Key</th> * <th>Type</th> * <th>Description</th> * </tr> * </thead> * <tbody> * <tr> * <td>{@code "fmt"}</td> * <td>String</td> * <td>The container format (which determines the handler)</td> * </tr><tr> * <td>{@code "mime"}</td> * <td>String</td> * <td>Mime type of the container.</td> * </tr><tr> * <td>{@code "ntrk"}</td> * <td>Integer</td> * <td>Number of tracks in the container</td> * </tr> * </tbody> * </table> * * Additional fields specific to individual codecs will also appear in * the return value. */ public native Bundle getMetrics(); Loading
media/java/android/media/MediaPlayer.java +58 −0 Original line number Diff line number Diff line Loading @@ -1498,6 +1498,64 @@ public class MediaPlayer extends PlayerBase * * @return the a map of attributes and values available for this video * player or null if no metrics are available. * * <table style="width: 0%"> * <thead> * <tr> * <th>Key</th> * <th>Type</th> * <th>Description</th> * </tr> * </thead> * <tbody> * <tr> * <td>{@code "video/codec"}</td> * <td>String</td> * <td>Identifies the video codec in use</td> * </tr><tr> * <td>{@code "video/mime"}</td> * <td>String</td> * <td>Mime type of the video being encoded/decoded</td> * </tr><tr> * <td>{@code "audio/codec"}</td> * <td>String</td> * <td>Identifies the audio codec in use</td> * </tr><tr> * <td>{@code "audio/mime"}</td> * <td>String</td> * <td>Mime type of the audio being encoded/decoded</td> * </tr><tr> * <td>{@code "ht"}</td> * <td>Integer</td> * <td>Height (pixels); valid only when mode=video</td> * </tr><tr> * <td>{@code "wid"}</td> * <td>Integer</td> * <td>Width (pixels); valid only when mode=video</td> * </tr><tr> * <td>{@code "frame"}</td> * <td>Integer</td> * <td>Number of decoded video frames sent to the display</td> * </tr><tr> * <td>{@code "dropped"}</td> * <td>Integer</td> * <td>Number of decoded video frames that were not sent to display. * These frames were dropped by the player.</td> * </tr><tr> * <td>{@code "durationMs"}</td> * <td>Integer</td> * <td>The length of the media being played (in ms), e.g. "This video lasts for 30000 milliseconds". </td> * </tr><tr> * <td>{@code "playingMs"}</td> * <td>Integer</td> * <td>The time the media has been played (in ms). If you watch a * 30 second twice through, this will report 60000 ms.</td> * </tr> * </tbody> * </table> * * Additional fields specific to individual codecs will also appear in * the return value. */ public native Bundle getMetrics(); Loading