camera_roll_open_video()

Create and open a new video file on the camera roll for writing.

Synopsis:

#include <camera/camera_api.h>
 
camera_error_t camera_roll_open_video(camera_handle_t handle, int *fd, char *filename, int namelen, camera_roll_video_fmt_t fmt)

Arguments:

handle

The handle returned by a call to the camera_open() function.

fd

A pointer to the file descriptor. The pointer that is returned pointers an open video file on the camera roll.

filename

A pointer to returned name of the file on the camera roll. Ensure that the array pointed to by filename is at least of size CAMERA_ROLL_NAMELEN.

namelen

The size of the buffer provided by the caller as the filename. The maximum size is indicated by the value of CAMERA_ROLL_NAMELEN.

fmt

The video file format to create.

Library:

libcamapi

Description:

The camera roll is a directory on the device where the camera application saves files. The camera service manages unique filenames on behalf of the user.

After you successfully call this function, a file is created and opened for writing. To close the file, you must call the camera_roll_close_video() function.

Returns:

CAMERA_OK when the function successfully completes, otherwise another camera_error_t value that provides the reason that the call failed.