I found that VirtualDub2, Shotcut, and Kdenlive can make png files smaller than ffmpeg. How do I adjust the settings to match the file size (or make it even smaller, if possible)?
Also, can ffmpeg make zip/7z/rar/zqad files?
+ Reply to Thread
Results 1 to 19 of 19
-
-
Use the ffmpeg png -pred (prediction method) settings listed in the help file to adjust the ffmpeg png compression . Default is "none" so it will produce larger files but export faster than say, vdub2's or shotcut's or kdenlive's png's . Higher compression ratio means slower exports as usual for tradeoffs
-
And my other question?
Oh, I tried what you said but they're still not smaller. -
Don't forget about specifying proper pixel type - you might be exporting 16bit RGB . By default if input video is >8bit, ffmpeg will export 16bit PNG's
Don't forget about proper YUV to RGB conversion or you'll get wrong colors
Don't forget the warning in your other thread about colorimetry flagged input YUV video to PNG sequence using ffmpeg - and the cHRM, gAMA tags - or PNGs will display differently in different programs and browser versions -
-
So specify 8bit PNG. Most displays will be 8bit RGB anyways. There is no benefit to use 16bit RGB for posting to a website for display, it will just make filesize larger
You know how to use zscale, format filters from the other threads . Sometimes ffmpeg gets it correct "automatically", sometimes not . It depends on the source video, flags, and the ffmpeg version
But you will get the wrong colors in some browsers like firefox with that workflow, because of the cHRM, gAMA tags if YUV video is colorimetry flagged . If using ffmpeg to export PNG's , I would use an avisynth script with PropClearAll() . That clears the flags and the exported PNG's will not have those tags, colors will look correct everywhere. You can also control the YUV to RGB conversion properly in avisynth if you wanted to
Vdub2 will look at flags for it's RGB conversion by default. If video flags are correct, RGB conversion should be correct. If flags are wrong, conversion will be wrong. If video is unflagged, it will use Rec601 for RGB conversion - it will be wrong for most HD sources -
-
It depends on the input video and output format
There is no 1 size fits all.
Different videos have different pixel types, different matrix/transfer/primaries , HDR vs. SDR . If you use the same settings for everything, you're going to get the wrong result for many cases . You saw an example of that before in your other threads
So it might be a different script for each video, same with output format. I only suggested the script as a workaround for ffmpeg png's . The ffmpeg png issues has reported many times . Many software that use ffmpeg for png exports have the same problem
For the compression side, use the highest compression settings in the help file and it will be the slowest as well. Trade offs. -
-
"24bpp" or "bit per pixel" is the same thing as 8bpc or "bit per channel" . 8bit Red, 8bit Green, 8bit Blue
-vf format=rgb24
The 8bit RGB image will be lower quality if your source material was true 10bit or higher (not 10bit encoded from a 8bit source) . And on a 10bit display (there are getting more common these days, but the majority are still 8bit), you might see a difference in quality, especially around gradients. The 8bit RGB image will show more banding -
-
Screenshots of every single frame in a video - is the same thing as exporting an image sequence from a video
Or maybe you're not describing what you want correctly ?
(and if video is YUV, and tagged with colorimetry flags - the output PNG sequence will have cHRM, gAMA tags that cause the PNG to display with wrong colors in firefox, chrome, edge(chromium) - thats about 90% of browsers) -
-
-
-
-
Depends on the source
But for the examples you posted - probably
You can crop to a region of interest at 1:1 . e.g. display the top left corner.
For websites that have limits on image upload filesizes, you can post links to 3rd party image hosts . This is a very common practice
Similar Threads
-
Smallest PNG File Size, Part 2
By Jay123210599 in forum Newbie / General discussionsReplies: 7Last Post: 15th Jan 2024, 16:58 -
Smallest PNG File Size
By Jay123210599 in forum Newbie / General discussionsReplies: 12Last Post: 12th Jan 2024, 06:00 -
How to add 1 pixel png to header of ts file hls
By conlele in forum Video ConversionReplies: 0Last Post: 21st Jul 2023, 09:03 -
Best compression, smallest size, highest quality?
By Sullah in forum Video ConversionReplies: 17Last Post: 12th Nov 2022, 10:48 -
Converting TTML2+PNG Subtitles to BDN(XML+PNG)
By MounaLafi in forum SubtitleReplies: 6Last Post: 25th Jan 2019, 06:48