I'm using the Xamarin.Essentials.MediaPicker to choose images and video to "attach" to notes in my app. I would like these to be referenced locally so they can just open it whenever.
However for iOS, at least, it seems when I open and close the app the reference to the file is lost. Also PickPhotoAsync only has a relative reference to the file, so I cannot even view it using the absolute path because there is no absolute path.
According to this page:
... in the example code they save the image to the local CacheDirectory. I don't want to nor do I see a need to duplicate the file, as that is a waste of resources on the device (especially for video).
For Android this doesn't seem to be an issue. And for UWP it isn't an issue unless I want to play video using the MediaElement (from Xamarin CommunityToolkit).
My question is... do I need to save these files to the local CacheDirectory or is there something I'm missing?