Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/trunk/src/audio/AudioStream.h @ 811

Last change on this file since 811 was 790, checked in by nicolasc, 17 years ago

merged FICN back into trunk
awaiting release.

File size: 891 bytes
RevLine 
[673]1#ifndef _AudioStream_H__
2#define _AudioStream_H__
[410]3
4#include "AudioIncludes.h"
[729]5
6#include "AudioPrereqs.h"
[410]7
8namespace audio
9{
[677]10  #define BUFFER_SIZE (4096 * 4)
[423]11
[729]12  class _AudioExport AudioStream
[677]13  {
14    public:
[715]15      AudioStream(std::string path);
[677]16      void open();
17      void release();
18      void display();
19      bool playback();
20      bool playing();
21      bool update();
22      inline bool isLoaded() { return loaded; }
[430]23
[677]24    protected:
25      bool stream(ALuint buffer);
26      void empty();
27      void check();
[715]28      std::string errorString(int code);
[423]29
[677]30    private:
[715]31      std::string path;
[677]32
33      FILE*           oggFile;
34      OggVorbis_File  oggStream;
35      vorbis_info*    vorbisInfo;
36      vorbis_comment* vorbisComment;
37      bool loaded;
38
39      ALuint buffers[2];
40      ALuint source;
41      ALenum format;
42  };
[410]43}
44
[673]45#endif /* _AudioStream_H__ */
Note: See TracBrowser for help on using the repository browser.