return mode_change;
}
-static bool is_dovi_frame(struct vframe_s *vf)
+bool is_dovi_frame(struct vframe_s *vf)
{
struct provider_aux_req_s req;
char *p;
}
return false;
}
+EXPORT_SYMBOL(is_dovi_frame);
#define signal_color_primaries ((vf->signal_type >> 16) & 0xff)
#define signal_transfer_characteristic ((vf->signal_type >> 8) & 0xff)
struct vframe_s *vf = NULL;
while (1) {
- vf = vf_peek(RECEIVER_NAME);
+ vf = video_vf_peek();
+
+#ifdef CONFIG_AMLOGIC_MEDIA_ENHANCEMENT_DOLBYVISION
+ if (is_dolby_vision_enable()
+ && vf && is_dovi_frame(vf)) {
+ pr_info("vsync_isr_in, ignore the omx %d frames drop for dv frame\n",
+ omx_need_drop_frame_num);
+ omx_need_drop_frame_num = 0;
+ omx_drop_done = true;
+ break;
+ }
+#endif
if (vf) {
if (omx_need_drop_frame_num >= vf->omx_index) {
//pr_info("vsync drop omx_index %d\n",
//vf->omx_index);
- vf = vf_get(RECEIVER_NAME);
- vf_put(vf, RECEIVER_NAME);
+ vf = video_vf_get();
+ video_vf_put(vf);
} else {
omx_drop_done = true;
break;
while (try_cnt--) {
vf = vf_peek(RECEIVER_NAME);
+#ifdef CONFIG_AMLOGIC_MEDIA_ENHANCEMENT_DOLBYVISION
+ if (is_dolby_vision_enable()
+ && vf && is_dovi_frame(vf)) {
+ pr_info("set_omx_pts ignore the omx %d frames drop for dv frame\n",
+ frame_num);
+ break;
+ }
+#endif
if (vf) {
if (frame_num >= vf->omx_index) {
vf = vf_get(RECEIVER_NAME);