mirror of
https://github.com/mpv-player/mpv
synced 2025-02-16 12:17:12 +00:00
video: remove redundant function
mp_image_params_from_image() is now trivial and can be removed.
This commit is contained in:
parent
2827ff1eab
commit
efa6b09b65
@ -490,12 +490,6 @@ bool mp_image_params_equals(const struct mp_image_params *p1,
|
||||
p1->rotate == p2->rotate;
|
||||
}
|
||||
|
||||
void mp_image_params_from_image(struct mp_image_params *params,
|
||||
const struct mp_image *image)
|
||||
{
|
||||
*params = image->params;
|
||||
}
|
||||
|
||||
// Set most image parameters, but not image format or size.
|
||||
// Display size is used to set the PAR.
|
||||
void mp_image_set_attributes(struct mp_image *image,
|
||||
|
@ -143,9 +143,6 @@ bool mp_image_params_valid(const struct mp_image_params *p);
|
||||
bool mp_image_params_equals(const struct mp_image_params *p1,
|
||||
const struct mp_image_params *p2);
|
||||
|
||||
void mp_image_params_from_image(struct mp_image_params *params,
|
||||
const struct mp_image *image);
|
||||
|
||||
void mp_image_set_params(struct mp_image *image,
|
||||
const struct mp_image_params *params);
|
||||
|
||||
|
@ -254,8 +254,8 @@ int mp_sws_reinit(struct mp_sws_context *ctx)
|
||||
int mp_sws_scale(struct mp_sws_context *ctx, struct mp_image *dst,
|
||||
struct mp_image *src)
|
||||
{
|
||||
mp_image_params_from_image(&ctx->src, src);
|
||||
mp_image_params_from_image(&ctx->dst, dst);
|
||||
ctx->src = src->params;
|
||||
ctx->dst = dst->params;
|
||||
|
||||
int r = mp_sws_reinit(ctx);
|
||||
if (r < 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user