dc1394/capture.h File Reference

Capture functions. More...

#include <dc1394/log.h>
#include <dc1394/video.h>

Defines

#define DC1394_CAPTURE_FLAGS_CHANNEL_ALLOC   0x00000001U

Enumerations

enum  dc1394capture_policy_t

Functions

dc1394error_t dc1394_capture_setup (dc1394camera_t *camera, uint32_t num_dma_buffers, uint32_t flags)
dc1394error_t dc1394_capture_stop (dc1394camera_t *camera)
int dc1394_capture_get_fileno (dc1394camera_t *camera)
dc1394error_t dc1394_capture_dequeue (dc1394camera_t *camera, dc1394capture_policy_t policy, dc1394video_frame_t **frame)
dc1394error_t dc1394_capture_enqueue (dc1394camera_t *camera, dc1394video_frame_t *frame)
dc1394bool_t dc1394_capture_is_frame_corrupt (dc1394camera_t *camera, dc1394video_frame_t *frame)

Detailed Description

Capture functions.

Author:
Damien Douxchamps: coding
Peter Antoniac: documentation maintainer

More details soon


Define Documentation

#define DC1394_CAPTURE_FLAGS_CHANNEL_ALLOC   0x00000001U

Capture flags. Currently limited to switching automatic functions on/off: channel allocation, bandwidth allocation and automatic starting of ISO transmission


Enumeration Type Documentation

The capture policy.

Can be blocking (wait for a frame forever) or polling (returns if no frames is in the ring buffer)


Function Documentation

dc1394error_t dc1394_capture_dequeue ( dc1394camera_t camera,
dc1394capture_policy_t  policy,
dc1394video_frame_t **  frame 
)

Captures a video frame. The returned struct contains the image buffer, among others. This image buffer SHALL NOT be freed, as it represents an area in the memory that belongs to the system.

dc1394error_t dc1394_capture_enqueue ( dc1394camera_t camera,
dc1394video_frame_t frame 
)

Returns a frame to the ring buffer once it has been used.

int dc1394_capture_get_fileno ( dc1394camera_t camera  ) 

Gets a file descriptor to be used for select(). Must be called after dc1394_capture_setup().

dc1394bool_t dc1394_capture_is_frame_corrupt ( dc1394camera_t camera,
dc1394video_frame_t frame 
)

Returns DC1394_TRUE if the given frame (previously dequeued) has been detected to be corrupt (missing data, corrupted data, overrun buffer, etc.). Note that certain types of corruption may go undetected in which case DC1394_FALSE will be returned. The ability to detect corruption also varies between platforms. Note that corrupt frames still need to be enqueued with dc1394_capture_enqueue() when no longer needed by the user.

dc1394error_t dc1394_capture_setup ( dc1394camera_t camera,
uint32_t  num_dma_buffers,
uint32_t  flags 
)

Setup the capture, using a ring buffer of a certain size (num_dma_buffers) and certain options (flags)

dc1394error_t dc1394_capture_stop ( dc1394camera_t camera  ) 

Stop the capture


Generated on 8 Jul 2010 for libdc1394 by  doxygen 1.6.1