gearmulator

Emulation of classic VA synths of the late 90s/2000s that are based on Motorola 56300 family DSPs
Log | Files | Refs | Submodules | README | LICENSE

README.md (4967B)


      1 libresample
      2 ===========
      3 
      4 Real-time library interface by Dominic Mazzoni
      5 
      6 Based on resample-1.7:
      7   http://www-ccrma.stanford.edu/~jos/resample/
      8 
      9 Two licenses available:
     10 License: LGPL - see LICENSE-LGPL.txt
     11 License: BSD - see LICENSE-BSD.txt
     12 
     13 History:
     14 
     15 This library is not the highest-quality resampling library
     16 available, nor is it the most flexible, nor is it the
     17 fastest.  But it is pretty good in all of these regards, and
     18 it is quite portable.  The best resampling library I am aware
     19 of is libsamplerate by Erik de Castro Lopo.  It's small, fast,
     20 and very high quality.  However, it uses the GPL for its
     21 license (with commercial options available) and I needed
     22 a more free library.  So I wrote this library, using
     23 the LGPL resample-1.7 library by Julius Smith as a basis.
     24 
     25 Resample-1.7 is a fixed-point resampler, and as a result
     26 has only limited precision.  I rewrote it to use single-precision
     27 floating-point arithmetic instead and increased the number
     28 of filter coefficients between time steps significantly.
     29 On modern processors it can resample in real time even
     30 with this extra overhead.
     31 
     32 Resample-1.7 was designed to read and write from files, so
     33 I removed all of that code and replaced it with an API that
     34 lets you pass samples in small chunks.  It should be easy
     35 to link to resample-1.7 as a library.
     36 
     37 Changes in version 0.1.3:
     38 
     39 * Fixed two bugs that were causing subtle problems
     40   on Intel x86 processors due to differences in roundoff errors.
     41 
     42 * Prefixed most function names with lrs and changed header file
     43   from resample.h to libresample.h, to avoid namespace
     44   collisions with existing programs and libraries.
     45 
     46 * Added resample_dup (thanks to Glenn Maynard)
     47 
     48 * Argument to resample_get_filter_width takes a const void *
     49   (thanks to Glenn Maynard)
     50 
     51 * resample-sndfile clips output to -1...1 (thanks to Glenn Maynard)
     52 
     53 Changes in version 0.1.4:
     54 
     55 * Added BSD license, with support from all authors and contributors.
     56 
     57 * Uploaded to GitHub: http://github.com/minorninth/libresample
     58 
     59 Usage notes:  
     60 
     61 - If the output buffer you pass is too small, resample_process
     62   may not use any input samples because its internal output
     63   buffer is too full to process any more.  So do not assume
     64   that it is an error just because no input samples were
     65   consumed.  Just keep passing valid output buffers.
     66 
     67 - Given a resampling factor f > 1, and a number of input
     68   samples n, the number of output samples should be between
     69   floor(n - f) and ceil(n + f).  In other words, if you
     70   resample 1000 samples at a factor of 8, the number of
     71   output samples might be between 7992 and 8008.  Do not
     72   assume that it will be exactly 8000.  If you need exactly
     73   8000 outputs, pad the input with extra zeros as necessary.
     74 
     75 License and warranty:
     76 
     77 All of the files in this package are Copyright 2003 by Dominic
     78 Mazzoni <dominic@minorninth.com>.  This library was based heavily
     79 on Resample-1.7, Copyright 1994-2002 by Julius O. Smith III
     80 <jos@ccrma.stanford.edu>, all rights reserved.
     81 
     82 Permission to use and copy is granted subject to the terms of the
     83 "GNU Lesser General Public License" (LGPL) as published by the
     84 Free Software Foundation; either version 2.1 of the License,
     85 or any later version.  In addition, Julius O. Smith III requests
     86 that a copy of any modified files be sent by email to
     87 jos@ccrma.stanford.edu so that he may incorporate them into the
     88 CCRMA version.
     89 
     90    This library is distributed in the hope that it will be useful,
     91    but WITHOUT ANY WARRANTY; without even the implied warranty of
     92    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
     93    Lesser General Public License for more details.
     94 
     95 Permission to use and copy is also granted subject to the terms of the
     96 BSD license found in LICENSE-BSD.txt.
     97 
     98 Redistribution and use in source and binary forms, with or without modification,
     99 are permitted provided that the following conditions are met:
    100 
    101 * Redistributions of source code must retain the above copyright notice, this
    102   list of conditions and the following disclaimer.
    103 
    104 * Redistributions in binary form must reproduce the above copyright notice, this
    105   list of conditions and the following disclaimer in the documentation and/or
    106   other materials provided with the distribution.
    107 
    108 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
    109 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
    110 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
    111 DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
    112 ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
    113 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
    114 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
    115 ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    116 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
    117 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.