VDeviceV4L Class Reference

#include <vdevicev4l.h>

Inherits VDeviceBase.

Collaboration diagram for VDeviceV4L:

Collaboration graph
[legend]

Public Member Functions

 VDeviceV4L (VideoDevice *device)
 ~VDeviceV4L ()
int initialize ()
int open_input ()
int close_all ()
int read_buffer (VFrame *frame)
int get_best_colormodel (Asset *asset)
int set_channel (Channel *channel)
int set_picture (PictureConfig *picture)

Private Member Functions

int set_cloexec_flag (int desc, int value)
int set_mute (int muted)
int v4l1_get_inputs ()
int v4l1_set_mute (int muted)
unsigned long translate_colormodel (int colormodel)
int v4l1_set_channel (Channel *channel)
int v4l1_get_norm (int norm)
int v4l1_set_picture (PictureConfig *picture)
void v4l1_start_capture ()
int capture_frame (int capture_frame_number)
int wait_v4l_frame ()
int read_v4l_frame (VFrame *frame)
int frame_to_vframe (VFrame *frame, unsigned char *input)
int next_frame (int previous_frame)
int close_v4l ()
int unmap_v4l_shmem ()
int v4l_init ()

Private Attributes

int input_fd
int output_fd
unsigned long device_colormodel
int colormodel
struct video_capability cap1
struct video_window window_params
struct video_picture picture_params
struct video_mbuf capture_params
char * capture_buffer
int capture_frame_number
int read_frame_number
int shared_memory
int initialization_complete
int got_first_frame

Detailed Description

Definition at line 8 of file vdevicev4l.h.


Constructor & Destructor Documentation

VDeviceV4L::VDeviceV4L ( VideoDevice device  ) 

Definition at line 28 of file vdevicev4l.C.

References initialize().

Here is the call graph for this function:

VDeviceV4L::~VDeviceV4L (  ) 

Definition at line 34 of file vdevicev4l.C.


Member Function Documentation

int VDeviceV4L::initialize (  ) 

int VDeviceV4L::open_input (  )  [virtual]

int VDeviceV4L::close_all (  )  [virtual]

Reimplemented from VDeviceBase.

Definition at line 75 of file vdevicev4l.C.

References close_v4l().

Here is the call graph for this function:

int VDeviceV4L::read_buffer ( VFrame frame  )  [virtual]

Reimplemented from VDeviceBase.

Definition at line 518 of file vdevicev4l.C.

References capture_buffer, capture_frame(), capture_frame_number, capture_params, got_first_frame, input_fd, next_frame(), read_v4l_frame(), SET_TRACE, shared_memory, v4l1_start_capture(), and wait_v4l_frame().

Here is the call graph for this function:

int VDeviceV4L::get_best_colormodel ( Asset asset  )  [virtual]

int VDeviceV4L::set_channel ( Channel channel  )  [virtual]

Reimplemented from VDeviceBase.

Definition at line 286 of file vdevicev4l.C.

References v4l1_set_channel().

Here is the call graph for this function:

int VDeviceV4L::set_picture ( PictureConfig picture  )  [virtual]

Reimplemented from VDeviceBase.

Definition at line 346 of file vdevicev4l.C.

References v4l1_set_picture().

Referenced by v4l_init().

Here is the call graph for this function:

int VDeviceV4L::set_cloexec_flag ( int  desc,
int  value 
) [private]

Definition at line 229 of file vdevicev4l.C.

Referenced by v4l_init().

int VDeviceV4L::set_mute ( int  muted  )  [private]

Definition at line 200 of file vdevicev4l.C.

References v4l1_set_mute().

Referenced by v4l_init().

Here is the call graph for this function:

int VDeviceV4L::v4l1_get_inputs (  )  [private]

Definition at line 175 of file vdevicev4l.C.

References ArrayList< TYPE >::append(), VDeviceBase::device, Channel::device_name, input_fd, VideoDevice::input_sources, and video_channel.

Referenced by open_input().

Here is the call graph for this function:

int VDeviceV4L::v4l1_set_mute ( int  muted  )  [private]

Definition at line 207 of file vdevicev4l.C.

References input_fd.

Referenced by set_mute().

unsigned long VDeviceV4L::translate_colormodel ( int  colormodel  )  [private]

Definition at line 270 of file vdevicev4l.C.

