Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

FileMOV Class Reference

#include <filemov.h>

Inheritance diagram for FileMOV:

FileBase List of all members.

Public Member Functions

 FileMOV (Asset *asset, File *file)
 ~FileMOV ()
int open_file (int rd, int wr)
int close_file ()
void asset_to_format ()
void format_to_asset ()
int64_t get_video_length ()
int64_t get_audio_length ()
int set_video_position (int64_t x)
int set_audio_position (int64_t x)
int write_samples (double **buffer, int64_t len)
int write_frames (VFrame ***frames, int len)
int64_t compressed_frame_size ()
int read_compressed_frame (VFrame *buffer)
int write_compressed_frame (VFrame *buffer)
int read_frame (VFrame *frame)
int read_samples (double *buffer, int64_t len)
int colormodel_supported (int colormodel)
int can_copy_from (Edit *edit, int64_t position)
void set_frame_start (int64_t offset)

Static Public Member Functions

static void get_parameters (BC_WindowBase *parent_window, Asset *asset, BC_WindowBase *&format_window, int audio_options, int video_options, int lock_compressor)
static int check_sig (Asset *asset)
static int get_best_colormodel (Asset *asset, int driver)
static char * strtocompression (char *string)
static char * compressiontostr (char *string)
static void fix_codecs (Asset *asset)

Private Member Functions

void new_audio_temp (int64_t len)
int read_raw (char *buffer, int64_t samples, int track)
int read_raw (VFrame *frame, float in_x1, float in_y1, float in_x2, float in_y2, float out_x1, float out_y1, float out_x2, float out_y2, int use_float, int interpolate)
int reset_parameters_derived ()

Private Attributes

int quicktime_atracks
int quicktime_vtracks
quicktime_t * fd
int depth
int64_t frames_correction
int64_t samples_correction
ArrayList< ThreadStruct * > threadframes
int total_threadframes
int current_threadframe
Mutex * threadframe_lock
FileMOVThread ** threads
char prefix_path [1024]
int suffix_number
float ** temp_float
int64_t temp_allocated

Friends

class FileMOVThread

Detailed Description

Definition at line 35 of file filemov.h.


Constructor & Destructor Documentation

FileMOV::FileMOV Asset asset,
File file
 

Definition at line 83 of file filemov.C.

FileMOV::~FileMOV  ) 
 

Definition at line 94 of file filemov.C.

References close_file(), and threadframe_lock.


Member Function Documentation

void FileMOV::asset_to_format  ) 
 

Definition at line 272 of file filemov.C.

References _, Asset::acodec, FileBase::asset, Asset::audio_data, Asset::bits, Asset::channels, depth, Asset::divx_bitrate, Asset::divx_fix_bitrate, Asset::divx_max_key_interval, Asset::divx_max_quantizer, Asset::divx_min_quantizer, Asset::divx_quality, Asset::divx_quantizer, Asset::divx_rc_period, Asset::divx_rc_reaction_period, Asset::divx_rc_reaction_ratio, fd, fix_codecs(), Asset::format, Asset::frame_rate, Asset::h264_bitrate, Asset::h264_fix_bitrate, Asset::h264_quantizer, Asset::height, Asset::jpeg_quality, Asset::layers, Asset::mp3_bitrate, Asset::mp4a_bitrate, Asset::ms_bitrate, Asset::ms_bitrate_tolerance, Asset::ms_fix_bitrate, Asset::ms_gop_size, Asset::ms_interlaced, Asset::ms_quantization, quicktime_atracks, quicktime_vtracks, Asset::sample_rate, Asset::vcodec, Asset::video_data, Asset::vorbis_bitrate, Asset::vorbis_max_bitrate, Asset::vorbis_min_bitrate, Asset::vorbis_vbr, Asset::width, and FileBase::wr.

Referenced by open_file().

int FileMOV::can_copy_from Edit edit,
int64_t  position
[virtual]
 

Reimplemented from FileBase.

Definition at line 498 of file filemov.C.

References Edit::asset, fd, Asset::format, FileBase::match4(), and Asset::vcodec.

int FileMOV::check_sig Asset asset  )  [static]
 

Definition at line 146 of file filemov.C.

References Asset::path.

Referenced by File::open_file().

int FileMOV::close_file  )  [virtual]
 

Reimplemented from FileBase.

Definition at line 228 of file filemov.C.

References FileBase::asset, Asset::channels, FileBase::close_file(), File::cpus, fd, FileBase::file, Asset::frame_rate, FileBase::reset_parameters(), FileMOVThread::stop_encoding(), temp_float, threadframes, threads, and FileBase::wr.

Referenced by ~FileMOV().

int FileMOV::colormodel_supported int  colormodel  )  [virtual]
 

Reimplemented from FileBase.

Definition at line 417 of file filemov.C.

int64_t FileMOV::compressed_frame_size  )  [virtual]
 

Reimplemented from FileBase.

Definition at line 960 of file filemov.C.

References File::current_frame, File::current_layer, fd, and FileBase::file.

char * FileMOV::compressiontostr char *  string  )  [static]
 

Definition at line 1105 of file filemov.C.

References _, DIV3_NAME, DIVX_NAME, DV_NAME, H263_NAME, H264_NAME, HV60_NAME, HV64_NAME, IMA4_NAME, FileBase::match4(), MJPA_NAME, MP3_NAME, MP4A_NAME, MP4V_NAME, PNGA_NAME, QTJPEG_NAME, RAW_NAME, RGB_NAME, RGBA_NAME, TWOS_NAME, ULAW_NAME, VORBIS_NAME, YUV411_NAME, YUV420_NAME, YUV422_NAME, YUV444_10BIT_NAME, YUV444_NAME, and YUVA4444_NAME.

Referenced by RecordGUI::create_objects(), and MOVConfigVideo::create_objects().

void FileMOV::fix_codecs Asset asset  )  [static]
 

Definition at line 129 of file filemov.C.

Referenced by asset_to_format(), and get_parameters().

void FileMOV::format_to_asset  ) 
 

Definition at line 376 of file filemov.C.

References Asset::acodec, FileBase::asset, Asset::audio_data, Asset::audio_length, Asset::bits, Asset::channels, depth, fd, Asset::format, Asset::frame_rate, Asset::height, Asset::interlace_mode, Asset::layers, Asset::sample_rate, Asset::vcodec, Asset::video_data, Asset::video_length, and Asset::width.

Referenced by open_file().

int64_t FileMOV::get_audio_length  ) 
 

Definition at line 537 of file filemov.C.

References fd, and samples_correction.

int FileMOV::get_best_colormodel Asset asset,
int  driver
[static]
 

Definition at line 422 of file filemov.C.

References FileBase::match4(), and Asset::vcodec.

Referenced by File::get_best_colormodel().

void FileMOV::get_parameters BC_WindowBase *  parent_window,
Asset asset,
BC_WindowBase *&  format_window,
int  audio_options,
int  video_options,
int  lock_compressor
[static]
 

Definition at line 100 of file filemov.C.

References MOVConfigVideo::create_objects(), MOVConfigAudio::create_objects(), and fix_codecs().

Referenced by File::get_options().

int64_t FileMOV::get_video_length  ) 
 

void FileMOV::new_audio_temp int64_t  len  )  [private]
 

Definition at line 567 of file filemov.C.

References FileBase::asset, Asset::channels, temp_allocated, and temp_float.

Referenced by read_samples(), and write_samples().

int FileMOV::open_file int  rd,
int  wr
[virtual]
 

Reimplemented from FileBase.

Definition at line 169 of file filemov.C.

References _, FileBase::asset, asset_to_format(), File::cpus, Asset::divx_use_deblocking, fd, FileBase::file, format_to_asset(), FileBase::match4(), Asset::path, prefix_path, read_frame(), set_video_position(), suffix_number, Asset::tcstart, and Asset::vcodec.

int FileMOV::read_compressed_frame VFrame *  buffer  )  [virtual]
 

Reimplemented from FileBase.

Definition at line 966 of file filemov.C.

References File::current_frame, File::current_layer, fd, and FileBase::file.

int FileMOV::read_frame VFrame *  frame  )  [virtual]
 

Reimplemented from FileBase.

Definition at line 908 of file filemov.C.

References File::current_frame, File::current_layer, fd, and FileBase::file.

Referenced by open_file().

int FileMOV::read_raw VFrame *  frame,
float  in_x1,
float  in_y1,
float  in_x2,
float  in_y2,
float  out_x1,
float  out_y1,
float  out_x2,
float  out_y2,
int  use_float,
int  interpolate
[private]
 

Definition at line 994 of file filemov.C.

References File::current_frame, File::current_layer, fd, and FileBase::file.

int FileMOV::read_raw char *  buffer,
int64_t  samples,
int  track
[private]
 

int FileMOV::read_samples double *  buffer,
int64_t  len
[virtual]
 

Reimplemented from FileBase.

Definition at line 1030 of file filemov.C.

References File::current_channel, fd, FileBase::file, new_audio_temp(), and temp_float.

int FileMOV::reset_parameters_derived  )  [private, virtual]
 

Reimplemented from FileBase.

Definition at line 152 of file filemov.C.

References depth, fd, frames_correction, FileBase::prev_track, quicktime_atracks, quicktime_vtracks, samples_correction, temp_allocated, temp_float, and threads.

int FileMOV::set_audio_position int64_t  x  )  [virtual]
 

Reimplemented from FileBase.

Definition at line 545 of file filemov.C.

References FileBase::asset, Asset::audio_length, and fd.

void FileMOV::set_frame_start int64_t  offset  ) 
 

Definition at line 267 of file filemov.C.

References fd.

int FileMOV::set_video_position int64_t  x  )  [virtual]
 

Reimplemented from FileBase.

Definition at line 555 of file filemov.C.

