Support injecting custom native codecs from Java.
This CL extends our support for injecting native codecs such that downstream users can create Java codecs that are backed by custom native codecs. After this CL, the Java codec interfaces expose createNativeVideo{En,Decoder}() methods that may return a value representing a pointer to the backing native codec. Previously, a similar mechanism was used for the special case of non-public Java codecs extending from the internal WrappedNativeVideo{En,De}coder classes. Tested: AppRTCMobile on Pixel XL and Pixel 2. Bug: webrtc:9495 Change-Id: I079ff744afc7bf9873ff983e775c136a6667266d Reviewed-on: https://webrtc-review.googlesource.com/87264 Commit-Queue: Rasmus Brandt <brandtr@webrtc.org> Reviewed-by: Sami Kalliomäki <sakal@webrtc.org> Cr-Commit-Position: refs/heads/master@{#23883}
This commit is contained in:

committed by
Commit Bot

parent
c75a5e8dd6
commit
42a2fc9cba
@ -23,13 +23,13 @@ public class VideoEncoderFallback extends WrappedNativeVideoEncoder {
|
||||
}
|
||||
|
||||
@Override
|
||||
long createNativeEncoder() {
|
||||
public long createNativeVideoEncoder() {
|
||||
return nativeCreateEncoder(fallback, primary);
|
||||
}
|
||||
|
||||
@Override
|
||||
boolean isSoftwareEncoder() {
|
||||
return isWrappedSoftwareEncoder(primary);
|
||||
public boolean isHardwareEncoder() {
|
||||
return primary.isHardwareEncoder();
|
||||
}
|
||||
|
||||
private static native long nativeCreateEncoder(VideoEncoder fallback, VideoEncoder primary);
|
||||
|
Reference in New Issue
Block a user