References BC_RGB888, BC_YUV411P, BC_YUV420P, BC_YUV422, and BC_YUV422P.

Referenced by get_best_colormodel().

int VDeviceV4L::v4l1_set_channel ( Channel channel  )  [private]

Definition at line 291 of file vdevicev4l.C.

References chanlists, Channel::entry, Channel::fine_tune, CHANLIST::freq, Channel::freqtable, Channel::input, input_fd, CHANLISTS::list, Channel::norm, v4l1_get_norm(), and video_channel.

Referenced by set_channel().

Here is the call graph for this function:

int VDeviceV4L::v4l1_get_norm ( int  norm  )  [private]

Definition at line 335 of file vdevicev4l.C.

References NTSC, PAL, and SECAM.

Referenced by v4l1_set_channel().

int VDeviceV4L::v4l1_set_picture ( PictureConfig picture  )  [private]

void VDeviceV4L::v4l1_start_capture (  )  [private]

Definition at line 162 of file vdevicev4l.C.

References capture_frame(), VideoInConfig::capture_length, capture_params, VDeviceBase::device, VideoDevice::in_config, and MIN.

Referenced by read_buffer().

Here is the call graph for this function:

int VDeviceV4L::capture_frame ( int  capture_frame_number  )  [private]

int VDeviceV4L::wait_v4l_frame (  )  [private]

Definition at line 392 of file vdevicev4l.C.

References capture_frame_number, and input_fd.

Referenced by read_buffer().

int VDeviceV4L::read_v4l_frame ( VFrame frame  )  [private]

Definition at line 401 of file vdevicev4l.C.

References capture_buffer, capture_frame_number, capture_params, and frame_to_vframe().

Referenced by read_buffer().

Here is the call graph for this function:

int VDeviceV4L::frame_to_vframe ( VFrame frame,
unsigned char *  input 
) [private]

int VDeviceV4L::next_frame ( int  previous_frame  )  [private]

int VDeviceV4L::close_v4l (  )  [private]

Definition at line 81 of file vdevicev4l.C.

References input_fd, and unmap_v4l_shmem().

Referenced by close_all().

Here is the call graph for this function:

int VDeviceV4L::unmap_v4l_shmem (  )  [private]

Definition at line 88 of file vdevicev4l.C.

References capture_buffer, capture_params, and shared_memory.

Referenced by close_v4l().

int VDeviceV4L::v4l_init (  )  [private]


Field Documentation

int VDeviceV4L::input_fd [private]

int VDeviceV4L::output_fd [private]

Definition at line 41 of file vdevicev4l.h.

unsigned long VDeviceV4L::device_colormodel [private]

Definition at line 43 of file vdevicev4l.h.

Referenced by capture_frame(), get_best_colormodel(), and v4l1_set_picture().

int VDeviceV4L::colormodel [private]

Definition at line 45 of file vdevicev4l.h.

Referenced by frame_to_vframe(), and get_best_colormodel().

struct video_capability VDeviceV4L::cap1 [read, private]

Definition at line 48 of file vdevicev4l.h.

struct video_window VDeviceV4L::window_params [read, private]

Definition at line 49 of file vdevicev4l.h.

Referenced by frame_to_vframe(), and v4l_init().

struct video_picture VDeviceV4L::picture_params [read, private]

Definition at line 50 of file vdevicev4l.h.

Referenced by v4l1_set_picture().

struct video_mbuf VDeviceV4L::capture_params [read, private]

char* VDeviceV4L::capture_buffer [private]

Definition at line 54 of file vdevicev4l.h.

Referenced by initialize(), read_buffer(), read_v4l_frame(), unmap_v4l_shmem(), and v4l_init().

Definition at line 55 of file vdevicev4l.h.

Referenced by initialize(), read_buffer(), read_v4l_frame(), v4l_init(), and wait_v4l_frame().

Definition at line 56 of file vdevicev4l.h.

Referenced by initialize().

Definition at line 57 of file vdevicev4l.h.

Referenced by initialize(), read_buffer(), unmap_v4l_shmem(), and v4l_init().

Definition at line 58 of file vdevicev4l.h.

Referenced by get_best_colormodel(), and initialize().

Definition at line 59 of file vdevicev4l.h.

Referenced by read_buffer(), and v4l_init().


The documentation for this class was generated from the following files:

Generated on Mon Apr 28 14:48:36 2008 for Cinelerra by  doxygen 1.5.5