comparison audio/AudioCallbackPlaySource.cpp @ 551:b9d8c7a690d6 bqresample

Add a ResamplerWrapper
author Chris Cannam
date Wed, 07 Dec 2016 13:57:45 +0000
parents c732251237b1
children 8c11ca1ebc39
comparison
equal deleted inserted replaced
550:c732251237b1 551:b9d8c7a690d6
26 #include "data/model/ReadOnlyWaveFileModel.h" 26 #include "data/model/ReadOnlyWaveFileModel.h"
27 #include "data/model/SparseOneDimensionalModel.h" 27 #include "data/model/SparseOneDimensionalModel.h"
28 #include "plugin/RealTimePluginInstance.h" 28 #include "plugin/RealTimePluginInstance.h"
29 29
30 #include "bqaudioio/SystemPlaybackTarget.h" 30 #include "bqaudioio/SystemPlaybackTarget.h"
31 #include "bqaudioio/ResamplerWrapper.h"
31 32
32 #include <rubberband/RubberBandStretcher.h> 33 #include <rubberband/RubberBandStretcher.h>
33 using namespace RubberBand; 34 using namespace RubberBand;
34 35
35 #include <iostream> 36 #include <iostream>
75 m_stretchRatio(1.0), 76 m_stretchRatio(1.0),
76 m_stretchMono(false), 77 m_stretchMono(false),
77 m_stretcherInputCount(0), 78 m_stretcherInputCount(0),
78 m_stretcherInputs(0), 79 m_stretcherInputs(0),
79 m_stretcherInputSizes(0), 80 m_stretcherInputSizes(0),
80 m_fillThread(0) 81 m_fillThread(0),
82 m_resamplerWrapper(0)
81 { 83 {
82 m_viewManager->setAudioPlaySource(this); 84 m_viewManager->setAudioPlaySource(this);
83 85
84 connect(m_viewManager, SIGNAL(selectionChanged()), 86 connect(m_viewManager, SIGNAL(selectionChanged()),
85 this, SLOT(selectionChanged())); 87 this, SLOT(selectionChanged()));
568 570
569 void 571 void
570 AudioCallbackPlaySource::setSystemPlaybackTarget(breakfastquay::SystemPlaybackTarget *target) 572 AudioCallbackPlaySource::setSystemPlaybackTarget(breakfastquay::SystemPlaybackTarget *target)
571 { 573 {
572 m_target = target; 574 m_target = target;
575 }
576
577 void
578 AudioCallbackPlaySource::setResamplerWrapper(breakfastquay::ResamplerWrapper *w)
579 {
580 m_resamplerWrapper = w;
573 } 581 }
574 582
575 void 583 void
576 AudioCallbackPlaySource::setSystemPlaybackBlockSize(int size) 584 AudioCallbackPlaySource::setSystemPlaybackBlockSize(int size)
577 { 585 {