mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-12-24 11:54:01 +00:00
beautification
This commit is contained in:
parent
244b5bfd2d
commit
b9982b375f
6
error.h
6
error.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: error.h,v 1.4 2003/02/26 19:20:26 mosu Exp $
|
||||
\version \$Id: error.h,v 1.5 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definitions for the error exception class
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -27,9 +27,9 @@
|
||||
#include "common.h"
|
||||
|
||||
class error_c {
|
||||
private:
|
||||
private:
|
||||
char *error;
|
||||
public:
|
||||
public:
|
||||
error_c(char *nerror) { error = strdup(nerror); if (!error) die("strdup"); };
|
||||
~error_c() { if (error) free(error); };
|
||||
char *get_error() { return error; };
|
||||
|
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: mp3_common.h,v 1.2 2003/02/16 17:04:38 mosu Exp $
|
||||
\version \$Id: mp3_common.h,v 1.3 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief helper functions for MP3 data
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -40,4 +40,4 @@ typedef struct {
|
||||
int find_mp3_header(char *buf, int size, unsigned long *_header);
|
||||
void decode_mp3_header(unsigned long header, mp3_header_t *h);
|
||||
|
||||
#endif
|
||||
#endif // __MP3_COMMON_H
|
||||
|
10
p_ac3.h
10
p_ac3.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: p_ac3.h,v 1.3 2003/02/26 19:20:26 mosu Exp $
|
||||
\version \$Id: p_ac3.h,v 1.4 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definition for the AC3 output module
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -26,7 +26,7 @@
|
||||
#include "ac3_common.h"
|
||||
|
||||
class ac3_packetizer_c: public q_c {
|
||||
private:
|
||||
private:
|
||||
u_int64_t bytes_output, packetno;
|
||||
unsigned long samples_per_sec;
|
||||
int channels;
|
||||
@ -36,7 +36,7 @@ class ac3_packetizer_c: public q_c {
|
||||
char *packet_buffer;
|
||||
int buffer_size;
|
||||
|
||||
public:
|
||||
public:
|
||||
ac3_packetizer_c(void *nprivate_data, int nprivate_size,
|
||||
unsigned long nsamples_per_sec, int nchannels,
|
||||
int nbitrate, audio_sync_t *nasync,
|
||||
@ -48,7 +48,7 @@ class ac3_packetizer_c: public q_c {
|
||||
|
||||
virtual void set_params(unsigned long nsamples_per_sec, int nchannels,
|
||||
int nbitrate);
|
||||
private:
|
||||
private:
|
||||
virtual void add_to_buffer(char *buf, int size);
|
||||
virtual char *get_ac3_packet(unsigned long *header,
|
||||
ac3_header_t *ac3header);
|
||||
@ -56,4 +56,4 @@ class ac3_packetizer_c: public q_c {
|
||||
virtual void remove_ac3_packet(int pos, int framesize);
|
||||
};
|
||||
|
||||
#endif // __P_AC3_h
|
||||
#endif // __P_AC3_H
|
||||
|
9
p_mp3.h
9
p_mp3.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: p_mp3.h,v 1.3 2003/02/26 19:20:26 mosu Exp $
|
||||
\version \$Id: p_mp3.h,v 1.4 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definition for the MP3 output module
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -26,7 +26,7 @@
|
||||
#include "mp3_common.h"
|
||||
|
||||
class mp3_packetizer_c: public q_c {
|
||||
private:
|
||||
private:
|
||||
u_int64_t bytes_output, packetno;
|
||||
unsigned long samples_per_sec;
|
||||
int channels;
|
||||
@ -37,7 +37,7 @@ class mp3_packetizer_c: public q_c {
|
||||
char *packet_buffer;
|
||||
int buffer_size;
|
||||
|
||||
public:
|
||||
public:
|
||||
mp3_packetizer_c(void *pr_data, int pd_size,
|
||||
unsigned long nsamples_per_sec, int nchannels,
|
||||
int nmp3rate, audio_sync_t *nasync,
|
||||
@ -46,7 +46,8 @@ class mp3_packetizer_c: public q_c {
|
||||
|
||||
virtual int process(char *buf, int size, int last_frame);
|
||||
virtual void set_header();
|
||||
private:
|
||||
|
||||
private:
|
||||
virtual void add_to_buffer(char *buf, int size);
|
||||
virtual char *get_mp3_packet(unsigned long *header,
|
||||
mp3_header_t *mp3header);
|
||||
|
8
p_pcm.h
8
p_pcm.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: p_pcm.h,v 1.2 2003/02/26 19:20:26 mosu Exp $
|
||||
\version \$Id: p_pcm.h,v 1.3 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definition for the PCM output module
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -25,7 +25,7 @@
|
||||
#include "queue.h"
|
||||
|
||||
class pcm_packetizer_c: public q_c {
|
||||
private:
|
||||
private:
|
||||
int packetno;
|
||||
int bps;
|
||||
u_int64_t bytes_output;
|
||||
@ -36,7 +36,7 @@ class pcm_packetizer_c: public q_c {
|
||||
audio_sync_t async;
|
||||
range_t range;
|
||||
|
||||
public:
|
||||
public:
|
||||
pcm_packetizer_c(void *nprivate_data, int nprivate_size,
|
||||
unsigned long nsamples_per_sec, int nchannels,
|
||||
int nbits_per_sample, audio_sync_t *nasync,
|
||||
@ -49,4 +49,4 @@ class pcm_packetizer_c: public q_c {
|
||||
|
||||
const int pcm_interleave = 16;
|
||||
|
||||
#endif
|
||||
#endif // __P_PCM_H
|
||||
|
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: p_video.h,v 1.4 2003/02/27 09:35:55 mosu Exp $
|
||||
\version \$Id: p_video.h,v 1.5 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definition for the video output module
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -36,6 +36,7 @@ private:
|
||||
u_int64_t last_id;
|
||||
packet_t *last_keyframe;
|
||||
cluster_helper_c *last_helper;
|
||||
|
||||
public:
|
||||
video_packetizer_c(void *, int, char *, double, int, int, int, int,
|
||||
audio_sync_t *, range_t *nrange, int) throw (error_c);
|
||||
@ -48,4 +49,4 @@ public:
|
||||
cluster_helper_c *helper);
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif // __P_VIDEO_H
|
||||
|
14
pr_generic.h
14
pr_generic.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: pr_generic.h,v 1.5 2003/02/27 09:35:55 mosu Exp $
|
||||
\version \$Id: pr_generic.h,v 1.6 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definition for the generic reader and packetizer
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -36,7 +36,7 @@ extern int track_number;
|
||||
|
||||
struct packet_t;
|
||||
|
||||
typedef class cluster_helper_c {
|
||||
class cluster_helper_c {
|
||||
private:
|
||||
int refcount;
|
||||
KaxCluster *cluster;
|
||||
@ -54,9 +54,9 @@ public:
|
||||
int get_packet_count();
|
||||
int release();
|
||||
KaxCluster &operator *();
|
||||
} cluster_helper_c;
|
||||
};
|
||||
|
||||
typedef class generic_packetizer_c {
|
||||
class generic_packetizer_c {
|
||||
protected:
|
||||
int serialno;
|
||||
void *private_data;
|
||||
@ -73,9 +73,9 @@ public:
|
||||
virtual void set_private_data(void *data, int size);
|
||||
virtual void added_packet_to_cluster(packet_t *packet,
|
||||
cluster_helper_c *helper);
|
||||
} generic_packetizer_c;
|
||||
};
|
||||
|
||||
typedef class generic_reader_c {
|
||||
class generic_reader_c {
|
||||
public:
|
||||
generic_reader_c();
|
||||
virtual ~generic_reader_c();
|
||||
@ -83,7 +83,7 @@ public:
|
||||
virtual packet_t *get_packet() = 0;
|
||||
virtual int display_priority() = 0;
|
||||
virtual void display_progress() = 0;
|
||||
} generic_reader_c;
|
||||
};
|
||||
|
||||
typedef struct packet_t {
|
||||
DataBuffer *data_buffer;
|
||||
|
6
queue.h
6
queue.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: queue.h,v 1.4 2003/02/26 19:20:26 mosu Exp $
|
||||
\version \$Id: queue.h,v 1.5 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definition for the queueing class
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -31,12 +31,12 @@ typedef struct q_page {
|
||||
} q_page_t;
|
||||
|
||||
class q_c: public generic_packetizer_c {
|
||||
private:
|
||||
private:
|
||||
u_int64_t id;
|
||||
struct q_page *first;
|
||||
struct q_page *current;
|
||||
|
||||
public:
|
||||
public:
|
||||
q_c() throw (error_c);
|
||||
virtual ~q_c();
|
||||
|
||||
|
8
r_ac3.h
8
r_ac3.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file r_avi.h
|
||||
\version \$Id: r_ac3.h,v 1.3 2003/02/26 19:20:26 mosu Exp $
|
||||
\version \$Id: r_ac3.h,v 1.4 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definitions for the AVI demultiplexer module
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -30,14 +30,14 @@
|
||||
#include "ac3_common.h"
|
||||
|
||||
class ac3_reader_c: public generic_reader_c {
|
||||
private:
|
||||
private:
|
||||
unsigned char *chunk;
|
||||
FILE *file;
|
||||
class ac3_packetizer_c *ac3packetizer;
|
||||
u_int64_t bytes_processed;
|
||||
u_int64_t size;
|
||||
|
||||
public:
|
||||
public:
|
||||
ac3_reader_c(char *fname, audio_sync_t *nasync, range_t *nrange)
|
||||
throw (error_c);
|
||||
virtual ~ac3_reader_c();
|
||||
@ -50,4 +50,4 @@ class ac3_reader_c: public generic_reader_c {
|
||||
static int probe_file(FILE *file, u_int64_t size);
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif // __R_AC3_H
|
||||
|
8
r_avi.h
8
r_avi.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file r_avi.h
|
||||
\version \$Id: r_avi.h,v 1.6 2003/02/26 19:20:26 mosu Exp $
|
||||
\version \$Id: r_avi.h,v 1.7 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definitions for the AVI demultiplexer module
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -46,7 +46,7 @@ typedef struct avi_demuxer_t {
|
||||
} avi_demuxer_t;
|
||||
|
||||
class avi_reader_c: public generic_reader_c {
|
||||
private:
|
||||
private:
|
||||
char *chunk;
|
||||
avi_t *avi;
|
||||
video_packetizer_c *vpacketizer;
|
||||
@ -64,7 +64,7 @@ class avi_reader_c: public generic_reader_c {
|
||||
int video_done, maxframes;
|
||||
int is_divx, rederive_keyframes;
|
||||
|
||||
public:
|
||||
public:
|
||||
avi_reader_c(char *fname, unsigned char *astreams,
|
||||
unsigned char *vstreams, audio_sync_t *nasync,
|
||||
range_t *nrange, char *nfourcc) throw (error_c);
|
||||
@ -77,7 +77,7 @@ class avi_reader_c: public generic_reader_c {
|
||||
|
||||
static int probe_file(FILE *file, u_int64_t size);
|
||||
|
||||
private:
|
||||
private:
|
||||
virtual int add_audio_demuxer(avi_t *avi, int aid);
|
||||
virtual int is_keyframe(unsigned char *data, long size,
|
||||
int suggestion);
|
||||
|
@ -27,13 +27,13 @@
|
||||
#include "p_textsubs.h"
|
||||
|
||||
class microdvd_reader_c: public generic_reader_c {
|
||||
private:
|
||||
private:
|
||||
char chunk[2048];
|
||||
FILE *file;
|
||||
textsubs_packetizer_c *textsubspacketizer;
|
||||
int act_wchar;
|
||||
|
||||
public:
|
||||
public:
|
||||
microdvd_reader_c(char *fname, audio_sync_t *nasync, range_t *nrange,
|
||||
char **ncomments) throw (error_c);
|
||||
virtual ~microdvd_reader_c();
|
||||
|
6
r_mp3.h
6
r_mp3.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: r_mp3.h,v 1.4 2003/02/26 19:20:26 mosu Exp $
|
||||
\version \$Id: r_mp3.h,v 1.5 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definitions for the MP3 reader module
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -30,14 +30,14 @@
|
||||
#include "p_mp3.h"
|
||||
|
||||
class mp3_reader_c: public generic_reader_c {
|
||||
private:
|
||||
private:
|
||||
unsigned char *chunk;
|
||||
FILE *file;
|
||||
class mp3_packetizer_c *mp3packetizer;
|
||||
u_int64_t bytes_processed;
|
||||
u_int64_t size;
|
||||
|
||||
public:
|
||||
public:
|
||||
mp3_reader_c(char *fname, audio_sync_t *nasync, range_t *nrange)
|
||||
throw (error_c);
|
||||
virtual ~mp3_reader_c();
|
||||
|
6
r_ogm.h
6
r_ogm.h
@ -44,7 +44,7 @@ typedef struct ogm_demuxer_t {
|
||||
} ogm_demuxer_t;
|
||||
|
||||
class ogm_reader_c: public generic_reader_c {
|
||||
private:
|
||||
private:
|
||||
ogg_sync_state oy;
|
||||
unsigned char *astreams, *vstreams, *tstreams;
|
||||
FILE *file;
|
||||
@ -58,7 +58,7 @@ class ogm_reader_c: public generic_reader_c {
|
||||
char *fourcc;
|
||||
int o_eos;
|
||||
|
||||
public:
|
||||
public:
|
||||
ogm_reader_c(char *fname, unsigned char *astreams,
|
||||
unsigned char *vstreams, unsigned char *tstreams,
|
||||
audio_sync_t *nasync, range_t *nrange, char **ncomments,
|
||||
@ -80,7 +80,7 @@ class ogm_reader_c: public generic_reader_c {
|
||||
|
||||
static int probe_file(FILE *file, u_int64_t size);
|
||||
|
||||
private:
|
||||
private:
|
||||
virtual ogm_demuxer_t *find_demuxer(int serialno);
|
||||
virtual int demuxing_requested(unsigned char *, int);
|
||||
virtual void flush_packetizers();
|
||||
|
4
r_srt.h
4
r_srt.h
@ -27,13 +27,13 @@
|
||||
#include "p_textsubs.h"
|
||||
|
||||
class srt_reader_c: public generic_reader_c {
|
||||
private:
|
||||
private:
|
||||
char chunk[2048];
|
||||
FILE *file;
|
||||
textsubs_packetizer_c *textsubspacketizer;
|
||||
int act_wchar;
|
||||
|
||||
public:
|
||||
public:
|
||||
srt_reader_c(char *fname, audio_sync_t *nasync, range_t *nrange,
|
||||
char **ncomments) throw (error_c);
|
||||
virtual ~srt_reader_c();
|
||||
|
@ -27,7 +27,7 @@
|
||||
#include "p_vobsub.h"
|
||||
|
||||
class vobsub_reader_c: public generic_reader_c {
|
||||
private:
|
||||
private:
|
||||
char chunk[2048];
|
||||
FILE *file, *subfile;
|
||||
vobsub_packetizer_c *vobsub_packetizer;
|
||||
@ -38,7 +38,7 @@ class vobsub_reader_c: public generic_reader_c {
|
||||
range_t range;
|
||||
char **comments;
|
||||
|
||||
public:
|
||||
public:
|
||||
vobsub_reader_c(char *fname, audio_sync_t *nasync, range_t *nrange,
|
||||
char **ncomments) throw (error_c);
|
||||
virtual ~vobsub_reader_c();
|
||||
@ -54,7 +54,8 @@ class vobsub_reader_c: public generic_reader_c {
|
||||
virtual void display_progress();
|
||||
|
||||
static int probe_file(FILE *file, u_int64_t size);
|
||||
private:
|
||||
|
||||
private:
|
||||
virtual void add_vobsub_packetizer(int width, int height,
|
||||
char *palette, int langidx,
|
||||
char *id, int index);
|
||||
|
6
r_wav.h
6
r_wav.h
@ -13,7 +13,7 @@
|
||||
|
||||
/*!
|
||||
\file
|
||||
\version \$Id: r_wav.h,v 1.3 2003/02/26 19:20:26 mosu Exp $
|
||||
\version \$Id: r_wav.h,v 1.4 2003/02/27 09:52:37 mosu Exp $
|
||||
\brief class definitions for the WAV reader module
|
||||
\author Moritz Bunkus <moritz @ bunkus.org>
|
||||
*/
|
||||
@ -34,7 +34,7 @@ extern "C" {
|
||||
}
|
||||
|
||||
class wav_reader_c: public generic_reader_c {
|
||||
private:
|
||||
private:
|
||||
unsigned char *chunk;
|
||||
FILE *file;
|
||||
class pcm_packetizer_c *pcmpacketizer;
|
||||
@ -42,7 +42,7 @@ class wav_reader_c: public generic_reader_c {
|
||||
struct wave_header wheader;
|
||||
u_int64_t bytes_processed;
|
||||
|
||||
public:
|
||||
public:
|
||||
wav_reader_c(char *fname, audio_sync_t *nasync, range_t *nrange)
|
||||
throw (error_c);
|
||||
virtual ~wav_reader_c();
|
||||
|
Loading…
Reference in New Issue
Block a user