MichielProost / Perfect-Plate

This Android application allows cheffs around the world to create, review and discover new recipes. Users can gain experience and level up in this app by completing challenges like creating a certain amount of recipes.
1 stars 2 forks source link

Reduce step/banner/profile images size #23

Closed Nuytemans-Dieter closed 3 years ago

Nuytemans-Dieter commented 3 years ago

Firebase has a built-in plugin extension for this. This should preferably happen before release, as it may decrease image loading time drastically.

MichielProost commented 3 years ago

Great idea! I'll try to add it in the next couple of days.

MichielProost commented 3 years ago

Unfortunately, we can't use the Firebase "resize-images" extension. We'll have to add this in our code. I discoverd that you can specify a max width and height in the ImagePicker. After doing some research online, 500 px max height and 500 px max width, seemed best. They usually use 300x300 for tumbnails and 500> for full quality images. What do you think Dieter?

Additional problem or conundrum: I'll have to re-upload the existing images on Firebase storage. Meaning, I will have to resize the images manually, upload them to Firebase, and re-set the original image fields in the recipe documents. I think this is unavoidable, but annoying nevertheless.

MichielProost commented 3 years ago

Fixed the issue. Image loading is now faster.