Android: Generate Java -> C++ JNI code for VideoEncoder
This is the first CL that tries generating Java -> C++ JNI code. Bug: webrtc:8278 Change-Id: I1ff0df10db0f80a3c84a61a4e82be8f713690a69 Reviewed-on: https://webrtc-review.googlesource.com/20873 Commit-Queue: Magnus Jedvert <magjed@webrtc.org> Reviewed-by: Sami Kalliomäki <sakal@webrtc.org> Cr-Commit-Position: refs/heads/master@{#20592}
This commit is contained in:

committed by
Commit Bot

parent
3f2634eadc
commit
18ce0f006d
@ -192,6 +192,7 @@ const char* VideoEncoderWrapper::ImplementationName() const {
|
||||
}
|
||||
|
||||
void VideoEncoderWrapper::OnEncodedFrame(JNIEnv* jni,
|
||||
jobject j_caller,
|
||||
jobject j_buffer,
|
||||
jint encoded_width,
|
||||
jint encoded_height,
|
||||
@ -402,25 +403,5 @@ std::string VideoEncoderWrapper::GetImplementationName(JNIEnv* jni) const {
|
||||
return JavaToStdString(jni, jname);
|
||||
}
|
||||
|
||||
JNI_FUNCTION_DECLARATION(void,
|
||||
VideoEncoderWrapper_onEncodedFrame,
|
||||
JNIEnv* jni,
|
||||
jclass,
|
||||
jlong j_native_encoder,
|
||||
jobject buffer,
|
||||
jint encoded_width,
|
||||
jint encoded_height,
|
||||
jlong capture_time_ns,
|
||||
jint frame_type,
|
||||
jint rotation,
|
||||
jboolean complete_frame,
|
||||
jobject qp) {
|
||||
VideoEncoderWrapper* native_encoder =
|
||||
reinterpret_cast<VideoEncoderWrapper*>(j_native_encoder);
|
||||
native_encoder->OnEncodedFrame(jni, buffer, encoded_width, encoded_height,
|
||||
capture_time_ns, frame_type, rotation,
|
||||
complete_frame, qp);
|
||||
}
|
||||
|
||||
} // namespace jni
|
||||
} // namespace webrtc
|
||||
|
Reference in New Issue
Block a user