In ffmpeg, if I use -vf format=rgb24, will I always get the correct colors for any image format, including jpg and webp? What should I set -qscale:v (-q:v) to so I can get the best quality, 2 or 1? Will adding -qmin 1 and -qmax 1 also improve the quality?
+ Reply to Thread
Results 1 to 5 of 5
-
Last edited by The Enigma; 17th Mar 2024 at 14:29.
-
No, as you can see in the documentation of mjpeg and libwebp, which are the default encoders used by ffmpeg for jpg and webp, neither supports the rgb24 pixel format.
ffmpeg -help encoder=mjpeg
Code:Encoder mjpeg [MJPEG (Motion JPEG)]: General capabilities: threads Threading capabilities: frame and slice Supported pixel formats: yuvj420p yuvj422p yuvj444p yuv420p yuv422p yuv444p ...
Code:Encoder libwebp [libwebp WebP image]: General capabilities: dr1 Threading capabilities: none Supported pixel formats: bgra yuv420p yuva420p ...
Code:libwebp encoder AVOptions: -lossless <int> E..V....... Use lossless mode (from 0 to 1) (default 0) -preset <int> E..V....... Configuration preset (from -1 to 5) (default none) none -1 E..V....... do not use a preset default 0 E..V....... default preset picture 1 E..V....... digital picture, like portrait, inner shot photo 2 E..V....... outdoor photograph, with natural lighting drawing 3 E..V....... hand or line drawing, with high-contrast details icon 4 E..V....... small-sized colorful images text 5 E..V....... text-like -cr_threshold <int> E..V....... Conditional replenishment threshold (from 0 to INT_MAX) (default 0) -cr_size <int> E..V....... Conditional replenishment block size (from 0 to 256) (default 16) -quality <float> E..V....... Quality (from 0 to 100) (default 75)
-
That bgra format for libwebp is perhaps 8bit rgb, like rgb24 is, not planar as rgb24 is, but I guess that does not matter. I read, most likely here (poisondeathray inputs) that it could be done losslessly. It was discussed here, try to google "videohelp forum rgb lossless webp"
-
Do these topics/posts remind anyone of a recently banned 'Troll' who kept starting topics about 'lossless' pic formats despite already having all the answers presented to him.
Similar Threads
-
Best Visually Lossless File for Highest Quality
By Jay123210599 in forum Newbie / General discussionsReplies: 0Last Post: 20th Jan 2024, 23:02 -
Smallest Visually Lossless Files
By Jay123210599 in forum Newbie / General discussionsReplies: 10Last Post: 19th Jan 2024, 02:10 -
VirtualDub2 Lossless jpgs
By Jay123210599 in forum Newbie / General discussionsReplies: 23Last Post: 15th Jan 2024, 22:03 -
Lossless JPGs
By Jay123210599 in forum ComputerReplies: 2Last Post: 2nd Jan 2024, 10:54 -
Virtually or Visually Lossless Number
By Jay123210599 in forum Newbie / General discussionsReplies: 31Last Post: 27th Dec 2023, 01:45