mirror of
https://github.com/mpv-player/mpv
synced 2024-12-20 22:02:59 +00:00
video: fix screenshots with anamorphic video
(Again.) This was caused by mp_image_set_params() not properly copying d_w/d_h, because mp_image_set_size() resets them.
This commit is contained in:
parent
50538c0ea2
commit
a014a2402d
@ -193,10 +193,10 @@ void mp_image_set_size(struct mp_image *mpi, int w, int h)
|
|||||||
void mp_image_set_params(struct mp_image *image,
|
void mp_image_set_params(struct mp_image *image,
|
||||||
const struct mp_image_params *params)
|
const struct mp_image_params *params)
|
||||||
{
|
{
|
||||||
image->params = *params;
|
// possibly initialize other stuff
|
||||||
// possibly reinitialize stuff
|
|
||||||
mp_image_setfmt(image, params->imgfmt);
|
mp_image_setfmt(image, params->imgfmt);
|
||||||
mp_image_set_size(image, params->w, params->h);
|
mp_image_set_size(image, params->w, params->h);
|
||||||
|
image->params = *params;
|
||||||
}
|
}
|
||||||
|
|
||||||
struct mp_image *mp_image_alloc(int imgfmt, int w, int h)
|
struct mp_image *mp_image_alloc(int imgfmt, int w, int h)
|
||||||
|
Loading…
Reference in New Issue
Block a user