Mark toI420 as Nullable
Bug: webrtc:12877 Change-Id: I1b52b46bc9208d20f1887bdc87497e4eb227ecaf Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/232330 Reviewed-by: Niels Moller <nisse@webrtc.org> Reviewed-by: Xavier Lepaul <xalep@webrtc.org> Reviewed-by: Henrik Boström <hbos@webrtc.org> Commit-Queue: Fabian Bergmark <fabianbergmark@google.com> Cr-Commit-Position: refs/heads/main@{#35050}
This commit is contained in:
parent
7b35b44b52
commit
f7a7698aaf
@ -69,6 +69,8 @@ class RTC_EXPORT VideoFrameBuffer : public rtc::RefCountInterface {
|
||||
// in another format, a conversion will take place. All implementations must
|
||||
// provide a fallback to I420 for compatibility with e.g. the internal WebRTC
|
||||
// software encoders.
|
||||
// Conversion may fail, for example if reading the pixel data from a texture
|
||||
// fails. If the conversion fails, nullptr is returned.
|
||||
virtual rtc::scoped_refptr<I420BufferInterface> ToI420() = 0;
|
||||
|
||||
// GetI420() methods should return I420 buffer if conversion is trivial, i.e
|
||||
|
||||
@ -13,6 +13,7 @@ package org.webrtc;
|
||||
import android.graphics.Matrix;
|
||||
import android.opengl.GLES11Ext;
|
||||
import android.opengl.GLES20;
|
||||
import androidx.annotation.Nullable;
|
||||
import java.nio.ByteBuffer;
|
||||
|
||||
/**
|
||||
@ -53,8 +54,11 @@ public class VideoFrame implements RefCounted {
|
||||
* Returns a memory-backed frame in I420 format. If the pixel data is in another format, a
|
||||
* conversion will take place. All implementations must provide a fallback to I420 for
|
||||
* compatibility with e.g. the internal WebRTC software encoders.
|
||||
*
|
||||
* <p> Conversion may fail, for example if reading the pixel data from a texture fails. If the
|
||||
* conversion fails, null is returned.
|
||||
*/
|
||||
@CalledByNative("Buffer") I420Buffer toI420();
|
||||
@Nullable @CalledByNative("Buffer") I420Buffer toI420();
|
||||
|
||||
@Override @CalledByNative("Buffer") void retain();
|
||||
@Override @CalledByNative("Buffer") void release();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user