mirror of
https://github.com/badaix/snapcast.git
synced 2025-08-01 23:59:43 +02:00
x
git-svn-id: svn://elaine/murooma/trunk@220 d8a302eb-03bc-478d-80e4-98257eca68ef
This commit is contained in:
parent
06570569a9
commit
dc583513aa
7 changed files with 204 additions and 14 deletions
|
@ -1,13 +1,39 @@
|
|||
#ifndef OGG_ENCODER_H
|
||||
#define OGG_ENCODER_H
|
||||
#include "encoder.h"
|
||||
#include <vorbis/vorbisenc.h>
|
||||
|
||||
|
||||
class OggEncoder
|
||||
{
|
||||
public:
|
||||
OggEncoder();
|
||||
virtual void encode(Chunk* chunk);
|
||||
virtual bool encode(Chunk* chunk);
|
||||
|
||||
private:
|
||||
void init();
|
||||
|
||||
ogg_stream_state os; /* take physical pages, weld into a logical
|
||||
stream of packets */
|
||||
ogg_page og; /* one Ogg bitstream page. Vorbis packets are inside */
|
||||
ogg_packet op; /* one raw packet of data for decode */
|
||||
|
||||
vorbis_info vi; /* struct that stores all the static vorbis bitstream
|
||||
settings */
|
||||
vorbis_comment vc; /* struct that stores all the user comments */
|
||||
|
||||
vorbis_dsp_state vd; /* central working state for the packet->PCM decoder */
|
||||
vorbis_block vb; /* local working space for packet->PCM decode */
|
||||
|
||||
ogg_packet header;
|
||||
ogg_packet header_comm;
|
||||
ogg_packet header_code;
|
||||
|
||||
int eos=0,ret;
|
||||
int i, founddata;
|
||||
|
||||
int32_t tv_sec;
|
||||
int32_t tv_usec;
|
||||
};
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue