{
tdm_sprd_hwc_window_data *hwc_window_data = NULL;
tbm_surface_queue_h tqueue = NULL;
+ int width, height;
+ tbm_format format;
if (error)
*error = TDM_ERROR_INVALID_PARAMETER;
RETURN_VAL_IF_FAIL(hwc_window != NULL, NULL);
+
hwc_window_data = hwc_window;
- int wight = hwc_window_data->info.src_config.size.h;
- int hight = hwc_window_data->info.src_config.size.v;
- tbm_format format = hwc_window_data->info.src_config.format;
+ width = hwc_window_data->info.src_config.size.h;
+ height = hwc_window_data->info.src_config.size.v;
+ format = hwc_window_data->info.src_config.format;
if (!hwc_window_data->tqueue) {
- tqueue = tbm_surface_queue_create(NUM_BUFFERS, wight, hight, format, TBM_BO_SCANOUT);
+ tqueue = tbm_surface_queue_create(NUM_BUFFERS, width, height, format, TBM_BO_SCANOUT);
if (error)
*error = TDM_ERROR_OPERATION_FAILED;
RETURN_VAL_IF_FAIL(tqueue != NULL, NULL);
int use_layers_zpos[NUM_LAYERS] = {0,};
int i;
- /* set target hwc window */
+ /* set target hwc window to the layer */
if (hwc_data->need_target_window) {
layer_data = tdm_sprd_output_get_layer(hwc_data->output_data, ZPOS_OSD);
_sprd_hwc_layer_attach_window(layer_data, hwc_data->target_hwc_window);
use_layers_zpos[hwc_data->target_hwc_window->lzpos] = 1;
}
- /* set hwc windows */
+ /* set the hwc_windows to the layers */
LIST_FOR_EACH_ENTRY_REV(hwc_window_data, &hwc_data->hwc_window_list, link) {
if (hwc_window_data->validated_type == TDM_HWC_WIN_COMPOSITION_NONE ||
hwc_window_data->validated_type == TDM_HWC_WIN_COMPOSITION_CLIENT)
return TDM_ERROR_NONE;
}
+/* assign the validated_type to the composited_wnds
+ * assign the layer_zpos to the composited_wnds
+ */
static void
_sprd_hwc_apply_policy(tdm_sprd_hwc_data *hwc_data , tdm_hwc_window **composited_wnds, uint32_t num_wnds)
{
if (error)
*error = TDM_ERROR_NONE;
+
return tqueue;
}
tdm_sprd_hwc_data *hwc_data = hwc;
tdm_error err;
- /* TODO: as the sprd-driver currently doesn't support DEVICE to CLIENT transition.
- * we silence skip 'composited_wnds' */
-
RETURN_VAL_IF_FAIL(hwc_data != NULL, TDM_ERROR_INVALID_PARAMETER);
RETURN_VAL_IF_FAIL(hwc_data->target_hwc_window != NULL, TDM_ERROR_OPERATION_FAILED);