2003-11-16 12:42:02 +00:00
|
|
|
/*
|
2004-12-15 21:12:35 +00:00
|
|
|
mkvmerge -- utility for splicing together matroska files
|
|
|
|
from component media subtypes
|
2005-01-12 15:03:47 +00:00
|
|
|
|
2004-12-15 21:12:35 +00:00
|
|
|
Distributed under the GPL
|
|
|
|
see the file COPYING for details
|
|
|
|
or visit http://www.gnu.org/copyleft/gpl.html
|
2005-01-12 15:03:47 +00:00
|
|
|
|
2004-12-15 21:12:35 +00:00
|
|
|
$Id$
|
2005-01-12 15:03:47 +00:00
|
|
|
|
2004-12-15 21:12:35 +00:00
|
|
|
class definition for the Flac packetizer
|
2005-01-12 15:03:47 +00:00
|
|
|
|
2004-12-15 21:12:35 +00:00
|
|
|
Written by Moritz Bunkus <moritz@bunkus.org>.
|
2004-12-15 21:38:48 +00:00
|
|
|
*/
|
2003-11-16 12:42:02 +00:00
|
|
|
|
|
|
|
#include "config.h"
|
|
|
|
|
|
|
|
#ifndef __P_FLAC_H
|
|
|
|
#define __P_FLAC_H
|
|
|
|
|
|
|
|
#include "os.h"
|
|
|
|
|
|
|
|
#if defined(HAVE_FLAC_FORMAT_H)
|
|
|
|
|
2004-07-26 18:17:16 +00:00
|
|
|
#include <FLAC/format.h>
|
|
|
|
|
2003-11-16 12:42:02 +00:00
|
|
|
#include "common.h"
|
|
|
|
#include "pr_generic.h"
|
2005-02-24 21:05:35 +00:00
|
|
|
#include "smart_pointers.h"
|
2003-11-16 12:42:02 +00:00
|
|
|
|
|
|
|
class flac_packetizer_c: public generic_packetizer_c {
|
|
|
|
private:
|
2005-10-09 09:55:53 +00:00
|
|
|
memory_cptr header;
|
2004-07-26 18:17:16 +00:00
|
|
|
int64_t num_packets;
|
|
|
|
FLAC__StreamMetadata_StreamInfo stream_info;
|
2003-11-16 12:42:02 +00:00
|
|
|
|
|
|
|
public:
|
2005-02-24 21:05:35 +00:00
|
|
|
flac_packetizer_c(generic_reader_c *_reader,
|
|
|
|
unsigned char *_header, int _l_header,
|
2005-02-24 14:19:32 +00:00
|
|
|
track_info_c &_ti) throw (error_c);
|
2003-11-16 12:42:02 +00:00
|
|
|
virtual ~flac_packetizer_c();
|
|
|
|
|
2005-05-25 21:31:26 +00:00
|
|
|
virtual int process(packet_cptr packet);
|
2003-11-16 12:42:02 +00:00
|
|
|
virtual void set_headers();
|
|
|
|
|
|
|
|
virtual void dump_debug_info();
|
2004-04-09 17:37:25 +00:00
|
|
|
|
|
|
|
virtual const char *get_format_name() {
|
|
|
|
return "Flac";
|
|
|
|
}
|
2005-03-02 15:53:34 +00:00
|
|
|
virtual connection_result_e can_connect_to(generic_packetizer_c *src,
|
|
|
|
string &error_message);
|
2003-11-16 12:42:02 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // HAVE_FLAC_STREAM_DECODER_H
|
|
|
|
#endif // __P_FLAC_H
|