Adding Video Metadata
As we discussed in Chapter 9, Android's
MediaStore content provider has a portion,
MediaStore.Video, dedicated to video in addition to the portions for image and audio files and metadata that we have previously looked at.
When triggering the Camera application via an intent, the Uri to the newly recorded video file that is returned is a
content:// style Uri, which is used in combination with a content provider—in this case, the
MediaStore. In order to add additional metadata, we can use the Uri returned to update the video's record in the MediaStore.
As with any content provider, we use the
update method on a
ContentResolver object obtained from our Context. We pass in the
content:// style Uri and the new data in the form ...