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

[Feature Request] option to optimize pictures #2353

Open
Tids opened this Issue Mar 8, 2019 · 9 comments

Comments

Projects
None yet
3 participants
@Tids
Copy link

Tids commented Mar 8, 2019

Lately on Linux I found the tool jpegoptim, that lossless optimizes pictures you give it. So I did it and saved some real space.
633 pics of my android phone, about 150MiB saved.
bildschirmfoto von 2019-03-08 08-52-29. Always keep in mind that this is without any quality loss, or resizing.

I think a feature like this would be nice to have in sd-maid. Since many of us have thousands of pictures, probably many GiB of them.

What do you think?

@SuperSandro2000

This comment has been minimized.

Copy link

SuperSandro2000 commented Mar 8, 2019

Has this tool any side effects? Losing meta data or making the images incompatible in any way?

https://github.com/tjko/jpegoptim

@Tids

This comment has been minimized.

Copy link
Author

Tids commented Mar 8, 2019

I dont see any side effects. I still can view them everywhere (Lin, Win, Android), can edit them.
Metadata is still in place (there is an additional argument to remove them, not active by default).

So if there are some downsides, I cant find them.

++thanks for the link to the project!

@SuperSandro2000

This comment has been minimized.

Copy link

SuperSandro2000 commented Mar 8, 2019

This would need intensive testing before it could even be included in the beta as it could have potentially big down sides.
Maybe some games check hashes of their assets and would then redownload everything or some other crazy shit.

@Tids

This comment has been minimized.

Copy link
Author

Tids commented Mar 8, 2019

It's would be for user data only. We should not optimize app data. Everything that you see inside your gallery app should be fine.

@d4rken

This comment has been minimized.

Copy link
Owner

d4rken commented Mar 8, 2019

Where would this fit within SD Maid?

@Tids

This comment has been minimized.

Copy link
Author

Tids commented Mar 8, 2019

@d4rken I don't understand that question. You mean which category? That's not easy. Probably if you change Databases to a generic "Optimizations" it would fit right in there. 🤔

@d4rken

This comment has been minimized.

Copy link
Owner

d4rken commented Mar 8, 2019

That was my question, and you are right it could fit in there. If we do jpeg optimization we should also do png optimization. Two more thoughts on this

  • This would not be a lossless procedure, this would need to be made clear to the user.
  • This would increase SD Maids size significantly as I would probably have to include the binaries (in multiple variations, e.g. x86/ARM) within.
  • Good point on the potential checksumming of private app assets @SuperSandro2000
@d4rken

This comment has been minimized.

Copy link
Owner

d4rken commented Mar 8, 2019

I'm wondering whether this wouldn't be better suited for an extra app 🤷‍♂️, that begs the question, are there any other apps that do this?

I know there are multiple "duplicate finder" tools similar to what SD Maid offers.

@SuperSandro2000

This comment has been minimized.

Copy link

SuperSandro2000 commented Mar 8, 2019

And we probably would need multiple binaries for different image formats.
Maybe even support video formats?

Then we would need to make clear that the operation could take a long time and use a lot of battery.

Then it would need a failsave for files that have the wrong extension or magic header.

Then we can't really tell if an image is already optimised or needs optimisation. So we would rerun the operation on the same file a lot.

Then I don't take many pictures but I already have 2.9 GB pics and 1.2 GB videos alone in my DCIM/Camera folder.

So maybe a new app would be necessary as this sounds a bit out of scope for as maid.

I did a quick search and this app https://play.google.com/store/apps/details?id=net.teknoraver.imageoptimizer does that and the are potentially a lot more. I didn't try any but I see one that looks to promising.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.