Audaspace: fix for building with scons.
authorJörg Müller <nexyon@gmail.com>
Sat, 29 Aug 2015 20:42:20 +0000 (22:42 +0200)
committerJörg Müller <nexyon@gmail.com>
Sat, 29 Aug 2015 20:42:20 +0000 (22:42 +0200)
Removed duplicated code.
CMake so far built only the now removed version and scons tried to build both.

intern/audaspace/CMakeLists.txt
intern/audaspace/intern/AUD_C-API.cpp

index 7fecb1a48a77657fe5c8273c75fc4e251bda2b29..b3682a778750522f7758987d637366ee0a044182 100644 (file)
@@ -164,6 +164,8 @@ set(SRC
        intern/AUD_SequencerHandle.h
        intern/AUD_SequencerReader.cpp
        intern/AUD_SequencerReader.h
+       intern/AUD_Set.cpp
+       intern/AUD_Set.h
        intern/AUD_SilenceFactory.cpp
        intern/AUD_SilenceFactory.h
        intern/AUD_SilenceReader.cpp
index 2d9a8e0ebc8bbb8589322430d3e374fde6fa67a6..341f1cd3f6b62af6757cbf0c91f28c4fcd30fcd2 100644 (file)
@@ -41,7 +41,6 @@
 #  include "AUD_PyAPI.h"
 #endif
 
-#include <set>
 #include <cstdlib>
 #include <cstring>
 #include <cmath>
@@ -1224,44 +1223,6 @@ void AUD_Handle_free(AUD_Handle *handle)
        delete handle;
 }
 
-void *AUD_createSet()
-{
-       return new std::set<void *>();
-}
-
-void AUD_destroySet(void *set)
-{
-       delete reinterpret_cast<std::set<void *>*>(set);
-}
-
-char AUD_removeSet(void *set, void *entry)
-{
-       if (set)
-               return reinterpret_cast<std::set<void *>*>(set)->erase(entry);
-       return 0;
-}
-
-void AUD_addSet(void *set, void *entry)
-{
-       if (entry)
-               reinterpret_cast<std::set<void *>*>(set)->insert(entry);
-}
-
-void *AUD_getSet(void *set)
-{
-       if (set) {
-               std::set<void *>* rset = reinterpret_cast<std::set<void *>*>(set);
-               if (!rset->empty()) {
-                       std::set<void *>::iterator it = rset->begin();
-                       void *result = *it;
-                       rset->erase(it);
-                       return result;
-               }
-       }
-
-       return NULL;
-}
-
 const char *AUD_mixdown(AUD_Sound *sound, unsigned int start, unsigned int length, unsigned int buffersize, const char *filename, AUD_DeviceSpecs specs, AUD_Container format, AUD_Codec codec, unsigned int bitrate)
 {
        try {