-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Frames from video exported to lossless PNG #17
Comments
No, |
Only if it's an MJPEG video (each video frame can be extracted as a JPEG image), because this program is focused on the JPEG format. Same algorithm be done for some video codecs that also use DCT, but this will require a lot of work (e.g. researching a specific codec). |
I'll explain your results about an image saved in JPEG format at 100% quality - a certain percentage of quality is converted into a quantization table (which may be specific to the JPEG encoder), which is saved in the JPEG file (not the percentage itself). This table is also used by Quant Smooth to determine which parts of the image are artifacts and which are not. At 100% quality, there are no JPEG compression artifacts, because this is the original image passed to the encoder, your image had artifacts before JPEG. And if someone just resaves low quality with higher quality - Quant Smooth will not be able to remove all artifacts, because the original quantization tables from the first compression in JPEG are lost. You can save the image as a JPEG with a quality that matches the quality of your video (but it's hard to guess what percentage is corresponds to), and then with Quant Smooth you will get some filtering, but this is a misuse of the program and will be inaccurate. Similar programs listed in the comparison work the same way. Hopefully this will help you understand how this works. |
Hi @ilyakurdyukov . Gradually the thought matured: Add custom_quality option and use it to generate the quantization matrix, not use internal one. PS: It would be an interesting move. |
Firstly, there's no prescribed way to convert a percentage into a QM. Secondly, if you used a different QM to the one stored in the image, you'd get meaningless results. |
I was wondering if the program can improve frames from low resolution video. I exported the frames to PNG (lossless) but since they are not accepted by the program I converted to JPEG Q=100 (still not a lossless step). I ran the program with max quality, -q 6, but there's no difference between frames.
So I'm guessing the program needs an "original" JPEG file and won't work with frames exported from video even though they have JPEG like compression artifacts.
The text was updated successfully, but these errors were encountered: