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

Unified Diff: talk/app/webrtc/java/jni/native_handle_impl.h

Issue 1357923002: wip Move SurfaceTexture.updateTexImage() from video renderers into MediaCodecVideoDecoder (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 3 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: talk/app/webrtc/java/jni/native_handle_impl.h
diff --git a/talk/app/webrtc/java/jni/native_handle_impl.h b/talk/app/webrtc/java/jni/native_handle_impl.h
index 68b213bf538a0524ed9b2fa936a5c4cc4a182db6..370039e50ef8d188f8957fdebef97f7a06ce5781 100644
--- a/talk/app/webrtc/java/jni/native_handle_impl.h
+++ b/talk/app/webrtc/java/jni/native_handle_impl.h
@@ -29,47 +29,18 @@
#ifndef TALK_APP_WEBRTC_JAVA_JNI_NATIVE_HANDLE_IMPL_H_
#define TALK_APP_WEBRTC_JAVA_JNI_NATIVE_HANDLE_IMPL_H_
-#include "webrtc/base/checks.h"
-#include "webrtc/common_video/interface/video_frame_buffer.h"
+#include <jni.h>
namespace webrtc_jni {
// Wrapper for texture object.
-class NativeHandleImpl {
- public:
- NativeHandleImpl() : texture_object_(NULL), texture_id_(-1) {}
+struct NativeHandleImpl {
+ NativeHandleImpl(JNIEnv* jni,
+ jint j_oes_texture_id,
+ jfloatArray j_transform_matrix);
- void* GetHandle() {
- return texture_object_;
- }
- int GetTextureId() {
- return texture_id_;
- }
- void SetTextureObject(void *texture_object, int texture_id) {
- texture_object_ = reinterpret_cast<jobject>(texture_object);
- texture_id_ = texture_id;
- }
-
- private:
- jobject texture_object_;
- int32_t texture_id_;
-};
-
-class JniNativeHandleBuffer : public webrtc::NativeHandleBuffer {
- public:
- JniNativeHandleBuffer(void* native_handle, int width, int height)
- : NativeHandleBuffer(native_handle, width, height) {}
-
- // TODO(pbos): Override destructor to release native handle, at the moment the
- // native handle is not released based on refcount.
-
- private:
- rtc::scoped_refptr<VideoFrameBuffer> NativeToI420Buffer() override {
- // TODO(pbos): Implement before using this in the encoder pipeline (or
- // remove the RTC_CHECK() in VideoCapture).
- RTC_NOTREACHED();
- return nullptr;
- }
+ const int oes_texture_id;
+ float sampling_matrix[16];
};
} // namespace webrtc_jni

Powered by Google App Engine
This is Rietveld 408576698