提交 9eee2137 编写于 作者: V Vitaly Prosyak 提交者: Alex Deucher

drm/amd/display: Fix handling of linear transfer function

Signed-off-by: NVitaly Prosyak <vitaly.prosyak@amd.com>
Reviewed-by: NTony Cheng <Tony.Cheng@amd.com>
Acked-by: NHarry Wentland <harry.wentland@amd.com>
Signed-off-by: NAlex Deucher <alexander.deucher@amd.com>
上级 3f7194bc
...@@ -1267,7 +1267,8 @@ bool mod_color_calculate_curve(enum dc_transfer_func_predefined trans, ...@@ -1267,7 +1267,8 @@ bool mod_color_calculate_curve(enum dc_transfer_func_predefined trans,
bool ret = false; bool ret = false;
struct pwl_float_data_ex *rgb_regamma = NULL; struct pwl_float_data_ex *rgb_regamma = NULL;
if (trans == TRANSFER_FUNCTION_UNITY) { if (trans == TRANSFER_FUNCTION_UNITY ||
trans == TRANSFER_FUNCTION_LINEAR) {
points->end_exponent = 0; points->end_exponent = 0;
points->x_point_at_y1_red = 1; points->x_point_at_y1_red = 1;
points->x_point_at_y1_green = 1; points->x_point_at_y1_green = 1;
...@@ -1337,7 +1338,8 @@ bool mod_color_calculate_degamma_curve(enum dc_transfer_func_predefined trans, ...@@ -1337,7 +1338,8 @@ bool mod_color_calculate_degamma_curve(enum dc_transfer_func_predefined trans,
bool ret = false; bool ret = false;
struct pwl_float_data_ex *rgb_degamma = NULL; struct pwl_float_data_ex *rgb_degamma = NULL;
if (trans == TRANSFER_FUNCTION_UNITY) { if (trans == TRANSFER_FUNCTION_UNITY ||
trans == TRANSFER_FUNCTION_LINEAR) {
for (i = 0; i <= MAX_HW_POINTS ; i++) { for (i = 0; i <= MAX_HW_POINTS ; i++) {
points->red[i] = coordinates_x[i].x; points->red[i] = coordinates_x[i].x;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册