FileDV Class Reference

#include <filedv.h>

Inherits FileBase.

Collaboration diagram for FileDV:

Collaboration graph
[legend]

Public Member Functions

 FileDV (Asset *asset, File *file)
 ~FileDV ()
int reset_parameters_derived ()
int open_file (int rd, int wr)
int close_file_derived ()
int64_t get_video_position ()
int64_t get_audio_position ()
int set_video_position (int64_t x)
int set_audio_position (int64_t x)
int audio_samples_copy (double **buffer, int64_t len)
int write_samples (double **buffer, int64_t len)
int write_frames (VFrame ***frames, int len)
int read_compressed_frame (VFrame *buffer)
int write_compressed_frame (VFrame *buffers)
int64_t compressed_frame_size ()
int read_samples (double *buffer, int64_t len)
int read_frame (VFrame *frame)
int colormodel_supported (int colormodel)
int can_copy_from (Edit *edit, int64_t position)
int get_audio_frame (int64_t pos)
int get_audio_offset (int64_t pos)

Static Public Member Functions

static void get_parameters (BC_WindowBase *parent_window, Asset *asset, BC_WindowBase *&format_window, int audio_options, int video_options)
static int check_sig (Asset *asset)
static int get_best_colormodel (Asset *asset, int driver)

Private Attributes

FILE * stream
Mutexstream_lock
Mutexdecoder_lock
Mutexvideo_position_lock
dv_decoder_t * decoder
dv_encoder_t * encoder
dv_encoder_t * audio_encoder
int64_t audio_position
int64_t video_position
unsigned char * video_buffer
unsigned char * audio_buffer
int16_t ** audio_sample_buffer
int audio_sample_buffer_start
int audio_sample_buffer_end
int audio_sample_buffer_len
int audio_sample_buffer_maxsize
int audio_frames_written
int output_size
int isPAL

Detailed Description

Definition at line 15 of file filedv.h.


Constructor & Destructor Documentation

FileDV::FileDV ( Asset asset,
File file 
)

FileDV::~FileDV (  ) 


Member Function Documentation

void FileDV::get_parameters ( BC_WindowBase parent_window,
Asset asset,
BC_WindowBase *&  format_window,
int  audio_options,
int  video_options 
) [static]

Definition at line 83 of file filedv.C.

References DVConfigVideo::create_objects(), DVConfigAudio::create_objects(), BC_WindowBase::run_window(), and window.

Referenced by File::get_options().

Here is the call graph for this function:

int FileDV::reset_parameters_derived (  )  [virtual]

int FileDV::open_file ( int  rd,
int  wr 
) [virtual]

int FileDV::check_sig ( Asset asset  )  [static]

Definition at line 320 of file filedv.C.

References fclose(), fopen(), fread(), and Asset::path.

Referenced by File::open_file().

Here is the call graph for this function:

int FileDV::close_file_derived (  )  [virtual]

Reimplemented from FileBase.

Definition at line 337 of file filedv.C.

References fclose(), and stream.

Here is the call graph for this function:

int64_t FileDV::get_video_position (  )  [virtual]

Reimplemented from FileBase.

Definition at line 345 of file filedv.C.

References video_position.

int64_t FileDV::get_audio_position (  )  [virtual]

Reimplemented from FileBase.

Definition at line 350 of file filedv.C.

References audio_position.

int FileDV::set_video_position ( int64_t  x  )  [virtual]

Reimplemented from FileBase.

Definition at line 355 of file filedv.C.

References video_position.

int FileDV::set_audio_position ( int64_t  x  )  [virtual]

Reimplemented from FileBase.

Definition at line 361 of file filedv.C.

References audio_position.

int FileDV::audio_samples_copy ( double **  buffer,
int64_t  len 
)

int FileDV::write_samples ( double **  buffer,
int64_t  len 
) [virtual]

int FileDV::write_frames ( VFrame ***  frames,
int  len 
) [virtual]

int FileDV::read_compressed_frame ( VFrame buffer  )  [virtual]

Reimplemented from FileBase.

Definition at line 674 of file filedv.C.

References eprintf, fread(), VFrame::get_data(), output_size, VFrame::set_compressed_size(), stream, and video_position.

Here is the call graph for this function:

int FileDV::write_compressed_frame ( VFrame buffers  )  [virtual]

Reimplemented from FileBase.

Definition at line 691 of file filedv.C.

