X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Faudio_filter.cc;h=3d3ecdfbb3deed7bfef315818646ffaf12e0dac3;hb=7c839a2530c910f062f3da8a02b7c70603c1f31b;hp=2c92236b6f55fe1b2a0c4ffd3bab3afaad30f5bb;hpb=2610abb85fc82056c51c540d7a3d8f691dfe3403;p=dcpomatic.git diff --git a/src/lib/audio_filter.cc b/src/lib/audio_filter.cc index 2c92236b6..3d3ecdfbb 100644 --- a/src/lib/audio_filter.cc +++ b/src/lib/audio_filter.cc @@ -1,24 +1,26 @@ /* Copyright (C) 2014 Carl Hetherington - This program is free software; you can redistribute it and/or modify + This file is part of DCP-o-matic. + + DCP-o-matic is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. - This program is distributed in the hope that it will be useful, + DCP-o-matic is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + along with DCP-o-matic. If not, see . */ #include "audio_filter.h" #include "audio_buffers.h" +#include "util.h" #include using std::min; @@ -104,7 +106,7 @@ AudioFilter::run (shared_ptr in) int const amount = min (in->frames(), _tail->frames()); if (amount < _tail->frames ()) { - _tail->move (amount, 0, _tail->frames() - amount); + _tail->move (_tail->frames() - amount, amount, 0); } _tail->copy_from (in.get(), amount, in->frames() - amount, _tail->frames () - amount);