Copyright dates

This commit is contained in:
Chris Cannam
2021-01-08 17:13:52 +00:00
55 changed files with 601 additions and 428 deletions

View File

@@ -5,7 +5,7 @@ An audio time-stretching and pitch-shifting library and utility program.
Written by Chris Cannam, chris.cannam@breakfastquay.com.
Published by Particular Programs Ltd t/a Breakfast Quay.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
Rubber Band is a library and utility program that permits changing the
tempo and pitch of an audio recording independently of one another.

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
@@ -199,7 +199,7 @@ int main(int argc, char **argv)
cerr << endl;
cerr << "Rubber Band" << endl;
cerr << "An audio time-stretching and pitch-shifting library and utility program." << endl;
cerr << "Copyright 2007-2020 Particular Programs Ltd." << endl;
cerr << "Copyright 2007-2021 Particular Programs Ltd." << endl;
cerr << endl;
cerr << " Usage: " << argv[0] << " [options] <infile.wav> <outfile.wav>" << endl;
cerr << endl;

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
@@ -672,9 +672,12 @@ RubberBandStretcher::Impl::configure()
if (m_channelData[c]->resampler) continue;
m_channelData[c]->resampler =
new Resampler(Resampler::FastestTolerable, 1, 4096 * 16,
m_debugLevel);
Resampler::Parameters params;
params.quality = Resampler::FastestTolerable;
params.maxBufferSize = 4096 * 16;
params.debugLevel = m_debugLevel;
m_channelData[c]->resampler = new Resampler(params, 1);
// rbs is the amount of buffer space we think we'll need
// for resampling; but allocate a sensible amount in case
@@ -813,9 +816,12 @@ RubberBandStretcher::Impl::reconfigure()
std::cerr << "WARNING: reconfigure(): resampler construction required in RT mode" << std::endl;
m_channelData[c]->resampler =
new Resampler(Resampler::FastestTolerable, 1, m_sWindowSize,
m_debugLevel);
Resampler::Parameters params;
params.quality = Resampler::FastestTolerable;
params.maxBufferSize = m_sWindowSize;
params.debugLevel = m_debugLevel;
m_channelData[c]->resampler = new Resampler(params, 1);
size_t rbs =
lrintf(ceil((m_increment * m_timeRatio * 2) / m_pitchScale));

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
@@ -217,8 +217,9 @@ RubberBandStretcher::Impl::consumeChannel(size_t c,
input = inputs[c] + offset;
}
toWrite = cd.resampler->resample(&input,
&cd.resamplebuf,
toWrite = cd.resampler->resample(&cd.resamplebuf,
cd.resamplebufSize,
&input,
samples,
1.0 / m_pitchScale,
final);
@@ -1090,8 +1091,9 @@ RubberBandStretcher::Impl::writeChunk(size_t channel, size_t shiftIncrement, boo
#endif
#endif
size_t outframes = cd.resampler->resample(&cd.accumulator,
&cd.resamplebuf,
size_t outframes = cd.resampler->resample(&cd.resamplebuf,
cd.resamplebufSize,
&cd.accumulator,
si,
1.0 / m_pitchScale,
last);

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

File diff suppressed because it is too large Load Diff

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
@@ -21,60 +21,118 @@
you must obtain a valid commercial licence before doing so.
*/
#ifndef _RUBBERBAND_RESAMPLER_H_
#define _RUBBERBAND_RESAMPLER_H_
#ifndef RUBBERBAND_RESAMPLER_H
#define RUBBERBAND_RESAMPLER_H
#include "system/sysutils.h"
namespace RubberBand {
class ResamplerImpl;
class Resampler
{
public:
enum Quality { Best, FastestTolerable, Fastest };
enum Exception { ImplementationError };
struct Parameters {
/**
* Construct a resampler with the given quality level and channel
* count. maxBufferSize gives a bound on the maximum incount size
* that may be passed to the resample function before the
* resampler needs to reallocate its internal buffers.
* Resampler filter quality level.
*/
Resampler(Quality quality, int channels, int maxBufferSize = 0,
int debugLevel = 0);
Quality quality;
/**
* Rate of expected input prior to resampling: may be used to
* determine the filter bandwidth for the quality setting. If
* you don't know what this will be, you can provide an
* arbitrary rate (such as the default) and the resampler will
* work fine, but quality may not be as designed.
*/
double initialSampleRate;
/**
* Bound on the maximum incount size that may be passed to the
* resample function before the resampler needs to reallocate
* its internal buffers. Default is zero, so that buffer
* allocation will happen on the first call and any subsequent
* call with a greater incount.
*/
int maxBufferSize;
/**
* Debug output level, from 0 to 3. Controls the amount of
* debug information printed to stderr.
*/
int debugLevel;
Parameters() :
quality(FastestTolerable),
initialSampleRate(44100),
maxBufferSize(0),
debugLevel(0) { }
};
/**
* Construct a resampler to process the given number of channels,
* with the given quality level, initial sample rate, and other
* parameters.
*/
Resampler(Parameters parameters, int channels);
~Resampler();
/**
* Resample the given multi-channel buffers, where incount is the
* number of frames in the input buffers. Returns the number of
* frames written to the output buffers.
* number of frames in the input buffers and outspace is the space
* available in the output buffers. Generally you want outspace to
* be at least ceil(incount * ratio).
*
* Returns the number of frames written to the output
* buffers. This may be smaller than outspace even where the ratio
* suggests otherwise, particularly at the start of processing
* where there may be a filter tail to allow for.
*/
int resample(const float *const R__ *const R__ in,
float *const R__ *const R__ out,
#ifdef __GNUC__
__attribute__((warn_unused_result))
#endif
int resample(float *const R__ *const R__ out,
int outspace,
const float *const R__ *const R__ in,
int incount,
float ratio,
double ratio,
bool final = false);
/**
* Resample the given interleaved buffer, where incount is the
* number of frames in the input buffer (i.e. it has incount *
* getChannelCount() samples). Returns the number of frames
* written to the output buffer.
* getChannelCount() samples) and outspace is the space available
* in frames in the output buffer (i.e. it has space for at least
* outspace * getChannelCount() samples). Generally you want
* outspace to be at least ceil(incount * ratio).
*
* Returns the number of frames written to the output buffer. This
* may be smaller than outspace even where the ratio suggests
* otherwise, particularly at the start of processing where there
* may be a filter tail to allow for.
*/
int resampleInterleaved(const float *const R__ in,
float *const R__ out,
#ifdef __GNUC__
__attribute__((warn_unused_result))
#endif
int resampleInterleaved(float *const R__ out,
int outspace,
const float *const R__ in,
int incount,
float ratio,
double ratio,
bool final = false);
int getChannelCount() const;
void reset();
class Impl;
protected:
ResamplerImpl *d;
Impl *d;
int m_method;
};

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
@@ -21,8 +21,8 @@
you must obtain a valid commercial licence before doing so.
*/
#ifndef _RUBBERBAND_ALLOCATORS_H_
#define _RUBBERBAND_ALLOCATORS_H_
#ifndef RUBBERBAND_ALLOCATORS_H
#define RUBBERBAND_ALLOCATORS_H
#include "VectorOps.h"

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as

View File

@@ -3,7 +3,7 @@
/*
Rubber Band Library
An audio time-stretching and pitch-shifting library.
Copyright 2007-2020 Particular Programs Ltd.
Copyright 2007-2021 Particular Programs Ltd.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as