References eprintf, fwrite(), VFrame::get_compressed_size(), VFrame::get_data(), output_size, stream, and video_position.

Here is the call graph for this function:

int64_t FileDV::compressed_frame_size (  )  [virtual]

Reimplemented from FileBase.

Definition at line 705 of file filedv.C.

References output_size.

int FileDV::read_samples ( double *  buffer,
int64_t  len 
) [virtual]

int FileDV::read_frame ( VFrame frame  )  [virtual]

int FileDV::colormodel_supported ( int  colormodel  )  [virtual]

Reimplemented from FileBase.

Definition at line 895 of file filedv.C.

int FileDV::can_copy_from ( Edit edit,
int64_t  position 
) [virtual]

Reimplemented from FileBase.

Definition at line 900 of file filedv.C.

References Edit::asset, Asset::format, FileBase::match4(), QUICKTIME_DV, QUICKTIME_DVCP, QUICKTIME_DVSD, and Asset::vcodec.

Here is the call graph for this function:

int FileDV::get_best_colormodel ( Asset asset,
int  driver 
) [static]

Definition at line 912 of file filedv.C.

References BC_COMPRESSED, BC_RGB888, BC_YUV422, and BC_YUV422P.

Referenced by File::get_best_colormodel().

int FileDV::get_audio_frame ( int64_t  pos  ) 

Definition at line 944 of file filedv.C.

References FileBase::asset, Asset::frame_rate, and Asset::sample_rate.

Referenced by get_audio_offset(), and read_samples().

int FileDV::get_audio_offset ( int64_t  pos  ) 

Definition at line 950 of file filedv.C.

References FileBase::asset, Asset::frame_rate, get_audio_frame(), and Asset::sample_rate.

Referenced by read_samples().

Here is the call graph for this function:


Field Documentation

FILE* FileDV::stream [private]

Definition at line 64 of file filedv.h.

Referenced by FileDV(), read_frame(), read_samples(), write_frames(), write_samples(), and ~FileDV().

Definition at line 65 of file filedv.h.

Referenced by FileDV(), read_frame(), read_samples(), and ~FileDV().

Definition at line 66 of file filedv.h.

Referenced by FileDV(), write_frames(), write_samples(), and ~FileDV().

dv_decoder_t* FileDV::decoder [private]

Definition at line 68 of file filedv.h.

Referenced by FileDV(), open_file(), read_frame(), read_samples(), reset_parameters_derived(), and ~FileDV().

dv_encoder_t* FileDV::encoder [private]

Definition at line 69 of file filedv.h.

Referenced by FileDV(), open_file(), reset_parameters_derived(), write_frames(), and ~FileDV().

dv_encoder_t* FileDV::audio_encoder [private]

Definition at line 70 of file filedv.h.

Referenced by FileDV(), open_file(), reset_parameters_derived(), write_samples(), and ~FileDV().

int64_t FileDV::audio_position [private]

int64_t FileDV::video_position [private]

unsigned char* FileDV::video_buffer [private]

Definition at line 75 of file filedv.h.

Referenced by FileDV(), open_file(), read_frame(), reset_parameters_derived(), write_frames(), and ~FileDV().

unsigned char* FileDV::audio_buffer [private]

int16_t** FileDV::audio_sample_buffer [private]

Definition at line 78 of file filedv.h.

Referenced by audio_samples_copy(), FileDV(), reset_parameters_derived(), write_samples(), and ~FileDV().

Definition at line 79 of file filedv.h.

Referenced by audio_samples_copy(), FileDV(), reset_parameters_derived(), and write_samples().

Definition at line 80 of file filedv.h.

Referenced by audio_samples_copy(), FileDV(), and reset_parameters_derived().

Definition at line 81 of file filedv.h.

Referenced by audio_samples_copy(), FileDV(), reset_parameters_derived(), and write_samples().

Definition at line 82 of file filedv.h.

Referenced by audio_samples_copy(), FileDV(), reset_parameters_derived(), and write_samples().

Definition at line 84 of file filedv.h.

Referenced by FileDV(), reset_parameters_derived(), and write_samples().

int FileDV::output_size [private]

int FileDV::isPAL [private]

Definition at line 87 of file filedv.h.

Referenced by open_file().


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

Generated on Mon Apr 28 14:24:57 2008 for Cinelerra by  doxygen 1.5.5