Commit b2d0a103 authored by Dmytro Laktyushkin's avatar Dmytro Laktyushkin Committed by Alex Deucher

drm/amd/display: add init calculation to scaler params

Signed-off-by: default avatarDmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Acked-by: default avatarHarry Wentland <Harry.Wentland@amd.com>
Reviewed-by: default avatarDmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 4a9a5d62
......@@ -971,8 +971,7 @@ bool dc_pre_update_surfaces_to_stream(
DC_SURFACE_TO_CORE(new_surfaces[i]))
continue;
resource_build_scaling_params(
new_surfaces[i], &context->res_ctx.pipe_ctx[j]);
resource_build_scaling_params(&context->res_ctx.pipe_ctx[j]);
}
if (!core_dc->res_pool->funcs->validate_bandwidth(core_dc, context)) {
......@@ -1364,7 +1363,7 @@ void dc_update_surfaces_for_stream(struct dc *dc,
if (pipe_ctx->surface != surface)
continue;
resource_build_scaling_params(updates[i].surface, pipe_ctx);
resource_build_scaling_params(pipe_ctx);
}
}
......
......@@ -927,6 +927,7 @@ static void get_surface_visual_confirm_color(const struct pipe_ctx *pipe_ctx,
color->color_b_cb = color_value;
break;
case PIXEL_FORMAT_420BPP12:
case PIXEL_FORMAT_420BPP15:
/* set boarder color to green */
color->color_g_y = color_value;
break;
......
......@@ -147,13 +147,24 @@ struct line_buffer_params {
enum lb_pixel_depth depth;
};
struct scl_inits {
struct fixed31_32 h;
struct fixed31_32 h_c;
struct fixed31_32 v;
struct fixed31_32 v_bot;
struct fixed31_32 v_c;
struct fixed31_32 v_c_bot;
};
struct scaler_data {
int h_active;
int v_active;
struct scaling_taps taps;
struct rect viewport;
struct rect viewport_c;
struct rect recout;
struct scaling_ratios ratios;
struct scl_inits inits;
struct sharpness_adj sharpness;
enum pixel_format format;
struct line_buffer_params lb_params;
......
......@@ -82,9 +82,7 @@ enum dc_status resource_map_pool_resources(
const struct core_dc *dc,
struct validate_context *context);
bool resource_build_scaling_params(
const struct dc_surface *surface,
struct pipe_ctx *pipe_ctx);
bool resource_build_scaling_params(struct pipe_ctx *pipe_ctx);
enum dc_status resource_build_scaling_params_for_context(
const struct core_dc *dc,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment