* Update C# binding
* Update IAudioManager simplify the playback of 2D/3D audio
This commit is contained in:
parent
cf79cb7dc1
commit
3e6ad2abe0
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -54,6 +54,16 @@ int main(int argc, char* argv[]) {
|
|||
#else
|
||||
cAudio::IAudioSource* mysound = manager->create("bling", AUDIO_FILE(cAudioTheme1.ogg),true);
|
||||
#endif
|
||||
|
||||
for (size_t i=0; i<10; i++)
|
||||
{
|
||||
#ifdef CAUDIO_PLATFORM_WIN
|
||||
manager->play2D(AUDIO_FILE("bling.ogg"));
|
||||
#else
|
||||
manager->play2D(AUDIO_FILE(bling.ogg));
|
||||
#endif
|
||||
}
|
||||
|
||||
if(mysound)
|
||||
{
|
||||
mysound->setVolume(0.5);
|
||||
|
@ -66,8 +76,6 @@ int main(int argc, char* argv[]) {
|
|||
|
||||
}
|
||||
|
||||
//Delete all IAudio sounds
|
||||
manager->releaseAllSources();
|
||||
//Shutdown cAudio
|
||||
manager->shutDown();
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ namespace cAudio
|
|||
ON_DATASOURCEREGISTER,
|
||||
};
|
||||
|
||||
cAudioManager() : AudioThread(NULL), AudioContext(NULL), Initialized(false) { }
|
||||
cAudioManager() : AudioThread(NULL), AudioContext(NULL), Initialized(false), MasterVolume(1.0f) { }
|
||||
virtual ~cAudioManager();
|
||||
|
||||
virtual bool initialize(const char* deviceName = 0x0, int outputFrequency = -1, int eaxEffectSlots = 4);
|
||||
|
@ -41,6 +41,13 @@ namespace cAudio
|
|||
virtual void releaseAllSources();
|
||||
virtual void release(IAudioSource* source);
|
||||
|
||||
virtual IAudioSource* play2D(const char* filename, bool playLooped = false, bool startPaused = false);
|
||||
virtual IAudioSource* play3D(const char* filename, cVector3 position, bool playLooped = false, bool startPaused = false);
|
||||
|
||||
virtual void setMasterVolume(float vol);
|
||||
virtual float getMasterVolume() const;
|
||||
virtual void stopAllSounds();
|
||||
|
||||
virtual IAudioSource* create(const char* name, const char* filename, bool stream = false);
|
||||
virtual IAudioSource* createFromMemory(const char* name, const char* data, size_t length, const char* extension);
|
||||
virtual IAudioSource* createFromRaw(const char* name, const char* data, size_t length, unsigned int frequency, AudioFormats format);
|
||||
|
@ -86,11 +93,17 @@ namespace cAudio
|
|||
|
||||
IAudioDeviceContext* AudioContext;
|
||||
|
||||
float MasterVolume;
|
||||
|
||||
//! Holds an index for fast searching of audio sources by name
|
||||
cAudioMap<cAudioString, IAudioSource*>::Type audioIndex;
|
||||
typedef cAudioMap<cAudioString, IAudioSource*>::Type::iterator audioIndexIterator;
|
||||
//! Holds all managed audio sources
|
||||
cAudioVector<IAudioSource*>::Type audioSources;
|
||||
//! Holds audio sources which gets deleted from the audioManager
|
||||
cAudioVector<IAudioSource*>::Type managedAudioSources;
|
||||
//! Holds audio sources which gets deleted from the audioManager
|
||||
cAudioVector<IAudioSource*>::Type managedAudioSourcesDelBuffer;
|
||||
//! Decoder map that holds all decoders by file extension
|
||||
cAudioMap<cAudioString, IAudioDecoderFactory*>::Type decodermap;
|
||||
typedef cAudioMap<cAudioString, IAudioDecoderFactory*>::Type::iterator decodermapIterator;
|
||||
|
|
|
@ -58,6 +58,39 @@ namespace cAudio
|
|||
/** \param source: Pointer to the source to release. */
|
||||
virtual void release(IAudioSource* source) = 0;
|
||||
|
||||
//! Creates an Audio Source object using the highest priority data source that has the referenced filename
|
||||
/**
|
||||
\param name: Name of the audio source.
|
||||
\param playLooped: if the sound is looped a IAudioSource is returned
|
||||
\param startPaused: if false the sound plays asap
|
||||
\return A pointer to an Audio Source or NULL if creation failed.
|
||||
*/
|
||||
virtual IAudioSource* play2D(const char* filename,
|
||||
bool playLooped = false,
|
||||
bool startPaused = false) = 0;
|
||||
|
||||
//! Creates an Audio Source object using the highest priority data source that has the referenced filename
|
||||
/**
|
||||
\param name: Name of the audio source.
|
||||
\param position: The start position of the sound.
|
||||
\param playLooped: if the sound is looped a IAudioSource is returned
|
||||
\param startPaused: if false the sound plays asap
|
||||
\return A pointer to an Audio Source or NULL if creation failed.
|
||||
*/
|
||||
virtual IAudioSource* play3D(const char* filename,
|
||||
cVector3 position,
|
||||
bool playLooped = false,
|
||||
bool startPaused = false) = 0;
|
||||
|
||||
//! Sets master volume. (valid range [0 - 1.0])
|
||||
virtual void setMasterVolume(float vol) = 0;
|
||||
|
||||
//! Get the master volume.
|
||||
virtual float getMasterVolume() const = 0;
|
||||
|
||||
//! Stops all playing sounds.
|
||||
virtual void stopAllSounds() = 0;
|
||||
|
||||
//! Creates an Audio Source object using the highest priority data source that has the referenced filename
|
||||
/**
|
||||
\param name: Name of the audio source.
|
||||
|
|
|
@ -33,7 +33,7 @@ namespace cAudio
|
|||
# define cfopen fopen
|
||||
#endif
|
||||
|
||||
#if CAUDIO_REROUTE_STL_ALLOCATIONS == 1
|
||||
#if CAUDIO_REROUTE_STRING_ALLOCATIONS == 1
|
||||
typedef std::basic_string< cAudioChar, std::char_traits<cAudioChar>, cSTLAllocator<cAudioChar> > cAudioString;
|
||||
#else
|
||||
//typedef std::string cAudioString;
|
||||
|
|
|
@ -80,7 +80,7 @@ namespace cAudio
|
|||
{
|
||||
cAudioMutexBasicLock lock(Mutex);
|
||||
size_t count = audioSources.size();
|
||||
for(unsigned int i=0; i<count; i++)
|
||||
for(size_t i=0; i<count; i++)
|
||||
{
|
||||
IAudioSource* source = audioSources[i];
|
||||
if (source->isValid())
|
||||
|
@ -88,6 +88,36 @@ namespace cAudio
|
|||
source->update();
|
||||
}
|
||||
}
|
||||
|
||||
if (!managedAudioSources.empty())
|
||||
{
|
||||
count = managedAudioSources.size();
|
||||
for(size_t i=0; i<count; i++)
|
||||
{
|
||||
IAudioSource* source = managedAudioSources[i];
|
||||
if (source->isValid())
|
||||
{
|
||||
source->update();
|
||||
if (source->isStopped())
|
||||
{
|
||||
managedAudioSourcesDelBuffer.push_back(source);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
count = managedAudioSourcesDelBuffer.size();
|
||||
for(size_t i=0; i<count; i++)
|
||||
{
|
||||
IAudioSource* source = managedAudioSourcesDelBuffer[i];
|
||||
cAudioVector<IAudioSource*>::Type::iterator it = std::find(managedAudioSources.begin(), managedAudioSources.end(), source);
|
||||
if (it != managedAudioSources.end())
|
||||
{
|
||||
managedAudioSources.erase(it);
|
||||
CAUDIO_DELETE source;
|
||||
}
|
||||
}
|
||||
managedAudioSourcesDelBuffer.clear();
|
||||
}
|
||||
}
|
||||
|
||||
void cAudioManager::run()
|
||||
|
@ -114,6 +144,84 @@ namespace cAudio
|
|||
}
|
||||
#endif
|
||||
|
||||
IAudioSource* cAudioManager::play2D(const char* filename, bool playLooped, bool startPaused)
|
||||
{
|
||||
cAudioMutexBasicLock lock(Mutex);
|
||||
IAudioSource* pAudioSrc = create("", filename, true);
|
||||
|
||||
if (!playLooped && !startPaused)
|
||||
{
|
||||
cAudioVector<IAudioSource*>::Type::iterator it = std::find(audioSources.begin(), audioSources.end(), pAudioSrc);
|
||||
if (it != audioSources.end())
|
||||
{
|
||||
audioSources.erase(it);
|
||||
}
|
||||
managedAudioSources.push_back(pAudioSrc);
|
||||
|
||||
pAudioSrc->play2d();
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (playLooped && !startPaused)
|
||||
{
|
||||
pAudioSrc->play2d(true);
|
||||
}
|
||||
|
||||
return pAudioSrc;
|
||||
}
|
||||
|
||||
IAudioSource* cAudioManager::play3D(const char* filename, cVector3 position, bool playLooped, bool startPaused)
|
||||
{
|
||||
cAudioMutexBasicLock lock(Mutex);
|
||||
IAudioSource* pAudioSrc = create("", filename, true);
|
||||
|
||||
if (!playLooped && !startPaused)
|
||||
{
|
||||
cAudioVector<IAudioSource*>::Type::iterator it = std::find(audioSources.begin(), audioSources.end(), pAudioSrc);
|
||||
if (it != audioSources.end())
|
||||
{
|
||||
audioSources.erase(it);
|
||||
}
|
||||
managedAudioSources.push_back(pAudioSrc);
|
||||
|
||||
pAudioSrc->play3d(position);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (playLooped && !startPaused)
|
||||
{
|
||||
pAudioSrc->play3d(position, 1.0, true);
|
||||
}
|
||||
|
||||
return pAudioSrc;
|
||||
}
|
||||
|
||||
void cAudioManager::setMasterVolume(float vol)
|
||||
{
|
||||
cAudioMutexBasicLock lock(Mutex);
|
||||
size_t count = audioSources.size();
|
||||
for(size_t i=0; i<count; i++)
|
||||
{
|
||||
audioSources[i]->setVolume(MasterVolume * audioSources[i]->getVolume());
|
||||
}
|
||||
}
|
||||
|
||||
float cAudioManager::getMasterVolume() const
|
||||
{
|
||||
return MasterVolume;
|
||||
}
|
||||
|
||||
void cAudioManager::stopAllSounds()
|
||||
{
|
||||
cAudioMutexBasicLock lock(Mutex);
|
||||
size_t count = audioSources.size();
|
||||
for(size_t i=0; i<count; i++)
|
||||
{
|
||||
if(audioSources[i]->isPlaying())
|
||||
audioSources[i]->stop();
|
||||
}
|
||||
}
|
||||
|
||||
IAudioSource* cAudioManager::createAudioSource(IAudioDecoder* decoder, const cAudioString& audioName, const cAudioString& dataSource)
|
||||
{
|
||||
if(decoder && decoder->isValid())
|
||||
|
@ -460,7 +568,8 @@ namespace cAudio
|
|||
void cAudioManager::releaseAllSources()
|
||||
{
|
||||
cAudioMutexBasicLock lock(Mutex);
|
||||
for(unsigned int i=0; i<audioSources.size(); ++i)
|
||||
size_t count = audioSources.size();
|
||||
for(size_t i=0; i<count; i++)
|
||||
{
|
||||
IAudioSource* source = audioSources[i];
|
||||
if(source)
|
||||
|
@ -468,6 +577,28 @@ namespace cAudio
|
|||
}
|
||||
audioSources.clear();
|
||||
audioIndex.clear();
|
||||
|
||||
count = managedAudioSources.size();
|
||||
for(size_t i=0; i<count; i++)
|
||||
{
|
||||
IAudioSource* source = managedAudioSources[i];
|
||||
if (source)
|
||||
{
|
||||
CAUDIO_DELETE source;
|
||||
}
|
||||
}
|
||||
managedAudioSources.clear();
|
||||
|
||||
count = managedAudioSourcesDelBuffer.size();
|
||||
for(size_t i=0; i<count; i++)
|
||||
{
|
||||
IAudioSource* source = managedAudioSourcesDelBuffer[i];
|
||||
if (source)
|
||||
{
|
||||
CAUDIO_DELETE source;
|
||||
}
|
||||
}
|
||||
managedAudioSourcesDelBuffer.clear();
|
||||
}
|
||||
|
||||
void cAudioManager::release(IAudioSource* source)
|
||||
|
|
|
@ -115,35 +115,39 @@ public class IAudioDecoder : IRefCounted {
|
|||
}
|
||||
|
||||
private void SwigDirectorConnect() {
|
||||
if (SwigDerivedClassHasMethod("getFormat", swigMethodTypes0))
|
||||
swigDelegate0 = new SwigDelegateIAudioDecoder_0(SwigDirectorgetFormat);
|
||||
if (SwigDerivedClassHasMethod("getFrequency", swigMethodTypes1))
|
||||
swigDelegate1 = new SwigDelegateIAudioDecoder_1(SwigDirectorgetFrequency);
|
||||
if (SwigDerivedClassHasMethod("isSeekingSupported", swigMethodTypes2))
|
||||
swigDelegate2 = new SwigDelegateIAudioDecoder_2(SwigDirectorisSeekingSupported);
|
||||
if (SwigDerivedClassHasMethod("isValid", swigMethodTypes3))
|
||||
swigDelegate3 = new SwigDelegateIAudioDecoder_3(SwigDirectorisValid);
|
||||
if (SwigDerivedClassHasMethod("readAudioData", swigMethodTypes4))
|
||||
swigDelegate4 = new SwigDelegateIAudioDecoder_4(SwigDirectorreadAudioData);
|
||||
if (SwigDerivedClassHasMethod("setPosition", swigMethodTypes5))
|
||||
swigDelegate5 = new SwigDelegateIAudioDecoder_5(SwigDirectorsetPosition);
|
||||
if (SwigDerivedClassHasMethod("seek", swigMethodTypes6))
|
||||
swigDelegate6 = new SwigDelegateIAudioDecoder_6(SwigDirectorseek);
|
||||
if (SwigDerivedClassHasMethod("getTotalTime", swigMethodTypes7))
|
||||
swigDelegate7 = new SwigDelegateIAudioDecoder_7(SwigDirectorgetTotalTime);
|
||||
if (SwigDerivedClassHasMethod("getTotalSize", swigMethodTypes8))
|
||||
swigDelegate8 = new SwigDelegateIAudioDecoder_8(SwigDirectorgetTotalSize);
|
||||
if (SwigDerivedClassHasMethod("getCompressedSize", swigMethodTypes9))
|
||||
swigDelegate9 = new SwigDelegateIAudioDecoder_9(SwigDirectorgetCompressedSize);
|
||||
if (SwigDerivedClassHasMethod("getCurrentTime", swigMethodTypes10))
|
||||
swigDelegate10 = new SwigDelegateIAudioDecoder_10(SwigDirectorgetCurrentTime);
|
||||
if (SwigDerivedClassHasMethod("getCurrentPosition", swigMethodTypes11))
|
||||
swigDelegate11 = new SwigDelegateIAudioDecoder_11(SwigDirectorgetCurrentPosition);
|
||||
if (SwigDerivedClassHasMethod("getCurrentCompressedPosition", swigMethodTypes12))
|
||||
swigDelegate12 = new SwigDelegateIAudioDecoder_12(SwigDirectorgetCurrentCompressedPosition);
|
||||
if (SwigDerivedClassHasMethod("getType", swigMethodTypes13))
|
||||
swigDelegate13 = new SwigDelegateIAudioDecoder_13(SwigDirectorgetType);
|
||||
cAudioCSharpWrapperPINVOKE.IAudioDecoder_director_connect(swigCPtr, swigDelegate0, swigDelegate1, swigDelegate2, swigDelegate3, swigDelegate4, swigDelegate5, swigDelegate6, swigDelegate7, swigDelegate8, swigDelegate9, swigDelegate10, swigDelegate11, swigDelegate12, swigDelegate13);
|
||||
if (SwigDerivedClassHasMethod("grab", swigMethodTypes0))
|
||||
swigDelegate0 = new SwigDelegateIAudioDecoder_0(SwigDirectorgrab);
|
||||
if (SwigDerivedClassHasMethod("drop", swigMethodTypes1))
|
||||
swigDelegate1 = new SwigDelegateIAudioDecoder_1(SwigDirectordrop);
|
||||
if (SwigDerivedClassHasMethod("getFormat", swigMethodTypes2))
|
||||
swigDelegate2 = new SwigDelegateIAudioDecoder_2(SwigDirectorgetFormat);
|
||||
if (SwigDerivedClassHasMethod("getFrequency", swigMethodTypes3))
|
||||
swigDelegate3 = new SwigDelegateIAudioDecoder_3(SwigDirectorgetFrequency);
|
||||
if (SwigDerivedClassHasMethod("isSeekingSupported", swigMethodTypes4))
|
||||
swigDelegate4 = new SwigDelegateIAudioDecoder_4(SwigDirectorisSeekingSupported);
|
||||
if (SwigDerivedClassHasMethod("isValid", swigMethodTypes5))
|
||||
swigDelegate5 = new SwigDelegateIAudioDecoder_5(SwigDirectorisValid);
|
||||
if (SwigDerivedClassHasMethod("readAudioData", swigMethodTypes6))
|
||||
swigDelegate6 = new SwigDelegateIAudioDecoder_6(SwigDirectorreadAudioData);
|
||||
if (SwigDerivedClassHasMethod("setPosition", swigMethodTypes7))
|
||||
swigDelegate7 = new SwigDelegateIAudioDecoder_7(SwigDirectorsetPosition);
|
||||
if (SwigDerivedClassHasMethod("seek", swigMethodTypes8))
|
||||
swigDelegate8 = new SwigDelegateIAudioDecoder_8(SwigDirectorseek);
|
||||
if (SwigDerivedClassHasMethod("getTotalTime", swigMethodTypes9))
|
||||
swigDelegate9 = new SwigDelegateIAudioDecoder_9(SwigDirectorgetTotalTime);
|
||||
if (SwigDerivedClassHasMethod("getTotalSize", swigMethodTypes10))
|
||||
swigDelegate10 = new SwigDelegateIAudioDecoder_10(SwigDirectorgetTotalSize);
|
||||
if (SwigDerivedClassHasMethod("getCompressedSize", swigMethodTypes11))
|
||||
swigDelegate11 = new SwigDelegateIAudioDecoder_11(SwigDirectorgetCompressedSize);
|
||||
if (SwigDerivedClassHasMethod("getCurrentTime", swigMethodTypes12))
|
||||
swigDelegate12 = new SwigDelegateIAudioDecoder_12(SwigDirectorgetCurrentTime);
|
||||
if (SwigDerivedClassHasMethod("getCurrentPosition", swigMethodTypes13))
|
||||
swigDelegate13 = new SwigDelegateIAudioDecoder_13(SwigDirectorgetCurrentPosition);
|
||||
if (SwigDerivedClassHasMethod("getCurrentCompressedPosition", swigMethodTypes14))
|
||||
swigDelegate14 = new SwigDelegateIAudioDecoder_14(SwigDirectorgetCurrentCompressedPosition);
|
||||
if (SwigDerivedClassHasMethod("getType", swigMethodTypes15))
|
||||
swigDelegate15 = new SwigDelegateIAudioDecoder_15(SwigDirectorgetType);
|
||||
cAudioCSharpWrapperPINVOKE.IAudioDecoder_director_connect(swigCPtr, swigDelegate0, swigDelegate1, swigDelegate2, swigDelegate3, swigDelegate4, swigDelegate5, swigDelegate6, swigDelegate7, swigDelegate8, swigDelegate9, swigDelegate10, swigDelegate11, swigDelegate12, swigDelegate13, swigDelegate14, swigDelegate15);
|
||||
}
|
||||
|
||||
private bool SwigDerivedClassHasMethod(string methodName, Type[] methodTypes) {
|
||||
|
@ -152,6 +156,14 @@ public class IAudioDecoder : IRefCounted {
|
|||
return hasDerivedMethod;
|
||||
}
|
||||
|
||||
private void SwigDirectorgrab() {
|
||||
grab();
|
||||
}
|
||||
|
||||
private bool SwigDirectordrop() {
|
||||
return drop();
|
||||
}
|
||||
|
||||
private int SwigDirectorgetFormat() {
|
||||
return (int)getFormat();
|
||||
}
|
||||
|
@ -208,20 +220,22 @@ public class IAudioDecoder : IRefCounted {
|
|||
return SWIGTYPE_p_std__basic_stringT_char_t.getCPtr(getType()).Handle;
|
||||
}
|
||||
|
||||
public delegate int SwigDelegateIAudioDecoder_0();
|
||||
public delegate int SwigDelegateIAudioDecoder_1();
|
||||
public delegate bool SwigDelegateIAudioDecoder_2();
|
||||
public delegate bool SwigDelegateIAudioDecoder_3();
|
||||
public delegate int SwigDelegateIAudioDecoder_4(IntPtr output, int amount);
|
||||
public delegate bool SwigDelegateIAudioDecoder_5(int position, bool relative);
|
||||
public delegate bool SwigDelegateIAudioDecoder_6(float seconds, bool relative);
|
||||
public delegate float SwigDelegateIAudioDecoder_7();
|
||||
public delegate int SwigDelegateIAudioDecoder_8();
|
||||
public delegate int SwigDelegateIAudioDecoder_9();
|
||||
public delegate float SwigDelegateIAudioDecoder_10();
|
||||
public delegate void SwigDelegateIAudioDecoder_0();
|
||||
public delegate bool SwigDelegateIAudioDecoder_1();
|
||||
public delegate int SwigDelegateIAudioDecoder_2();
|
||||
public delegate int SwigDelegateIAudioDecoder_3();
|
||||
public delegate bool SwigDelegateIAudioDecoder_4();
|
||||
public delegate bool SwigDelegateIAudioDecoder_5();
|
||||
public delegate int SwigDelegateIAudioDecoder_6(IntPtr output, int amount);
|
||||
public delegate bool SwigDelegateIAudioDecoder_7(int position, bool relative);
|
||||
public delegate bool SwigDelegateIAudioDecoder_8(float seconds, bool relative);
|
||||
public delegate float SwigDelegateIAudioDecoder_9();
|
||||
public delegate int SwigDelegateIAudioDecoder_10();
|
||||
public delegate int SwigDelegateIAudioDecoder_11();
|
||||
public delegate int SwigDelegateIAudioDecoder_12();
|
||||
public delegate IntPtr SwigDelegateIAudioDecoder_13();
|
||||
public delegate float SwigDelegateIAudioDecoder_12();
|
||||
public delegate int SwigDelegateIAudioDecoder_13();
|
||||
public delegate int SwigDelegateIAudioDecoder_14();
|
||||
public delegate IntPtr SwigDelegateIAudioDecoder_15();
|
||||
|
||||
private SwigDelegateIAudioDecoder_0 swigDelegate0;
|
||||
private SwigDelegateIAudioDecoder_1 swigDelegate1;
|
||||
|
@ -237,21 +251,25 @@ public class IAudioDecoder : IRefCounted {
|
|||
private SwigDelegateIAudioDecoder_11 swigDelegate11;
|
||||
private SwigDelegateIAudioDecoder_12 swigDelegate12;
|
||||
private SwigDelegateIAudioDecoder_13 swigDelegate13;
|
||||
private SwigDelegateIAudioDecoder_14 swigDelegate14;
|
||||
private SwigDelegateIAudioDecoder_15 swigDelegate15;
|
||||
|
||||
private static Type[] swigMethodTypes0 = new Type[] { };
|
||||
private static Type[] swigMethodTypes1 = new Type[] { };
|
||||
private static Type[] swigMethodTypes2 = new Type[] { };
|
||||
private static Type[] swigMethodTypes3 = new Type[] { };
|
||||
private static Type[] swigMethodTypes4 = new Type[] { typeof(SWIGTYPE_p_void), typeof(int) };
|
||||
private static Type[] swigMethodTypes5 = new Type[] { typeof(int), typeof(bool) };
|
||||
private static Type[] swigMethodTypes6 = new Type[] { typeof(float), typeof(bool) };
|
||||
private static Type[] swigMethodTypes7 = new Type[] { };
|
||||
private static Type[] swigMethodTypes8 = new Type[] { };
|
||||
private static Type[] swigMethodTypes4 = new Type[] { };
|
||||
private static Type[] swigMethodTypes5 = new Type[] { };
|
||||
private static Type[] swigMethodTypes6 = new Type[] { typeof(SWIGTYPE_p_void), typeof(int) };
|
||||
private static Type[] swigMethodTypes7 = new Type[] { typeof(int), typeof(bool) };
|
||||
private static Type[] swigMethodTypes8 = new Type[] { typeof(float), typeof(bool) };
|
||||
private static Type[] swigMethodTypes9 = new Type[] { };
|
||||
private static Type[] swigMethodTypes10 = new Type[] { };
|
||||
private static Type[] swigMethodTypes11 = new Type[] { };
|
||||
private static Type[] swigMethodTypes12 = new Type[] { };
|
||||
private static Type[] swigMethodTypes13 = new Type[] { };
|
||||
private static Type[] swigMethodTypes14 = new Type[] { };
|
||||
private static Type[] swigMethodTypes15 = new Type[] { };
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -88,6 +88,58 @@ public class IAudioManager : IDisposable {
|
|||
cAudioCSharpWrapperPINVOKE.IAudioManager_release(swigCPtr, IAudioSource.getCPtr(source));
|
||||
}
|
||||
|
||||
public virtual IAudioSource play2D(string filename, bool playLooped, bool startPaused) {
|
||||
IntPtr cPtr = cAudioCSharpWrapperPINVOKE.IAudioManager_play2D__SWIG_0(swigCPtr, filename, playLooped, startPaused);
|
||||
IAudioSource ret = (cPtr == IntPtr.Zero) ? null : new IAudioSource(cPtr, false);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public virtual IAudioSource play2D(string filename, bool playLooped) {
|
||||
IntPtr cPtr = cAudioCSharpWrapperPINVOKE.IAudioManager_play2D__SWIG_1(swigCPtr, filename, playLooped);
|
||||
IAudioSource ret = (cPtr == IntPtr.Zero) ? null : new IAudioSource(cPtr, false);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public virtual IAudioSource play2D(string filename) {
|
||||
IntPtr cPtr = cAudioCSharpWrapperPINVOKE.IAudioManager_play2D__SWIG_2(swigCPtr, filename);
|
||||
IAudioSource ret = (cPtr == IntPtr.Zero) ? null : new IAudioSource(cPtr, false);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public virtual IAudioSource play3D(string filename, cVector3 position, bool playLooped, bool startPaused) {
|
||||
IntPtr cPtr = cAudioCSharpWrapperPINVOKE.IAudioManager_play3D__SWIG_0(swigCPtr, filename, cVector3.getCPtr(position), playLooped, startPaused);
|
||||
IAudioSource ret = (cPtr == IntPtr.Zero) ? null : new IAudioSource(cPtr, false);
|
||||
if (cAudioCSharpWrapperPINVOKE.SWIGPendingException.Pending) throw cAudioCSharpWrapperPINVOKE.SWIGPendingException.Retrieve();
|
||||
return ret;
|
||||
}
|
||||
|
||||
public virtual IAudioSource play3D(string filename, cVector3 position, bool playLooped) {
|
||||
IntPtr cPtr = cAudioCSharpWrapperPINVOKE.IAudioManager_play3D__SWIG_1(swigCPtr, filename, cVector3.getCPtr(position), playLooped);
|
||||
IAudioSource ret = (cPtr == IntPtr.Zero) ? null : new IAudioSource(cPtr, false);
|
||||
if (cAudioCSharpWrapperPINVOKE.SWIGPendingException.Pending) throw cAudioCSharpWrapperPINVOKE.SWIGPendingException.Retrieve();
|
||||
return ret;
|
||||
}
|
||||
|
||||
public virtual IAudioSource play3D(string filename, cVector3 position) {
|
||||
IntPtr cPtr = cAudioCSharpWrapperPINVOKE.IAudioManager_play3D__SWIG_2(swigCPtr, filename, cVector3.getCPtr(position));
|
||||
IAudioSource ret = (cPtr == IntPtr.Zero) ? null : new IAudioSource(cPtr, false);
|
||||
if (cAudioCSharpWrapperPINVOKE.SWIGPendingException.Pending) throw cAudioCSharpWrapperPINVOKE.SWIGPendingException.Retrieve();
|
||||
return ret;
|
||||
}
|
||||
|
||||
public virtual void setMasterVolume(float vol) {
|
||||
cAudioCSharpWrapperPINVOKE.IAudioManager_setMasterVolume(swigCPtr, vol);
|
||||
}
|
||||
|
||||
public virtual float getMasterVolume() {
|
||||
float ret = cAudioCSharpWrapperPINVOKE.IAudioManager_getMasterVolume(swigCPtr);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public virtual void stopAllSounds() {
|
||||
cAudioCSharpWrapperPINVOKE.IAudioManager_stopAllSounds(swigCPtr);
|
||||
}
|
||||
|
||||
public virtual IAudioSource create(string name, string filename, bool stream) {
|
||||
IntPtr cPtr = cAudioCSharpWrapperPINVOKE.IAudioManager_create__SWIG_0(swigCPtr, name, filename, stream);
|
||||
IAudioSource ret = (cPtr == IntPtr.Zero) ? null : new IAudioSource(cPtr, false);
|
||||
|
|
|
@ -70,17 +70,21 @@ public class IDataSource : IRefCounted {
|
|||
}
|
||||
|
||||
private void SwigDirectorConnect() {
|
||||
if (SwigDerivedClassHasMethod("isValid", swigMethodTypes0))
|
||||
swigDelegate0 = new SwigDelegateIDataSource_0(SwigDirectorisValid);
|
||||
if (SwigDerivedClassHasMethod("getCurrentPos", swigMethodTypes1))
|
||||
swigDelegate1 = new SwigDelegateIDataSource_1(SwigDirectorgetCurrentPos);
|
||||
if (SwigDerivedClassHasMethod("getSize", swigMethodTypes2))
|
||||
swigDelegate2 = new SwigDelegateIDataSource_2(SwigDirectorgetSize);
|
||||
if (SwigDerivedClassHasMethod("read", swigMethodTypes3))
|
||||
swigDelegate3 = new SwigDelegateIDataSource_3(SwigDirectorread);
|
||||
if (SwigDerivedClassHasMethod("seek", swigMethodTypes4))
|
||||
swigDelegate4 = new SwigDelegateIDataSource_4(SwigDirectorseek);
|
||||
cAudioCSharpWrapperPINVOKE.IDataSource_director_connect(swigCPtr, swigDelegate0, swigDelegate1, swigDelegate2, swigDelegate3, swigDelegate4);
|
||||
if (SwigDerivedClassHasMethod("grab", swigMethodTypes0))
|
||||
swigDelegate0 = new SwigDelegateIDataSource_0(SwigDirectorgrab);
|
||||
if (SwigDerivedClassHasMethod("drop", swigMethodTypes1))
|
||||
swigDelegate1 = new SwigDelegateIDataSource_1(SwigDirectordrop);
|
||||
if (SwigDerivedClassHasMethod("isValid", swigMethodTypes2))
|
||||
swigDelegate2 = new SwigDelegateIDataSource_2(SwigDirectorisValid);
|
||||
if (SwigDerivedClassHasMethod("getCurrentPos", swigMethodTypes3))
|
||||
swigDelegate3 = new SwigDelegateIDataSource_3(SwigDirectorgetCurrentPos);
|
||||
if (SwigDerivedClassHasMethod("getSize", swigMethodTypes4))
|
||||
swigDelegate4 = new SwigDelegateIDataSource_4(SwigDirectorgetSize);
|
||||
if (SwigDerivedClassHasMethod("read", swigMethodTypes5))
|
||||
swigDelegate5 = new SwigDelegateIDataSource_5(SwigDirectorread);
|
||||
if (SwigDerivedClassHasMethod("seek", swigMethodTypes6))
|
||||
swigDelegate6 = new SwigDelegateIDataSource_6(SwigDirectorseek);
|
||||
cAudioCSharpWrapperPINVOKE.IDataSource_director_connect(swigCPtr, swigDelegate0, swigDelegate1, swigDelegate2, swigDelegate3, swigDelegate4, swigDelegate5, swigDelegate6);
|
||||
}
|
||||
|
||||
private bool SwigDerivedClassHasMethod(string methodName, Type[] methodTypes) {
|
||||
|
@ -89,6 +93,14 @@ public class IDataSource : IRefCounted {
|
|||
return hasDerivedMethod;
|
||||
}
|
||||
|
||||
private void SwigDirectorgrab() {
|
||||
grab();
|
||||
}
|
||||
|
||||
private bool SwigDirectordrop() {
|
||||
return drop();
|
||||
}
|
||||
|
||||
private bool SwigDirectorisValid() {
|
||||
return isValid();
|
||||
}
|
||||
|
@ -109,23 +121,29 @@ public class IDataSource : IRefCounted {
|
|||
return seek(amount, relative);
|
||||
}
|
||||
|
||||
public delegate bool SwigDelegateIDataSource_0();
|
||||
public delegate int SwigDelegateIDataSource_1();
|
||||
public delegate int SwigDelegateIDataSource_2();
|
||||
public delegate int SwigDelegateIDataSource_3(IntPtr output, int size);
|
||||
public delegate bool SwigDelegateIDataSource_4(int amount, bool relative);
|
||||
public delegate void SwigDelegateIDataSource_0();
|
||||
public delegate bool SwigDelegateIDataSource_1();
|
||||
public delegate bool SwigDelegateIDataSource_2();
|
||||
public delegate int SwigDelegateIDataSource_3();
|
||||
public delegate int SwigDelegateIDataSource_4();
|
||||
public delegate int SwigDelegateIDataSource_5(IntPtr output, int size);
|
||||
public delegate bool SwigDelegateIDataSource_6(int amount, bool relative);
|
||||
|
||||
private SwigDelegateIDataSource_0 swigDelegate0;
|
||||
private SwigDelegateIDataSource_1 swigDelegate1;
|
||||
private SwigDelegateIDataSource_2 swigDelegate2;
|
||||
private SwigDelegateIDataSource_3 swigDelegate3;
|
||||
private SwigDelegateIDataSource_4 swigDelegate4;
|
||||
private SwigDelegateIDataSource_5 swigDelegate5;
|
||||
private SwigDelegateIDataSource_6 swigDelegate6;
|
||||
|
||||
private static Type[] swigMethodTypes0 = new Type[] { };
|
||||
private static Type[] swigMethodTypes1 = new Type[] { };
|
||||
private static Type[] swigMethodTypes2 = new Type[] { };
|
||||
private static Type[] swigMethodTypes3 = new Type[] { typeof(SWIGTYPE_p_void), typeof(int) };
|
||||
private static Type[] swigMethodTypes4 = new Type[] { typeof(int), typeof(bool) };
|
||||
private static Type[] swigMethodTypes3 = new Type[] { };
|
||||
private static Type[] swigMethodTypes4 = new Type[] { };
|
||||
private static Type[] swigMethodTypes5 = new Type[] { typeof(SWIGTYPE_p_void), typeof(int) };
|
||||
private static Type[] swigMethodTypes6 = new Type[] { typeof(int), typeof(bool) };
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -44,11 +44,11 @@ public class IRefCounted : IDisposable {
|
|||
public IRefCounted() : this(cAudioCSharpWrapperPINVOKE.new_IRefCounted(), true) {
|
||||
}
|
||||
|
||||
public void grab() {
|
||||
public virtual void grab() {
|
||||
cAudioCSharpWrapperPINVOKE.IRefCounted_grab(swigCPtr);
|
||||
}
|
||||
|
||||
public bool drop() {
|
||||
public virtual bool drop() {
|
||||
bool ret = cAudioCSharpWrapperPINVOKE.IRefCounted_drop(swigCPtr);
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -12,16 +12,6 @@ using System;
|
|||
using System.Runtime.InteropServices;
|
||||
|
||||
public class cAudioCSharpWrapper {
|
||||
public static IMemoryProvider getMemoryProvider() {
|
||||
IntPtr cPtr = cAudioCSharpWrapperPINVOKE.getMemoryProvider();
|
||||
IMemoryProvider ret = (cPtr == IntPtr.Zero) ? null : new IMemoryProvider(cPtr, false);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static void cAudioSleep(uint ms) {
|
||||
cAudioCSharpWrapperPINVOKE.cAudioSleep(ms);
|
||||
}
|
||||
|
||||
public static string toWINSTR(string str) {
|
||||
string ret = cAudioCSharpWrapperPINVOKE.toWINSTR(str);
|
||||
return ret;
|
||||
|
@ -38,6 +28,16 @@ public class cAudioCSharpWrapper {
|
|||
return ret;
|
||||
}
|
||||
|
||||
public static IMemoryProvider getMemoryProvider() {
|
||||
IntPtr cPtr = cAudioCSharpWrapperPINVOKE.getMemoryProvider();
|
||||
IMemoryProvider ret = (cPtr == IntPtr.Zero) ? null : new IMemoryProvider(cPtr, false);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static void cAudioSleep(uint ms) {
|
||||
cAudioCSharpWrapperPINVOKE.cAudioSleep(ms);
|
||||
}
|
||||
|
||||
public static float Epsilon {
|
||||
get {
|
||||
float ret = cAudioCSharpWrapperPINVOKE.Epsilon_get();
|
||||
|
|
|
@ -189,6 +189,15 @@ class cAudioCSharpWrapperPINVOKE {
|
|||
}
|
||||
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_toWINSTR")]
|
||||
public static extern string toWINSTR(string jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_toUTF8")]
|
||||
public static extern string toUTF8(HandleRef jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_fromUTF8")]
|
||||
public static extern IntPtr fromUTF8(string jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IMemoryProvider_Allocate")]
|
||||
public static extern IntPtr IMemoryProvider_Allocate(HandleRef jarg1, uint jarg2, string jarg3, int jarg4, string jarg5);
|
||||
|
||||
|
@ -219,15 +228,6 @@ class cAudioCSharpWrapperPINVOKE {
|
|||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_cAudioSleep")]
|
||||
public static extern void cAudioSleep(uint jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_toWINSTR")]
|
||||
public static extern string toWINSTR(string jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_toUTF8")]
|
||||
public static extern string toUTF8(HandleRef jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_fromUTF8")]
|
||||
public static extern IntPtr fromUTF8(string jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioDeviceList_getDeviceCount")]
|
||||
public static extern uint IAudioDeviceList_getDeviceCount(HandleRef jarg1);
|
||||
|
||||
|
@ -283,7 +283,7 @@ class cAudioCSharpWrapperPINVOKE {
|
|||
public static extern bool IDataSource_seek(HandleRef jarg1, int jarg2, bool jarg3);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IDataSource_director_connect")]
|
||||
public static extern void IDataSource_director_connect(HandleRef jarg1, IDataSource.SwigDelegateIDataSource_0 delegate0, IDataSource.SwigDelegateIDataSource_1 delegate1, IDataSource.SwigDelegateIDataSource_2 delegate2, IDataSource.SwigDelegateIDataSource_3 delegate3, IDataSource.SwigDelegateIDataSource_4 delegate4);
|
||||
public static extern void IDataSource_director_connect(HandleRef jarg1, IDataSource.SwigDelegateIDataSource_0 delegate0, IDataSource.SwigDelegateIDataSource_1 delegate1, IDataSource.SwigDelegateIDataSource_2 delegate2, IDataSource.SwigDelegateIDataSource_3 delegate3, IDataSource.SwigDelegateIDataSource_4 delegate4, IDataSource.SwigDelegateIDataSource_5 delegate5, IDataSource.SwigDelegateIDataSource_6 delegate6);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_new_IDataSourceFactory")]
|
||||
public static extern IntPtr new_IDataSourceFactory();
|
||||
|
@ -730,7 +730,7 @@ class cAudioCSharpWrapperPINVOKE {
|
|||
public static extern IntPtr IAudioDecoder_getType(HandleRef jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioDecoder_director_connect")]
|
||||
public static extern void IAudioDecoder_director_connect(HandleRef jarg1, IAudioDecoder.SwigDelegateIAudioDecoder_0 delegate0, IAudioDecoder.SwigDelegateIAudioDecoder_1 delegate1, IAudioDecoder.SwigDelegateIAudioDecoder_2 delegate2, IAudioDecoder.SwigDelegateIAudioDecoder_3 delegate3, IAudioDecoder.SwigDelegateIAudioDecoder_4 delegate4, IAudioDecoder.SwigDelegateIAudioDecoder_5 delegate5, IAudioDecoder.SwigDelegateIAudioDecoder_6 delegate6, IAudioDecoder.SwigDelegateIAudioDecoder_7 delegate7, IAudioDecoder.SwigDelegateIAudioDecoder_8 delegate8, IAudioDecoder.SwigDelegateIAudioDecoder_9 delegate9, IAudioDecoder.SwigDelegateIAudioDecoder_10 delegate10, IAudioDecoder.SwigDelegateIAudioDecoder_11 delegate11, IAudioDecoder.SwigDelegateIAudioDecoder_12 delegate12, IAudioDecoder.SwigDelegateIAudioDecoder_13 delegate13);
|
||||
public static extern void IAudioDecoder_director_connect(HandleRef jarg1, IAudioDecoder.SwigDelegateIAudioDecoder_0 delegate0, IAudioDecoder.SwigDelegateIAudioDecoder_1 delegate1, IAudioDecoder.SwigDelegateIAudioDecoder_2 delegate2, IAudioDecoder.SwigDelegateIAudioDecoder_3 delegate3, IAudioDecoder.SwigDelegateIAudioDecoder_4 delegate4, IAudioDecoder.SwigDelegateIAudioDecoder_5 delegate5, IAudioDecoder.SwigDelegateIAudioDecoder_6 delegate6, IAudioDecoder.SwigDelegateIAudioDecoder_7 delegate7, IAudioDecoder.SwigDelegateIAudioDecoder_8 delegate8, IAudioDecoder.SwigDelegateIAudioDecoder_9 delegate9, IAudioDecoder.SwigDelegateIAudioDecoder_10 delegate10, IAudioDecoder.SwigDelegateIAudioDecoder_11 delegate11, IAudioDecoder.SwigDelegateIAudioDecoder_12 delegate12, IAudioDecoder.SwigDelegateIAudioDecoder_13 delegate13, IAudioDecoder.SwigDelegateIAudioDecoder_14 delegate14, IAudioDecoder.SwigDelegateIAudioDecoder_15 delegate15);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_new_IAudioDecoderFactory")]
|
||||
public static extern IntPtr new_IAudioDecoderFactory();
|
||||
|
@ -777,6 +777,33 @@ class cAudioCSharpWrapperPINVOKE {
|
|||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_release")]
|
||||
public static extern void IAudioManager_release(HandleRef jarg1, HandleRef jarg2);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_play2D__SWIG_0")]
|
||||
public static extern IntPtr IAudioManager_play2D__SWIG_0(HandleRef jarg1, string jarg2, bool jarg3, bool jarg4);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_play2D__SWIG_1")]
|
||||
public static extern IntPtr IAudioManager_play2D__SWIG_1(HandleRef jarg1, string jarg2, bool jarg3);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_play2D__SWIG_2")]
|
||||
public static extern IntPtr IAudioManager_play2D__SWIG_2(HandleRef jarg1, string jarg2);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_play3D__SWIG_0")]
|
||||
public static extern IntPtr IAudioManager_play3D__SWIG_0(HandleRef jarg1, string jarg2, HandleRef jarg3, bool jarg4, bool jarg5);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_play3D__SWIG_1")]
|
||||
public static extern IntPtr IAudioManager_play3D__SWIG_1(HandleRef jarg1, string jarg2, HandleRef jarg3, bool jarg4);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_play3D__SWIG_2")]
|
||||
public static extern IntPtr IAudioManager_play3D__SWIG_2(HandleRef jarg1, string jarg2, HandleRef jarg3);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_setMasterVolume")]
|
||||
public static extern void IAudioManager_setMasterVolume(HandleRef jarg1, float jarg2);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_getMasterVolume")]
|
||||
public static extern float IAudioManager_getMasterVolume(HandleRef jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_stopAllSounds")]
|
||||
public static extern void IAudioManager_stopAllSounds(HandleRef jarg1);
|
||||
|
||||
[DllImport("cAudioCSharpWrapper", EntryPoint="CSharp_IAudioManager_create__SWIG_0")]
|
||||
public static extern IntPtr IAudioManager_create__SWIG_0(HandleRef jarg1, string jarg2, string jarg3, bool jarg4);
|
||||
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
#define CAUDIO_API
|
||||
|
||||
%{
|
||||
#include "cAudioString.h"
|
||||
#include "IRefCounted.h"
|
||||
#include "EAudioFormats.h"
|
||||
#include "IAudioEffects.h"
|
||||
|
@ -32,7 +33,6 @@
|
|||
#include "cAudioMemory.h"
|
||||
#include "cAudioPlatform.h"
|
||||
#include "cAudioSleep.h"
|
||||
#include "cAudioString.h"
|
||||
#include "cSTLAllocator.h"
|
||||
#include "cVector3.h"
|
||||
#include "IAudioCapture.h"
|
||||
|
@ -142,6 +142,7 @@
|
|||
%feature("director") cAudio::IAudioDecoderFactory;
|
||||
%feature("director") cAudio::IAudioDecoder;
|
||||
|
||||
%include "..\cAudio\include\cAudioString.h"
|
||||
%include "..\cAudio\include\IMemoryProvider.h"
|
||||
%include "..\cAudio\include\cAudioDefines.h"
|
||||
%include "..\cAudio\include\cAudioMemory.h"
|
||||
|
|
|
@ -344,6 +344,7 @@ namespace Swig {
|
|||
#include <stdexcept>
|
||||
|
||||
|
||||
#include "cAudioString.h"
|
||||
#include "IRefCounted.h"
|
||||
#include "EAudioFormats.h"
|
||||
#include "IAudioEffects.h"
|
||||
|
@ -369,7 +370,6 @@ namespace Swig {
|
|||
#include "cAudioMemory.h"
|
||||
#include "cAudioPlatform.h"
|
||||
#include "cAudioSleep.h"
|
||||
#include "cAudioString.h"
|
||||
#include "cSTLAllocator.h"
|
||||
#include "cVector3.h"
|
||||
#include "IAudioCapture.h"
|
||||
|
@ -803,6 +803,28 @@ SwigDirector_IDataSource::~SwigDirector_IDataSource() {
|
|||
}
|
||||
|
||||
|
||||
void SwigDirector_IDataSource::grab() {
|
||||
if (!swig_callbackgrab) {
|
||||
cAudio::IRefCounted::grab();
|
||||
return;
|
||||
} else {
|
||||
swig_callbackgrab();
|
||||
}
|
||||
}
|
||||
|
||||
bool SwigDirector_IDataSource::drop() {
|
||||
bool c_result = SwigValueInit< bool >() ;
|
||||
unsigned int jresult = 0 ;
|
||||
|
||||
if (!swig_callbackdrop) {
|
||||
return cAudio::IRefCounted::drop();
|
||||
} else {
|
||||
jresult = (unsigned int) swig_callbackdrop();
|
||||
c_result = jresult ? true : false;
|
||||
}
|
||||
return c_result;
|
||||
}
|
||||
|
||||
bool SwigDirector_IDataSource::isValid() {
|
||||
bool c_result = SwigValueInit< bool >() ;
|
||||
unsigned int jresult = 0 ;
|
||||
|
@ -876,7 +898,9 @@ bool SwigDirector_IDataSource::seek(int amount, bool relative) {
|
|||
return c_result;
|
||||
}
|
||||
|
||||
void SwigDirector_IDataSource::swig_connect_director(SWIG_Callback0_t callbackisValid, SWIG_Callback1_t callbackgetCurrentPos, SWIG_Callback2_t callbackgetSize, SWIG_Callback3_t callbackread, SWIG_Callback4_t callbackseek) {
|
||||
void SwigDirector_IDataSource::swig_connect_director(SWIG_Callback0_t callbackgrab, SWIG_Callback1_t callbackdrop, SWIG_Callback2_t callbackisValid, SWIG_Callback3_t callbackgetCurrentPos, SWIG_Callback4_t callbackgetSize, SWIG_Callback5_t callbackread, SWIG_Callback6_t callbackseek) {
|
||||
swig_callbackgrab = callbackgrab;
|
||||
swig_callbackdrop = callbackdrop;
|
||||
swig_callbackisValid = callbackisValid;
|
||||
swig_callbackgetCurrentPos = callbackgetCurrentPos;
|
||||
swig_callbackgetSize = callbackgetSize;
|
||||
|
@ -885,6 +909,8 @@ void SwigDirector_IDataSource::swig_connect_director(SWIG_Callback0_t callbackis
|
|||
}
|
||||
|
||||
void SwigDirector_IDataSource::swig_init_callbacks() {
|
||||
swig_callbackgrab = 0;
|
||||
swig_callbackdrop = 0;
|
||||
swig_callbackisValid = 0;
|
||||
swig_callbackgetCurrentPos = 0;
|
||||
swig_callbackgetSize = 0;
|
||||
|
@ -1168,6 +1194,28 @@ SwigDirector_IAudioDecoder::~SwigDirector_IAudioDecoder() {
|
|||
}
|
||||
|
||||
|
||||
void SwigDirector_IAudioDecoder::grab() {
|
||||
if (!swig_callbackgrab) {
|
||||
cAudio::IRefCounted::grab();
|
||||
return;
|
||||
} else {
|
||||
swig_callbackgrab();
|
||||
}
|
||||
}
|
||||
|
||||
bool SwigDirector_IAudioDecoder::drop() {
|
||||
bool c_result = SwigValueInit< bool >() ;
|
||||
unsigned int jresult = 0 ;
|
||||
|
||||
if (!swig_callbackdrop) {
|
||||
return cAudio::IRefCounted::drop();
|
||||
} else {
|
||||
jresult = (unsigned int) swig_callbackdrop();
|
||||
c_result = jresult ? true : false;
|
||||
}
|
||||
return c_result;
|
||||
}
|
||||
|
||||
cAudio::AudioFormats SwigDirector_IAudioDecoder::getFormat() {
|
||||
cAudio::AudioFormats c_result = SwigValueInit< cAudio::AudioFormats >() ;
|
||||
int jresult = 0 ;
|
||||
|
@ -1366,7 +1414,9 @@ cAudio::cAudioString SwigDirector_IAudioDecoder::getType() const {
|
|||
return c_result;
|
||||
}
|
||||
|
||||
void SwigDirector_IAudioDecoder::swig_connect_director(SWIG_Callback0_t callbackgetFormat, SWIG_Callback1_t callbackgetFrequency, SWIG_Callback2_t callbackisSeekingSupported, SWIG_Callback3_t callbackisValid, SWIG_Callback4_t callbackreadAudioData, SWIG_Callback5_t callbacksetPosition, SWIG_Callback6_t callbackseek, SWIG_Callback7_t callbackgetTotalTime, SWIG_Callback8_t callbackgetTotalSize, SWIG_Callback9_t callbackgetCompressedSize, SWIG_Callback10_t callbackgetCurrentTime, SWIG_Callback11_t callbackgetCurrentPosition, SWIG_Callback12_t callbackgetCurrentCompressedPosition, SWIG_Callback13_t callbackgetType) {
|
||||
void SwigDirector_IAudioDecoder::swig_connect_director(SWIG_Callback0_t callbackgrab, SWIG_Callback1_t callbackdrop, SWIG_Callback2_t callbackgetFormat, SWIG_Callback3_t callbackgetFrequency, SWIG_Callback4_t callbackisSeekingSupported, SWIG_Callback5_t callbackisValid, SWIG_Callback6_t callbackreadAudioData, SWIG_Callback7_t callbacksetPosition, SWIG_Callback8_t callbackseek, SWIG_Callback9_t callbackgetTotalTime, SWIG_Callback10_t callbackgetTotalSize, SWIG_Callback11_t callbackgetCompressedSize, SWIG_Callback12_t callbackgetCurrentTime, SWIG_Callback13_t callbackgetCurrentPosition, SWIG_Callback14_t callbackgetCurrentCompressedPosition, SWIG_Callback15_t callbackgetType) {
|
||||
swig_callbackgrab = callbackgrab;
|
||||
swig_callbackdrop = callbackdrop;
|
||||
swig_callbackgetFormat = callbackgetFormat;
|
||||
swig_callbackgetFrequency = callbackgetFrequency;
|
||||
swig_callbackisSeekingSupported = callbackisSeekingSupported;
|
||||
|
@ -1384,6 +1434,8 @@ void SwigDirector_IAudioDecoder::swig_connect_director(SWIG_Callback0_t callback
|
|||
}
|
||||
|
||||
void SwigDirector_IAudioDecoder::swig_init_callbacks() {
|
||||
swig_callbackgrab = 0;
|
||||
swig_callbackdrop = 0;
|
||||
swig_callbackgetFormat = 0;
|
||||
swig_callbackgetFrequency = 0;
|
||||
swig_callbackisSeekingSupported = 0;
|
||||
|
@ -1437,6 +1489,46 @@ void SwigDirector_IAudioDecoderFactory::swig_init_callbacks() {
|
|||
extern "C" {
|
||||
#endif
|
||||
|
||||
SWIGEXPORT char * SWIGSTDCALL CSharp_toWINSTR(char * jarg1) {
|
||||
char * jresult ;
|
||||
char *arg1 = (char *) 0 ;
|
||||
char *result = 0 ;
|
||||
|
||||
arg1 = (char *)jarg1;
|
||||
result = (char *)cAudio::toWINSTR((char const *)arg1);
|
||||
jresult = SWIG_csharp_string_callback((const char *)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT char * SWIGSTDCALL CSharp_toUTF8(void * jarg1) {
|
||||
char * jresult ;
|
||||
cAudio::cAudioString *arg1 = 0 ;
|
||||
char *result = 0 ;
|
||||
|
||||
arg1 = (cAudio::cAudioString *)jarg1;
|
||||
if (!arg1) {
|
||||
SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "cAudio::cAudioString const & type is null", 0);
|
||||
return 0;
|
||||
}
|
||||
result = (char *)cAudio::toUTF8((std::basic_string< char > const &)*arg1);
|
||||
jresult = SWIG_csharp_string_callback((const char *)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_fromUTF8(char * jarg1) {
|
||||
void * jresult ;
|
||||
char *arg1 = (char *) 0 ;
|
||||
cAudio::cAudioString result;
|
||||
|
||||
arg1 = (char *)jarg1;
|
||||
result = cAudio::fromUTF8((char const *)arg1);
|
||||
jresult = new cAudio::cAudioString((const cAudio::cAudioString &)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_IMemoryProvider_Allocate(void * jarg1, unsigned long jarg2, char * jarg3, int jarg4, char * jarg5) {
|
||||
void * jresult ;
|
||||
cAudio::IMemoryProvider *arg1 = (cAudio::IMemoryProvider *) 0 ;
|
||||
|
@ -1545,46 +1637,6 @@ SWIGEXPORT void SWIGSTDCALL CSharp_cAudioSleep(unsigned int jarg1) {
|
|||
}
|
||||
|
||||
|
||||
SWIGEXPORT char * SWIGSTDCALL CSharp_toWINSTR(char * jarg1) {
|
||||
char * jresult ;
|
||||
char *arg1 = (char *) 0 ;
|
||||
char *result = 0 ;
|
||||
|
||||
arg1 = (char *)jarg1;
|
||||
result = (char *)cAudio::toWINSTR((char const *)arg1);
|
||||
jresult = SWIG_csharp_string_callback((const char *)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT char * SWIGSTDCALL CSharp_toUTF8(void * jarg1) {
|
||||
char * jresult ;
|
||||
cAudio::cAudioString *arg1 = 0 ;
|
||||
char *result = 0 ;
|
||||
|
||||
arg1 = (cAudio::cAudioString *)jarg1;
|
||||
if (!arg1) {
|
||||
SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "cAudio::cAudioString const & type is null", 0);
|
||||
return 0;
|
||||
}
|
||||
result = (char *)cAudio::toUTF8(*arg1);
|
||||
jresult = SWIG_csharp_string_callback((const char *)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_fromUTF8(char * jarg1) {
|
||||
void * jresult ;
|
||||
char *arg1 = (char *) 0 ;
|
||||
cAudio::cAudioString result;
|
||||
|
||||
arg1 = (char *)jarg1;
|
||||
result = cAudio::fromUTF8((char const *)arg1);
|
||||
jresult = new cAudio::cAudioString((const cAudio::cAudioString &)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT unsigned int SWIGSTDCALL CSharp_IAudioDeviceList_getDeviceCount(void * jarg1) {
|
||||
unsigned int jresult ;
|
||||
cAudio::IAudioDeviceList *arg1 = (cAudio::IAudioDeviceList *) 0 ;
|
||||
|
@ -1793,11 +1845,11 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_IDataSource_seek(void * jarg1, int ja
|
|||
}
|
||||
|
||||
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_IDataSource_director_connect(void *objarg, SwigDirector_IDataSource::SWIG_Callback0_t callback0, SwigDirector_IDataSource::SWIG_Callback1_t callback1, SwigDirector_IDataSource::SWIG_Callback2_t callback2, SwigDirector_IDataSource::SWIG_Callback3_t callback3, SwigDirector_IDataSource::SWIG_Callback4_t callback4) {
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_IDataSource_director_connect(void *objarg, SwigDirector_IDataSource::SWIG_Callback0_t callback0, SwigDirector_IDataSource::SWIG_Callback1_t callback1, SwigDirector_IDataSource::SWIG_Callback2_t callback2, SwigDirector_IDataSource::SWIG_Callback3_t callback3, SwigDirector_IDataSource::SWIG_Callback4_t callback4, SwigDirector_IDataSource::SWIG_Callback5_t callback5, SwigDirector_IDataSource::SWIG_Callback6_t callback6) {
|
||||
cAudio::IDataSource *obj = (cAudio::IDataSource *)objarg;
|
||||
SwigDirector_IDataSource *director = dynamic_cast<SwigDirector_IDataSource *>(obj);
|
||||
if (director) {
|
||||
director->swig_connect_director(callback0, callback1, callback2, callback3, callback4);
|
||||
director->swig_connect_director(callback0, callback1, callback2, callback3, callback4, callback5, callback6);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3612,11 +3664,11 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_IAudioDecoder_getType(void * jarg1) {
|
|||
}
|
||||
|
||||
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_IAudioDecoder_director_connect(void *objarg, SwigDirector_IAudioDecoder::SWIG_Callback0_t callback0, SwigDirector_IAudioDecoder::SWIG_Callback1_t callback1, SwigDirector_IAudioDecoder::SWIG_Callback2_t callback2, SwigDirector_IAudioDecoder::SWIG_Callback3_t callback3, SwigDirector_IAudioDecoder::SWIG_Callback4_t callback4, SwigDirector_IAudioDecoder::SWIG_Callback5_t callback5, SwigDirector_IAudioDecoder::SWIG_Callback6_t callback6, SwigDirector_IAudioDecoder::SWIG_Callback7_t callback7, SwigDirector_IAudioDecoder::SWIG_Callback8_t callback8, SwigDirector_IAudioDecoder::SWIG_Callback9_t callback9, SwigDirector_IAudioDecoder::SWIG_Callback10_t callback10, SwigDirector_IAudioDecoder::SWIG_Callback11_t callback11, SwigDirector_IAudioDecoder::SWIG_Callback12_t callback12, SwigDirector_IAudioDecoder::SWIG_Callback13_t callback13) {
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_IAudioDecoder_director_connect(void *objarg, SwigDirector_IAudioDecoder::SWIG_Callback0_t callback0, SwigDirector_IAudioDecoder::SWIG_Callback1_t callback1, SwigDirector_IAudioDecoder::SWIG_Callback2_t callback2, SwigDirector_IAudioDecoder::SWIG_Callback3_t callback3, SwigDirector_IAudioDecoder::SWIG_Callback4_t callback4, SwigDirector_IAudioDecoder::SWIG_Callback5_t callback5, SwigDirector_IAudioDecoder::SWIG_Callback6_t callback6, SwigDirector_IAudioDecoder::SWIG_Callback7_t callback7, SwigDirector_IAudioDecoder::SWIG_Callback8_t callback8, SwigDirector_IAudioDecoder::SWIG_Callback9_t callback9, SwigDirector_IAudioDecoder::SWIG_Callback10_t callback10, SwigDirector_IAudioDecoder::SWIG_Callback11_t callback11, SwigDirector_IAudioDecoder::SWIG_Callback12_t callback12, SwigDirector_IAudioDecoder::SWIG_Callback13_t callback13, SwigDirector_IAudioDecoder::SWIG_Callback14_t callback14, SwigDirector_IAudioDecoder::SWIG_Callback15_t callback15) {
|
||||
cAudio::IAudioDecoder *obj = (cAudio::IAudioDecoder *)objarg;
|
||||
SwigDirector_IAudioDecoder *director = dynamic_cast<SwigDirector_IAudioDecoder *>(obj);
|
||||
if (director) {
|
||||
director->swig_connect_director(callback0, callback1, callback2, callback3, callback4, callback5, callback6, callback7, callback8, callback9, callback10, callback11, callback12, callback13);
|
||||
director->swig_connect_director(callback0, callback1, callback2, callback3, callback4, callback5, callback6, callback7, callback8, callback9, callback10, callback11, callback12, callback13, callback14, callback15);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3790,6 +3842,156 @@ SWIGEXPORT void SWIGSTDCALL CSharp_IAudioManager_release(void * jarg1, void * ja
|
|||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_IAudioManager_play2D__SWIG_0(void * jarg1, char * jarg2, unsigned int jarg3, unsigned int jarg4) {
|
||||
void * jresult ;
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
char *arg2 = (char *) 0 ;
|
||||
bool arg3 ;
|
||||
bool arg4 ;
|
||||
cAudio::IAudioSource *result = 0 ;
|
||||
|
||||
arg1 = (cAudio::IAudioManager *)jarg1;
|
||||
arg2 = (char *)jarg2;
|
||||
arg3 = jarg3 ? true : false;
|
||||
arg4 = jarg4 ? true : false;
|
||||
result = (cAudio::IAudioSource *)(arg1)->play2D((char const *)arg2,arg3,arg4);
|
||||
jresult = (void *)result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_IAudioManager_play2D__SWIG_1(void * jarg1, char * jarg2, unsigned int jarg3) {
|
||||
void * jresult ;
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
char *arg2 = (char *) 0 ;
|
||||
bool arg3 ;
|
||||
cAudio::IAudioSource *result = 0 ;
|
||||
|
||||
arg1 = (cAudio::IAudioManager *)jarg1;
|
||||
arg2 = (char *)jarg2;
|
||||
arg3 = jarg3 ? true : false;
|
||||
result = (cAudio::IAudioSource *)(arg1)->play2D((char const *)arg2,arg3);
|
||||
jresult = (void *)result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_IAudioManager_play2D__SWIG_2(void * jarg1, char * jarg2) {
|
||||
void * jresult ;
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
char *arg2 = (char *) 0 ;
|
||||
cAudio::IAudioSource *result = 0 ;
|
||||
|
||||
arg1 = (cAudio::IAudioManager *)jarg1;
|
||||
arg2 = (char *)jarg2;
|
||||
result = (cAudio::IAudioSource *)(arg1)->play2D((char const *)arg2);
|
||||
jresult = (void *)result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_IAudioManager_play3D__SWIG_0(void * jarg1, char * jarg2, void * jarg3, unsigned int jarg4, unsigned int jarg5) {
|
||||
void * jresult ;
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
char *arg2 = (char *) 0 ;
|
||||
cAudio::cVector3 arg3 ;
|
||||
bool arg4 ;
|
||||
bool arg5 ;
|
||||
cAudio::cVector3 *argp3 ;
|
||||
cAudio::IAudioSource *result = 0 ;
|
||||
|
||||
arg1 = (cAudio::IAudioManager *)jarg1;
|
||||
arg2 = (char *)jarg2;
|
||||
argp3 = (cAudio::cVector3 *)jarg3;
|
||||
if (!argp3) {
|
||||
SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null cAudio::cVector3", 0);
|
||||
return 0;
|
||||
}
|
||||
arg3 = *argp3;
|
||||
arg4 = jarg4 ? true : false;
|
||||
arg5 = jarg5 ? true : false;
|
||||
result = (cAudio::IAudioSource *)(arg1)->play3D((char const *)arg2,arg3,arg4,arg5);
|
||||
jresult = (void *)result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_IAudioManager_play3D__SWIG_1(void * jarg1, char * jarg2, void * jarg3, unsigned int jarg4) {
|
||||
void * jresult ;
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
char *arg2 = (char *) 0 ;
|
||||
cAudio::cVector3 arg3 ;
|
||||
bool arg4 ;
|
||||
cAudio::cVector3 *argp3 ;
|
||||
cAudio::IAudioSource *result = 0 ;
|
||||
|
||||
arg1 = (cAudio::IAudioManager *)jarg1;
|
||||
arg2 = (char *)jarg2;
|
||||
argp3 = (cAudio::cVector3 *)jarg3;
|
||||
if (!argp3) {
|
||||
SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null cAudio::cVector3", 0);
|
||||
return 0;
|
||||
}
|
||||
arg3 = *argp3;
|
||||
arg4 = jarg4 ? true : false;
|
||||
result = (cAudio::IAudioSource *)(arg1)->play3D((char const *)arg2,arg3,arg4);
|
||||
jresult = (void *)result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_IAudioManager_play3D__SWIG_2(void * jarg1, char * jarg2, void * jarg3) {
|
||||
void * jresult ;
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
char *arg2 = (char *) 0 ;
|
||||
cAudio::cVector3 arg3 ;
|
||||
cAudio::cVector3 *argp3 ;
|
||||
cAudio::IAudioSource *result = 0 ;
|
||||
|
||||
arg1 = (cAudio::IAudioManager *)jarg1;
|
||||
arg2 = (char *)jarg2;
|
||||
argp3 = (cAudio::cVector3 *)jarg3;
|
||||
if (!argp3) {
|
||||
SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null cAudio::cVector3", 0);
|
||||
return 0;
|
||||
}
|
||||
arg3 = *argp3;
|
||||
result = (cAudio::IAudioSource *)(arg1)->play3D((char const *)arg2,arg3);
|
||||
jresult = (void *)result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_IAudioManager_setMasterVolume(void * jarg1, float jarg2) {
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
float arg2 ;
|
||||
|
||||
arg1 = (cAudio::IAudioManager *)jarg1;
|
||||
arg2 = (float)jarg2;
|
||||
(arg1)->setMasterVolume(arg2);
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT float SWIGSTDCALL CSharp_IAudioManager_getMasterVolume(void * jarg1) {
|
||||
float jresult ;
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
float result;
|
||||
|
||||
arg1 = (cAudio::IAudioManager *)jarg1;
|
||||
result = (float)((cAudio::IAudioManager const *)arg1)->getMasterVolume();
|
||||
jresult = result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_IAudioManager_stopAllSounds(void * jarg1) {
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
|
||||
arg1 = (cAudio::IAudioManager *)jarg1;
|
||||
(arg1)->stopAllSounds();
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_IAudioManager_create__SWIG_0(void * jarg1, char * jarg2, char * jarg3, unsigned int jarg4) {
|
||||
void * jresult ;
|
||||
cAudio::IAudioManager *arg1 = (cAudio::IAudioManager *) 0 ;
|
||||
|
|
|
@ -16,25 +16,31 @@ class SwigDirector_IDataSource : public cAudio::IDataSource, public Swig::Direct
|
|||
public:
|
||||
SwigDirector_IDataSource();
|
||||
virtual ~SwigDirector_IDataSource();
|
||||
virtual void grab();
|
||||
virtual bool drop();
|
||||
virtual bool isValid();
|
||||
virtual int getCurrentPos();
|
||||
virtual int getSize();
|
||||
virtual int read(void *output, int size);
|
||||
virtual bool seek(int amount, bool relative);
|
||||
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback0_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback1_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback2_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback3_t)(void *, int);
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback4_t)(int, unsigned int);
|
||||
void swig_connect_director(SWIG_Callback0_t callbackisValid, SWIG_Callback1_t callbackgetCurrentPos, SWIG_Callback2_t callbackgetSize, SWIG_Callback3_t callbackread, SWIG_Callback4_t callbackseek);
|
||||
typedef void (SWIGSTDCALL* SWIG_Callback0_t)();
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback1_t)();
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback2_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback3_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback4_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback5_t)(void *, int);
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback6_t)(int, unsigned int);
|
||||
void swig_connect_director(SWIG_Callback0_t callbackgrab, SWIG_Callback1_t callbackdrop, SWIG_Callback2_t callbackisValid, SWIG_Callback3_t callbackgetCurrentPos, SWIG_Callback4_t callbackgetSize, SWIG_Callback5_t callbackread, SWIG_Callback6_t callbackseek);
|
||||
|
||||
private:
|
||||
SWIG_Callback0_t swig_callbackisValid;
|
||||
SWIG_Callback1_t swig_callbackgetCurrentPos;
|
||||
SWIG_Callback2_t swig_callbackgetSize;
|
||||
SWIG_Callback3_t swig_callbackread;
|
||||
SWIG_Callback4_t swig_callbackseek;
|
||||
SWIG_Callback0_t swig_callbackgrab;
|
||||
SWIG_Callback1_t swig_callbackdrop;
|
||||
SWIG_Callback2_t swig_callbackisValid;
|
||||
SWIG_Callback3_t swig_callbackgetCurrentPos;
|
||||
SWIG_Callback4_t swig_callbackgetSize;
|
||||
SWIG_Callback5_t swig_callbackread;
|
||||
SWIG_Callback6_t swig_callbackseek;
|
||||
void swig_init_callbacks();
|
||||
};
|
||||
|
||||
|
@ -156,6 +162,8 @@ class SwigDirector_IAudioDecoder : public cAudio::IAudioDecoder, public Swig::Di
|
|||
public:
|
||||
SwigDirector_IAudioDecoder(cAudio::IDataSource *stream);
|
||||
virtual ~SwigDirector_IAudioDecoder();
|
||||
virtual void grab();
|
||||
virtual bool drop();
|
||||
virtual cAudio::AudioFormats getFormat();
|
||||
virtual int getFrequency();
|
||||
virtual bool isSeekingSupported();
|
||||
|
@ -171,37 +179,41 @@ public:
|
|||
virtual int getCurrentCompressedPosition();
|
||||
virtual cAudio::cAudioString getType() const;
|
||||
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback0_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback1_t)();
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback2_t)();
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback3_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback4_t)(void *, int);
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback5_t)(int, unsigned int);
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback6_t)(float, unsigned int);
|
||||
typedef float (SWIGSTDCALL* SWIG_Callback7_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback8_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback9_t)();
|
||||
typedef float (SWIGSTDCALL* SWIG_Callback10_t)();
|
||||
typedef void (SWIGSTDCALL* SWIG_Callback0_t)();
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback1_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback2_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback3_t)();
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback4_t)();
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback5_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback6_t)(void *, int);
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback7_t)(int, unsigned int);
|
||||
typedef unsigned int (SWIGSTDCALL* SWIG_Callback8_t)(float, unsigned int);
|
||||
typedef float (SWIGSTDCALL* SWIG_Callback9_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback10_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback11_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback12_t)();
|
||||
typedef void * (SWIGSTDCALL* SWIG_Callback13_t)();
|
||||
void swig_connect_director(SWIG_Callback0_t callbackgetFormat, SWIG_Callback1_t callbackgetFrequency, SWIG_Callback2_t callbackisSeekingSupported, SWIG_Callback3_t callbackisValid, SWIG_Callback4_t callbackreadAudioData, SWIG_Callback5_t callbacksetPosition, SWIG_Callback6_t callbackseek, SWIG_Callback7_t callbackgetTotalTime, SWIG_Callback8_t callbackgetTotalSize, SWIG_Callback9_t callbackgetCompressedSize, SWIG_Callback10_t callbackgetCurrentTime, SWIG_Callback11_t callbackgetCurrentPosition, SWIG_Callback12_t callbackgetCurrentCompressedPosition, SWIG_Callback13_t callbackgetType);
|
||||
typedef float (SWIGSTDCALL* SWIG_Callback12_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback13_t)();
|
||||
typedef int (SWIGSTDCALL* SWIG_Callback14_t)();
|
||||
typedef void * (SWIGSTDCALL* SWIG_Callback15_t)();
|
||||
void swig_connect_director(SWIG_Callback0_t callbackgrab, SWIG_Callback1_t callbackdrop, SWIG_Callback2_t callbackgetFormat, SWIG_Callback3_t callbackgetFrequency, SWIG_Callback4_t callbackisSeekingSupported, SWIG_Callback5_t callbackisValid, SWIG_Callback6_t callbackreadAudioData, SWIG_Callback7_t callbacksetPosition, SWIG_Callback8_t callbackseek, SWIG_Callback9_t callbackgetTotalTime, SWIG_Callback10_t callbackgetTotalSize, SWIG_Callback11_t callbackgetCompressedSize, SWIG_Callback12_t callbackgetCurrentTime, SWIG_Callback13_t callbackgetCurrentPosition, SWIG_Callback14_t callbackgetCurrentCompressedPosition, SWIG_Callback15_t callbackgetType);
|
||||
|
||||
private:
|
||||
SWIG_Callback0_t swig_callbackgetFormat;
|
||||
SWIG_Callback1_t swig_callbackgetFrequency;
|
||||
SWIG_Callback2_t swig_callbackisSeekingSupported;
|
||||
SWIG_Callback3_t swig_callbackisValid;
|
||||
SWIG_Callback4_t swig_callbackreadAudioData;
|
||||
SWIG_Callback5_t swig_callbacksetPosition;
|
||||
SWIG_Callback6_t swig_callbackseek;
|
||||
SWIG_Callback7_t swig_callbackgetTotalTime;
|
||||
SWIG_Callback8_t swig_callbackgetTotalSize;
|
||||
SWIG_Callback9_t swig_callbackgetCompressedSize;
|
||||
SWIG_Callback10_t swig_callbackgetCurrentTime;
|
||||
SWIG_Callback11_t swig_callbackgetCurrentPosition;
|
||||
SWIG_Callback12_t swig_callbackgetCurrentCompressedPosition;
|
||||
SWIG_Callback13_t swig_callbackgetType;
|
||||
SWIG_Callback0_t swig_callbackgrab;
|
||||
SWIG_Callback1_t swig_callbackdrop;
|
||||
SWIG_Callback2_t swig_callbackgetFormat;
|
||||
SWIG_Callback3_t swig_callbackgetFrequency;
|
||||
SWIG_Callback4_t swig_callbackisSeekingSupported;
|
||||
SWIG_Callback5_t swig_callbackisValid;
|
||||
SWIG_Callback6_t swig_callbackreadAudioData;
|
||||
SWIG_Callback7_t swig_callbacksetPosition;
|
||||
SWIG_Callback8_t swig_callbackseek;
|
||||
SWIG_Callback9_t swig_callbackgetTotalTime;
|
||||
SWIG_Callback10_t swig_callbackgetTotalSize;
|
||||
SWIG_Callback11_t swig_callbackgetCompressedSize;
|
||||
SWIG_Callback12_t swig_callbackgetCurrentTime;
|
||||
SWIG_Callback13_t swig_callbackgetCurrentPosition;
|
||||
SWIG_Callback14_t swig_callbackgetCurrentCompressedPosition;
|
||||
SWIG_Callback15_t swig_callbackgetType;
|
||||
void swig_init_callbacks();
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue