Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members

RageSoundDriver_CA.h

Go to the documentation of this file.
00001 #ifndef RAGE_SOUND_DRIVER_CA_H 00002 #define RAGE_SOUND_DRIVER_CA_H 00003 00004 #include "RageSoundDriver_Generic_Software.h" 00005 00006 struct AudioTimeStamp; 00007 struct AudioBufferList; 00008 struct OpaqueAudioConverter; 00009 typedef struct OpaqueAudioConverter *AudioConverterRef; 00010 typedef unsigned long UInt32; 00011 typedef UInt32 AudioDeviceID; 00012 typedef UInt32 AudioDevicePropertyID; 00013 typedef unsigned char Boolean; 00014 typedef long OSStatus; 00015 class CAAudioHardwareDevice; 00016 class RageSoundBase; 00017 00018 class RageSound_CA : public RageSound_Generic_Software 00019 { 00020 private: 00021 int64_t mDecodePos; 00022 float mLatency; 00023 CAAudioHardwareDevice *mOutputDevice; 00024 AudioConverterRef mConverter; 00025 00026 static OSStatus GetData(AudioDeviceID inDevice, 00027 const AudioTimeStamp *inNow, 00028 const AudioBufferList *inInputData, 00029 const AudioTimeStamp *inInputTime, 00030 AudioBufferList *outOutputData, 00031 const AudioTimeStamp *inOutputTime, 00032 void *inClientData); 00033 00034 static OSStatus OverloadListener(AudioDeviceID inDevice, 00035 UInt32 inChannel, 00036 Boolean isInput, 00037 AudioDevicePropertyID inPropertyID, 00038 void *inData); 00039 00040 public: 00041 RageSound_CA(); 00042 CString Init(); 00043 ~RageSound_CA(); 00044 float GetPlayLatency() const { return mLatency; } 00045 int64_t GetPosition(const RageSoundBase *sound) const; 00046 void SetupDecodingThread(); 00047 }; 00048 00049 #define RAGE_SOUND_CA 00050 00051 #endif 00052 00053 /* 00054 * (c) 2004 Steve Checkoway 00055 * All rights reserved. 00056 * 00057 * Permission is hereby granted, free of charge, to any person obtaining a 00058 * copy of this software and associated documentation files (the 00059 * "Software"), to deal in the Software without restriction, including 00060 * without limitation the rights to use, copy, modify, merge, publish, 00061 * distribute, and/or sell copies of the Software, and to permit persons to 00062 * whom the Software is furnished to do so, provided that the above 00063 * copyright notice(s) and this permission notice appear in all copies of 00064 * the Software and that both the above copyright notice(s) and this 00065 * permission notice appear in supporting documentation. 00066 * 00067 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 00068 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 00069 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF 00070 * THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS 00071 * INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT 00072 * OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS 00073 * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR 00074 * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 00075 * PERFORMANCE OF THIS SOFTWARE. 00076 */

Generated on Thu Jan 27 20:57:28 2005 for StepMania by doxygen 1.3.7