Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(397)

Unified Diff: webrtc/sdk/android/src/jni/native_handle_impl.h

Issue 2991633002: Implement AndroidVideoBuffer::ToI420. (Closed)
Patch Set: Cache values. Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/sdk/android/src/jni/native_handle_impl.h
diff --git a/webrtc/sdk/android/src/jni/native_handle_impl.h b/webrtc/sdk/android/src/jni/native_handle_impl.h
index cd9ad9cf016fb9d58df1f4dbba97a10e79f20e54..670e735c8476725e87f2043af0fa467fb8a9951e 100644
--- a/webrtc/sdk/android/src/jni/native_handle_impl.h
+++ b/webrtc/sdk/android/src/jni/native_handle_impl.h
@@ -104,7 +104,6 @@ class AndroidTextureBuffer : public AndroidVideoFrameBuffer {
class AndroidVideoBuffer : public AndroidVideoFrameBuffer {
public:
AndroidVideoBuffer(JNIEnv* jni,
- jmethodID j_retain_id,
jmethodID j_release_id,
int width,
int height,
@@ -116,11 +115,11 @@ class AndroidVideoBuffer : public AndroidVideoFrameBuffer {
// Returns an instance of VideoRenderer.I420Frame (deprecated)
jobject ToJavaI420Frame(JNIEnv* jni, int rotation);
- private:
Type type() const override;
int width() const override;
int height() const override;
+ private:
rtc::scoped_refptr<webrtc::I420BufferInterface> ToI420() override;
AndroidType android_type() override { return AndroidType::kJavaBuffer; }
@@ -128,8 +127,7 @@ class AndroidVideoBuffer : public AndroidVideoFrameBuffer {
const jmethodID j_release_id_;
const int width_;
const int height_;
- // Holds a VideoFrame.Buffer.
magjed_webrtc 2017/07/28 09:45:05 Keep this comment.
sakal 2017/07/28 11:08:49 Done.
- ScopedGlobalRef<jobject> j_video_frame_buffer_;
+ const ScopedGlobalRef<jobject> j_video_frame_buffer_;
};
class AndroidVideoBufferFactory {

Powered by Google App Engine
This is Rietveld 408576698