PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | French EN
  • Taking photos with thumbnail
VideoGenerateThumbnail (Example)
Taking photos with thumbnail
This example is used to take photos and to generate a thumbnail.
Reminder: If photos must be used in Android applications, we advise you to work with miniatures and not with the initial photos taken by the device.
sImageFile is string
sThumbnail is string

// Takes a photo with the camera of the Android device
sImageFile = VideoStartApp(viVideoCapture)
IF sImageFile = "" THEN
Error("Unable to take the photo. ", ErrorInfo())
RETURN
END

// Generates a thumbnail from the photo taken by the device
// and displays the thumbnail in an Image control
sThumbnail = fExtractPath(sImageFile, fDrive + fDirectory + fFileName) + "_thumb.jpg"
IF VideoGenerateThumbnail(sImageFile, sThumbnail) = True THEN
IMG_Photo = sThumbnail
ELSE
Error("Unable to generate the thumbnail.", ErrorInfo())
END
Minimum version required
  • Version 17
Comments
Click [Add] to post a comment