DownloadMediaItem function downloads a media item with the given media key from the camera.
mediakey: The unique media item key of the item to be downloaded.
cameraName: The camera name of the camera on which the function should be executed. If left empty, then the first connected camera is taken.
waitUntilFinished: If true then the function blocks until the camera returns the function result. If false, then the function immediately returns.
targetFilename: If set then the media item is saved to the target filename. If the target filename exists then it will be overwritten. If the target filename field is left empty then a new filename is automatically generated. On some systems such as Apple iOS, Windows RT, and OS X (App Store version only) this field is ignored due to system security restrictions. On Android the path must point to a writable location (e.g. SD cards on unrooted devices will NOT work). On mobile systems the downloaded media item is automatically added to the system gallery.
bool: DownloadMediaItem(int mediakey [, string cameraName = "", bool waitUntilFinished = false, string targetFilename = ""])
var result = DownloadMediaItem(1002323, "GoPro Hero 4", false, "c:/myimages/sample.jpg"); // downloads the media item with the key 1002323 from the camera and saves the result to // "c:/myimages/sample.jpg". // False is returned if the download fails, or if the key is invalid.