Skip to content
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

Png compression #905

Merged
merged 2 commits into from
Jan 12, 2022
Merged

Png compression #905

merged 2 commits into from
Jan 12, 2022

Conversation

EricClaeys
Copy link
Collaborator

png is lossless so "quality" is really just the amount of compression. Since dark frames stick around a long time, compress them at the max setting (9) rather than the min (0).

png is lossless, so "quality" only determines the amount of compression and hence the time needed to save the file (higher values are compressed more).
Since darks stick around for a long time, perform the max compression.
png is lossless, so "quality" only determines the amount of compression and hence the time needed to save the file (higher values are compressed more).
Copy link
Collaborator

@AndreasLMeg AndreasLMeg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems correct
(https://docs.opencv.org/4.x/d8/d6a/group__imgcodecs__flags.html#gga292d81be8d76901bff7988d18d2b42acad2548321c69ab9c0582fd51e75ace1d0)

IMWRITE_PNG_COMPRESSION Python: cv.IMWRITE_PNG_COMPRESSION For PNG, it can be the compression level from 0 to 9. A higher value means a smaller size and longer compression time. If specified, strategy is changed to IMWRITE_PNG_STRATEGY_DEFAULT (Z_DEFAULT_STRATEGY). Default value is 1 (best speed setting).

@EricClaeys EricClaeys merged commit 3c166c2 into master Jan 12, 2022
@EricClaeys EricClaeys deleted the png-compression branch January 12, 2022 06:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants