|
|
@@ -702,6 +702,9 @@ void arkapi_video_release(video_handle *handle)
|
|
|
|
|
|
if(!pdd->kernel_used)
|
|
|
arkapi_display_hide_layer(handle->handle_disp);
|
|
|
+
|
|
|
+ arkapi_display_wait_for_vsync(handle->handle_disp);
|
|
|
+
|
|
|
if (handle->handle_disp)
|
|
|
arkapi_display_close_layer(handle->handle_disp);
|
|
|
|
|
|
@@ -755,11 +758,14 @@ int arkapi_video_play(video_handle *handle, const void *src_addr, int len, int f
|
|
|
|
|
|
arkapi_video_lock(handle);
|
|
|
|
|
|
+ if (len > MAX_STREAM_BUFFER_SIZE) {
|
|
|
+ printf("%s error, too large frame.\n", __func__);
|
|
|
+ len = MAX_STREAM_BUFFER_SIZE;
|
|
|
+ }
|
|
|
+
|
|
|
memcpy(handle->in_buffer.virtualAddress, src_addr, len);
|
|
|
//ark_dbg("%s: src_addr=0x%p, len=%d.\n", __func__, src_addr, len);
|
|
|
|
|
|
- if (len > MAX_STREAM_BUFFER_SIZE)
|
|
|
- len = MAX_STREAM_BUFFER_SIZE;
|
|
|
handle->in_buffer.size = len;
|
|
|
handle->out_buffer.num = 0;
|
|
|
|
|
|
@@ -853,11 +859,14 @@ int arkapi_video_play_add_seekstatus(video_handle *handle, const void *src_addr,
|
|
|
|
|
|
arkapi_video_lock(handle);
|
|
|
|
|
|
+ if (len > MAX_STREAM_BUFFER_SIZE) {
|
|
|
+ printf("%s error, too large frame.\n", __func__);
|
|
|
+ len = MAX_STREAM_BUFFER_SIZE;
|
|
|
+ }
|
|
|
+
|
|
|
memcpy(handle->in_buffer.virtualAddress, src_addr, len);
|
|
|
//ark_dbg("%s: src_addr=0x%p, len=%d.\n", __func__, src_addr, len);
|
|
|
|
|
|
- if (len > MAX_STREAM_BUFFER_SIZE)
|
|
|
- len = MAX_STREAM_BUFFER_SIZE;
|
|
|
handle->in_buffer.size = len;
|
|
|
handle->out_buffer.num = 0;
|
|
|
|