SecUSo / privacy-friendly-finance-manager

GNU General Public License v3.0
43 stars 22 forks source link

Vectorize Image assets #11

Closed TPS closed 4 years ago

TPS commented 5 years ago

I noticed that the recent apk y'all recently released (& @IzzySoft published) is the size of the previous release. A quick look leads me to believe that's mostly due to the many sets of PNG image assets.

Could I suggest vectorizing them? That'd help immensely w/ the size by allowing not to have so many DPI versions, all of which are large. Here're some links (which also mention adding/keeping adaptive capabilities, if desired, to the launcher icons):

IzzySoft commented 5 years ago

Nope @TPS, that's not the reason of the size increase. The new APK is "multi platform", and thus contains an .so of ~3M for 5 platforms (ARM, ARMv7, ARM64v8, x68 and x86_64) which were not present in previous versions. So to cut back in size, those had to be separated – or at least split into ARM and x86. I could arrange to only pick up the ARM variant, as I do with several other packages (usually ARMv7, which also works on ARMv8 devices but not the other way around). An ARM APK covering all 3 variants would be just below 7M, a plain ARMv7 APK about 4M.

Not sure where you found that many PNGs: there's a large number, right, but they are very small. I'd wonder if they amount to much more than 200k. The big addition were the .so files for libsqlcipher which haven't been there before.

Kamuno commented 5 years ago

Most of the drawables are vector images already. Only the app icon and some secuso logos are pngs.

Our app icons all have a standardized look and we would have to change every app's icon if we moved to adaptive icons. This will inevitably have to happen in the future but for now this has a rather low priority.

@IzzySoft is correct about the increase in size. It is mainly because of the crypto library we added.

IzzySoft commented 5 years ago

Thanks for confirming, @Kamuno! Just for orientation: will you keep it that way (i.e. future versions are expected to be of similar size) – or have you plans to split? Because in the former case, I need to reduce the number of versions I keep by 1 (to stay within the 20M per-app limit; with 7M or less I'd keep 3).

Kamuno commented 5 years ago

@IzzySoft I didn't even know it was possible to split the builds into different "plattform packs". I don't think we intend to split the apks (yet). I think most users do not care to know what architecture they are on (although they would probably rather use an app store).

Maybe in the future if the app size keeps increasing. Thanks for bringing this to our attention, though.

IzzySoft commented 5 years ago

@Kamuno I just saw I can withdraw that question: your app just reached the official repo, so I simply removed it from mine (takes effect in about 9 hours with the next sync).

As for the "technic": I've seen it in other projects that multiple APKs were offered, each with a specific suffix (like _x86, _armv7 etc). I guess they all use the same package name (those I've seen did), and the user just picks the one (s)he needs. AFAIK F-Droid also supports something like that (multiple platform specific APKs using the same package name), but I'd need to check to make sure.

I agree it's not that urgent – but I see it would be nice to have, and not be "wasteful with resources" (in nature we just learn that the hard way)… Thanks for considering!