In this PR, I added the functionality to use the camera, as well as pick an image from the device's gallery. The captured (or chosen, in the case of the gallery) is uploaded to Firebase Storage.
The naming semantics for uploading are as follows:
/users/{USER_UID}/shirts/{GENERATED_IMAGE_UID}
Note that shirts is constant at the moment. This will change with the integration of Cloud Vision, which will identify the garment. The {USER_UID} is the unique identifier of the logged in user that firebase gives us for free :) The generated_image_uid will just generate a random number in the form of a string. There might be some collisions (same file names), but with the scope of our project I do not think this will be an issue.
In this PR, I added the functionality to use the camera, as well as pick an image from the device's gallery. The captured (or chosen, in the case of the gallery) is uploaded to Firebase Storage.
The naming semantics for uploading are as follows: /users/{USER_UID}/shirts/{GENERATED_IMAGE_UID}
Note that shirts is constant at the moment. This will change with the integration of Cloud Vision, which will identify the garment. The {USER_UID} is the unique identifier of the logged in user that firebase gives us for free :) The generated_image_uid will just generate a random number in the form of a string. There might be some collisions (same file names), but with the scope of our project I do not think this will be an issue.