major fixes for MIDI patch change and note undo/redo. Patch change handling was compl...
[ardour.git] / libs / ardour / ardour / audiosource.h
index c6ec2a56ada30e0a905c2817b595a6943115022e..344541d945a1cefb61c4a606fd7df8b52d628737 100644 (file)
 #define __ardour_audio_source_h__
 
 #include <boost/shared_ptr.hpp>
+#include <boost/shared_array.hpp>
 #include <boost/enable_shared_from_this.hpp>
 
 #include <time.h>
 
-#include <glibmm/thread.h>
+#include <glibmm/threads.h>
 #include <boost/function.hpp>
 
 #include "ardour/source.h"
@@ -116,9 +117,9 @@ class AudioSource : virtual public Source,
           thread, or a lock around calls that use them.
        */
 
-       static std::vector<boost::shared_ptr<Sample> > _mixdown_buffers;
-       static std::vector<boost::shared_ptr<gain_t> > _gain_buffers;
-       static Glib::StaticMutex    _level_buffer_lock;
+        static std::vector<boost::shared_array<Sample> > _mixdown_buffers;
+       static std::vector<boost::shared_array<gain_t> > _gain_buffers;
+        static Glib::Threads::Mutex    _level_buffer_lock;
 
        static void ensure_buffers_for_level (uint32_t, framecnt_t);
        static void ensure_buffers_for_level_locked (uint32_t, framecnt_t);
@@ -157,7 +158,7 @@ class AudioSource : virtual public Source,
         *  PeaksReady means that _peaks_built cannot be changed
         *  during the handling of the signal.
         */
-       mutable Glib::Mutex _peaks_ready_lock;
+        mutable Glib::Threads::Mutex _peaks_ready_lock;
 
        PBD::FdFileDescriptor* _peakfile_descriptor;
        int        _peakfile_fd;