dev->need_empty_ready = true;
wake_up_interruptible(&dev->wq);
}
+ if (!dev->is_sideband)
+ set_blackout_policy(0);
dev->is_sideband = true;
current_is_sideband = true;
}
if ((dev->is_sideband && !current_is_sideband) ||
(dev->received_count == 0)) {
- if (dev->is_sideband && !current_is_sideband)
+ if (dev->is_sideband && !current_is_sideband) {
+ set_blackout_policy(1);
vc_print(dev->index, PRINT_OTHER,
"sideband to non\n");
+ }
dev->is_sideband = false;
if (dev->index == 0)
set_video_path_select("video_render.0", 0);
int ret;
int timeout = 0;
+ if (dev->is_sideband)
+ set_blackout_policy(1);
+
disable_video_layer(dev, 1);
video_set_global_output(dev->index, 0);
ret = video_composer_release_path(dev);
new_frame = gvideo_recv[0]->cur_buf;
}
}
- vd_layer[0].dispbuf_mapping = &gvideo_recv[0]->cur_buf;
+ if (new_frame || gvideo_recv[0]->cur_buf)
+ vd_layer[0].dispbuf_mapping = &gvideo_recv[0]->cur_buf;
cur_blackout = 1;
} else if (gvideo_recv[1] &&
(gvideo_recv[1]->path_id == vd1_path_id)) {
new_frame = gvideo_recv[1]->cur_buf;
}
}
- vd_layer[0].dispbuf_mapping = &gvideo_recv[1]->cur_buf;
+ if (new_frame || gvideo_recv[1]->cur_buf)
+ vd_layer[0].dispbuf_mapping = &gvideo_recv[1]->cur_buf;
cur_blackout = 1;
} else if (vd1_path_id == VFM_PATH_PIP) {
/* pip display on VD1 */
new_frame = cur_pipbuf;
}
}
- vd_layer[0].dispbuf_mapping = &cur_pipbuf;
+ if (new_frame || cur_pipbuf)
+ vd_layer[0].dispbuf_mapping = &cur_pipbuf;
cur_blackout = blackout_pip | force_blackout;
} else if (vd1_path_id != VFM_PATH_INVAILD) {
/* priamry display on VD1 */
new_frame = cur_dispbuf;
}
}
- vd_layer[0].dispbuf_mapping = &cur_dispbuf;
+ if (new_frame || cur_dispbuf)
+ vd_layer[0].dispbuf_mapping = &cur_dispbuf;
cur_blackout = blackout | force_blackout;
} else {
cur_blackout = 1;
new_frame2 = gvideo_recv[0]->cur_buf;
}
}
- vd_layer[1].dispbuf_mapping = &gvideo_recv[0]->cur_buf;
+ if (new_frame2 || gvideo_recv[0]->cur_buf)
+ vd_layer[1].dispbuf_mapping = &gvideo_recv[0]->cur_buf;
cur_blackout = 1;
} else if (gvideo_recv[1] &&
(gvideo_recv[1]->path_id == vd2_path_id)) {
new_frame2 = gvideo_recv[1]->cur_buf;
}
}
- vd_layer[1].dispbuf_mapping = &gvideo_recv[1]->cur_buf;
+ if (new_frame2 || gvideo_recv[1]->cur_buf)
+ vd_layer[1].dispbuf_mapping = &gvideo_recv[1]->cur_buf;
cur_blackout = 1;
} else if (vd2_path_id == VFM_PATH_AMVIDEO) {
/* priamry display in VD2 */
new_frame2 = cur_dispbuf;
}
}
- vd_layer[1].dispbuf_mapping = &cur_dispbuf;
+ if (new_frame2 || cur_dispbuf)
+ vd_layer[1].dispbuf_mapping = &cur_dispbuf;
cur_blackout = blackout | force_blackout;
} else if (vd2_path_id != VFM_PATH_INVAILD) {
/* pip display in VD2 */
new_frame2 = cur_pipbuf;
}
}
- vd_layer[1].dispbuf_mapping = &cur_pipbuf;
+ if (new_frame2 || cur_pipbuf)
+ vd_layer[1].dispbuf_mapping = &cur_pipbuf;
cur_blackout = blackout_pip | force_blackout;
} else {
cur_blackout = 1;
if (layer->dispbuf &&
is_local_vf(layer->dispbuf))
layer->dispbuf = NULL;
- if (layer->dispbuf_mapping &&
- *layer->dispbuf_mapping &&
- is_local_vf(*layer->dispbuf_mapping)) {
- *layer->dispbuf_mapping = NULL;
+ if (layer->dispbuf_mapping) {
+ if (*layer->dispbuf_mapping &&
+ is_local_vf(*layer->dispbuf_mapping))
+ *layer->dispbuf_mapping = NULL;
layer->dispbuf_mapping = NULL;
layer->dispbuf = NULL;
}
if (layer->dispbuf &&
is_local_vf(layer->dispbuf))
layer->dispbuf = NULL;
- if (layer->dispbuf_mapping &&
- *layer->dispbuf_mapping &&
- is_local_vf(*layer->dispbuf_mapping)) {
- *layer->dispbuf_mapping = NULL;
+ if (layer->dispbuf_mapping) {
+ if (*layer->dispbuf_mapping &&
+ is_local_vf(*layer->dispbuf_mapping))
+ *layer->dispbuf_mapping = NULL;
layer->dispbuf_mapping = NULL;
layer->dispbuf = NULL;
}