From 908e77bd00593a8bc5480fb1a07368b7c27778f3 Mon Sep 17 00:00:00 2001 From: Alex Glaznev Date: Wed, 22 Apr 2015 09:25:34 -0700 Subject: [PATCH] Allow Java code to detect if VP8 and H.264 HW decoding is supported. R=wzh@webrtc.org Review URL: https://webrtc-codereview.appspot.com/43269004 Cr-Commit-Position: refs/heads/master@{#9058} --- .../webrtc/java/src/org/webrtc/MediaCodecVideoDecoder.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/talk/app/webrtc/java/src/org/webrtc/MediaCodecVideoDecoder.java b/talk/app/webrtc/java/src/org/webrtc/MediaCodecVideoDecoder.java index c62465a0c7..5c9cd26181 100644 --- a/talk/app/webrtc/java/src/org/webrtc/MediaCodecVideoDecoder.java +++ b/talk/app/webrtc/java/src/org/webrtc/MediaCodecVideoDecoder.java @@ -50,7 +50,7 @@ import java.nio.ByteBuffer; // This class is an implementation detail of the Java PeerConnection API. // MediaCodec is thread-hostile so this class must be operated on a single // thread. -class MediaCodecVideoDecoder { +public class MediaCodecVideoDecoder { // This class is constructed, operated, and destroyed by its C++ incarnation, // so the class and its methods have non-public visibility. The API this // class exposes aims to mimic the webrtc::VideoDecoder API as closely as @@ -182,11 +182,11 @@ class MediaCodecVideoDecoder { return (CURRENT_SDK_VERSION >= EGL14_SDK_VERSION); } - private static boolean isVp8HwSupported() { + public static boolean isVp8HwSupported() { return findDecoder(VP8_MIME_TYPE, supportedVp8HwCodecPrefixes) != null; } - private static boolean isH264HwSupported() { + public static boolean isH264HwSupported() { return findDecoder(H264_MIME_TYPE, supportedH264HwCodecPrefixes) != null; }