References FileBase::asset, File::current_layer, fd, FileBase::file, and Asset::video_length.

Referenced by open_file().

char * FileMOV::strtocompression char *  string  )  [static]
 

Definition at line 1068 of file filemov.C.

References _, DIV3_NAME, DIVX_NAME, DV_NAME, H263_NAME, H264_NAME, HV60_NAME, HV64_NAME, IMA4_NAME, MJPA_NAME, MP3_NAME, MP4A_NAME, MP4V_NAME, PNG_NAME, PNGA_NAME, QTJPEG_NAME, RAW_NAME, RGB_NAME, RGBA_NAME, TWOS_NAME, ULAW_NAME, VORBIS_NAME, YUV411_NAME, YUV420_NAME, YUV422_NAME, YUV444_10BIT_NAME, YUV444_NAME, and YUVA4444_NAME.

Referenced by MOVConfigVideoPopup::handle_event(), and MOVConfigAudioPopup::handle_event().

int FileMOV::write_compressed_frame VFrame *  buffer  )  [virtual]
 

Reimplemented from FileBase.

Definition at line 980 of file filemov.C.

References File::current_layer, fd, and FileBase::file.

int FileMOV::write_frames VFrame ***  frames,
int  len
[virtual]
 

Reimplemented from FileBase.

Definition at line 636 of file filemov.C.

References FileBase::asset, File::cpus, File::current_frame, current_threadframe, FileMOVThread::encode_buffer(), fd, FileBase::file, FileMOVThread, Asset::format, Asset::frame_rate, Asset::height, Asset::layers, FileBase::match4(), FileMOVThread::start_encoding(), threadframes, threads, total_threadframes, Asset::vcodec, and Asset::width.

int FileMOV::write_samples double **  buffer,
int64_t  len
[virtual]
 

Reimplemented from FileBase.

Definition at line 588 of file filemov.C.

References FileBase::asset, Asset::channels, fd, new_audio_temp(), Asset::sample_rate, and temp_float.


Friends And Related Function Documentation

friend class FileMOVThread [friend]
 

Definition at line 41 of file filemov.h.

Referenced by write_frames().


Member Data Documentation

int FileMOV::current_threadframe [private]
 

Definition at line 104 of file filemov.h.

Referenced by FileMOVThread::run(), and write_frames().

int FileMOV::depth [private]
 

Definition at line 96 of file filemov.h.

Referenced by asset_to_format(), format_to_asset(), and reset_parameters_derived().

quicktime_t* FileMOV::fd [private]
 

Definition at line 95 of file filemov.h.

Referenced by asset_to_format(), can_copy_from(), close_file(), compressed_frame_size(), format_to_asset(), get_audio_length(), open_file(), read_compressed_frame(), read_frame(), read_raw(), read_samples(), reset_parameters_derived(), set_audio_position(), set_frame_start(), set_video_position(), write_compressed_frame(), write_frames(), and write_samples().

int64_t FileMOV::frames_correction [private]
 

Definition at line 97 of file filemov.h.

Referenced by reset_parameters_derived().

char FileMOV::prefix_path[1024] [private]
 

Definition at line 108 of file filemov.h.

Referenced by open_file().

int FileMOV::quicktime_atracks [private]
 

Definition at line 92 of file filemov.h.

Referenced by asset_to_format(), and reset_parameters_derived().

int FileMOV::quicktime_vtracks [private]
 

Definition at line 93 of file filemov.h.

Referenced by asset_to_format(), and reset_parameters_derived().

int64_t FileMOV::samples_correction [private]
 

Definition at line 98 of file filemov.h.

Referenced by get_audio_length(), and reset_parameters_derived().

int FileMOV::suffix_number [private]
 

Definition at line 109 of file filemov.h.

Referenced by open_file().

int64_t FileMOV::temp_allocated [private]
 

Definition at line 113 of file filemov.h.

Referenced by new_audio_temp(), and reset_parameters_derived().

float** FileMOV::temp_float [private]
 

Definition at line 112 of file filemov.h.

Referenced by close_file(), new_audio_temp(), read_samples(), reset_parameters_derived(), and write_samples().

Mutex* FileMOV::threadframe_lock [private]
 

Definition at line 105 of file filemov.h.

Referenced by FileMOVThread::run(), and ~FileMOV().

ArrayList<ThreadStruct*> FileMOV::threadframes [private]
 

Definition at line 101 of file filemov.h.

Referenced by close_file(), FileMOVThread::run(), and write_frames().

FileMOVThread** FileMOV::threads [private]
 

Definition at line 107 of file filemov.h.

Referenced by close_file(), reset_parameters_derived(), and write_frames().

int FileMOV::total_threadframes [private]
 

Definition at line 103 of file filemov.h.

Referenced by FileMOVThread::run(), and write_frames().


The documentation for this class was generated from the following files:
Generated on Sun Jan 8 13:39:14 2006 for Cinelerra-svn by  doxygen 1.4.4