PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
  • Save in image format
  • Use conditions:
  • Required permissions
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Saves the video currently transmitted by a "camera" as an image or a video sequence.
The formats in which the video is saved are:
  • Windows Mobile an image in JPEG format or a video sequence in ASF format.
  • Android an image in JPEG format or a video sequence. The format and quality of captured video depend on the default setting of device and they can differ between the different devices.
  • iPhone/iPad an image in JPEG format or a video sequence. The format and quality of captured video depend on the default setting of device and they can differ between the different devices.
AndroidiPhone/iPad Note: To directly get a photo or a video by using the native video application found on the device, use VideoStartApp.
Versions 16 and later
Android This function is now available for Android applications.
New in version 16
Android This function is now available for Android applications.
Android This function is now available for Android applications.
Versions 21 and later
iPhone/iPad This function is now available for iPhone/iPad applications.
New in version 21
iPhone/iPad This function is now available for iPhone/iPad applications.
iPhone/iPad This function is now available for iPhone/iPad applications.
Example
Syntax
<Result> = <Camera control>.Capture(<File to create> [, <Type of capture> [, <Capture duration> [, <Number of images per second> [, <Display during capture>]]]])
<Result>: Boolean
  • True if the video was successfully saved,
  • False otherwise. To find out the error details, use ErrorInfo.
<Camera control>: Control name
Name of Camera control to use.
<File to create>: Character string (with quotes)
Name and full (or relative) path of file to create.
Windows Mobile If an image is saved, a JPEG file is created. If a video sequence is saved, an ASF file is created.
Versions 16 and later
Android If an image is saved, a JPEG file is created. If a video sequence is saved, the format and quality of captured video depend on the default setting of device and they can differ between the different devices..
New in version 16
Android If an image is saved, a JPEG file is created. If a video sequence is saved, the format and quality of captured video depend on the default setting of device and they can differ between the different devices..
Android If an image is saved, a JPEG file is created. If a video sequence is saved, the format and quality of captured video depend on the default setting of device and they can differ between the different devices..
Caution: No UNC path can be used.
<Type of capture>: Optional integer constant
Type of capture:
viPictureCapture
Windows Mobile The capture is performed in a JPEG file.

Versions 16 and later
Android The capture is performed in a JPEG file.
New in version 16
Android The capture is performed in a JPEG file.
Android The capture is performed in a JPEG file.
viVideoCapture
(Default value)

Windows Mobile The capture is performed in ASF format.

Versions 16 and later
Android If a video sequence is saved, the format and quality of captured video depend on the default setting of device and they can differ between the different devices..
New in version 16
Android If a video sequence is saved, the format and quality of captured video depend on the default setting of device and they can differ between the different devices..
Android If a video sequence is saved, the format and quality of captured video depend on the default setting of device and they can differ between the different devices..
<Capture duration>: Optional integer
Duration of capture (in seconds). If this parameter is set to 0 or if it is not specified, the capture will stop:
  • during the call to <Camera>.Stop.
  • when the specified disk is full.
This parameter can correspond to:
  • an integer corresponding to the number of seconds,
  • a Duration variable,
  • Versions 23 and later
    the direct indication of duration (1 s or 10 ms for example).
    New in version 23
    the direct indication of duration (1 s or 10 ms for example).
    the direct indication of duration (1 s or 10 ms for example).
<Number of images per second>: Optional integer
Number of images saved per second (15 by default). This parameter is taken into account only if <Type of capture> is equal to viVideoCapture.
Windows Mobile This parameter is ignored.
<Display during capture>: Optional boolean
  • True (by default) if the video currently transmitted must be viewed in the specified Camera control,
  • False otherwise.
Versions 16 and later
AndroidiPhone/iPad This parameter is ignored. The video saved is always viewed in the Camera control.
New in version 16
AndroidiPhone/iPad This parameter is ignored. The video saved is always viewed in the Camera control.
AndroidiPhone/iPad This parameter is ignored. The video saved is always viewed in the Camera control.
Remarks

Save in image format

Only the image displayed when running <Camera>.Capture will be saved in BMP format. To save this image, you can also use:

Use conditions:

  • Windows Mobile This function requires a device that operates in Windows CE version 5.0 (or later) and that is equipped with a camera.
  • Versions 16 and later
    Android This function requires a device equipped with a camera. It can also be used during an execution in the Android emulator (for the capture of images only).
    New in version 16
    Android This function requires a device equipped with a camera. It can also be used during an execution in the Android emulator (for the capture of images only).
    Android This function requires a device equipped with a camera. It can also be used during an execution in the Android emulator (for the capture of images only).
  • Versions 17 and later
    Android The camera setting can be identified and modified by VideoParameter and VideoListParameter.
    New in version 17
    Android The camera setting can be identified and modified by VideoParameter and VideoListParameter.
    Android The camera setting can be identified and modified by VideoParameter and VideoListParameter.
Versions 16 and later
Android

Required permissions

The call to this function modifies the permissions required by the application.
Required permissions:
  • CAMERA: This permission allows the applications to access the camera.
  • RECORD_AUDIO: This permission allows the applications to record the sound.
New in version 16
Android

Required permissions

The call to this function modifies the permissions required by the application.
Required permissions:
  • CAMERA: This permission allows the applications to access the camera.
  • RECORD_AUDIO: This permission allows the applications to record the sound.
Android

Required permissions

The call to this function modifies the permissions required by the application.
Required permissions:
  • CAMERA: This permission allows the applications to access the camera.
  • RECORD_AUDIO: This permission allows the applications to record the sound.
Related Examples:
The Camera functions Unit examples (WINDEV Mobile): The Camera functions
[ + ] Using the WLanguage "Camera" functions to start the native video camera application of the device in order to record a video or to take a photo.
Android System Android (WINDEV Mobile): Android System
[ + ] This application is a tutorial example presenting some of the new features of WINDEV Mobile for Android.
The following system functions are used:
- NFC
- Multimedia control
- Brightness
- Volume
- WIFI
- Bluetooth
- Toast
- Progress Bar control
- 9-image mode
- Compass
- Accelerometer
- Camera control
- LED
- Vibrations
- Notifications
- Drawing functions
- Internet
Component : wd240obj.dll
Minimum version required
  • Version 23
This page is also available for…
Comments
video Capture
https://youtu.be/0sv8F0V0-gw
https://windevdesenvolvimento.blogspot.com/2019/09/dicas-2278-windev-webdev-mobile-camera.html
// BTN_TIRAr_FOTO
CAM_CAMERA.Capture("C:\TEMP\FOTO.JPEG",viPictureCapture,2)
IMG_FOTO="C:\TEMP\FOTO.JPEG"
amarildo
08 Sep. 2019
video Capture
https://youtu.be/i1x0L20j-u8
// BTN INICIA GRAVACAO
CAM_CAMERA.Capture("C:\temp\teste.mp4",viVideoCapture,0)
amarildo
29 Aug. 2019