ORKVideoCaptureStep Class Reference

Inherits from ORKStep : NSObject
Declared in ORKVideoCaptureStep.h

The ORKVideoCaptureStep class represents a step that captures a video through the device camera. A template image can optionally be laid over the camera preview to assist in properly capturing the video.

To use the video capture step, optionally set the templateImage and templateImageInsets properties, incorporate the step into a task, and present the task with a task view controller.

If implementing a video capture task like this one, remember that people will take your instructions literally. So be cautious. Make sure your template image is high contrast and very visible against a variety of backgrounds.

The recording length can be a max of 20 minutes. It defaults to 2 minutes.

  templateImage

An image to be displayed over the camera preview.

@property (nonatomic, strong) UIImage *templateImage

Discussion

The image is stretched to fit the available space while retaining its aspect ratio. When choosing a size for this asset, be sure to take into account the variations in device form factors.

Declared In

ORKVideoCaptureStep.h

  templateImageInsets

Insets to be used in positioning and sizing the templateImage.

@property (nonatomic) UIEdgeInsets templateImageInsets

Discussion

The insets are interpreted as percentages relative to the preview frame size. The left and right insets are relative to the width of the preview frame. The top and bottom insets are relative to the height of the preview frame.

Declared In

ORKVideoCaptureStep.h

  duration

The duration, in seconds, for the recording.

@property (nonatomic) NSNumber *duration

Discussion

The maximum that this can be set to is 20.0 minutes (60*20 seconds). The minimum that this can be set to is 0.01 minutes (1 second).

The default value is 2.0 minutes (60*2 seconds).

Declared In

ORKVideoCaptureStep.h

  audioMute

A Boolean indicating whether the audio is recorded or not.

@property (nonatomic, getter=isAudioMute) BOOL audioMute

Discussion

The default value is NO.

Declared In

ORKVideoCaptureStep.h

  flashMode

Constants indicating the mode of the flash on the receiver’s device, if it has one.

@property (nonatomic) AVCaptureFlashMode flashMode

Discussion

The default value is AVCaptureFlashModeOff (see AVCaptureFlashMode).

Declared In

ORKVideoCaptureStep.h

  devicePosition

Constants indicating the physical position of an AVCaptureDevice’s hardware on the system.

@property (nonatomic) AVCaptureDevicePosition devicePosition

Discussion

The default value is AVCaptureDevicePositionBack (see AVCaptureDevicePosition). If AVCaptureDevicePositionUnspecified is set, then it defaults to AVCaptureDevicePositionBack.

Declared In

ORKVideoCaptureStep.h

  accessibilityInstructions

An accessibility hint of the capture preview.

@property (nonatomic, copy) NSString *accessibilityInstructions

Discussion

This property can be used to specify accessible instructions for capturing the video. The use of this property can assist when the templateImage may not be visible to the user.

For example, if you want to capture a video of the user’s right hand, you may use a template image that displays the outline of the right hand. You may also want to set this property to a string such as @“Extend your right hand, palm side down, one foot from your device. Tap the Capture Video button, or two finger tap on the preview, to capture a video of your extended right hand.”

Declared In

ORKVideoCaptureStep.h

  accessibilityHint

An accessibility hint of the capture button.

@property (nonatomic, copy) NSString *accessibilityHint

Declared In

ORKVideoCaptureStep.h