Vegastrike 0.5.1 rc1  1.0
Original sources for Vegastrike Evolved
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
OpenALRenderableSource.h
Go to the documentation of this file.
1 //
2 // C++ Interface: Audio::OpenALRenderableSource
3 //
4 #ifndef __AUDIO_OPENALRENDERABLESOURCE_H__INCLUDED__
5 #define __AUDIO_OPENALRENDERABLESOURCE_H__INCLUDED__
6 
7 #include "al.h"
8 
9 #include "../../RenderableSource.h"
10 
11 #include "../../Exceptions.h"
12 #include "../../Types.h"
13 
14 namespace Audio {
15 
24  {
25  ALuint alSource;
26  bool alBuffersAttached;
27 
28  public:
30 
31  virtual ~OpenALRenderableSource();
32 
33  protected:
35  virtual void startPlayingImpl(Timestamp start) throw(Exception);
36 
38  virtual void stopPlayingImpl() throw(Exception);
39 
41  virtual bool isPlayingImpl() const throw(Exception);
42 
44  virtual Timestamp getPlayingTimeImpl() const throw(Exception);
45 
47  virtual void updateImpl(int flags, const Listener& sceneListener) throw(Exception);
48 
50  virtual void seekImpl(Timestamp time) throw(Exception);
51 
53  ALuint getALSource() const { return alSource; }
54 
58  void attachALBuffers() throw(Exception);
59  };
60 
61 };
62 
63 #endif//__AUDIO_OPENALRENDERABLESOURCE_H__INCLUDED__