Main Page   Modules   Class Hierarchy   Compound List   File List   Compound Members   File Members  

dec_ogg.h

Go to the documentation of this file.
00001 /* MuSE - Multiple Streaming Engine
00002  * Copyright (C) 2000-2002 Denis Roio aka jaromil <jaromil@dyne.org>
00003  *
00004  * This source code is free software; you can redistribute it and/or
00005  * modify it under the terms of the GNU Public License as published 
00006  * by the Free Software Foundation; either version 2 of the License,
00007  * or (at your option) any later version.
00008  *
00009  * This source code is distributed in the hope that it will be useful,
00010  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
00012  * Please refer to the GNU Public License for more details.
00013  *
00014  * You should have received a copy of the GNU Public License along with
00015  * this source code; if not, write to:
00016  * Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00017  *
00018  * "$Id: dec_ogg.h,v 1.4 2004/04/03 00:33:03 jaromil Exp $"
00019  *
00020  */
00021 
00027 #ifndef __IN_OGGVORBIS_H__
00028 #define __IN_OGGVORBIS_H__
00029 
00030 #include <config.h>
00031 #ifdef HAVE_VORBIS
00032 
00033 #include <decoder.h>
00034 
00035 /* oggvorbis lib */
00036 extern "C" {
00037 #include <ogg/ogg.h>
00038 #include <vorbis/codec.h>
00039 #include <vorbis/vorbisfile.h>
00040 }
00041 
00052 class MuseDecOgg: public MuseDec {
00053  private:
00054   OggVorbis_File   vf;
00055   vorbis_info      *vi;
00056   vorbis_comment   *vc;
00057 
00058   int current_section, old_section;
00059 
00060   FILE *oggfile;
00061 
00062   char _inbuf[IN_CHUNK+2];
00063 
00064  public:
00065   MuseDecOgg();
00066   ~MuseDecOgg();
00067 
00068   int load(char *file);
00069   bool seek(float pos);
00070 
00071   IN_DATATYPE *get_audio();
00072 
00073 };
00074 
00075 #endif /* HAVE VORBIS */
00076 #endif

Generated on Sat Apr 17 17:38:48 2004 for MuSE by doxygen1.3