Re: Screenshot color wrong
The Wanderer <[email protected]>
| Newsgroups | gmane.comp.video.mplayer.user |
|---|---|
| Organization | This space intentionally left blank. |
| Message-ID | <[email protected]> |
On 2020-09-03 at 10:16, [email protected] wrote: > After some further testing it seems like not the magic but the > messing-up is done here: > > [swscaler @ 00000000025fbdc0]bicubic scaler, from yuv420p to rgb24 using > MMXEXT > [swscaler @ 00000000025fbdc0]using unscaled yuv420p -> rgb24 special > converter > > When I leave the -vf screenshot out, those two lines are not in the output > > "mplayer.exe test.mp4" results in (cut output): > Starting playback... > Movie-Aspect is 0.74:1 - prescaling to correct movie aspect. > VO: [direct3d] 1014x1376 => 1014x1376 Planar YV12 > > > "mplayer.exe -vf screenshot test.mp4" results in (cut output): > Starting playback... > Movie-Aspect is 0.74:1 - prescaling to correct movie aspect. > [swscaler @ 0000000001f4bdc0]bicubic scaler, from yuv420p to rgb24 using > MMXEXT > [swscaler @ 0000000001f4bdc0]using unscaled yuv420p -> rgb24 special > converter > VO: [direct3d] 1014x1376 => 1014x1376 Planar YV12 > > > For both output on the screen looks good, only the colors in the > screenshot are red-shifted. > > It seems as if the screenshot filter automatically triggers the scale > filter too, which performs an unwanted "YUV<−>RGB colorspace conversion". > > Is there a possibility to switch this conversion/scaling off? Could not > find anything in docs or on the net. I doubt it. My guess is that the automatic insertion of this filter is the way in which the "screenshot" filter is able to "accept[] an arbitrary colorspace", as described in its entry in the man page: if the input isn't already in the correct form for what the filter can handle internally (i.e., apparently, rgb24), "screenshot" will automatically call "scale" to convert it into that format. That said, as far as I'm aware the result of that automatic scaling is supposed to be visually identical to the input. If it's not, then unless something else in your environment is causing the effective difference (e.g. by handling the different colorspace differently - display color profiles, maybe?), I'd expect that to be considered a bug. What I'd suggest to try, in pursuit of a possible workaround, would be manually inserting '-vf format=rgb24,scale=-1:-1' (which appears to perform the same no-size-change-involved conversion) into your playback command, and if that produces the same color shift, play around with other options to see if you can find a combination that leaves the end result after the scale filter looking how you want. If you can manage that, then replacing the 'format=rgb24,scale=-1:-1' with 'screenshot' should I think produce screenshots that match what you saw with the explicit scale filter command. I can't really test it myself, since on a random sample MP4 I happen to have lying around, the screenshots match identically with the result of playing the video normally and pausing at the same point. -- The Wanderer The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore all progress depends on the unreasonable man. -- George Bernard Shaw _______________________________________________ MPlayer-users mailing list [email protected] https://lists.mplayerhq.hu/mailman/listinfo/mplayer-users
signature.asc
(application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEJCOqsZEc2qVC44pUBKk1jTQoMmsFAl9RinwACgkQBKk1jTQo MmtRMg/+I8VBlszE409nLn6NMuaWthOGT3jrB+pPrkqQ62hNAKjwwuKid9F5okYe b0Seg8ZZRyftz69nJccVvRV0X56Mh7I0QBbgklGM6bJ3OdbuE9fuquKQRaP/94OI e5OPhxkHwXxhKtqFAQrdmoxPqK7zF44K6Pgm1eClBqni4RNEQYA6JtEf1RnWtuPm QzVJYvhNnDEIJCPvSithDStfU1826qjPQBu+Y6UNr86pX8t3wUIEuasnlpEUnghQ J7lvuq1tTf3MoVBcTxPClC4slERVaIEpGstTR1+8HQbSYMiaGNpwa8SYwSMvVLDF LFjmdagRZ/rU90pG1cJPS0Qgd5KLyythndp2BZW1inJ19SFKy5m3vQbpYLMvwkES SPNIFgkoX9VX6RGTF8Wu0lYMML1DL3R43F9OzbGM02JSdfd+AUciZ8oy4CMw0V4f WK9qpOoytn4FFA2oCPRXdDCUCe9OqjBu5epYB0srmVe3/ma0h7sHxBzBOg80JrdO ty8RIF2jWi9gvd0Wr3Td0fYk/mgyo0RJvVIhsOwMHihQ7EcUFROziazhRbsOvKa2 QOVRIqUrHkMMkIykpxAlc5p6D5vXWlIwCWm3aJ8HzrMlabYbl3ojjdX9mIVKOpqC ewzT2a4Ai8Q98gRG/+agEK9HK1TOtn4r9xAWowjx3/gS480PeBU= =2FQY -----END PGP SIGNATURE-----