CAMOpen

Syntax

#include <cafe/camera/camera.h>

int CAMOpen(CAMHandle hCam);

Parameters

hCam Handle returned from CAMInit.

Return Values

A value of zero indicates success and any other value indicates the type of error that was encountered.

The following error codes can be returned.

CAMERA_ERROR_INVALID_HANDLE hCam handle is invalid.
CAMERA_ERROR_UNIINITIALIZED Camera driver has not been initialized by a successful CAMInit call.
CAMERA_ERROR_DEVICE_IN_USE A previous CAMOpen call has already started camera operation.
CAMERA_ERROR_UVD_FAILURE UVD decoder failed to open.
CAMERA_ERROR_DEVICE_NOT_READY Camera streaming could not be started; DRC may be detached.
CAMERA_ERROR_NONE No error.

Description

Calling this function will start the streaming of compressed video frames from the selected DRC's camera. Streaming continues until CAMClose is called. To get decompressed video frames, the application has to call CAMSubmitTargetSurface and wait for the CAMEventHandler callback.

NOTE:
The DRC screen briefly turns black when calling this function. This is a hardware specification and it is recommended to take action to anticipate this occurrence such as manually fading out to black.

Do Not Call From

Background Do not call this function from the background.
Interrupt handler Do not call this function from any interrupt handler.
Exception handler Do not call this function from any exception handler.

See Also

CAMHandle
CAMInit
CAMClose
CAMSubmitTargetSurface

Revision History

2013-05-08 Automated cleanup pass.
2012-08-02 Cleanup Pass.
2011-10-24 Initial version.


CONFIDENTIAL