[SCM] calf/master: + Monosynth: 3 more waveforms

js at users.alioth.debian.org js at users.alioth.debian.org
Tue May 7 15:36:48 UTC 2013


The following commit has been merged in the master branch:
commit d5bbbe0ddbb923b95d4bb2fe0861f3f65f59afa4
Author: kfoltman <kfoltman at 78b06b96-2940-0410-b7fc-879d825d01d8>
Date:   Sun Dec 23 15:45:50 2007 +0000

    + Monosynth: 3 more waveforms
    
    
    
    git-svn-id: https://calf.svn.sourceforge.net/svnroot/calf/trunk@39 78b06b96-2940-0410-b7fc-879d825d01d8

diff --git a/src/calf/modules_synths.h b/src/calf/modules_synths.h
index 258b3cb..a29ecd3 100644
--- a/src/calf/modules_synths.h
+++ b/src/calf/modules_synths.h
@@ -35,7 +35,7 @@ namespace synth {
 class monosynth_audio_module: public null_audio_module
 {
 public:
-    enum { wave_saw, wave_sqr, wave_pulse, wave_sine, wave_triangle, wave_count };
+    enum { wave_saw, wave_sqr, wave_pulse, wave_sine, wave_triangle, wave_varistep, wave_skewsaw, wave_skewsqr, wave_count };
     enum { flt_lp12, flt_lp24, flt_2lp12, flt_hp12, flt_lpbr, flt_hpbr, flt_bp6, flt_2bp6 };
     enum { par_wave1, par_wave2, par_detune, par_osc2xpose, par_oscmode, par_oscmix, par_filtertype, par_cutoff, par_resonance, par_cutoffsep, par_envmod, par_envtores, par_envtoamp, par_attack, par_decay, par_sustain, par_release, par_keyfollow, par_legato, par_portamento, par_vel2filter, par_vel2amp, param_count };
     enum { in_count = 0, out_count = 2, support_midi = true, rt_capable = true };
@@ -200,6 +200,22 @@ public:
             data[i + 1536] = -1 + i / 512.0;
         }
         waves[wave_triangle].make(bl, data);
+        
+        for (int i = 0, j = 1; i < 2048; i++) {
+            data[i] = -1 + j / 1024.0;
+            if (i == j)
+                j *= 2;
+        }
+        waves[wave_varistep].make(bl, data);
+
+        for (int i = 0; i < 2048; i++) {
+            data[i] = -1 + fmod (i * i / 8192.0, 2.0);
+        }
+        waves[wave_skewsaw].make(bl, data);
+        for (int i = 0; i < 2048; i++) {
+            data[i] = fmod (i * i / 2048.0, 2.0) < 1.0 ? -1.0 : +1.0;
+        }
+        waves[wave_skewsqr].make(bl, data);
     }
     void deactivate() {
     }
diff --git a/src/modules.cpp b/src/modules.cpp
index 81ed974..3dfb323 100644
--- a/src/modules.cpp
+++ b/src/modules.cpp
@@ -175,7 +175,7 @@ const char *monosynth_audio_module::port_names[] = {
     "Out L", "Out R", 
 };
 
-const char *monosynth_waveform_names[] = { "Sawtooth", "Square", "Pulse", "Sine", "Triangle" };
+const char *monosynth_waveform_names[] = { "Sawtooth", "Square", "Pulse", "Sine", "Triangle", "Varistep", "Skewed Saw", "Skewed Square" };
 const char *monosynth_mode_names[] = { "0 : 0", "0 : 180", "0 : 90", "90 : 90", "90 : 270", "Random" };
 const char *monosynth_legato_names[] = { "Retrig", "Legato", "Fng Retrig", "Fng Legato" };
 

-- 
calf audio plugins packaging



More information about the pkg-multimedia-commits mailing list