Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
path: root/src/audio
diff options
context:
space:
mode:
Diffstat (limited to 'src/audio')
-rw-r--r--src/audio/buffers.cc2
-rw-r--r--src/audio/pcm.cc13
-rw-r--r--src/audio/pcm.h5
3 files changed, 2 insertions, 18 deletions
diff --git a/src/audio/buffers.cc b/src/audio/buffers.cc
index dd83000..4e26c33 100644
--- a/src/audio/buffers.cc
+++ b/src/audio/buffers.cc
@@ -87,6 +87,8 @@ size_t Buffers::load(std::string name)
registry[name] = id;
index++;
+ delete pcm;
+
return id;
}
diff --git a/src/audio/pcm.cc b/src/audio/pcm.cc
index b485199..7a3f767 100644
--- a/src/audio/pcm.cc
+++ b/src/audio/pcm.cc
@@ -33,17 +33,4 @@ void PCM::clear()
memset(pcm_data, 0, pcm_size);
}
-void PCM::load(const char *name)
-{
- PCM *pcm = Wav::load(name);
- if (pcm) {
- delete pcm;
- }
-}
-
-void PCM::load(std::string const & name)
-{
- load(name.c_str());
-}
-
}
diff --git a/src/audio/pcm.h b/src/audio/pcm.h
index 740a23c..dc8eb16 100644
--- a/src/audio/pcm.h
+++ b/src/audio/pcm.h
@@ -38,11 +38,6 @@ public:
/// number of channels
inline unsigned int channels() const { return pcm_channels; }
- /// load PCM audio data from file
- static void load(std::string const & name);
-
- static void load(const char *name);
-
private:
unsigned char *pcm_data;