/[svn]/linuxsampler/trunk/src/engines/gig/EGDecay.h
ViewVC logotype

Diff of /linuxsampler/trunk/src/engines/gig/EGDecay.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 828 by schoenebeck, Tue Aug 16 17:14:25 2005 UTC revision 829 by schoenebeck, Sat Jan 14 14:07:47 2006 UTC
# Line 3  Line 3 
3   *   LinuxSampler - modular, streaming capable sampler                     *   *   LinuxSampler - modular, streaming capable sampler                     *
4   *                                                                         *   *                                                                         *
5   *   Copyright (C) 2003, 2004 by Benno Senoner and Christian Schoenebeck   *   *   Copyright (C) 2003, 2004 by Benno Senoner and Christian Schoenebeck   *
6   *   Copyright (C) 2005 Christian Schoenebeck                              *   *   Copyright (C) 2005, 2006 Christian Schoenebeck                        *
7   *                                                                         *   *                                                                         *
8   *   This library is free software; you can redistribute it and/or modify  *   *   This library is free software; you can redistribute it and/or modify  *
9   *   it under the terms of the GNU General Public License as published by  *   *   it under the terms of the GNU General Public License as published by  *
# Line 93  namespace LinuxSampler { namespace gig { Line 93  namespace LinuxSampler { namespace gig {
93                  return (Level += Coeff);                  return (Level += Coeff);
94              }              }
95    
96                /**
97                 * Returns the level which this envelope will have in
98                 * \a SamplePoints steps. It will not alter anything.
99                 */
100                inline float level(const int SamplePoints) const {
101                    return Level + RTMath::Min(SamplePoints, StepsLeft) * Coeff;
102                }
103    
104          private:          private:
105              float Level;     ///< current EG output level              float Level;     ///< current EG output level
106              float Coeff;     ///< linear coefficient for changing the output level in time              float Coeff;     ///< linear coefficient for changing the output level in time

Legend:
Removed from v.828  
changed lines
  Added in v.829

  ViewVC Help
Powered by ViewVC