diff -Nru din-55/CHANGELOG din-56/CHANGELOG --- din-55/CHANGELOG 2022-09-22 13:31:38.000000000 +0000 +++ din-56/CHANGELOG 2022-12-24 03:18:48.000000000 +0000 @@ -1,3 +1,49 @@ +DIN Is Noise 56: + + /* + new drone movements: rail and strafe + + rail moves a drone along its velocity vector + strafe moves a drone lateral (perpendicular) to the velocity vector + + access rail and strafe using Drone Tools > Move / Rail / Strafe option list + click on the option to activate + then just move mouse up or down to rail or strafe + + interesting fx possible if the drone velocity vectors are + auto rotating / flipping / pausing when railing or strafing! + *\ + + /* + new auto pause for auto rotating drone velocity and/or accleration vectors + + basically, pause rotating every few seconds for a few seconds + set values of 'every few seconds' and 'for a few seconds' from: + Drone Params > Defaults for new drones OR + Drone Params > Motion for existing drones + *\ + + /* + new auto flip (= change direction of) rotation of curves on + any curve editor + *\ + + /* + new Curves tab on Menu of all curve editors + lists curves available for editing + can turn on/off curves for better/easier & targeted editing + *\ + + * improved FFT display and handling on waveform editors + * improved waveform display on keyboard-keyboard + * improved auto flip of rotation of velocity/acceleration vectors of drones + @ launched drones from muted drones are not muted (default until DIN55) + @ they serve no purpose, you can just select the launcher and + stop launching :) + - Fractaliser does not change curve name on apply + ! fixed Menu > Drone tools > Immortalize to turn mortal launched drones immortal + ! fixed resizing of Sine_Mixer harmonics/phases widget when moving Sine_Mixer + DIN Is Noise 55: /* an overhaul of Gravity diff -Nru din-55/configure din-56/configure --- din-55/configure 2022-09-22 14:07:36.000000000 +0000 +++ din-56/configure 2022-12-24 03:16:44.000000000 +0000 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for din 55. +# Generated by GNU Autoconf 2.69 for din 56. # # # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. @@ -576,8 +576,8 @@ # Identity of this package. PACKAGE_NAME='din' PACKAGE_TARNAME='din' -PACKAGE_VERSION='55' -PACKAGE_STRING='din 55' +PACKAGE_VERSION='56' +PACKAGE_STRING='din 56' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -1250,7 +1250,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures din 55 to adapt to many kinds of systems. +\`configure' configures din 56 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1317,7 +1317,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of din 55:";; + short | recursive ) echo "Configuration of din 56:";; esac cat <<\_ACEOF @@ -1411,7 +1411,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -din configure 55 +din configure 56 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -1542,7 +1542,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by din $as_me 55, which was +It was created by din $as_me 56, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -2405,7 +2405,7 @@ # Define the identity of the package. PACKAGE='din' - VERSION='55' + VERSION='56' cat >>confdefs.h <<_ACEOF @@ -4876,7 +4876,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by din $as_me 55, which was +This file was extended by din $as_me 56, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -4933,7 +4933,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -din config.status 55 +din config.status 56 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" diff -Nru din-55/configure.ac din-56/configure.ac --- din-55/configure.ac 2022-09-19 01:45:19.000000000 +0000 +++ din-56/configure.ac 2022-12-24 03:16:35.000000000 +0000 @@ -1,4 +1,4 @@ -AC_INIT([din], [55]) +AC_INIT([din], [56]) AM_INIT_AUTOMAKE([foreign]) AC_CONFIG_SRCDIR([configure.ac]) AC_PROG_CC diff -Nru din-55/debian/changelog din-56/debian/changelog --- din-55/debian/changelog 2022-10-09 20:41:53.000000000 +0000 +++ din-56/debian/changelog 2022-12-25 18:11:42.000000000 +0000 @@ -1,3 +1,14 @@ +din (56-1) unstable; urgency=medium + + * New upstream version 56 + * Refresh patchset + * Change my email address + * Bump Standards-Version to 4.6.2 + * Remove obsolete lintian-overrides + * Add salsa ci config + + -- Dennis Braun Sun, 25 Dec 2022 19:11:42 +0100 + din (55-1) unstable; urgency=medium * New upstream version 55 diff -Nru din-55/debian/control din-56/debian/control --- din-55/debian/control 2022-10-09 20:41:53.000000000 +0000 +++ din-56/debian/control 2022-12-25 16:26:07.000000000 +0000 @@ -5,7 +5,7 @@ Uploaders: Alessio Treglia , Edward Wang , - Dennis Braun + Dennis Braun Build-Depends: debhelper-compat (= 13), docbook-to-man, @@ -18,7 +18,7 @@ librtmidi-dev, libsdl1.2-dev, tcl8.6-dev -Standards-Version: 4.6.1 +Standards-Version: 4.6.2 Homepage: https://dinisnoise.org/ Vcs-Git: https://salsa.debian.org/multimedia-team/din.git Vcs-Browser: https://salsa.debian.org/multimedia-team/din diff -Nru din-55/debian/copyright din-56/debian/copyright --- din-55/debian/copyright 2022-09-24 14:55:27.000000000 +0000 +++ din-56/debian/copyright 2022-12-25 16:21:15.000000000 +0000 @@ -14,7 +14,7 @@ Files: debian/* Copyright: - 2020-2022 Dennis Braun + 2020-2022 Dennis Braun 2018 Olivier Humbert 2013-2015 Alessio Treglia License: GPL-2+ diff -Nru din-55/debian/din.lintian-overrides din-56/debian/din.lintian-overrides --- din-55/debian/din.lintian-overrides 2022-09-24 14:55:27.000000000 +0000 +++ din-56/debian/din.lintian-overrides 1970-01-01 00:00:00.000000000 +0000 @@ -1,4 +0,0 @@ -# Couldn't find these spelling errors in source code -spelling-error-in-binary usr/bin/din anothe another -spelling-error-in-binary usr/bin/din Pres Press -spelling-error-in-binary usr/bin/din Standar Standard diff -Nru din-55/debian/patches/0001-Fix_spelling_errors.patch din-56/debian/patches/0001-Fix_spelling_errors.patch --- din-55/debian/patches/0001-Fix_spelling_errors.patch 2022-09-24 15:05:50.000000000 +0000 +++ din-56/debian/patches/0001-Fix_spelling_errors.patch 2022-12-25 16:53:51.000000000 +0000 @@ -6,7 +6,7 @@ =================================================================== --- din.orig/src/din.cc +++ din/src/din.cc -@@ -750,7 +750,7 @@ void din::save_drones () { +@@ -751,7 +751,7 @@ void din::save_drones () { drone& di = *(*i); file << "id " << di.id << endl; file << "is " << di.is << endl; @@ -15,7 +15,7 @@ file << "wavepos " << di.player.x << spc << di.vol << endl; file << "color " << di.r << spc << di.g << spc << di.b << endl; file << "arrow " << di.arrow << endl; -@@ -2188,7 +2188,7 @@ int din::handle_input () { +@@ -2193,7 +2193,7 @@ int din::handle_input () { else if (keypressed (SDLK_F1)) helptext(); // bpms @@ -24,7 +24,7 @@ if (SHIFT) lower_delta (gater_delta.bpm, -1, "delta_gater_bpm = "); else if (CTRL) { -@@ -3336,7 +3336,7 @@ void din::rotate_drones () { +@@ -3435,7 +3435,7 @@ void din::rotate_drones () { dx = cx + rv.x; dy = cy + rv.y; di.set_center (dx, dy); @@ -33,7 +33,7 @@ /*if (di.chuck.yes && di.chuck.sun) { cx = di.chuck.sun->cx; cy = di.chuck.sun->cy; -@@ -3370,7 +3370,7 @@ void din::scale_drones () { +@@ -3469,7 +3469,7 @@ void din::scale_drones () { for (drone_iterator p = di.connections.begin (), q = di.connections.end (); p != q; ++p) rm.push_back (*p); nrm = nrm + di.nconn + 1; } @@ -46,7 +46,7 @@ =================================================================== --- din.orig/src/menu.cc +++ din/src/menu.cc -@@ -4077,7 +4077,7 @@ void ball_ops_listener::changed (field& +@@ -4208,7 +4208,7 @@ void ball_ops_listener::changed (field& MENU.sp_turn_max.set_value (maxx); } else maxx = b->op_turn.rd.max; b->op_turn.rd.set (-minn, maxx); @@ -55,7 +55,7 @@ cons << YELLOW << BUFFER << eol; } else if (&f == MENUP.sp_turn_max.f_value) { -@@ -4087,7 +4087,7 @@ void ball_ops_listener::changed (field& +@@ -4218,7 +4218,7 @@ void ball_ops_listener::changed (field& minn = -maxx; } else minn = b->op_turn.rd.min; b->op_turn.rd.set (minn, maxx); diff -Nru din-55/debian/patches/0002-Use-system-provided-rtaudio-and-rtmidi.patch din-56/debian/patches/0002-Use-system-provided-rtaudio-and-rtmidi.patch --- din-55/debian/patches/0002-Use-system-provided-rtaudio-and-rtmidi.patch 2022-09-24 14:55:27.000000000 +0000 +++ din-56/debian/patches/0002-Use-system-provided-rtaudio-and-rtmidi.patch 2022-12-25 16:55:04.000000000 +0000 @@ -16,22 +16,23 @@ delete mode 100644 src/RtMidi.cpp delete mode 100644 src/RtMidi.h -Index: din/src/Makefile.am -=================================================================== ---- din.orig/src/Makefile.am -+++ din/src/Makefile.am -@@ -5,7 +5,7 @@ LIBS += -ltcl8.6 -lSDL -lGL -lpthread - +diff --git a/src/Makefile.am b/src/Makefile.am +index 1afe155..752d4da 100644 +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -5,7 +5,7 @@ LIBS += -ltcl8.6 -lSDL -lGL -lpthread -lasound bin_PROGRAMS = din --din_SOURCES = alarm.cc arrow_button.cc audio.cc authors_note.cc autoflip.cc autorotator.cc ball.cc ball_ops.cc basic_editor.cc beat2value.cc binaural_drone.cc binaural_drones.cc bit_display.cc box_selector.cc button.cc capturer.cc checkbutton.cc chrono.cc circler.cc command.cc compressor.cc console.cc console_iterator.cc countries.cc cross_button.cc curve.cc curve_display.cc curve_editor.cc curve_library.cc curve_mixer.cc curve_picker.cc curve_samples.cc custom_periodic.cc defvelaccel.cc delay.cc din.cc din_info.cc drawrrow.cc drone.cc eval.cc fader.cc fft.cc field.cc filled_button.cc font.cc font_editor.cc fractaliser.cc globals.cc glyph.cc gravity.cc help.cc hit.cc item_list.cc keyboard_keyboard.cc label.cc levels.cc line.cc lissajous.cc listeners.cc main.cc menu.cc mesh.cc midi_in.cc minus_button.cc mocap.cc modulator.cc mondrian.cc morpher.cc morse_code.cc mouse_slider.cc multi_curve.cc noiser.cc note.cc number.cc oscilloscope.cc phrasor.cc play.cc plugin_browser.cc plugin.cc plus_button.cc point_modulator.cc range.cc recorder.cc rect.cc rose_milker.cc scale_info.cc scalelist.cc scale_notes.cc separator.cc settings.cc sine_mixer.cc slit.cc solver.cc spiraler.cc starrer.cc superformula.cc tap_bpm.cc tcl_interp.cc textboard.cc tokenizer.cc trail.cc triggered_note.cc ui.cc ui_sin_cos_radius.cc viewwin.cc warper.cc widget.cc RtAudio.cpp RtMidi.cpp kiss_fft.c -+din_SOURCES = alarm.cc arrow_button.cc audio.cc authors_note.cc autoflip.cc autorotator.cc ball.cc ball_ops.cc basic_editor.cc beat2value.cc binaural_drone.cc binaural_drones.cc bit_display.cc box_selector.cc button.cc capturer.cc checkbutton.cc chrono.cc circler.cc command.cc compressor.cc console.cc console_iterator.cc countries.cc cross_button.cc curve.cc curve_display.cc curve_editor.cc curve_library.cc curve_mixer.cc curve_picker.cc curve_samples.cc custom_periodic.cc defvelaccel.cc delay.cc din.cc din_info.cc drawrrow.cc drone.cc eval.cc fader.cc fft.cc field.cc filled_button.cc font.cc font_editor.cc fractaliser.cc globals.cc glyph.cc gravity.cc help.cc hit.cc item_list.cc keyboard_keyboard.cc label.cc levels.cc line.cc lissajous.cc listeners.cc main.cc menu.cc mesh.cc midi_in.cc minus_button.cc mocap.cc modulator.cc mondrian.cc morpher.cc morse_code.cc mouse_slider.cc multi_curve.cc noiser.cc note.cc number.cc oscilloscope.cc phrasor.cc play.cc plugin_browser.cc plugin.cc plus_button.cc point_modulator.cc range.cc recorder.cc rect.cc rose_milker.cc scale_info.cc scalelist.cc scale_notes.cc separator.cc settings.cc sine_mixer.cc slit.cc solver.cc spiraler.cc starrer.cc superformula.cc tap_bpm.cc tcl_interp.cc textboard.cc tokenizer.cc trail.cc triggered_note.cc ui.cc ui_sin_cos_radius.cc viewwin.cc warper.cc widget.cc kiss_fft.c +-din_SOURCES = alarm.cc arrow_button.cc audio.cc authors_note.cc autoflip.cc autopause.cc autorotator.cc ball.cc ball_ops.cc basic_editor.cc beat2value.cc binaural_drone.cc binaural_drones.cc bit_display.cc box_selector.cc button.cc capturer.cc checkbutton.cc chrono.cc circler.cc command.cc compressor.cc console.cc console_iterator.cc countries.cc cross_button.cc curve.cc curve_display.cc curve_editor.cc curve_library.cc curve_mixer.cc curve_picker.cc curve_samples.cc custom_periodic.cc defvelaccel.cc delay.cc din.cc din_info.cc drawrrow.cc drone.cc eval.cc fader.cc fft.cc field.cc filled_button.cc font.cc font_editor.cc fractaliser.cc globals.cc glyph.cc gravity.cc help.cc hit.cc item_list.cc keyboard_keyboard.cc label.cc levels.cc line.cc lissajous.cc listeners.cc main.cc menu.cc mesh.cc midi_in.cc minus_button.cc mocap.cc modulator.cc mondrian.cc morpher.cc morse_code.cc mouse_slider.cc multi_curve.cc noiser.cc note.cc number.cc oscilloscope.cc phrasor.cc play.cc plugin_browser.cc plugin.cc plus_button.cc point_modulator.cc range.cc recorder.cc rect.cc rose_milker.cc scale_info.cc scalelist.cc scale_notes.cc separator.cc settings.cc sine_mixer.cc slit.cc solver.cc spiraler.cc starrer.cc superformula.cc tap_bpm.cc tcl_interp.cc textboard.cc tokenizer.cc trail.cc triggered_note.cc ui.cc ui_sin_cos_radius.cc viewwin.cc warper.cc widget.cc RtAudio.cpp RtMidi.cpp kiss_fft.c ++din_SOURCES = alarm.cc arrow_button.cc audio.cc authors_note.cc autoflip.cc autopause.cc autorotator.cc ball.cc ball_ops.cc basic_editor.cc beat2value.cc binaural_drone.cc binaural_drones.cc bit_display.cc box_selector.cc button.cc capturer.cc checkbutton.cc chrono.cc circler.cc command.cc compressor.cc console.cc console_iterator.cc countries.cc cross_button.cc curve.cc curve_display.cc curve_editor.cc curve_library.cc curve_mixer.cc curve_picker.cc curve_samples.cc custom_periodic.cc defvelaccel.cc delay.cc din.cc din_info.cc drawrrow.cc drone.cc eval.cc fader.cc fft.cc field.cc filled_button.cc font.cc font_editor.cc fractaliser.cc globals.cc glyph.cc gravity.cc help.cc hit.cc item_list.cc keyboard_keyboard.cc label.cc levels.cc line.cc lissajous.cc listeners.cc main.cc menu.cc mesh.cc midi_in.cc minus_button.cc mocap.cc modulator.cc mondrian.cc morpher.cc morse_code.cc mouse_slider.cc multi_curve.cc noiser.cc note.cc number.cc oscilloscope.cc phrasor.cc play.cc plugin_browser.cc plugin.cc plus_button.cc point_modulator.cc range.cc recorder.cc rect.cc rose_milker.cc scale_info.cc scalelist.cc scale_notes.cc separator.cc settings.cc sine_mixer.cc slit.cc solver.cc spiraler.cc starrer.cc superformula.cc tap_bpm.cc tcl_interp.cc textboard.cc tokenizer.cc trail.cc triggered_note.cc ui.cc ui_sin_cos_radius.cc viewwin.cc warper.cc widget.cc kiss_fft.c - dist_include = alarm.h angle.h arrow_button.h audio.h authors_note.h autoflip.h autorotator.h ball.h ball_ops.h basic_editor.h beat2value.h binaural_drone.h binaural_drones.h bit_display.h box.h box_selector.h button.h capturer.h checkbutton.h chrono.h circler.h color.h command.h compressor.h console.h console_iterator.h constant_radius.h container.h cosine.h countries.h cross_button.h crvpt.h curve_display.h curve_editor.h curve.h curve_library.h curve_listener.h curve_mixer.h curve_picker.h curve_samples.h custom_periodic.h defvelaccel.h delay.h dingl.h din.h din_info.h drawrrow.h drone.h fader.h fft.h field.h file-utils.h filled_button.h font_editor.h font.h fractaliser.h funktion.h globals.h glyph.h gravity.h help.h hit.h input.h instrument.h item_list.h keyboard_keyboard.h _kiss_fft_guts.h kiss_fft.h label_field.h label_field_slider.h label.h levels.h line.h lissajous.h listeners.h log.h main.h menu.h mesh.h midi_in.h minus_button.h mocap.h mod_params.h modulator.h mondrian.h morpher.h morse_code.h mouse_slider.h multi_curve.h noiser.h note.h number.h octave_shift_data.h options_list.h osc.h oscilloscope.h phrasor.h play.h plugin_browser.h plugin.h plus_button.h point.h point_modulator.h random.h range.h recorder.h rect.h rose_milker.h RtAudio.h RtError.h RtMidi.h scale_info.h scalelist.h scale_notes.h separator.h settings.h sine.h sine_mixer.h slider.h slit.h solver.h spinner2.h spinner.h spiraler.h starrer.h state_button.h strength_editor.h superformula.h tap_bpm.h tcl_interp.h textboard.h tick.h tokenizer.h trail.h triggered_note.h ui.h ui_list.h ui_sin_cos_radius.h utils.h vector2d.h viewwin.h warper.h wav.h widget.h + dist_include = alarm.h angle.h arrow_button.h audio.h authors_note.h autoflip.h autopause.h autorotator.h ball.h ball_ops.h basic_editor.h beat2value.h binaural_drone.h binaural_drones.h bit_display.h box.h box_selector.h button.h capturer.h checkbutton.h chrono.h circler.h color.h command.h compressor.h console.h console_iterator.h constant_radius.h container.h cosine.h countries.h cross_button.h crvpt.h curve_display.h curve_editor.h curve.h curve_library.h curve_listener.h curve_mixer.h curve_picker.h curve_samples.h custom_periodic.h defvelaccel.h delay.h dingl.h din.h din_info.h drawrrow.h drone.h fader.h fft.h field.h file-utils.h filled_button.h font_editor.h font.h fractaliser.h funktion.h globals.h glyph.h gravity.h help.h hit.h input.h instrument.h item_list.h keyboard_keyboard.h _kiss_fft_guts.h kiss_fft.h label_field.h label_field_slider.h label.h levels.h line.h lissajous.h listeners.h log.h main.h menu.h mesh.h midi_in.h minus_button.h mocap.h mod_params.h modulator.h mondrian.h morpher.h morse_code.h mouse_slider.h multi_curve.h noiser.h note.h number.h octave_shift_data.h options_list.h osc.h oscilloscope.h phrasor.h play.h plugin_browser.h plugin.h plus_button.h point.h point_modulator.h random.h range.h recorder.h rect.h rose_milker.h RtAudio.h RtError.h RtMidi.h scale_info.h scalelist.h scale_notes.h separator.h settings.h sine.h sine_mixer.h slider.h slit.h solver.h spinner2.h spinner.h spiraler.h starrer.h state_button.h strength_editor.h superformula.h tap_bpm.h tcl_interp.h textboard.h tick.h tokenizer.h trail.h triggered_note.h ui.h ui_list.h ui_sin_cos_radius.h utils.h vector2d.h viewwin.h warper.h wav.h widget.h -Index: din/src/RtAudio.cpp -=================================================================== ---- din.orig/src/RtAudio.cpp +diff --git a/src/RtAudio.cpp b/src/RtAudio.cpp +deleted file mode 100644 +index c37b849..0000000 +--- a/src/RtAudio.cpp +++ /dev/null @@ -1,10136 +0,0 @@ -/************************************************************************/ @@ -10170,9 +10171,10 @@ - // - // vim: et sts=2 sw=2 - -Index: din/src/RtAudio.h -=================================================================== ---- din.orig/src/RtAudio.h +diff --git a/src/RtAudio.h b/src/RtAudio.h +deleted file mode 100644 +index 158cfc0..0000000 +--- a/src/RtAudio.h +++ /dev/null @@ -1,1162 +0,0 @@ -/************************************************************************/ @@ -11337,9 +11339,10 @@ -// End: -// -// vim: et sts=2 sw=2 -Index: din/src/RtMidi.cpp -=================================================================== ---- din.orig/src/RtMidi.cpp +diff --git a/src/RtMidi.cpp b/src/RtMidi.cpp +deleted file mode 100644 +index 1fab6ee..0000000 +--- a/src/RtMidi.cpp +++ /dev/null @@ -1,3747 +0,0 @@ -/**********************************************************************/ @@ -15089,9 +15092,10 @@ -} - -#endif // __UNIX_JACK__ -Index: din/src/RtMidi.h -=================================================================== ---- din.orig/src/RtMidi.h +diff --git a/src/RtMidi.h b/src/RtMidi.h +deleted file mode 100644 +index 46b9cf8..0000000 +--- a/src/RtMidi.h +++ /dev/null @@ -1,676 +0,0 @@ -/**********************************************************************/ @@ -15770,10 +15774,10 @@ -#endif - -#endif -Index: din/src/audio.h -=================================================================== ---- din.orig/src/audio.h -+++ din/src/audio.h +diff --git a/src/audio.h b/src/audio.h +index b53e002..1442d48 100644 +--- a/src/audio.h ++++ b/src/audio.h @@ -9,7 +9,7 @@ #ifndef __AUDIO #define __AUDIO @@ -15783,10 +15787,10 @@ #include #include -Index: din/src/midi_in.h -=================================================================== ---- din.orig/src/midi_in.h -+++ din/src/midi_in.h +diff --git a/src/midi_in.h b/src/midi_in.h +index 766f801..cd9545e 100644 +--- a/src/midi_in.h ++++ b/src/midi_in.h @@ -8,7 +8,7 @@ #ifndef __midi_in #define __midi_in diff -Nru din-55/debian/salsa-ci.yml din-56/debian/salsa-ci.yml --- din-55/debian/salsa-ci.yml 1970-01-01 00:00:00.000000000 +0000 +++ din-56/debian/salsa-ci.yml 2022-12-25 16:57:38.000000000 +0000 @@ -0,0 +1,4 @@ +--- +include: + - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/salsa-ci.yml + - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/pipeline-jobs.yml diff -Nru din-55/src/alarm.h din-56/src/alarm.h --- din-55/src/alarm.h 2022-01-12 07:56:36.000000000 +0000 +++ din-56/src/alarm.h 2022-11-24 06:44:15.000000000 +0000 @@ -21,4 +21,6 @@ void stop (); }; +typedef alarm_t alarmt; + #endif diff -Nru din-55/src/arrow_button.cc din-56/src/arrow_button.cc --- din-55/src/arrow_button.cc 2022-01-12 04:04:48.000000000 +0000 +++ din-56/src/arrow_button.cc 2022-10-31 03:17:08.000000000 +0000 @@ -7,6 +7,12 @@ #include "arrow_button.h" + +arrow_button::arrow_button (int _sz, int _dir) { + set_size (_sz); + set_dir (_dir); +} + void arrow_button::set_dir (int _dir) { dir = _dir; const box& e = extents; diff -Nru din-55/src/arrow_button.h din-56/src/arrow_button.h --- din-55/src/arrow_button.h 2022-01-12 04:04:48.000000000 +0000 +++ din-56/src/arrow_button.h 2022-10-31 05:08:13.000000000 +0000 @@ -17,10 +17,7 @@ int v[6]; - arrow_button (int _sz = 10, int _dir = right) { - set_size (_sz); - set_dir (_dir); - } + arrow_button (int sze = 12, int dirr = right); void draw (); diff -Nru din-55/src/autoflip.cc din-56/src/autoflip.cc --- din-55/src/autoflip.cc 2022-01-12 04:41:35.000000000 +0000 +++ din-56/src/autoflip.cc 2022-12-05 02:49:25.000000000 +0000 @@ -7,26 +7,32 @@ #include "defvelaccel.h" #include "autoflip.h" +#include "console.h" -void autoflipt::calc (float& theta, int& dir, defvelaccel& d) { - total += theta; - if (total >= angle.rad) { - dir = -dir; - total = repdiv (total, angle.rad); - if (d.autos.flip.deg.rndrd) angle = d.autos.flip.deg (); - } +int autoflipt::calc (float& theta, defvelaccel& d) { + float nexttotal = total + theta; + int flipdir = 0; + if (nexttotal >= angle.rad) { + flipdir = 1; + theta = angle.rad - total; + total = 0.0f; + if (rndang) angle = d.autos.flip.deg (1); + } else + total = nexttotal; + return flipdir; } autoflipt::autoflipt (defvelaccel& d) { yes = d.autos.flip.yes; angle = d.autos.flip.deg(); + rndang = d.autos.flip.deg.rndrd; total = 0.0f; } std::istream& operator>> (std::istream& file, autoflipt& af) { float d; - file >> af.yes >> d >> af.total; + file >> af.yes >> af.rndang >> d >> af.total; af.angle = d; return file; } @@ -34,6 +40,6 @@ std::ostream& operator<< (std::ostream& file, autoflipt& af) { extern const char spc; - file << af.yes << spc << af.angle.deg << spc << af.total; + file << af.yes << spc << af.rndang << spc << af.angle.deg << spc << af.total; return file; } diff -Nru din-55/src/autoflip.h din-56/src/autoflip.h --- din-55/src/autoflip.h 2022-01-12 04:41:27.000000000 +0000 +++ din-56/src/autoflip.h 2022-11-28 10:47:40.000000000 +0000 @@ -15,18 +15,14 @@ struct autoflipt { int yes; anglet angle; + int rndang; float total; autoflipt (defvelaccel& d); - void calc (float& theta, int& dir, defvelaccel& d); + int calc (float& theta, defvelaccel& d); inline void set (float deg) {angle = deg;} }; std::istream& operator>> (std::istream& file, autoflipt& af); std::ostream& operator<< (std::ostream& file, autoflipt& af); -template T repdiv (T n, T d) { - T o = n / d; - return (o - int(o)); -} - #endif diff -Nru din-55/src/autopause.cc din-56/src/autopause.cc --- din-55/src/autopause.cc 1970-01-01 00:00:00.000000000 +0000 +++ din-56/src/autopause.cc 2022-11-28 19:06:55.000000000 +0000 @@ -0,0 +1,66 @@ +/* +* autopause.cc +* DIN Is Noise is copyright (c) 2006-2022 Jagannathan Sampath +* DIN Is Noise is released under GNU Public License 2.0 +* For more information, please visit https://dinisnoise.org/ +*/ + +#include "chrono.h" +#include "autopause.h" +#include "defvelaccel.h" +#include "autorotator.h" +#include "console.h" + +autopauset::autopauset (defvelaccel& d) { + a = 0; + yes = d.autos.pause.yes; + every = d.autos.pause.every (); + f0r = d.autos.pause.f0r (); + rndt[0] = d.autos.pause.every.rndrd; + rndt[1] = d.autos.pause.f0r.rndrd; + settrigt (0, every); + settrigt (1, f0r); + t[0] = &every; + t[1] = &f0r; + vt[0] = &d.autos.pause.every; + vt[1] = &d.autos.pause.f0r; +} + +void autopauset::settrigt (int i, double& d) { + alarmt& ai = alm[i]; + ai.triggert = d; +} + +void autopauset::operator() (autorotator& ar) { + alarmt &aa = alm[a]; + if (aa(ui_clk())) { + aa.stop (); + a = !a; + double& ta = *t[a]; + if (rndt[a]) ta = (*vt[a])(1); + if (a) ar.yes = 0; else ar.yes = 1; + alarmt& nxt = alm[a]; + nxt.triggert = ta; + nxt.start (); + } +} + +void autopauset::go () { + a = 0; + alm[a].start (); +} + +void autopauset::setyes (int y, autorotator& ar) { + yes = y; + if (!yes && a) ar.setyes (1); +} + +std::istream& operator>> (std::istream& file, autopauset& ap) { + file >> ap.yes >> ap.rndt[0] >> ap.rndt[1]; + return file; +} + +std::ostream& operator<< (std::ostream& file, autopauset& ap) { + file << ap.yes << spc << ap.rndt[0] << spc << ap.rndt[1] << spc; + return file; +} diff -Nru din-55/src/autopause.h din-56/src/autopause.h --- din-55/src/autopause.h 1970-01-01 00:00:00.000000000 +0000 +++ din-56/src/autopause.h 2022-12-06 06:33:46.000000000 +0000 @@ -0,0 +1,35 @@ +/* +* autopause.h +* DIN Is Noise is copyright (c) 2006-2022 Jagannathan Sampath +* DIN Is Noise is released under GNU Public License 2.0 +* For more information, please visit https://dinisnoise.org/ +*/ + +#ifndef __autopause +#define __autopause + +#include "alarm.h" + +struct defvelaccel; +struct autorotator; +struct valt; + +struct autopauset { + int yes; + int a; + double every, f0r; + int rndt [2]; + alarmt alm[2]; + double* t[2]; + valt* vt[2]; + autopauset (defvelaccel& d); + void settrigt (int i, double& d); + void setyes (int y, autorotator& ar); + void go (); + void operator() (autorotator& ar); +}; + +std::istream& operator>> (std::istream& file, autopauset& ap); +std::ostream& operator<< (std::ostream& file, autopauset& ap); + +#endif diff -Nru din-55/src/autorotator.cc din-56/src/autorotator.cc --- din-55/src/autorotator.cc 2022-02-05 08:04:40.000000000 +0000 +++ din-56/src/autorotator.cc 2022-12-02 08:40:00.000000000 +0000 @@ -10,9 +10,12 @@ #include "chrono.h" #include "console.h" -autorotator::autorotator (defvelaccel& d) : dva (d), autoflip(d) { +autorotator::autorotator (defvelaccel& d) : dva(d), autoflip(d), autopause(d) { - yes = d.autos.rot.yes; + flipdir = 0; + + setyes (d.autos.rot.yes); + autopause.setyes (autopause.yes, *this); int i = 0; if (d.autos.rot.dir == RANDOM) i = get_rand_bit (); else i = d.autos.rot.dir; @@ -28,23 +31,33 @@ set_rpm (d.autos.rot.rpm()); deg = 6.0f; tps = 1.0f; - } - else { + } else { setdeg (d.autos.rot.dps()); settps (d.autos.rot.tps()); tik.start (); rpm = 0.0f; } + +} + +int autorotator::yess () { + if (autopause.yes) autopause (*this); + return yes; +} + +void autorotator::setyes (int y) { + yes = y; + if (yes && autopause.yes) autopause.go (); } void autorotator::set_rpm (float r) { if (r > 0) { rpm = r; extern const float TWO_PI; - angle.perrot = TWO_PI * r / 60.0f; + angle.per = TWO_PI * r / 60.0f; } else { rpm = 0; - angle.perrot = 0.0f; + angle.per = 0.0f; } } @@ -58,35 +71,43 @@ } void autorotator::calc (double dt) { + if (mov == SMOOTH) - angle.theta = dt * angle.perrot; + angle.theta = dt * angle.per; else { extern ui_clock ui_clk; if (tik (ui_clk())) { if (dva.autos.rot.uet.deg) setdeg (dva.autos.rot.dps()); if (dva.autos.rot.uet.tps) settps (dva.autos.rot.tps()); - angle.theta = angle.perrot; + angle.theta = angle.per; } else angle.theta = 0.0f; } - if (autoflip.yes) autoflip.calc (angle.theta, dir, dva); + if (autoflip.yes) flipdir = autoflip.calc (angle.theta, dva); + angle.theta *= dir; + if (flipdir) { + dir *= -1; + flipdir = 0; + } + } std::istream& operator>> (std::istream& file, autorotator& ar) { - file >> ar.yes >> ar.dir >> ar.rpm >> ar.mov >> ar.deg >> ar.tps >> ar.autoflip; + file >> ar.yes >> ar.dir >> ar.rpm >> ar.mov >> ar.deg >> ar.tps >> ar.autoflip >> ar.autopause; if (ar.mov == autorotator::SMOOTH) ar.set_rpm (ar.rpm); else { ar.setdeg (ar.deg); ar.settps (ar.tps); } + ar.setyes (ar.yes); return file; } std::ostream& operator<< (std::ostream& file, autorotator& ar) { extern const char spc; - file << ar.yes << spc << ar.dir << spc << ar.rpm << spc << ar.mov << spc << ar.deg << spc << ar.tps << spc << ar.autoflip; + file << ar.yes << spc << ar.dir << spc << ar.rpm << spc << ar.mov << spc << ar.deg << spc << ar.tps << spc << ar.autoflip << spc << ar.autopause; return file; } diff -Nru din-55/src/autorotator.h din-56/src/autorotator.h --- din-55/src/autorotator.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/autorotator.h 2022-12-02 08:35:37.000000000 +0000 @@ -8,22 +8,29 @@ #ifndef __autorotator #define __autorotator -#include "autoflip.h" #include "alarm.h" +#include "autoflip.h" +#include "autopause.h" struct defvelaccel; + struct autorotator { defvelaccel& dva; int yes; + int yess (); + void setyes (int y); enum {CLOCKWISE, ANTICLOCKWISE, RANDOM}; int dir; // +1 = anti-clockwise , -1 = clockwise + int flipdir; autoflipt autoflip; - enum {TICK, SMOOTH}; + autopauset autopause; + + enum {SMOOTH, TICK}; int mov; alarm_t tik; @@ -33,10 +40,10 @@ float rpm; struct anglett { - float perrot; + float per; float theta; anglett () { - perrot = 0.0f; + per = 0.0f; theta = 0.0f; } } angle; @@ -51,7 +58,7 @@ deg = d; if (deg < 0.0f) deg = 0.0f; extern const float PI_BY_180; - angle.perrot = deg * PI_BY_180; + angle.per = deg * PI_BY_180; } inline void settps (float t) { diff -Nru din-55/src/capturer.h din-56/src/capturer.h --- din-55/src/capturer.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/capturer.h 2022-09-28 17:26:38.000000000 +0000 @@ -36,7 +36,6 @@ int sbx, sby; std::vector caps; - //std::list caps; int ncaps; sel _sel; diff -Nru din-55/src/command.cc din-56/src/command.cc --- din-55/src/command.cc 2022-09-17 11:12:05.000000000 +0000 +++ din-56/src/command.cc 2022-11-08 09:18:49.000000000 +0000 @@ -261,14 +261,6 @@ MENU.lf_conn_steps.set_text (s); MENU.stepsl.typing (MENU.lf_conn_steps.fld); MENU.stepsl.changed (MENU.lf_conn_steps.fld); - } else if (varn == "fft") { - int e; tz >> e; - if (e) { - fft0.ab_fold.set_dir (arrow_button::right); - } else { - fft0.ab_fold.set_dir (arrow_button::down); - } - fft0.clicked (fft0.ab_fold); } else if (varn == "current_plugin") { int c; tz >> c; uis.plugin__browser.set_cur (c); @@ -334,6 +326,11 @@ tz >> din0.selected_drones[0]->chuck.speed; }*/ + /*else if (varn == "cvis") { + int i, v; tz >> i >> v; + uis.crved->setcrvvis (i, v); + }*/ + else { if (varn != "") { result = varn + ": not found."; diff -Nru din-55/src/curve_display.cc din-56/src/curve_display.cc --- din-55/src/curve_display.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/curve_display.cc 2022-10-08 09:43:14.000000000 +0000 @@ -8,12 +8,40 @@ #include "curve_display.h" #include "viewwin.h" #include "multi_curve.h" +#include "console.h" #include using namespace std; extern viewport view; +void curve_display::add_gutter () { + static const float GUTTER = 0.01f; + bbox.resize (GUTTER, GUTTER); +} + +void curve_display::unit_bbox () { + bbox (0, -1, 1, 1); + add_gutter (); +} + +curve_display::curve_display (int w, int h) { + gl_pts = 0; + n_glpts = 0; + crv = 0; + set_size (w, h); + unit_bbox (); +} + +void curve_display::setbbox (int sf) { + if (sf) { + bbox (-0.5f, -1, 1.5f, 1); + } else { + bbox (0, -1, 1, 1); + } + add_gutter (); +} + void curve_display::calc_bbox () { crv->calc_bbox (bbox); add_gutter (); @@ -54,21 +82,6 @@ glDrawArrays (GL_LINE_STRIP, 0, n); } -void curve_display::add_gutter () { - static const float GUTTER = 0.01f; - bbox.left -= GUTTER; - bbox.right += GUTTER; - bbox.bottom -= GUTTER; - bbox.top += GUTTER; -} - -void curve_display::unit_bbox () { - bbox.left = 0; bbox.bottom = -1; - bbox.right = 1; bbox.top = 1; - add_gutter (); - bbox.calc (); -} - curve_display::~curve_display () { if (gl_pts) delete [] gl_pts; } diff -Nru din-55/src/curve_display.h din-56/src/curve_display.h --- din-55/src/curve_display.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/curve_display.h 2022-10-08 08:55:01.000000000 +0000 @@ -19,7 +19,9 @@ multi_curve* crv; box bbox; + void unit_bbox (); void calc_bbox (); + void setbbox (int sf); void add_gutter (); void draw (); @@ -28,24 +30,13 @@ float* gl_pts; int n_glpts; - curve_display (int w = 96, int h = 96) { - - gl_pts = 0; - n_glpts = 0; - - crv = 0; - set_extents (0, 0, w, h); - - } + curve_display (int w = 96, int h = 96); + ~curve_display (); void set_size (int w, int h) { set_extents (extents.left, extents.bottom, extents.left + w, extents.bottom + h); } - void unit_bbox (); - - ~curve_display (); - }; #endif diff -Nru din-55/src/curve_editor.cc din-56/src/curve_editor.cc --- din-55/src/curve_editor.cc 2022-09-20 18:46:09.000000000 +0000 +++ din-56/src/curve_editor.cc 2022-12-22 06:10:29.000000000 +0000 @@ -33,7 +33,7 @@ extern int SAMPLE_RATE; extern int FPS; extern double TIME_PER_FRAME; -extern const float TWO_PI; +extern const float TWO_PI, PI; extern char BUFFER []; extern instrument* get_current_instrument (); @@ -43,21 +43,21 @@ curve_editor::curve_editor (const std::string& settingsf) { + curves = 0; curcrv = 0; + curcrvchgd = 1; + savedrots = 0; todo = next_todo = NOTHING; cursor_mesg = next_cursor_mesg = ""; - is_waveform_editor = fft_enabled = samples_enabled = draw_curve_only = 0; + waved = fft_enabled = samples_enabled = draw_curve_only = 0; load (settingsf); lmb_move = 0; lmb_clicked = 0; - angle = 0; - last_rpm = 0; - gl_pts = 0; n_pts = 0; @@ -102,13 +102,28 @@ file >> ignore >> samples_enabled; file >> ignore >> hz >> ignore >> nperiods; cs.set (hz, nperiods); - file >> ignore >> is_waveform_editor; + file >> ignore >> waved; file >> ignore >> draw_curve_only; file >> ignore >> kbkb_attack_editor; file >> ignore >> overlay; file >> ignore >> axis; file >> ignore >> draw_plugin_output; + file >> ignore >> savedrots; + if (savedrots) { + curveinfo.resize (savedrots); + float deg; + for (int i = 0; i < savedrots; ++i) { + curve_info& ci = curveinfo[i]; + float s, t; + file >> ci.lastrpm >> ci.angle >> ci.totang >> ci.dir >> deg >> ci.autoflip >> ci.randoflip >> s >> t; + ci.rd.set (s, t); + ci.every0 = deg; + ci.every = ci.every0; + ci.startt = 0; + } + } + dlog << ", done >>>" << endl; } @@ -136,18 +151,23 @@ file << "samples_enabled " << samples_enabled << endl; file << "hz " << hz << endl; file << "nperiods " << nperiods << endl; - file << "is_waveform_editor " << is_waveform_editor << endl; + file << "waved " << waved << endl; file << "draw_curve_only " << draw_curve_only << endl; file << "sustain_editing " << kbkb_attack_editor << endl; file << "overlay " << overlay << endl; file << "mirror_axis " << axis << endl; file << "draw_plugin_output " << draw_plugin_output << endl; + file << "rotatingcurves " << curves << endl; + for (int i = 0; i < curves; ++i) { + curve_info& ci = curveinfo[i]; + file << ci.lastrpm << spc << ci.angle << spc << ci.totang << spc << ci.dir << spc << ci.every0.deg << spc << ci.autoflip << spc << ci.randoflip << spc << ci.rd.min << spc << ci.rd.max << spc; + } + } void curve_editor::prep_move () { undos.push_back (undo_t (pik.crv_id, *pik.crv, win)); - curveinfo[pik.crv_id].lisner->selected (pik.crv_id); if (keydown (SDLK_SPACE)) { cons << YELLOW << "Moving whole curve"; todo = MOVE_ALL; @@ -171,7 +191,7 @@ if (lmb_move == FINISH_ON_CLICK) { cons << RED << "Finished moving " << pik << eol; - do_nothing (); + quick_nothing (); return 1; } @@ -179,7 +199,7 @@ hittest (); if (pik()) { // hit if (pomo.hit (pik)) - ; + ; // point modulator is moving hit element so ignore else prep_move (); return 1; @@ -214,14 +234,14 @@ if (pik()) mirror (); return 1; case START_CAPTURE: - do_nothing (); + abs_nothing (); return 1; case ASSIGN_CAPTURE: hittest (); assign_mouse_capture (); return 1; case PICK_CURVE: - hittest (); + hittest (); if (pik()) curve_picked (); return 1; } @@ -258,9 +278,12 @@ paste_using_menu (); } else { // delete vertex or tanget todo = REMOVE_VERTEX; - hittest (); - if (pik()) remove (); - todo = NOTHING; + cursor_mesg = " Click on vertex to delete. ESC to stop."; + hittest (); + if (pik()) { + remove (); + quick_nothing (); + } } } else if (keypressedd (SDLK_z)) { // undo & redo @@ -288,7 +311,7 @@ } else if (keypressed (SDLK_c)) { if (CTRL) { // l_ctrl + c - copy curve - if (num_curves == 1) { + if (onecurve()) { pik = pick_cur_curve (); copy_curve (); } else { @@ -325,7 +348,7 @@ cons << GREEN << "Removed the " << uis.over->name << " from overlay" << eol; MENU.cb_overlay.set_state (overlay, 0); } - else if (keypressed (SDLK_F1)) helptext(); // show help + else if (keypressed (SDLK_F1)) helptext(); return 1; @@ -348,14 +371,6 @@ } } -void curve_editor::pick (int i) { - int ncurves = curveinfo.size (); - if (i > -1 && i < ncurves) { - curve_info& ci = curveinfo[i]; - ci.lisner->selected (i); - } -} - void curve_editor::calc_hit_params (hit_t& hit) { if (!hit()) return; multi_curve* crv = get_curve (hit.crv_id); @@ -370,26 +385,34 @@ hit.right_tangent_magnitude = (float) magnitude (hit.right_tangent.x, hit.right_tangent.y); const point& hp = hit.get (); obj2mouse (hp.x, hp.y); curcrv = hit.crv_id; + curcrvchgd = 1; } void curve_editor::hittest () { hitlist.clear (); - for (int i = 0, j = curveinfo.size (); i < j; ++i) { + for (int i = 0, j = curves; i < j; ++i) { curve_info& ci = curveinfo[i]; multi_curve* crv = ci.curve; - hittest (crv, i, crv->vertices, hit_t::VERTEX); - hittest (crv, i, crv->left_tangents, hit_t::LEFT_TANGENT); - hittest (crv, i, crv->right_tangents, hit_t::RIGHT_TANGENT); + if (ci.visible) { + hittest (crv, i, crv->vertices, hit_t::VERTEX); + hittest (crv, i, crv->left_tangents, hit_t::LEFT_TANGENT); + hittest (crv, i, crv->right_tangents, hit_t::RIGHT_TANGENT); + } } int n = hitlist.size(); - if (n) n = filter_hitlist (); + if (n) + n = filter_hitlist (); + else { + pik = hit_t (); + return; + } if (n == 1) { pik = hitlist [0]; calc_hit_params (pik); } else { - pik = hit_t (); + pik = hit_t (); if (n > 1) show_curve_picker (); } } @@ -405,7 +428,7 @@ int curve_editor::filter_hitlist () { - for (int i = 0, j = curveinfo.size (); i < j; ++i) curveinfo[i].picked = 0; + for (int i = 0, j = curves; i < j; ++i) curveinfo[i].picked = 0; for (vector::iterator i = hitlist.begin (), j = hitlist.end (); i != j;) { hit_t& hit = *i; if (todo == PICK_CURVE) { @@ -438,7 +461,6 @@ void curve_editor::set_pick_from_hitlist (int i) { pik = hitlist [i]; calc_hit_params (pik); - curveinfo [curcrv].lisner->selected (curcrv); cons << GREEN << "Picked " << pik << eol; } @@ -549,14 +571,14 @@ crv->evaluate(); ci.lisner->edited (this, pik.crv_id); } else { - cons << RED << "cant delete curve: " << crv->name << eol; + cons << RED << "Cannot delete curve: " << crv->name << eol; undos.pop_back (); } clear_hit (pik); } void curve_editor::swap () { - if (num_curves == 2) { + if (curves == 2) { multi_curve& crv0 = *get_curve (0); multi_curve& crv1 = *get_curve (1); @@ -578,7 +600,7 @@ crv1.set_color (r1, g1, b1); cons << "Swapped curve " << crv0.name << " with " << crv1.name << eol; - curve_info &ci0 = get_curve_info (0), &ci1 = get_curve_info (1); + curve_info &ci0 = curveinfo[0], &ci1 = curveinfo[1]; pomo.validate (); ci0.lisner->edited (this, 0); @@ -712,12 +734,11 @@ if (mark_segments) mark_curve_segments (); // draw curve profile, vertices, tangents and handles - int j = curveinfo.size (); - //int j1 = j > 1; + int j = curves; for (int i = 0; i < j; ++i) { - curve_info& ci = curveinfo[i]; - multi_curve* crv = ci.curve; - //if (i == curcrv && j1) glLineWidth (2); // hilite current + curve_info& ci = curveinfo [i]; + if (ci.visible) { + multi_curve* crv = ci.curve; if (draw_curve_only) { glColor3f (crv->r, crv->g, crv->b); draw_curve (crv); @@ -728,7 +749,7 @@ draw_vertices (crv); draw_curve (crv); } - //glLineWidth (1); + } } // mark beat/value (gater, fm/am, octave shift) @@ -762,7 +783,7 @@ // label vertices if (label_vertices) { - for (int i = 0, j = curveinfo.size (); i < j; ++i) { + for (int i = 0, j = curves; i < j; ++i) { curve_info& ci = curveinfo[i]; multi_curve* crv = ci.curve; for (int m = 0, n = crv->num_vertices; m < n; ++m) { @@ -774,7 +795,7 @@ } } - if (samples_enabled && curveinfo.size()) cs.draw (this, curveinfo[0].curve); + if (samples_enabled && curves) cs.draw (this, curveinfo[0].curve); if (kbkb_attack_editor) { mkr[0]=susx;mkr[1]=susbox.bottom; @@ -806,25 +827,27 @@ // drop vertical lines from current curve's profile points glColor3f (0.2f, 0.2f, 0.2f); curve_info& ci = curveinfo [curcrv]; - multi_curve* crv = ci.curve; - vector& curv = crv->curv; - int m = 0; - for (int i = 0, j = curv.size(); i < j; ++i) m += curv[i].vpts.size (); - int e = 2 * m; - int n = 2 * e; - alloc_gl_pts (n); - for (int i = 0, j = curv.size(), k = 0; i < j; ++i) { - vector& vpts = curv[i].vpts; - for (int p = 0, q = vpts.size (); p < q; ++p) { - float dx, dy; obj2win (vpts[p].x, vpts[p].y, dx, dy); - gl_pts [k++]=dx; - gl_pts [k++]=dy; - gl_pts [k++]=dx; - gl_pts [k++]=0; - } - } - glVertexPointer (2, GL_FLOAT, 0, gl_pts); - glDrawArrays (GL_LINES, 0, e); + if (ci.visible) { + multi_curve* crv = ci.curve; + vector& curv = crv->curv; + int m = 0; + for (int i = 0, j = curv.size(); i < j; ++i) m += curv[i].vpts.size (); + int e = 2 * m; + int n = 2 * e; + alloc_gl_pts (n); + for (int i = 0, j = curv.size(), k = 0; i < j; ++i) { + vector& vpts = curv[i].vpts; + for (int p = 0, q = vpts.size (); p < q; ++p) { + float dx, dy; obj2win (vpts[p].x, vpts[p].y, dx, dy); + gl_pts [k++]=dx; + gl_pts [k++]=dy; + gl_pts [k++]=dx; + gl_pts [k++]=0; + } + } + glVertexPointer (2, GL_FLOAT, 0, gl_pts); + glDrawArrays (GL_LINES, 0, e); + } } void curve_editor::draw_handle (const point& p) { @@ -902,7 +925,7 @@ void curve_editor::dodo (list& do1, list& do2, std::string mesg) { if (do1.size() > 0) { undo_t& last = do1.back (); - if (last.i < num_curves) { + if (last.i < curves) { curve_info& ci = curveinfo[last.i]; multi_curve* crv = ci.curve; mix = *crv; @@ -911,6 +934,7 @@ crv->get_color (r, g, b); *crv = last.curve; crv->set_color (r, g, b); + if (MENU.show) setup_tools_menu (); else curcrvchgd = 1; pomo.validate (); ci.lisner->edited (this, last.i); win = last.win; @@ -922,42 +946,42 @@ } void curve_editor::add (multi_curve* crv, curve_listener* lsnr) { - curveinfo.push_back (curve_info (crv, lsnr)); - if (++num_curves == 1) { + if (curves < savedrots) { + curve_info& cc = curveinfo [curves]; + cc.curve = crv; + cc.lisner = lsnr; + } else { + curveinfo.push_back (curve_info (crv, lsnr)); + } + if (++curves == 1) { render_curve_samples (); hlabel_only = crv->shapeform; } + ++visibles; } void curve_editor::clear () { curveinfo.clear (); hitlist.clear (); clear_hit (pik); - num_curves = 0; + curves = 0; } multi_curve* curve_editor::get_curve (int i) { - if (i > -1 && i < (int) curveinfo.size()) { - curve_info& ci = curveinfo [i]; - return ci.curve; - } - return 0; -} - -curve_info& curve_editor::get_curve_info (int i) { - return curveinfo[i]; + curve_info& ci = curveinfo [i]; + return ci.curve; } void curve_editor::enter () { calc_visual_params (); - if (is_waveform_editor) uis.dofft (); - setup_tools_menu (); - // MENU.set_snap (snap_what); + //if (waved) fft0.go (curveinfo[curcrv].curve); + MENU.populatecurvestab (this); MENU.set_vertices_carry_tangents (carry_tangents); MENU.set_mirror_tangents (mirror_tangents); MENU.sp_waveform_hz.set_value (hz); MENU.sp_waveform_periods.set_value (nperiods); - MENU.sp_curve_rpm.set_value (last_rpm); + curcrvchgd = 1; + dont_call_listener (MENU.cb_show_waveform_samples, samples_enabled); dont_call_listener (MENU.cb_label_vertices, label_vertices); dont_call_listener (MENU.cb_draw_curve, draw_curve_only); @@ -992,17 +1016,6 @@ rotate (); } -curve_info::curve_info (multi_curve* c, curve_listener* l, int p) { - curve = c; - lisner = l; - picked = p; -} - -curve_info::curve_info () { - curve = 0; - lisner = 0; - picked = 0; -} void curve_editor::clear_hit (hit_t& h) { @@ -1017,7 +1030,7 @@ if (dir == 1) crv = library->next (); else crv = library->prev(); crv.set_color (mix.r, mix.g, mix.b); crv.name = mix.name; - setup_tools_menu (); + if (MENU.show) setup_tools_menu (); else curcrvchgd = 1; pomo.validate (); curveinfo[pik.crv_id].lisner->edited (this, pik.crv_id); cons.rollup (1); @@ -1058,8 +1071,9 @@ pomo.validate (); ci.lisner->edited (this, hit.crv_id); cons << GREEN << "Pasted into " << crv->name << eol; - } else cons << RED << "Nothing to paste!" << eol; - do_nothing (); + } else + cons << RED << "Nothing to paste!" << eol; + quick_nothing (); } else cons << RED << "Pick a curve to paste." << eol; } @@ -1136,7 +1150,7 @@ } void curve_editor::insert_using_menu () { - if (num_curves == 1) { + if (onecurve()) { todo = INSERT_VERTEX; cursor_mesg = " Click to insert vertex. ESC to stop."; } else { @@ -1153,10 +1167,10 @@ todo = FOLD_VERTEX; cursor_mesg = " Click on vertex to fold tangents. ESC to stop."; } else { - if (num_curves == 1) { + if (onecurve()) { pik = pick_cur_curve (); fold_all_tangents (pik); - do_nothing (); + quick_nothing (); } else { todo = PICK_CURVE; next_todo = FOLD_ALL; @@ -1172,10 +1186,10 @@ todo = UNFOLD_VERTEX; cursor_mesg = " Click on vertex to unfold tangents. ESC to stop."; } else { - if (num_curves == 1) { + if (onecurve()) { pik = pick_cur_curve (); unfold_all_tangents (pik); - do_nothing (); + quick_nothing (); } else { todo = PICK_CURVE; cursor_mesg = " Pick curve to unfold tangents. ESC to stop."; @@ -1191,11 +1205,11 @@ todo = MIRROR_VERTEX; cursor_mesg = " Click on vertex or tangent to flip. ESC to stop."; } else { - if (num_curves == 1) { + if (onecurve()) { pik = pick_cur_curve (); int whole_curve = 1; mirror (whole_curve); - do_nothing (); + quick_nothing (); } else { todo = PICK_CURVE; cursor_mesg = " Pick the curve to flip. ESC to stop."; @@ -1206,8 +1220,8 @@ } void curve_editor::copy_using_menu () { - if (num_curves == 1) { - copy = *curveinfo[0].curve; + if (onecurve()) { + copy = *curveinfo[curcrv].curve; cons << GREEN << "Copied " << copy.name << eol; } else { todo = PICK_CURVE; @@ -1218,7 +1232,7 @@ } void curve_editor::paste_using_menu () { - if (num_curves == 1) { + if (onecurve()) { pik = pick_cur_curve (); paste (pik); } else { @@ -1259,7 +1273,7 @@ crv.set_right_tangent (hit.id, vx, vy); crv.evaluate (); ci.lisner->edited (this, hit.crv_id); - do_nothing (); + quick_nothing (); } } @@ -1275,7 +1289,7 @@ crv.set_right_tangent (hit.id, vx + obj.x, vy); crv.evaluate (); ci.lisner->edited (this, hit.crv_id); - do_nothing (); + quick_nothing (); } } @@ -1287,7 +1301,7 @@ } void curve_editor::toggle_waveform_samples_display () { - if (is_waveform_editor) { + if (waved) { samples_enabled = !samples_enabled; render_curve_samples (); dont_call_listener (MENU.cb_show_waveform_samples, samples_enabled); @@ -1306,24 +1320,28 @@ render_curve_samples (); } -void curve_editor::do_nothing () { +void curve_editor::abs_nothing () { stop_mouse_capture (); - lmb_move = 0; if (todo == ADD_VERTEX) { - if (MENU.show == 0) + if (rmb) replace (); else clear_scratch_curve (); } + quick_nothing (); +} + +void curve_editor::quick_nothing () { todo = next_todo = NOTHING; cursor_mesg = next_cursor_mesg = ""; + lmb_move = 0; } void curve_editor::copy_curve () { if (pik()) { copy = *get_curve(pik.crv_id); cons << GREEN << "Copied "<< copy.name << "." << eol; - do_nothing (); + quick_nothing (); } } @@ -1341,15 +1359,23 @@ void curve_editor::do_pick_curve () { clear_hit (pik); - todo = PICK_CURVE; - cursor_mesg = " Click to pick curve, ESC to abort!"; - next_todo = NOTHING; - next_cursor_mesg = ""; + if (onecurve()) { + pik = pick_cur_curve (); + cons << "Picked " << pik.crv->name << eol; + quick_nothing (); + return; + } else { + todo = PICK_CURVE; + cursor_mesg = " Click to pick curve, ESC to abort!"; + next_todo = NOTHING; + next_cursor_mesg = ""; + } } hit_t curve_editor::pick_cur_curve () { multi_curve* crv = curveinfo[curcrv].curve; - return hit_t (crv, 0); + curcrvchgd = 1; + return hit_t (crv, curcrv); } multi_curve* curve_editor::get_picked_curve () { @@ -1360,25 +1386,17 @@ return pik.crv; } -void curve_editor::set_picked_curve_name (const string& name) { - if (pik()) { - cons << "Curve " << pik.crv->name << " changed to " << name << eol; - pik.crv->set_name (name); - } else - cons << RED << "Please pick a curve" << eol; -} void curve_editor::delete_curve () { if (library) library->del (); } void curve_editor::draw_replacement_curve_using_menu () { - if (num_curves == 1) { - cons << YELLOW << "Replacing the viewed curve" << eol; + if (onecurve()) { pik = pick_cur_curve (); show_scratch_curve = 1; todo = ADD_VERTEX; - cursor_mesg = " Click to add vertex. ESC to stop."; + cursor_mesg = " Click to add vertex. ESC to abort!"; } else { todo = PICK_CURVE; cursor_mesg = " Pick curve to replace. ESC to abort!"; @@ -1393,7 +1411,7 @@ win_scratch_points.push_back (point (sx, sy)); float curvx, curvy; win2obj (sx, sy, curvx, curvy); curv_scratch_points.push_back (point(curvx, curvy)); - if (curv_scratch_points.size () < 2) cursor_mesg = "Click to add vertex. ESC to abort!"; else cursor_mesg = "Click to add vertex. ESC to complete."; + if (curv_scratch_points.size () > 1) cursor_mesg = "Click to add vertex. Right click to complete."; } void curve_editor::assign_mouse_capture () { @@ -1401,7 +1419,7 @@ undos.push_back (undo_t (pik.crv_id, *get_curve(pik.crv_id), win)); macros.push_back (mouse_macro (mocap0, pik, capturer.add ())); cons << GREEN << "Assigned mouse capture to " << pik << eol; - do_nothing (); + quick_nothing (); } } @@ -1421,7 +1439,7 @@ i = macros.erase (i); j = macros.end (); if (macros.empty()) { - do_nothing (); + quick_nothing (); return; } } else ++i; @@ -1449,6 +1467,13 @@ cursor_mesg = " Capturing mouse. Click or ESC to finish!"; } +void curve_editor::set_picked_curve_name (const string& name) { + if (!pik()) pik = pick_cur_curve (); + cons << "Curve " << pik.crv->name; + pik.crv->set_name (name); + cons << " changed to " << name << eol; +} + void curve_editor::set_limit (float f) { if (!pik()) pik = pick_cur_curve (); curve_info& ci = curveinfo [pik.crv_id]; @@ -1456,18 +1481,32 @@ crv->set_limit (f); crv->evaluate (); ci.lisner->edited (this, pik.crv_id); + cons << "Curve roughness = " << f << eol; } -void curve_editor::setup_tools_menu () { +void curve_editor::set_curve_style (multi_curve* crv) { + const char* pre [] = {" Curve is", " Waveform is"}; + int i = waved; + int s = crv->shapeform; + const char* awhat [] = {"classical", "a shape" }; + sprintf (BUFFER, "%s %s", pre[i], awhat[s]); + MENU.ol_curve_style.set_text(BUFFER); + float cx [] = {0.0f, 0.5f}; + crv->cx = cx[s]; + crv->cy = 0.0f; +} + +void curve_editor::toggle_curve_style () { multi_curve* crv = get_curve (curcrv); - MENU.lf_curve_name.set_text (crv->name); - MENU.sp_curve_limit.set_value (crv->limit); - MENU.picked (MENU.ol_mirror.option, 0); - set_curve_style (); + mix = *crv; + crv->set_shapeform (!crv->shapeform); + set_curve_style (crv); + render_curve_samples (); + //if (crv->shapeform && waved && !samples_enabled) toggle_waveform_samples_display (); + curveinfo[curcrv].lisner->edited (this, curcrv); } void curve_editor::curve_picked () { - setup_tools_menu (); if (next_todo == FOLD_ALL) fold_all_tangents (pik); else if (next_todo == UNFOLD_ALL) unfold_all_tangents (pik); else if (next_todo == MIRROR_ALL) {int whole_curve = 1; mirror (whole_curve);} @@ -1476,53 +1515,49 @@ else { todo = next_todo; cursor_mesg = next_cursor_mesg; + cons << GREEN << "Picked " << pik.crv->name << eol; } } - -void curve_editor::set_curve_style () { - multi_curve* crv = get_curve (curcrv); - string pre (" Curve is "); if (is_waveform_editor) pre = " Waveform is "; - if (crv->shapeform) MENU.ol_curve_style.set_text(pre + "a shape"); else MENU.ol_curve_style.set_text (pre + "classical"); -} - -void curve_editor::toggle_curve_style () { - multi_curve* crv = get_curve (curcrv); - mix = *crv; - crv->set_shapeform (!crv->shapeform); - set_curve_style (); - render_curve_samples (); - if (crv->shapeform && is_waveform_editor && !samples_enabled) toggle_waveform_samples_display (); - curveinfo[curcrv].lisner->edited (this, curcrv); -} - -void curve_editor::set_rpm (float _rpm) { - if (_rpm == 0) { - rpm = hit_t (); - } else { - if (!pik()) pik = pick_cur_curve (); - rpm = pik; - float rps = _rpm / 60.0; +void curve_editor::set_rpm (float r) { + cons << "RPM = " << r << eol; + curve_info& ci = curveinfo [curcrv]; + if (r != 0) { + float rps = r / 60.0; float rpf = rps / FPS; - angle = rpf * TWO_PI; - if (last_rpm == 0) { - undos.push_back (undo_t (rpm.crv_id, *rpm.crv, win)); - rpm.crv->calc_centroid (); - } - startt = ui_clk() - TIME_PER_FRAME; + ci.angle = rpf * TWO_PI; + if (ci.lastrpm == 0) { + undos.push_back (undo_t (curcrv, *ci.curve, win)); + ci.totang = 0.0f; + } + ci.startt = ui_clk() - TIME_PER_FRAME; } - last_rpm = _rpm; + ci.lastrpm = r; } void curve_editor::rotate () { - if (rpm()) { - float now = ui_clk(); - float elapsed = now - startt; - if (elapsed >= TIME_PER_FRAME) { - float mult = elapsed / TIME_PER_FRAME; - rpm.crv->rotate (mult * angle); - curveinfo[rpm.crv_id].lisner->edited (this, rpm.crv_id); - startt = ui_clk(); + for (int i = 0; i < curves; ++i) { + curve_info& ci = curveinfo[i]; + if (ci.lastrpm) { + float now = ui_clk(); + float elapsed = now - ci.startt; + if (elapsed >= TIME_PER_FRAME) { + float mult = elapsed / TIME_PER_FRAME; + float byangle = mult * ci.angle; + float sum = ci.totang + byangle; + if (ci.autoflip && sum >= ci.every.rad) { + float finrot = ci.every.rad - ci.totang; + ci.curve->rotate (ci.dir * finrot); + ci.totang = 0.0f; + ci.dir *= -1; + if (ci.randoflip) ci.randeg (); + } else { + ci.totang = sum; + ci.curve->rotate (ci.dir * byangle); + } + ci.lisner->edited (this, i); + ci.startt = ui_clk (); + } } } } @@ -1556,7 +1591,8 @@ void curve_editor::apply_plugin (plugin* p) { int r = 0; - multi_curve* crv = curveinfo [curcrv].curve; + curve_info& ci = curveinfo [curcrv]; + multi_curve* crv = ci.curve; if (p->mix) mix = *crv; if (p->undo) { undos.push_back (undo_t (curcrv, *crv, win)); @@ -1570,18 +1606,17 @@ } if (r) { - if (p == &spiraler_ || p == &rosemilker) - crv->centroid_style = multi_curve::SET; - else - crv->centroid_style = multi_curve::CALC; pomo.validate (); - curveinfo[curcrv].lisner->edited (this, curcrv); + ci.lisner->edited (this, curcrv); } + + ci.totang = 0.0f; + } int curve_editor::stop_todo () { if (todo != curve_editor::NOTHING) { - do_nothing (); + abs_nothing (); return 1; } return 0; @@ -1675,7 +1710,7 @@ int curve_editor::esc () { int ret = 0; - if (stop_todo()) + if (stop_todo ()) ret = 1; else { if (!rmb) { @@ -1697,3 +1732,61 @@ if (over) uis.plugin__browser.plugins[uis.plugin__browser.cur]->draw (dynamic_cast(over)); unproject (); } + +int curve_editor::setcrvvis (int i, int v) { + + int& vi = curveinfo[i].visible; + vi = v; + + static const int d [] = {-1, 1}; + visibles += d[v]; + + if (visibles == 0) { + visibles = 1; + vi = 1; + curcrv = i; + pik = pick_cur_curve (); + setup_tools_menu (); + return 0; + } else if (visibles == 1) { + curcrv = -1; + for (int i = 0; i < curves; ++i) { + curve_info& ci = curveinfo[i]; + if (ci.visible) curcrv = i; + } + pik = pick_cur_curve (); + setup_tools_menu (); + } + + return 1; + +} + +curve_info::curve_info (multi_curve* c, curve_listener* l, int p) { + init (); + curve = c; + lisner = l; + picked = p; +} + +curve_info::curve_info () { + init (); + curve = 0; + lisner = 0; +} + +void curve_info::init () { + picked = 0; + visible = 1; + angle = 0; + lastrpm = 0; + dir = 1; + autoflip = 0; + randoflip = 0; + rd.set (0.0f, 1.0f); + totang = 0.0f; + every0 = 180.0f; + every = every0; + startt = 0.0; +} + diff -Nru din-55/src/curve_editor.h din-56/src/curve_editor.h --- din-55/src/curve_editor.h 2022-02-27 08:54:44.000000000 +0000 +++ din-56/src/curve_editor.h 2022-11-08 06:19:13.000000000 +0000 @@ -31,14 +31,13 @@ #include "point_modulator.h" #include "hit.h" #include "help.h" +#include "angle.h" struct multi_curve; struct curve_editor; struct curve_library; struct plugin; -extern const char spc; - struct mouse_macro { // for applying mouse capture to hit vertex/tangent of hit curve mocap mo; // mouse capture data @@ -58,41 +57,62 @@ typedef undo_t redo_t; struct curve_info { + multi_curve* curve; - int picked; - int disabled; curve_listener* lisner; + + int picked; + + int visible; + + float lastrpm; + float angle; + float totang; + int dir; + + int autoflip; + anglet every0, every; + int randoflip; + rnd rd; + void randeg () { + every = rd () * every0.deg; + } + double startt; + curve_info (multi_curve* c, curve_listener* l, int picked = 0); curve_info (); + void init (); }; struct curve_editor : basic_editor { - std::vector curveinfo; // edited curves + // edited curves + // + std::vector curveinfo; + int curves; int curcrv; - int num_curves; - void clear (); + int curcrvchgd; + int visibles; + int setcrvvis (int i, int v); + int onecurve () { return (curves == 1 || visibles == 1); } + int savedrots; void add (multi_curve* crv, curve_listener* lsnr); - curve_info& get_curve_info (int i); + void clear (); multi_curve* get_curve (int i); + // curve editor features // int carry_tangents; // when vertex moves, their tangents move too. int mirror_tangents; // when 1 tangent of a vertex moves, the other moves too. - - int lmb_clicked; // picking // std::vector hitlist; - hit_t pik; - multi_curve* get_picked_curve (); - std::string get_picked_curve_name (); hit_t pick_cur_curve (); void set_picked_curve_name (const std::string& n); void curve_picked (); @@ -134,7 +154,8 @@ int next_todo; int stop_todo (); - void do_nothing (); + void abs_nothing (); + void quick_nothing (); void do_pick_curve (); @@ -235,7 +256,6 @@ // curve selection ops - void pick (int k); void toggle (int k); void enable (int k); void enable_all (); @@ -283,7 +303,7 @@ void enter (); void bg (); - void set_curve_style (); + void set_curve_style (multi_curve* crv); void toggle_curve_style (); void apply_mocap (); @@ -291,7 +311,7 @@ int fft_enabled; - int is_waveform_editor; + int waved; int samples_enabled; float hz; int nperiods; @@ -313,12 +333,8 @@ void setup_tools_menu (); - float startt; - hit_t rpm; - float rotx, roty; - float angle; - float last_rpm; - void set_rpm (float RPM); + + void set_rpm (float r); void rotate (); void scale (float sx, float sy); @@ -340,6 +356,9 @@ void drawerlay (); + int lmb_clicked; + + }; diff -Nru din-55/src/curve_listener.h din-56/src/curve_listener.h --- din-55/src/curve_listener.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/curve_listener.h 2022-10-26 09:01:33.000000000 +0000 @@ -8,11 +8,13 @@ #ifndef __CURVE_LISTENER #define __CURVE_LISTENER + struct curve_editor; struct curve_listener { - virtual void selected (int i) {} virtual void edited (curve_editor* ed, int i); virtual ~curve_listener () {} }; + #define CURVE_LISTENER(name) struct name : curve_listener { void edited (curve_editor* ed, int i); }; + #endif diff -Nru din-55/src/defvelaccel.cc din-56/src/defvelaccel.cc --- din-55/src/defvelaccel.cc 2022-02-10 09:28:51.000000000 +0000 +++ din-56/src/defvelaccel.cc 2022-11-28 02:42:33.000000000 +0000 @@ -24,17 +24,21 @@ f >> dva.autos.rot.yes >> dva.autos.rot.dir >> dva.autos.rot.mov >> dva.autos.rot.rpm >> dva.autos.rot.dps >> dva.autos.rot.tps; f >> dva.autos.rot.uet.deg >> dva.autos.rot.uet.tps; f >> dva.autos.flip.yes >> dva.autos.flip.deg; + f >> dva.autos.pause.yes >> dva.autos.pause.every >> dva.autos.pause.f0r; dva.rotrd.set (-dva.clock.rad, dva.anticlock.rad); return f; } +defvelaccel::autost::pauset::pauset() : yes(1), every(1.0f, 0), f0r(1.0f, 0) {} + extern const char spc; std::ostream& operator<< (std::ostream& f, defvelaccel& dva) { f << dva.mag << spc << dva.dir << spc << dva.neg << spc << dva.rndrot << spc << dva.clock << spc << dva.anticlock << spc << dva.sync << spc; f << dva.autos.rot.yes << spc << dva.autos.rot.dir << spc << dva.autos.rot.mov << spc << dva.autos.rot.rpm << spc << dva.autos.rot.dps << spc << dva.autos.rot.tps << spc << dva.autos.rot.uet.deg << spc << dva.autos.rot.uet.tps << spc; - f << dva.autos.flip.yes << spc << dva.autos.flip.deg; + f << dva.autos.flip.yes << spc << dva.autos.flip.deg << spc; + f << dva.autos.pause.yes << spc << dva.autos.pause.every << spc << dva.autos.pause.f0r; return f; } diff -Nru din-55/src/defvelaccel.h din-56/src/defvelaccel.h --- din-55/src/defvelaccel.h 2022-02-05 09:25:29.000000000 +0000 +++ din-56/src/defvelaccel.h 2022-11-28 19:06:06.000000000 +0000 @@ -19,6 +19,7 @@ val = v; rndrd = rr; } + float operator()(int) {return rd() * val;} float operator()() {if (rndrd) return rd() * val; else return val;} valt& operator= (float v) { val = v; @@ -74,6 +75,13 @@ flipt () : deg (180), yes(0) {} } flip; + struct pauset { + int yes; + valt every; + valt f0r; + pauset (); + } pause; + } autos; defvelaccel (const std::string& n); diff -Nru din-55/src/din.cc din-56/src/din.cc --- din-55/src/din.cc 2022-09-20 18:46:09.000000000 +0000 +++ din-56/src/din.cc 2022-12-20 19:13:17.000000000 +0000 @@ -190,9 +190,10 @@ load_ranges (); } else { int last_num_ranges = num_ranges; + int ht = lastr->extents.height; create_ranges (NUM_OCTAVES * scaleinfo.num_ranges); set_range_width (last_num_ranges, last_range, WIDTH); - set_range_height (last_num_ranges, last_range, HEIGHT); + set_range_height (last_num_ranges, last_range, ht); init_range_mod (last_num_ranges, last_range); if (last_num_octaves < NUM_OCTAVES) calc_added_range_notes (last_num_octaves, last_num_ranges); } @@ -997,9 +998,14 @@ void din::immortalize_drones () { if (num_selected_drones) { for (int i = 0; i < num_selected_drones; ++i) { - drone& ds = *selected_drones[i]; - ds.birth = -1; - ds.reincarnate = 0; + drone* pds = selected_drones[i]; + pds->birth = -1; + pds->reincarnate = 0; + if (pds->gravity) { + pds->gravity = 0; + erase (gravitated, pds); + erase (satellites, pds); + } } } else cons << RED_PSD << eol; } @@ -1165,7 +1171,7 @@ int style = dinfo.bounce.style; if (style == din_info::bouncet::RANDOM) style = get_rand_bit (); if (style == din_info::bouncet::BACK) di.vx *= -reduction; - di.vy = reduction * -di.vy; + di.vy *= -reduction; } } @@ -1410,7 +1416,6 @@ if (!di.frozen && di.launch_every (ui_clk())) { // time to launch a drone - for (int p = 0, q = di.dpl; p < q; ++p) { #define CALLEDFROMLAUNCHER 1 @@ -1445,7 +1450,7 @@ newdrone.trail.total = di.trail.total; newdrone.snap = di.snap; - newdrone.gab = di.gab; + // newdrone.gab = di.gab; newdrone.arrow = di.arrow; @@ -2676,8 +2681,8 @@ // AM along a direction vector, FM along a direction vector float x = di.cx + dm.fm.result * (*dm.fm.dirx) + dm.am.result * (*dm.am.dirx); float y = di.cy + dm.fm.result * (*dm.fm.diry) + dm.am.result * (*dm.am.diry); - if (di.autorot.v.yes) rotate_vector (di.vx, di.vy, di.autorot.v.angle.theta); - if (di.autorot.a.yes) rotate_vector (di.ax, di.ay, di.autorot.a.angle.theta); + if (di.autorot.v.yess()) rotate_vector (di.vx, di.vy, di.autorot.v.angle.theta); + if (di.autorot.a.yess()) rotate_vector (di.ax, di.ay, di.autorot.a.angle.theta); di.set_pos (x, y); // di.set_pos (di.cx + dm.fm.result, di.cy + dm.am.result); } @@ -2741,15 +2746,15 @@ drone& ds = *selected_drones[i]; int amst [] = {state, !ds.autorot.v.yes}; int fmst [] = {state, !ds.autorot.a.yes}; - ds.autorot.v.yes = amst[tog]; - ds.autorot.a.yes = fmst[tog]; + ds.autorot.v.setyes (amst[tog]); + ds.autorot.a.setyes (fmst[tog]); } } else { for (int i = 0; i < num_selected_drones; ++i) { drone& ds = *selected_drones[i]; - int& yes = ds.autorot.arr[what]->yes; - int states[] = {state, !yes}; - yes = states[tog]; + autorotator& ar = *ds.autorot.arr[what]; + int states[] = {state, !ar.yes}; + ar.setyes (states[tog]); } } TOGGLEMENU @@ -2778,18 +2783,75 @@ yes = states[tog]; } } - TOGGLEMENU } else cons << RED_PSD << eol; + TOGGLEMENU } +void din::setautopause (int what, int state, int tog) { + if (num_selected_drones) { + if (what == menu::autorott::BOTH) { + for (int i = 0; i < num_selected_drones; ++i) { + drone& ds = *selected_drones[i]; + int amst [] = {state, !ds.autorot.v.autopause.yes}; + int fmst [] = {state, !ds.autorot.a.autopause.yes}; + ds.autorot.v.autopause.setyes (amst[tog], ds.autorot.v); + ds.autorot.a.autopause.setyes (fmst[tog], ds.autorot.a); + } + } else { + for (int i = 0; i < num_selected_drones; ++i) { + drone& ds = *selected_drones[i]; + autorotator& ar = *ds.autorot.arr[what]; + autopauset& ap = ar.autopause; + int states[] = {state, !ap.yes}; + ap.setyes (states[tog], ar); + } + } + } else + cons << RED_PSD << eol; + + TOGGLEMENU +} + +void din::setrndflipause (int what, int which, int state, int tog) { + if (num_selected_drones) { + if (what == menu::autorott::BOTH) { + for (int i = 0; i < num_selected_drones; ++i) { + drone& ds = *selected_drones[i]; + int* vw [] = {&ds.autorot.v.autoflip.rndang, &ds.autorot.v.autopause.rndt[0],&ds.autorot.v.autopause.rndt[1]}; + int* aw [] = {&ds.autorot.a.autoflip.rndang, &ds.autorot.a.autopause.rndt[0],&ds.autorot.a.autopause.rndt[1]}; + int& dsvw = *vw[which]; + int& dsaw = *aw[which]; + int vst [] = {state, !dsvw}; + int ast [] = {state, !dsaw}; + dsvw = vst[tog]; + dsaw = ast[tog]; + } + } else { + for (int i = 0; i < num_selected_drones; ++i) { + drone& ds = *selected_drones[i]; + autorotator& ar = *ds.autorot.arr[what]; + int* w [] = {&ar.autoflip.rndang, &ar.autopause.rndt[0], &ar.autopause.rndt[1]}; + int& wv = *w[which]; + int states[] = {state, !wv}; + wv = states[tog]; + } + } + } else + cons << RED_PSD << eol; + + TOGGLEMENU +} + + void din::setautorotparam (int which, int what) { if (which == menu::autorott::BOTH) { for (int i = 0; i < num_selected_drones; ++i) { drone& ds = *selected_drones[i]; autorotator &var = ds.autorot.v, &aar = ds.autorot.a; - var.yes = aar.yes = 1; + var.setyes (1); + aar.setyes (1); if (what == menu::autorott::RPM) { var.mov = aar.mov = autorotator::SMOOTH; var.set_rpm (ds.autorot.v.rpm + MENU.autorotate.rpm()); @@ -2873,6 +2935,42 @@ cons << RED_PSD << eol; } +void din::setautopauseparam (int what, int which) { + static const char* pl [] = {"Every", "For"}; + spinner* sp [] = {MENUP.autorotate.autopause.every, MENUP.autorotate.autopause.f0r}; + if (what == menu::autorott::BOTH) { + for (int i = 0; i < num_selected_drones; ++i) { + drone& ds = *selected_drones[i]; + autopauset &vp = ds.autorot.v.autopause, &ap = ds.autorot.a.autopause; + spinner& spw = *sp[which]; + double* vapp [] = {&vp.every, &vp.f0r}; + double* aapp [] = {&ap.every, &ap.f0r}; + double& dv = *vapp[which]; + double& da = *aapp[which]; + dv += spw(); + if (dv < 0) dv = 0.0; + da += spw(); + if (da < 0) da = 0.0; + cons << "Drone : " << i << " Velocity Auto pause " << pl[which] << spc << dv << " seconds, Acceleration Auto pause " << pl[which] \ + << da << eol; + } + } else { + const char* strs[2] = {" Velocity", " Acceleration"}; + spinner& spw = *sp[which]; + for (int i = 0; i < num_selected_drones; ++i) { + drone& ds = *selected_drones[i]; + autopauset& ap = ds.autorot.arr[what]->autopause; + double* app [] = {&ap.every, &ap.f0r}; + double& dp = *app[which]; + dp += spw (); + if (dp < 0) dp = 0.0; + cons << "Drone : " << i << strs[what] << " Auto pause " << pl[which] << spc << dp << " seconds" << eol; + } + } +} + + + void din::setautoflipangle (int what) { if (what == menu::autorott::BOTH) { @@ -3174,7 +3272,8 @@ } void din::start_moving_drones () { - if (num_selected_drones) set_moving_drones (1); else cons << RED_PSD << eol; + SELECTED_DRONES_EXIST + set_moving_drones (1); } void din::toggle_moving_drones () { @@ -4779,6 +4878,20 @@ return 0; } +void din::rail (int dir, double scl) { + for (int i = 0; i < num_selected_drones; ++i) { + drone& di = *selected_drones[i]; + di.set_center (di.cx + dir * scl * di.vx, di.cy + dir * scl * di.vy); + } +} + +void din::strafe (int dir, double scl) { + for (int i = 0; i < num_selected_drones; ++i) { + drone& di = *selected_drones[i]; + di.set_center (di.cx + dir * scl * di.vy, di.cy - dir * scl * di.vx); + } +} + /*void din::eval_conns () { for (drone_iterator i = drones.begin (), j = drones.end (); i != j; ++i) { drone& di = *(*i); diff -Nru din-55/src/din.h din-56/src/din.h --- din-55/src/din.h 2022-06-16 20:40:27.000000000 +0000 +++ din-56/src/din.h 2022-12-20 19:03:51.000000000 +0000 @@ -14,6 +14,8 @@ #define TOGO " to go!" #define CLEAR_SELECTED_DRONES if (SHIFT || CTRL) ; else clear_selected_drones (); +#define SELECTED_DRONES_EXIST if (num_selected_drones == 0) { cons << RED_PSD << eol; return; } +#define _SELECTED_DRONES_EXIST_ if (din0.num_selected_drones == 0) { cons << RED_PSD << eol; return; } #define RESETALLCHUCKTRAILS if (drone::chuckt::autoresettrails) din0.resetallchucktrails (); @@ -256,6 +258,8 @@ enum {NONE, SCALE, ROTATE}; int xforming; void resize_xform_vectors (); + void rail (int dir, double scl); + void strafe (int dir, double scl); // drone tone void update_drone_tone (); @@ -297,6 +301,10 @@ void setautorotdir (int which, int dir); void setautoflip (int which, int state, int tog = 0); void setautoflipangle (int which); + void setautopause (int which, int state, int tog = 0); + void setautopauseparam (int what, int which); + void setrndflipause (int what, int which, int state, int tog = 0); + // drone death void mortalize_drones (int reincarnate = 0); diff -Nru din-55/src/drone.cc din-56/src/drone.cc --- din-55/src/drone.cc 2022-06-13 18:56:19.000000000 +0000 +++ din-56/src/drone.cc 2022-11-28 03:08:47.000000000 +0000 @@ -256,15 +256,14 @@ cons << "drone: " << i << whatstr[what] << whati << eol; } -void drone::change_modpos (int i, int what, float delta) { +void drone::change_modpos (int i, int what, float val) { float* whats [] = {&mod.am.bv.now, &mod.fm.bv.now}; - float& whati = *whats[what]; + float& whatv = *whats[what]; + whatv = val; static const char* whatstr [] = {", AM position = ", ", FM position = "}; - whati = delta; - cons << "drone: " << i << whatstr[what] << whati << eol; + cons << "drone: " << i << whatstr[what] << whatv << eol; } - void drone::clear_targets () { targets.clear (); cur_target = 0; diff -Nru din-55/src/eval.cc din-56/src/eval.cc --- din-55/src/eval.cc 2022-06-06 20:09:11.000000000 +0000 +++ din-56/src/eval.cc 2022-11-03 13:32:05.000000000 +0000 @@ -365,7 +365,37 @@ } -int fractaliser::apply (multi_curve& crv) { +int plugin::apply (multi_curve& crv) { + +#ifdef __EVALUATION__ + cons << RED << "Can apply plugins only in the Licensed Version of DIN Is Noise" << eol; + return 0; +#endif + + int n = points.size (); + if (n == 0) return 0; + + crv.clear (0); + + for (int i = 0; i < n; ++i) { + point& p = points[i]; + crv.add_vertex (p.x, p.y); + crv.add_left_tangent (p.x, p.y); + crv.add_right_tangent (p.x, p.y); + } + + if (shapeform) + crv.set_shapeform (1); + else + crv.evaluate (); + + CRVED->set_curve_style (&crv); + + return 1; + +} + +int fractaliser::apply (multi_curve& crv) { // needed bcos of tangents #ifdef __EVALUATION__ cons << RED << "Can apply plugins only in the Licensed Version of DIN Is Noise" << eol; return 0; @@ -374,7 +404,7 @@ int npts = points.size (); if (npts == 0) return 0; crv.clear (0); - if (change_curve_name) crv.set_name (ss.str()); + // if (change_curve_name) crv.set_name (ss.str()); typedef std::list< point >::iterator points_list_iterator; points_list_iterator lti = left_tangents.begin (), rti = right_tangents.begin (); @@ -386,7 +416,7 @@ crv.add_left_tangent (lt.x, lt.y); crv.add_right_tangent (rt.x, rt.y); } - if (shapeform) crv.shapeform = 1; + crv.set_shapeform (shapeform); crv.evaluate (); return 1; } @@ -1050,35 +1080,6 @@ ++num_balls; } -int plugin::apply (multi_curve& crv) { - -#ifdef __EVALUATION__ - cons << RED << "Can apply plugins only in the Licensed Version of DIN Is Noise" << eol; - return 0; -#endif - - int n = points.size (); - if (n == 0) return 0; - - crv.clear (0); - - for (int i = 0; i < n; ++i) { - point& p = points[i]; - crv.add_vertex (p.x, p.y); - crv.add_left_tangent (p.x, p.y); - crv.add_right_tangent (p.x, p.y); - } - - if (shapeform) - crv.set_shapeform (1); - else - crv.evaluate (); - - CRVED->set_curve_style (); - - return 1; - -} state_button* point_modulator::add (hit_t& h) { #ifdef __EVALUATION__ @@ -1282,7 +1283,7 @@ cd_waveform_display.set_size (96, 96); cd_waveform_display.crv = &keybd2.wave; // keyboard-keyboard's waveform - cd_waveform_display.calc_bbox (); + cd_waveform_display.setbbox (keybd2.wave.shapeform); // octave shift l_octave_shift.set_text ("Octave Shift"); diff -Nru din-55/src/factory/attack.ed din-56/src/factory/attack.ed --- din-55/src/factory/attack.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/attack.ed 2022-10-24 06:38:20.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/binaural-drones.hlp din-56/src/factory/binaural-drones.hlp --- din-55/src/factory/binaural-drones.hlp 2021-03-10 05:56:27.000000000 +0000 +++ din-56/src/factory/binaural-drones.hlp 2022-11-03 16:39:21.000000000 +0000 @@ -1,116 +1,119 @@ -DIN Is Noise Copyright (c) 2006-2021 Jagannathan Sampath . - -Binaural Drones - -Launch with Menu > Instrument > Binaural drones. - -A binaural drone pair is a pair of drones, one drone goes into your left -ear (the L drone) and the other drone goes into your right ear (the R -drone). So, you need to hear this on headphones :) The L drone and the R -drone each vibrate at their own pitch (in Hz). You hear the difference -between the pitches (the Separation) as a beat at that pitch. eg., if the -difference is 1 Hz, you hear a beat every second. These beats are called -binaural beats. - -DIN can make binaural drone pairs starting at a pitch (default @ 100 Hz) -with any separation between the drones of a pair, default @ 1 Hz. - -DIN can also make binaural drone pairs at the notes of the scale starting -at the key note. The key note can be the starting pitch or the pitch or -note you set on the Settings page. You can also set the other notes of the -scale there. - -Turn on Close Octave to create a binaural pair on the octave note too. - -Turn on Resize separation to vary the separation between L and R drones of -each pair so that their absolute pitch always falls on the notes of the -scale. - -Justification determines the drone that gets the starting pitch. Left sets -it to the L drone, Right sets it to the R drone. eg., for a Starting pitch -100 Hz and Separation 1 Hz and Justification = Left, L drone is @ 100 Hz, R -drone is @ 101 Hz. If Justification = Right, R drone is @ 100 Hz, L drone -is @ 99 Hz. If Justification = Center, the L drone is @ 99.5 Hz and R drone -is @ 100.5 Hz. - -Spacing (in Hz) determines the spacing between two successive binaural -drone pairs, default @ 50 Hz. - -Press 2 or Menu > Editors > Waveform to edit the waveform that drives all -binaural drone pairs. - -Menu > Edit to edit the binaural drones. - -Master volume in % determines the overall loudness of all binaural drone -pairs. 100% is loudest. 0% is silence. > 100% is valid too. Careful :) - -Volume fade time in seconds is the time taken to fade in or out when -creating, destroying, syncing, changing the volume of a drone pair or when -changing the master volume. - -Pitch fade time in seconds is the time taken to change the L drone or the R -drone of any binaural drone pair from one pitch to another. You can see -this when you modulate, flip or change L, R pitches or separation of -selected drone pairs. - -When fading pitch or volume, you can press ESC to abort. Useful when the -fade times are long, also useful when you have unexpectedly reached a more -interesting sound...:) - -DIN lists the binaural drone pairs in a list. Click an element to select -or deselect, hold SHIFT button down and click to select a group, and clear, -invert selection. You can also select based on L, R, Separation Hz or -Volume: Select L, R, Separation or Volume from the options, choose the -operator: >=, <=, =, <> (the range operator) or id (id numbers of drone -pairs listed between the []), enter the value and press ENTER or click on -Select to execute. DIN selects the matching pairs. The range operator -takes two values, the low and high. The id operator takes 3 values -(3rd value is optional and is 1 when not present), the start id, the end id -and the increment. - -You can edit the pitch of the L drone, the R drone, Separation, -Justification and the Volume % of a selected pair in the fields to the -right. When you select more than one pair, the L and R pitch fields accept -relative instead of absolute values ie you change the L and R Hz rather -than set it. - -Flip to swap the pitches of selected drone pairs. ESC to abort. - -Modulate [actually Multiply] the pitches of L and R drone of selected pairs -by an Amount. Press LEFT_ARROW to modulate down, RIGHT_ARROW to modulate -up. ESC to abort. With default Amount @ 2.0, you octave shift when you -modulate the selected pairs :) You can modulate up or down an interval -using the value of DIN's interval variables. eg., $1, $2b, $2, $3b $3, $4, -$5b, $5, $6b, $6, $7b, $7 or $8: eg., type $2b, press ENTER and click -LEFT_ARROW or RIGHT_ARROW to modulate down or up by a semitone :) $1 is 1.0 -and $8 is 2.0 which is the octave shift again :) - -Delete deletes the selected binaural drone pairs. DIN first fades out the -volume of the pairs and then deletes them. ESC to abort delete when -fading out. - -Sync syncs ie aligns the phase of the selected binaural drone pairs. DIN -first fades out the pairs, aligns their phase in silence and then restores -volume. ESC to abort sync on fade out or in. - -Recommend keep the Compressor and Delays off. - -Recording: - -CTRL + ENTER - to start/stop sound recording or Click on the Record button -at the bottom of the microtonal-keyboard - -ALT + ENTER - clear existing recording or choose Menu > File > Clear - -Menu > File > Save to save the recording as a .WAV file on the desktop. - -Console: - -TAB : enter/leave command mode UP_ARROW / DOWN_ARROW: scroll up/down SHIFT -+ UP_ARROW / DOWN_ARROW: scroll up/down command history - -In command mode, type help to reveal available commands. Or type help -command_name to get help for a particular command. - -PgUp, PgDn: page up, page down BACKSPACE : delete all text in console ` : -fold/unfold console +DIN Is Noise +Copyright (c) 2006-2022 Jagannathan Sampath . + +Binaural Drones + +Launch with Menu > Instrument > Binaural drones. + +In a binaural drone pair, one drone goes into your left ear +(the L drone) and the other drone goes into your right ear (the R drone). +So, you need to hear this on headphones :) The L drone and the R +drone each vibrates at its own pitch (in Hz). You hear the difference +between the pitches (the Separation) as a beat at that pitch. eg., if the +difference is 1 Hz, you hear a beat every second. These beats are called +binaural beats. + +DIN can make binaural drone pairs starting at a pitch (default @ 100 Hz) +with any separation between the drones of a pair, default @ 1 Hz. + +DIN can also make binaural drone pairs at the notes of the scale starting +at the key note. The key note can be the starting pitch or the pitch or +note you set on the Settings page. You can also set the other notes of the +scale there. + + Turn on Close Octave to create a binaural pair on the octave note too. + + Turn on Resize separation to vary the separation between L and R drones of + each pair so that their absolute pitch always falls on the notes of the + scale. + +Justification determines the drone that gets the starting pitch. Left sets +it to the L drone, Right sets it to the R drone. eg., for a Starting pitch +100 Hz and Separation 1 Hz and Justification = Left, L drone is @ 100 Hz, R +drone is @ 101 Hz. If Justification = Right, R drone is @ 100 Hz, L drone +is @ 99 Hz. If Justification = Center, the L drone is @ 99.5 Hz and R drone +is @ 100.5 Hz. + +Spacing (in Hz) determines the spacing between two successive binaural +drone pairs, default @ 50 Hz. + +Press 2 or Menu > Editors > Waveform to edit the waveform that drives all +binaural drone pairs. + +Menu > Edit to edit the binaural drones. + +Master volume in % determines the overall loudness of all binaural drone +pairs. 100% is loudest. 0% is silence. > 100% is valid too. Careful :) + +Volume fade time in seconds is the time taken to fade in or out when +creating, destroying, syncing, changing the volume of a drone pair or when +changing the master volume. + +Pitch fade time in seconds is the time taken to change the L drone or the R +drone of any binaural drone pair from one pitch to another. You can see +this when you modulate, flip or change L, R pitches or separation of +selected drone pairs. + +When fading pitch or volume, you can press ESC to abort. Useful when the +fade times are long, also useful when you have unexpectedly reached a more +interesting sound...:) + +DIN lists the binaural drone pairs in a list. Click an element to select +or deselect, hold SHIFT button down and click to select a group, and clear, +invert selection. You can also select based on L, R, Separation Hz or +Volume: Select L, R, Separation or Volume from the options, choose the +operator: >=, <=, =, <> (the range operator) or id (id numbers of drone +pairs listed between the []), enter the value and press ENTER or click on +Select to execute. DIN selects the matching pairs. The range operator +takes two values, the low and high. The id operator takes 3 values +(3rd value is optional and is 1 when not present), the start id, the end id +and the increment. + +You can edit the pitch of the L drone, the R drone, Separation, +Justification and the Volume % of a selected pair in the fields to the +right. When you select more than one pair, the L and R pitch fields accept +relative instead of absolute values ie you change the L and R Hz rather +than set it. + +Flip to swap the pitches of selected drone pairs. ESC to abort. + +Modulate [actually Multiply] the pitches of L and R drone of selected pairs +by an Amount. Press LEFT_ARROW to modulate down, RIGHT_ARROW to modulate +up. ESC to abort. With default Amount @ 2.0, you octave shift when you +modulate the selected pairs :) You can modulate up or down an interval +using the value of DIN's interval variables. eg., $1, $2b, $2, $3b $3, $4, +$5b, $5, $6b, $6, $7b, $7 or $8: eg., type $2b, press ENTER and click +LEFT_ARROW or RIGHT_ARROW to modulate down or up by a semitone :) $1 is 1.0 +and $8 is 2.0 which is the octave shift again :) + +Delete deletes the selected binaural drone pairs. DIN first fades out the +volume of the pairs and then deletes them. ESC to abort delete when +fading out. + +Sync syncs ie aligns the phase of the selected binaural drone pairs. DIN +first fades out the pairs, aligns their phase in silence and then restores +volume. ESC to abort sync on fade out or in. + +Recommend keep the Compressor and Delays off. + +Recording: + +CTRL + ENTER - to start/stop sound recording or Click on the Record button +at the bottom of the microtonal-keyboard + +ALT + ENTER - clear existing recording or choose Menu > File > Clear + +Menu > File > Save to save the recording as a .WAV file on the desktop. + +Console: + +TAB : enter/leave command mode +UP_ARROW / DOWN_ARROW: scroll up/down +SHIFT + UP_ARROW / DOWN_ARROW: scroll up/down command history + +In command mode, type help to reveal available commands. Or type help +command_name to get help for a particular command. + +PgUp, PgDn: page up, page down +BACKSPACE : delete all text in console +` : fold/unfold console diff -Nru din-55/src/factory/binaural-drones-waveform.ed din-56/src/factory/binaural-drones-waveform.ed --- din-55/src/factory/binaural-drones-waveform.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/binaural-drones-waveform.ed 2022-10-24 06:38:43.000000000 +0000 @@ -26,3 +26,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/circler_cos.ed din-56/src/factory/circler_cos.ed --- din-55/src/factory/circler_cos.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/circler_cos.ed 2022-10-24 06:38:43.000000000 +0000 @@ -23,3 +23,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/circler_radius.ed din-56/src/factory/circler_radius.ed --- din-55/src/factory/circler_radius.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/circler_radius.ed 2022-10-24 06:38:43.000000000 +0000 @@ -22,3 +22,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/circler_sin.ed din-56/src/factory/circler_sin.ed --- din-55/src/factory/circler_sin.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/circler_sin.ed 2022-10-24 06:38:43.000000000 +0000 @@ -23,3 +23,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/compressor.ed din-56/src/factory/compressor.ed --- din-55/src/factory/compressor.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/compressor.ed 2022-10-24 06:38:43.000000000 +0000 @@ -21,3 +21,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/decay.ed din-56/src/factory/decay.ed --- din-55/src/factory/decay.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/decay.ed 2022-10-24 06:38:43.000000000 +0000 @@ -22,3 +22,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/delay.ed din-56/src/factory/delay.ed --- din-55/src/factory/delay.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/delay.ed 2022-10-24 06:38:43.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/din_info din-56/src/factory/din_info --- din-55/src/factory/din_info 2022-06-06 20:57:02.000000000 +0000 +++ din-56/src/factory/din_info 2022-12-06 06:31:59.000000000 +0000 @@ -34,8 +34,8 @@ drones-are 0 drone-life-time 3 handle-trail-size 3 10 -v0 6 0 0 1 1 0 0 45 45 1 0 0 1 45 0 0 1 90 0 0 1 1 0 0 1 0 0 0 180 0 0 1 -a0 1 0 0 1 0 0 0 45 45 1 0 0 1 45 0 0 1 90 0 0 1 1 0 0 1 0 0 0 180 0 0 1 +v0 6 0 0 1 1 0 0 45 45 1 0 0 0 45 0 0 1 90 0 0 1 1 0 0 1 0 0 0 180 0 0 1 0 1 0 0 1 1 0 0 1 +a0 1 0 0 1 0 0 0 45 45 1 0 0 0 45 0 0 1 90 0 0 1 1 0 0 1 0 0 0 180 0 0 1 0 1 0 0 1 1 0 0 1 def-vel-accel 0 chuck 1 1 1 anchored 0 diff -Nru din-55/src/factory/d_menu din-56/src/factory/d_menu --- din-55/src/factory/d_menu 2022-09-21 06:36:56.000000000 +0000 +++ din-56/src/factory/d_menu 2022-12-19 17:40:28.000000000 +0000 @@ -1,495 +1,513 @@ -_Keyboard_Keyboard 40 355 -_Microtonal_Keyboard 40 328 -_Mondrian 40 302 -_Binaural_Drones 40 274 -_Waveform 40 355 -_Drone_Waveform 149 355 -_Drone_Modulation 220 301 -_Voice_Modulation 40 301 -_Gater 40 328 -_Waveform 40 355 -_Attack 40 328 -_Decay 40 301 -_MIDI_Velocity 40 274 -_Delays 40 247 -_Octave_Shift 243 247 -_Compressor 119 247 -_Morse_Code 385 247 -_Waveform 40 360 -_Attack 40 335 -_Decay 40 308 -_Waveform 40 355 -_Range_modulation 493 274 -_Range_Width_&_Height 40 274 -_Range_Pitch_&_Volume 263 274 -_Point_Modulation 518 247 -_Noise_Interpolator 40 220 -_Drone_Pendulum 228 220 -_Lifetime_2_Velocity 404 301 -_Exit_DIN_Is_Noise 40 355 --Octave-Shift-Shift 40 358 --left 45 330 --right 74 330 -_BPM 177 337 -_BPM 271 310 -_Volume 42 358 -_Show_anchors 548 32 -_Handle_size 42 251 -_Trail_length 42 277 -_AM_Depth 42 286 -_FM_Depth 42 262 -_AM_BPM 42 238 -_FM_BPM 42 214 -_Instrument 100 391 -_Editors 214 391 -_Drone_Params 502 391 -_File 40 391 --Style-=-loop-loop 99 310 -_Gater 40 310 --AM-style-=-loop-loop 40 166 --FM-style-=-loop-loop 40 190 -_Drone_Tools 372 391 --Add 42 361 -_Move 209 361 -_Delete 133 361 -_Select_all 40 211 -_Invert_selected 159 211 -_Record_a_phrase 40 334 -_Clear_phrase 205 334 -_Phrase_position 40 310 -0x854fe8 201 310 -0x84ab68 40 92 -_Default_to_Selected 195 92 -_Default_to_all 407 92 -_Selected_to_all 567 92 -_Set_key_to_pitch_at_cursor 40 286 -_Show_oscilloscope 40 223 -_Height 69 197 -_Samples 54 172 -_Tap_BPM 40 262 -0x857db0 51 218 --90.000 133 262 -_AM 163 238 -_FM 200 238 -_Gater 100 238 -_Octave_Shift 243 238 -_Auto_reset 100 214 -_Tools 302 391 --left 40 352 --right 70 353 --up 55 366 --down 55 338 -_Close 245 69 -_X 208 349 -_Y 229 349 -_Both 251 349 -_None 304 349 -_Snap? 148 349 -0x7fbfb8 91 352 -0x7fc208 120 352 -_Insert_vertex 40 318 -_Delete_vertex 182 318 -_Fold_tangents 40 272 -_Unfold_tangents 189 272 -0x8494e8 347 272 -0x849a88 44 250 -0x84a028 328 250 -_(Selection_only) 535 272 -_Undo 40 295 -_Redo 96 295 -_Copy 156 295 -_Paste 212 295 -_Draw_&_replace_curve 332 318 -_Library 40 160 --left 114 164 --right 130 164 -_Curve_name 40 225 -_Add 160 160 -_Replace 209 160 -_Delete 297 160 -_Mouse_capture 40 138 -_Start 190 138 -_Assign 263 138 -_Label_vertices 211 47 -_Show_waveform 40 26 -_Hz 88 4 -_Pick_curve 365 349 -_Curve_roughness 40 203 -_Cycles 48 -18 --Waveform-is-classical 40 181 -_RPM 40 112 -_Stop 52 90 -_Draw_curve_only 40 47 --Saved-04:46-of-04:46 40 328 -_Clear 40 305 -0x7fb5c0 40 280 --Overwrite 109 305 -_Select_attractees 517 211 -_Select_attractors 326 211 -_Orbit 243 337 -_Show_velocity 41 32 -_Show_acceleration 197 32 -_Velocity 55 277 -_Acceleration 55 -65 -_Show_Gravity 397 32 -_Move_under_Gravity 305 337 -_Rotate_velocity 41 -40 -_Drones_per_minute 42 253 -_Launch 40 337 -_Stop_launch 116 337 -0x851be8 40 162 -_Rows 77 140 -_Columns 198 140 -_Track 390 337 -_Select_tracked 218 188 -_Bounces 43 -398 -_Speed_% 43 -422 -_Add 40 358 -_Move_balls 197 358 -_Delete_selected_balls 325 334 -_Delete_all_balls 554 334 -_Select_all_balls 40 309 -_Invert_ball_selection 224 309 -_Select_balls_in_box 447 309 -_Split_box_horizontally 40 93 -_Split_box_vertically 40 70 -_Delete_box 40 -2 -_Min_Voices 40 302 -_Ball_attack_time 43 275 -_Ball_decay_time 43 251 -_Ball_speed 43 229 -_Freeze_balls 316 358 -_Thaw_balls 453 358 --left 40 344 --right 71 344 --up 56 360 --down 56 329 -0x7fbe90 94 342 -0x7fc0e0 122 342 -_Turn_Off_UI 40 252 -_Set_targets 461 337 -_Clear_targets 585 337 -_Lifetime 42 206 -_Orbit_insert_time 42 -90 -_Clear_modulations 447 118 -_Modulate_balls_up 257 118 -_Modulate_balls_down 40 118 -_Create 302 391 -_Master_volume_(%) 40 355 -_Separation_(Hz) 42 328 -_Create_binaural_drones_on_the_notes_of_the_scale 40 193 -_Create_binaural_drones_using_parameters_above 40 220 -_Start_Pitch_(Hz) 40 354 -_Number_of_Pairs 42 274 -_Spacing_(Hz) 40 247 -_Close_octave 54 139 -_Volume_fade_time_(secs) 40 330 -_Ball_direction 60 204 -_Ball_trail_length 43 179 -_Note_polygon_points 43 79 -_Note_polygon_radius 43 53 -_Auto-change_ball_direction_clockwise 40 166 -_Stop_auto-changing_ball_direction 40 142 -_Auto-change_ball_direction_anti-clockwise 40 190 -_Flip_ball_direction 40 213 -_Randomize_box_color 353 -2 --Justification-=-Center 40 301 -_Resize_separation 53 112 --Key-note-is-start-pitch 55 166 -_Add_/_Remove_slits 40 286 -_Select_wreckers 40 238 -_Select_healers 220 238 -_Healers_<>_Wreckers 381 238 -_Toggle_wreckers 40 262 -_Toggle_healers 217 262 -_Toggle_bouncers 376 262 -_Slit_size 43 129 -_Remove_slits_on_edge 243 286 -_Toggle_slit_animation 457 286 -_Auto_adjust_voices 228 302 -_Ball_volume 43 155 -_Draw_boxes 40 301 -_Fill_boxes 157 301 -_Draw_notes 40 279 -_Label_notes 157 279 --bouncer 80 358 -_into_2_boxes 268 94 -_into_2_boxes 248 70 -_N 55 21 -_Make_note_grid 40 46 -_Make_N_x_N_grid 198 46 -_Delete_all_boxes 167 -2 --Voice 302 391 -_Misc 724 391 -_Select_launchers 40 188 -_seloncre 321 279 -_Freeze 603 361 -_Thaw 679 361 -_AM_Depth 40 276 -_FM_Depth 40 254 -_AM_BPM 40 231 -_FM_BPM 40 207 -_Scale 265 361 -_Rotate 331 361 -_Selection_target_=_balls 40 334 -_Slit_open/close_time 43 104 -_Mark_segments 368 47 -_Auto_split_box 40 356 -_Auto_delete_box 40 216 -_Every 49 334 -_Every 49 192 --Pick-a-random-box 68 309 --Split-at-notes 68 287 --Split-horizontally-&-vertically 68 262 --Pick-a-random-box 67 168 -_Min_split_size 88 238 -_Speed 40 228 -_Turn 40 337 -_Teleport 40 96 -_Every 60 316 -_Clockwise_Max 60 293 -_Anti-clockwise_Max 60 269 -_Every 60 206 -_Brake 60 184 -_Accelerate 60 162 -_Max_speed 63 118 -_Every 60 74 -_Max_distance 60 52 -_Position 157 256 -_Heading 253 256 -_Trails 337 256 -_Draw_ball: 40 256 -_Sync 77 250 -_Sync 77 140 -_Every 60 8 -_Max_clones 60 -14 -_Offset 60 -36 -_Max_balls 60 -58 -_Clone 40 30 -_Clone_can_clone_too 516 8 --Click-arrow-to-load-ball 40 355 -_Tools 302 391 -_Params 374 391 -_Ball_Ops 456 391 -_Box_Ops 558 391 -_Misc 652 391 -_Transform 40 -80 -_Every 60 -102 --bouncer-becomes-wrecker 63 -124 --healer-becomes-bouncer 63 -168 --wrecker-becomes-healer 63 -146 -_Label_pitch_and_volume 287 279 --il_binaural_drones 40 274 -_Edit 382 391 -_All 40 274 -_None 83 274 -_Invert 142 274 -_Delete 540 274 -_Sync 540 245 -_Pitch_fade_time_(secs) 366 330 -_Amount 190 300 --right 156 301 --left 127 301 -_Modulate 40 300 -_Select 219 274 --L-L 285 274 -_>= 334 274 -0x7fbd40 401 275 --dL-(Hz)-(Hz) 540 166 --dR-(Hz)-(Hz) 540 139 -_Separation_(Hz) 540 112 -_Volume_(%) 540 193 --Justification-=-Center 541 85 -_Flip 540 220 -_All 299 262 -_Left 130 287 -_Right 185 287 -_Both 247 287 -_Snap_left 40 336 -_Snap_right 245 336 -0x851648 42 -445 -_Modulate 40 214 -_Range 40 360 -_Width 63 189 -_BPM 77 165 -_Mark 208 360 -_Modulation? 40 237 -_Pause/Resume 170 237 -_Start 315 237 -_Stop 385 237 -_Toggle 440 237 -_Get 164 360 -0x850568 458 335 -_Height 53 141 -_BPM 79 117 -_Ranges 642 391 -_Adjust? 40 287 -_Adjust_Height? 40 262 -_Selected 197 262 -_Depth 54 132 -_Width 54 157 -_Drone_Arrow 41 227 -_Default_width 40 69 -_Default_height 40 44 -_Left 228 312 -_Right 287 312 -0x84b6a8 410 312 -_Modulation_affects_velocity 41 236 -_Set 414 237 -_Unset 456 237 -_Toggle 342 237 -_Browse_drone 378 188 -0x852188 216 117 -_Create_drones 77 117 -0x852728 389 117 -0x7fbbf0 572 116 -_Sync 357 140 -_In 77 95 -_Flip 416 140 -_Overlay_instrument 40 70 -_Spacing 76 117 -_BPM 76 93 -0x850b08 56 140 -_Swap 280 295 -_Overlay_pitch_distribution 40 190 -_Overlay_volume_distributon 314 190 -_Level_size 40 166 -0x84b108 40 312 -_Both 353 312 -_Drone_Master_Volume 40 360 -_Drone_Pendulum's_parameters? 76 69 -_Drones_Per_Pendulum 98 25 -_Apply_to 98 47 -_AM_BPM 199 47 -_FM_BPM 286 47 -_Set_to_Rows 120 2 -_Set_to_Columns 249 2 -0x8510a8 43 279 -_Ball_triggers_note_<>_Ball_triggers_noise 40 -27 --with-center-fixed 131 214 -_Draw_mesh_outline 41 8 -_Steps 244 262 -0x855218 41 107 -0x855448 189 107 -0x855678 336 107 -0x8558a8 41 88 -0x855ad8 189 88 -0x855d08 336 88 -_Wrap 336 262 -_main 40 383 -_dp0 40 303 -_Modulation 40 309 -_Motion 231 309 -_Visual 156 309 -_Connect 156 262 -_Disconnect 40 262 --Random 478 107 -_dp1 40 331 -_Abort 112 337 -_Connection_stiffness 44 60 -_Reset 178 227 --Mute 40 311 --Unmute 97 311 --Mute/Unmute-Time 469 311 --Drone-volume 110 337 --Drone->-Noise 182 311 --Noise->-Drone 326 311 --Find-center 406 361 -- 40 160 -0x8740d8 159 160 -- 52 137 -- 118 137 -- 173 136 -- 69 11 -- 176 11 -0x874c70 52 88 --Defaults 377 309 --Wand-distance 41 13 --Drones-are-immortal 43 234 --Min-Rise-time 42 208 --Min-Fall-time 42 185 --Life-time 42 162 --Mortalize 40 287 --Reincarnate 150 287 --Immortalize 277 287 --Horizontal 254 103 --Vertical 351 103 --Velocity 461 103 --Acceleration 559 103 --Horizontal 254 80 --Vertical 351 80 --Velocity 461 80 --Acceleration 559 80 --Set-AM-direction-to:-to: 40 103 --Set-FM-direction-to:-to: 40 80 --Chuck 308 309 --Chuck 532 361 --Toggle 43 252 --Flip 41 278 --Speed 91 278 --Length 43 228 --Angle-per-frame 43 176 --Trail-length 43 203 --Handle-size 42 64 --Set 40 181 -0x881718 80 181 --- 249 181 --Zero 351 181 --Vertical 445 181 --Horizontal 557 181 --Velocity 650 181 --Acceleration 299 181 --Auto-flip 69 -15 --Every 362 -16 --Set 175 -16 --Unset 217 -16 --Toggle 280 -16 --Velocity 43 -12 --Magnitude 98 -58 --Vertical 250 -60 --Vertical 204 -59 --Horizontal 98 -81 --Vertical 81 -35 --Mouse 99 -104 --Randomize 99 -127 --Draw-chuck-outline 40 149 --Auto-reset-trails 40 125 --Drone-is-anchored 43 257 --Trail-size 42 41 --Position 54 182 --Cap 71 204 --Decap 122 204 --Degrees 52 62 --Ticks-per-Second 52 37 --Movement? 52 113 --Smooth 161 113 --Ticked 240 113 --Drone-Arrow 41 -473 --Head 161 -496 --Shoulder-Width 161 -543 --Shoulder-Position 161 -520 --Cap 178 -564 -0x882710 41 -580 --Track 388 262 --Auto-rotate 98 -172 --Smooth 115 -216 --Clockwise 115 -195 --RPM 115 -238 --Degrees-per-Second 115 -261 --Ticks-per-Second 115 -308 --Auto-flip 98 -349 --Every 135 -373 --v0 40 283 --a0 41 -62 --Sync 116 -148 --Generations 42 91 --Drones-Per-Minute 42 138 --Reset-every-tick 144 -284 --Reset-every-tick 144 -328 --Drones-per-launch 42 115 --Drones-per-launch 42 230 --AM-Position 40 153 --FM-Position 40 128 --Set-AM-BPM-to-FM-BPM 40 180 --Set-FM-BPM-to-AM-BPM 272 180 -Opacity 58 147 +_Keyboard_Keyboard 40 415 +_Microtonal_Keyboard 40 390 +_Mondrian 40 365 +_Binaural_Drones 40 341 +_Waveform 40 415 +_Drone_Waveform 149 415 +_Drone_Modulation 220 361 +_Voice_Modulation 40 361 +_Gater 40 388 +_Waveform 40 415 +_Attack 40 388 +_Decay 40 361 +_MIDI_Velocity 40 334 +_Delays 40 307 +_Octave_Shift 243 307 +_Compressor 119 307 +_Morse_Code 385 307 +_Waveform 40 420 +_Attack 40 395 +_Decay 40 368 +_Waveform 40 415 +_Range_modulation 493 334 +_Range_Width_&_Height 40 334 +_Range_Pitch_&_Volume 263 334 +_Point_Modulation 518 307 +_Noise_Interpolator 40 280 +_Drone_Pendulum 228 280 +_Lifetime_2_Velocity 404 361 +_Exit_DIN_Is_Noise 40 415 +-Octave-Shift-Shift 40 418 +-left 45 390 +-right 74 390 +_BPM 177 397 +_BPM 271 370 +_Volume 42 418 +_Show_anchors 548 103 +_Handle_size 42 313 +_Trail_length 42 337 +_AM_Depth 42 346 +_FM_Depth 42 322 +_AM_BPM 42 298 +_FM_BPM 42 274 +_Instrument 100 451 +_Editors 214 451 +_Drone_Params 502 451 +_File 40 451 +-Style-=-loop-loop 99 370 +_Gater 40 370 +-AM-style-=-loop-loop 40 226 +-FM-style-=-loop-loop 40 250 +_Drone_Tools 372 451 +-Add 42 421 +_Move 214 421 +_Delete 139 421 +_Select_all 40 271 +_Invert_selected 159 271 +_Record_a_phrase 40 394 +_Clear_phrase 205 394 +_Phrase_position 40 370 +0x854fe8 201 370 +0x84ab68 40 152 +_Default_to_Selected 195 152 +_Default_to_all 407 152 +_Selected_to_all 567 152 +_Set_key_to_pitch_at_cursor 40 346 +_Show_oscilloscope 40 283 +_Height 69 257 +_Samples 54 232 +_Tap_BPM 40 322 +0x857db0 51 278 +-90.000 133 322 +_AM 163 298 +_FM 200 298 +_Gater 100 298 +_Octave_Shift 243 298 +_Auto_reset 100 274 +_Tools 302 451 +-left 40 412 +-right 70 413 +-up 55 426 +-down 55 398 +_Close 125 230 +_X 208 409 +_Y 229 409 +_Both 251 409 +_None 304 409 +_Snap? 148 409 +0x7fbfb8 91 412 +0x7fc208 120 412 +_Insert_vertex 40 378 +_Delete_vertex 182 378 +_Fold_tangents 40 332 +_Unfold_tangents 189 332 +0x8494e8 347 332 +0x849a88 44 310 +0x84a028 328 310 +_(Selection_only) 539 332 +_Undo 40 355 +_Redo 96 355 +_Copy 156 355 +_Paste 212 355 +_Draw_&_replace_curve 332 378 +_Library 40 220 +-left 114 224 +-right 130 224 +_Curve_name 40 285 +_Add 160 220 +_Replace 209 220 +_Delete 297 220 +_Mouse_capture 40 198 +_Start 190 198 +_Assign 263 198 +_Label_vertices 211 52 +_Show_waveform 40 31 +_Hz 88 9 +_Pick_curve 365 409 +_Curve_roughness 40 263 +_Cycles 48 -13 +-Waveform-is-classical 40 241 +_RPM 40 172 +_Stop 57 150 +_Draw_curve_only 40 52 +-Saved-04:46-of-04:46 40 388 +_Clear 40 365 +0x7fb5c0 40 340 +-Overwrite 109 365 +_Select_attractees 517 271 +_Select_attractors 326 271 +_Orbit 400 397 +_Show_velocity 41 103 +_Show_acceleration 197 103 +_Velocity 55 337 +_Acceleration 55 -140 +_Show_Gravity 397 103 +_Move_under_Gravity 242 397 +_Rotate_velocity 42 -116 +_Drones_per_minute 42 312 +_Launch 40 397 +_Stop_launch 116 397 +0x851be8 40 222 +_Rows 77 200 +_Columns 198 200 +_Track 460 397 +_Select_tracked 218 248 +_Bounces 43 -415 +_Speed_% 43 -436 +_Add 40 418 +_Move_balls 203 418 +_Delete_selected_balls 325 394 +_Delete_all_balls 554 394 +_Select_all_balls 40 369 +_Invert_ball_selection 224 369 +_Select_balls_in_box 447 369 +_Split_box_horizontally 40 153 +_Split_box_vertically 40 130 +_Delete_box 40 58 +_Min_Voices 40 362 +_Ball_attack_time 43 335 +_Ball_decay_time 43 311 +_Ball_speed 43 289 +_Freeze_balls 321 418 +_Thaw_balls 453 418 +-left 40 404 +-right 71 404 +-up 56 420 +-down 56 389 +0x7fbe90 94 402 +0x7fc0e0 122 402 +_Turn_Off_UI 40 312 +_Set_targets 526 397 +_Clear_targets 648 397 +_Lifetime 42 264 +_Orbit_insert_time 42 -165 +_Clear_modulations 447 178 +_Modulate_balls_up 257 178 +_Modulate_balls_down 40 178 +_Create 302 451 +_Master_volume_(%) 40 415 +_Separation_(Hz) 42 388 +_Create_binaural_drones_on_the_notes_of_the_scale 40 253 +_Create_binaural_drones_using_parameters_above 40 280 +_Start_Pitch_(Hz) 40 414 +_Number_of_Pairs 42 334 +_Spacing_(Hz) 40 307 +_Close_octave 54 199 +_Volume_fade_time_(secs) 40 390 +_Ball_direction 60 264 +_Ball_trail_length 43 239 +_Note_polygon_points 43 139 +_Note_polygon_radius 43 113 +_Auto-change_ball_direction_clockwise 40 226 +_Stop_auto-changing_ball_direction 40 202 +_Auto-change_ball_direction_anti-clockwise 40 250 +_Flip_ball_direction 40 273 +_Randomize_box_color 353 58 +-Justification-=-Center 40 361 +_Resize_separation 53 172 +-Key-note-is-start-pitch 55 226 +_Add_/_Remove_slits 40 346 +_Select_wreckers 40 298 +_Select_healers 220 298 +_Healers_<>_Wreckers 381 298 +_Toggle_wreckers 40 322 +_Toggle_healers 217 322 +_Toggle_bouncers 376 322 +_Slit_size 43 189 +_Remove_slits_on_edge 243 346 +_Toggle_slit_animation 457 346 +_Auto_adjust_voices 228 362 +_Ball_volume 43 215 +_Draw_boxes 40 361 +_Fill_boxes 157 361 +_Draw_notes 40 339 +_Label_notes 157 339 +-healer 80 418 +_into_2_boxes 268 154 +_into_2_boxes 248 130 +_N 55 81 +_Make_note_grid 40 106 +_Make_N_x_N_grid 198 106 +_Delete_all_boxes 167 58 +-Voice 302 451 +_Misc 724 451 +_Select_launchers 40 248 +_seloncre 321 339 +_Freeze 577 421 +_Thaw 646 421 +_AM_Depth 40 336 +_FM_Depth 40 314 +_AM_BPM 40 291 +_FM_BPM 40 267 +_Scale 310 421 +_Rotate 377 421 +_Selection_target_=_balls 40 394 +_Slit_open/close_time 43 164 +_Mark_segments 368 52 +_Auto_split_box 40 416 +_Auto_delete_box 40 276 +_Every 49 394 +_Every 49 252 +-Pick-a-random-box 68 369 +-Split-at-notes 68 347 +-Split-horizontally-&-vertically 68 322 +-Pick-a-random-box 67 228 +_Min_split_size 88 298 +_Speed 40 288 +_Turn 40 397 +_Teleport 40 156 +_Every 60 376 +_Clockwise_Max 60 353 +_Anti-clockwise_Max 60 329 +_Every 60 266 +_Brake 60 244 +_Accelerate 60 222 +_Max_speed 63 178 +_Every 60 134 +_Max_distance 60 112 +_Position 157 316 +_Heading 253 316 +_Trails 337 316 +_Draw_ball: 40 316 +_Sync 77 310 +_Sync 77 200 +_Every 60 68 +_Max_clones 60 46 +_Offset 60 24 +_Max_balls 60 2 +_Clone 40 90 +_Clone_can_clone_too 516 68 +- 40 415 +_Tools 302 451 +_Params 374 451 +_Ball_Ops 456 451 +_Box_Ops 558 451 +_Misc 652 451 +_Transform 40 -20 +_Every 60 -42 +-bouncer-becomes-wrecker 63 -64 +-healer-becomes-bouncer 63 -108 +-wrecker-becomes-healer 63 -86 +_Label_pitch_and_volume 287 339 +-il_binaural_drones 40 334 +_Edit 382 451 +_All 40 334 +_None 83 334 +_Invert 142 334 +_Delete 540 334 +_Sync 540 305 +_Pitch_fade_time_(secs) 366 390 +_Amount 190 360 +-right 156 361 +-left 127 361 +_Modulate 40 360 +_Select 219 334 +-L-L 285 334 +_>= 338 334 +0x7fbd40 409 335 +-dL-(Hz)-(Hz) 540 226 +-dR-(Hz)-(Hz) 540 199 +_Separation_(Hz) 540 172 +_Volume_(%) 540 253 +-Justification-=-Center 541 145 +_Flip 540 280 +_All 299 322 +_Left 130 347 +_Right 185 347 +_Both 247 347 +_Snap_left 40 396 +_Snap_right 245 396 +0x851648 42 -458 +_Modulate 40 274 +_Range 40 420 +_Width 63 249 +_BPM 77 225 +_Mark 208 420 +_Modulation? 40 297 +_Pause/Resume 170 297 +_Start 315 297 +_Stop 385 297 +_Toggle 440 297 +_Get 164 420 +0x850568 458 395 +_Height 53 201 +_BPM 79 177 +_Ranges 642 451 +_Adjust? 40 347 +_Adjust_Height? 40 322 +_Selected 197 322 +_Depth 54 200 +_Width 54 224 +_Drone_Arrow 41 291 +_Default_width 40 129 +_Default_height 40 104 +_Left 228 372 +_Right 287 372 +0x84b6a8 410 372 +_Modulation_affects_velocity 41 296 +_Set 418 297 +_Unset 460 297 +_Toggle 346 297 +_Browse_drone 378 248 +0x852188 216 177 +_Create_drones 77 177 +0x852728 389 177 +0x7fbbf0 576 176 +_Sync 357 200 +_In 77 155 +_Flip 416 200 +_Overlay_instrument 40 75 +_Spacing 76 177 +_BPM 76 153 +0x850b08 56 200 +_Swap 280 355 +_Overlay_pitch_distribution 40 250 +_Overlay_volume_distributon 314 250 +_Level_size 40 226 +0x84b108 40 372 +_Both 353 372 +_Drone_Master_Volume 40 420 +_Drone_Pendulum's_parameters? 76 129 +_Drones_Per_Pendulum 98 85 +_Apply_to 98 107 +_AM_BPM 199 107 +_FM_BPM 286 107 +_Set_to_Rows 120 62 +_Set_to_Columns 249 62 +0x8510a8 43 339 +_Ball_triggers_note_<>_Ball_triggers_noise 40 33 +-with-center-fixed 131 274 +_Draw_mesh_outline 41 79 +_Steps 244 322 +0x855218 41 175 +0x855448 189 175 +0x855678 336 175 +0x8558a8 41 156 +0x855ad8 189 156 +0x855d08 336 156 +_Wrap 336 322 +_main 40 443 +_dp0 40 363 +_Modulation 40 369 +_Motion 231 369 +_Visual 156 369 +_Connect 156 322 +_Disconnect 40 322 +-Random 478 175 +_dp1 40 391 +_Abort 112 397 +_Connection_stiffness 44 128 +_Reset 178 291 +-Mute 40 371 +-Unmute 97 371 +-Mute/Unmute-Time 469 371 +-Drone-volume 110 397 +-Drone->-Noise 182 371 +-Noise->-Drone 326 371 +-Find-center 454 421 +- 40 217 +0x8740d8 159 217 +- 52 195 +- 118 195 +- 173 194 +- 71 128 +- 178 127 +0x874c70 54 103 +-Defaults 377 369 +-Wand-distance 41 73 +-Drones-are-immortal 43 294 +-Min-Rise-time 42 268 +-Min-Fall-time 42 245 +-Life-time 42 222 +-Mortalize 40 347 +-Reincarnate 150 347 +-Immortalize 277 347 +-Horizontal 253 166 +-Vertical 350 166 +-Velocity 460 166 +-Acceleration 558 166 +-Horizontal 252 142 +-Vertical 349 142 +-Velocity 459 142 +-Acceleration 557 142 +-Set-AM-direction-to:-to: 40 166 +-Set-FM-direction-to:-to: 40 142 +-Chuck 308 369 +-Chuck 331 397 +-Toggle 43 313 +-Flip 41 338 +-Speed 91 338 +-Length 43 290 +-Angle-per-frame 43 242 +-Trail-length 43 267 +-Handle-size 42 124 +-Set 40 240 +0x881718 80 240 +-- 249 240 +-Zero 351 240 +-Vertical 445 240 +-Horizontal 557 240 +-Velocity 650 240 +-Acceleration 299 240 +-Auto-flip 71 33 +-Every 83 8 +-Set 174 32 +-Unset 221 32 +-Toggle 286 32 +-Velocity 43 48 +-Magnitude 98 2 +-Vertical 250 0 +-Vertical 204 1 +-Horizontal 98 -21 +-Vertical 81 25 +-Mouse 99 -44 +-Randomize 99 -67 +-Draw-chuck-outline 40 216 +-Auto-reset-trails 40 192 +-Drone-is-anchored 43 317 +-Trail-size 42 101 +-Position 54 247 +-Cap 71 271 +-Decap 122 271 +-Degrees 54 80 +-Ticks-per-Second 54 55 +-Movement? 52 171 +-Smooth 70 150 +-Ticked 149 150 +-Drone-Arrow 41 -486 +-Head 161 -509 +-Shoulder-Width 161 -556 +-Shoulder-Position 161 -533 +-Cap 178 -577 +0x882710 41 -593 +-Track 388 322 +-Auto-rotate 98 -112 +-Smooth 115 -156 +-Clockwise 115 -135 +-RPM 115 -178 +-Degrees-per-Second 115 -201 +-Ticks-per-Second 115 -248 +-Auto-flip 115 -292 +-Every 125 -316 +-v0 40 343 +-a0 40 -136 +-Sync 116 -88 +-Generations 42 151 +-Drones-Per-Minute 42 198 +-Reset-every-tick 144 -224 +-Reset-every-tick 144 -268 +-Drones-per-launch 42 175 +-Drones-per-launch 42 289 +-AM-Position 40 215 +-FM-Position 40 190 +-Set-AM-BPM-to-FM-BPM 40 241 +-Set-FM-BPM-to-AM-BPM 272 241 +Opacity 58 207 +fliprot 374 451 +-Flip 112 149 +-Autoflip 57 125 +0x839878 57 102 +a 162 125 +-Auto-pause 115 -339 +-Every 127 -361 +-For 127 -385 +- 71 -16 +-Set 191 -16 +-Unset 239 -16 +-Toggle 304 -16 +-Every 83 -39 +-For 83 -63 +-Randomize-Auto-flip-/-Every 71 -87 +-Set 401 -87 +-Unset 448 -87 +-Toggle 512 -87 diff -Nru din-55/src/factory/d_parameters din-56/src/factory/d_parameters --- din-55/src/factory/d_parameters 2020-05-22 17:21:34.000000000 +0000 +++ din-56/src/factory/d_parameters 2022-12-22 03:43:50.000000000 +0000 @@ -8,7 +8,7 @@ _Waveform 471 395 0x869648 482 292 _left 568 398 -_right 582 398 +_right 584 398 _Octave_Shift 471 268 _right 529 238 _left 499 238 diff -Nru din-55/src/factory/d_plugin_browser din-56/src/factory/d_plugin_browser --- din-55/src/factory/d_plugin_browser 2020-06-11 04:11:25.000000000 +0000 +++ din-56/src/factory/d_plugin_browser 2022-11-02 16:02:01.000000000 +0000 @@ -1,4 +1,4 @@ _Sine_Mixer 539 535 -_down 509 539 -fb_items 523 541 +_down 505 539 +fb_items 523 542 items_list 523 535 diff -Nru din-55/src/factory/d_point_modulator din-56/src/factory/d_point_modulator --- din-55/src/factory/d_point_modulator 2019-09-12 15:12:21.000000000 +0000 +++ din-56/src/factory/d_point_modulator 2022-11-02 16:04:45.000000000 +0000 @@ -6,7 +6,7 @@ _right 64 136 0x5ea018 90 136 0x5ea318 123 135 -_right 47 183 +_right 46 184 _X_depth 64 109 _X_BPM 78 86 _Y_depth 64 63 diff -Nru din-55/src/factory/drone.ed din-56/src/factory/drone.ed --- din-55/src/factory/drone.ed 2022-09-12 03:20:57.000000000 +0000 +++ din-56/src/factory/drone.ed 2022-10-24 06:38:43.000000000 +0000 @@ -26,3 +26,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/drone-modulation.ed din-56/src/factory/drone-modulation.ed --- din-55/src/factory/drone-modulation.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/drone-modulation.ed 2022-10-24 06:38:43.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/drone-pend.ed din-56/src/factory/drone-pend.ed --- din-55/src/factory/drone-pend.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/drone-pend.ed 2022-10-24 06:38:43.000000000 +0000 @@ -22,3 +22,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/font.ed din-56/src/factory/font.ed --- din-55/src/factory/font.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/font.ed 2022-10-24 06:38:43.000000000 +0000 @@ -18,3 +18,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/gater.ed din-56/src/factory/gater.ed --- din-55/src/factory/gater.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/gater.ed 2022-10-24 06:38:43.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/gravmod.ed din-56/src/factory/gravmod.ed --- din-55/src/factory/gravmod.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/gravmod.ed 2022-10-24 06:38:43.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/keyboard-keyboard.hlp din-56/src/factory/keyboard-keyboard.hlp --- din-55/src/factory/keyboard-keyboard.hlp 2022-06-03 06:53:25.000000000 +0000 +++ din-56/src/factory/keyboard-keyboard.hlp 2022-11-03 12:43:43.000000000 +0000 @@ -7,22 +7,22 @@ Notes of the scale are mapped to keys on the computer keyboard. -Compass is 3 octaves. +Range is 3 octaves. 1st octave: t, r, e, w, q, a, s 2nd octave: d, f, g, h, j, k, l 3rd octave: ;, ', ], [, p, o, i, u -The keys assigned depend on the notes in the scale. +Press the keys above to hear notes of the scale. The keys +assigned depend on the notes in the scale. z: shift an octave down x: shift an octave up -SHIFT + ESC to abort active octave shift -or click Abort on the octave shift widget. - -!Careful! You could end up at an 'inbetween note' as your key note :) -To return, goto Settings screen to set the key note to a standard note. +SHIFT + ESC to abort active octave shift or click Abort on +the octave shift widget. You may end up at an 'inbetween +note' as your key note. To return, goto Settings screen +to set the key note to a standard note. F11 & F12 : decrease/increase octave shift bpm Or set BPM using the Octave Shift widget. @@ -37,13 +37,6 @@ Press 2 to edit the waveform or Menu > Editors > Waveform -Delay: - - Click on the Delay button to toggle stereo delay lines. - - Use the Delay editor (press 6 or Menu > Editors > Delays) to change - feedback & volume curves. - Mouse driven pitch bend: Dotted vertical line marks the mouse position of the last triggered note. @@ -59,7 +52,7 @@ If Show nearby notes is ON, mouse move only bends the last triggered note. Move your mouse to the nearby note to bend to that note. - Press SPACE to stop mouse driven pitch bend. You will get it back when you + Press SPACE to stop mouse driven pitch bend. It will come back when you trigger a new note. MIDI: @@ -74,6 +67,31 @@ Edit MIDI velocity curve (press 5 or Menu > Editors > Velocity) +Parameters: + + Edit Voices, Attack time, Decay time and Hz/pixel using the Spinners. + + Voices is number of simultaneous voices (= keys you can press) each + sounding at its maximum volume guaranteed to sound correct (= not + distort) + + Attack time is the attack time in seconds for a voice. + + Decay time is the decay time in seconds for a voice. + + Hz/pixel is the amount in hz the pitch of a note will bend for + every pixel you move beyond the dotted line with your mouse. + + Use the Octave Shift widget to influence octave shift over bpm. + + Click left arrow to shift an octave down. + Click right arrow to shift an octave up. + Change BPM to control speed of octave shift. + Click Abort to abort octave shift. + + Choose if keys trigger notes or noise + Or press ENTER to toggle + Instrument: 1 : switch to another instrument or choose from Menu > Instrument @@ -91,21 +109,12 @@ Set sustain (marked by a blue triangle) on the attack editor. -Parameters: - - Edit Voices, Attack time, Decay time and Hz/pixel using the Spinners. - - Hz/pixel is the amount in hz the pitch of a note will bend for - every pixel you move beyond the dotted line with your mouse. +Delay: - Use the Octave Shift widget to influence octave shift over bpm. - Click left arrow to shift an octave down. - Click right arrow to shift an octave up. - Change BPM to control speed of octave shift. - Click Abort to abort octave shift. + Click on the Delay button to toggle stereo delay lines. - Choose if keys trigger notes or noise - Or press ENTER to toggle + Use the Delay editor (press 6 or Menu > Editors > Delays) to change + feedback & volume curves. Recording: @@ -125,4 +134,4 @@ In command mode, type help to reveal available commands. Or type help command_name to get help for a particular command. Please note, -command mode is for developer use and remains unsupported. +command mode is unsupported and for developer use. diff -Nru din-55/src/factory/keyboard-keyboard-waveform.ed din-56/src/factory/keyboard-keyboard-waveform.ed --- din-55/src/factory/keyboard-keyboard-waveform.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/keyboard-keyboard-waveform.ed 2022-10-24 06:38:43.000000000 +0000 @@ -26,3 +26,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/microtonal-keyboard-waveform.ed din-56/src/factory/microtonal-keyboard-waveform.ed --- din-55/src/factory/microtonal-keyboard-waveform.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/microtonal-keyboard-waveform.ed 2022-10-24 06:38:43.000000000 +0000 @@ -26,3 +26,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/modulation.ed din-56/src/factory/modulation.ed --- din-55/src/factory/modulation.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/modulation.ed 2022-10-24 06:38:43.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/modv.ed din-56/src/factory/modv.ed --- din-55/src/factory/modv.ed 2022-03-01 06:38:49.000000000 +0000 +++ din-56/src/factory/modv.ed 2022-10-24 06:38:43.000000000 +0000 @@ -22,3 +22,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/mondrian_attack.ed din-56/src/factory/mondrian_attack.ed --- din-55/src/factory/mondrian_attack.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/mondrian_attack.ed 2022-10-24 06:38:43.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/mondrian_decay.ed din-56/src/factory/mondrian_decay.ed --- din-55/src/factory/mondrian_decay.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/mondrian_decay.ed 2022-10-24 06:38:44.000000000 +0000 @@ -22,3 +22,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/mondrian.ed din-56/src/factory/mondrian.ed --- din-55/src/factory/mondrian.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/mondrian.ed 2022-10-24 06:38:44.000000000 +0000 @@ -26,3 +26,4 @@ half_slit_size 20 turn_sync 1 speed_sync 1 +rotatingcurves 0 diff -Nru din-55/src/factory/mondrian.hlp din-56/src/factory/mondrian.hlp --- din-55/src/factory/mondrian.hlp 2021-03-10 05:56:23.000000000 +0000 +++ din-56/src/factory/mondrian.hlp 2022-11-03 16:38:25.000000000 +0000 @@ -1,263 +1,268 @@ -DIN Is Noise - -Copyright (c) 2006-2021 Jagannathan Sampath . - ---------------- -| Mondrian |--| ---------------- - -Inspired by the work of Dutch artist Piet Mondrian. - -Balls bounce in boxes. -Pass thru slits. -Sound on impact. -Pitch from point of impact. -Initial volume from Menu > Parameters > Min Voices - More voices means less volume per voice and vice-versa. - -Horizontal goes from Key note to octave above. -Vertical goes Key note to octave above. - -Set Key note and choose notes of the scale from Settings screen. - -Boxes: - -Create boxes within boxes. - -r - split box under cursor into two new vertical boxes - Menu > Tools > Split box vertically into 2 boxes - -SHIFT + r - split box under cursor into vertical boxes - on the notes of the scale. Or Menu > Tools > - Split box vertically at notes - -CTRL + r - split box under cursor vertically into N boxes. - or Menu > Tools > Split box vertically into N boxes - - Set N from Tools menu. - -f - split box under cursor into two new horizontal boxes - Or Menu > Tools > Split box horizontally into 2 boxes - -SHIFT + f - split box under cursor into horizontal boxes - on the notes of the scale Or Menu > Tools > - Split box horizontally at notes - -CTRL + f - split box under cursor horizontally into N boxes. - or Menu > Tools > Split box horizontally into N boxes - - Set N from tools menu. - -v - delete box under cursor or Menu > Tools > Delete box - -SHIFT + v - delete all boxes in Mondrian - or Menu > Tools > Delete all boxes - -t - make a grid of boxes on the notes of the scale - or Menu > Tools > Make note grid - -SHIFT + t - make an N x N grid of boxes. - or Menu > Tools > Make N x N grid - - Set N from tools menu. - -Click on a box's edge and just move mouse to move the edge. -Click again or ESC to stop. - -Slits: - - Slits let balls of a box pass thru its walls or ceilings into - other boxes. - - You can make or close slits or let wrecking and healing balls - [see below] make and close them automatically. - - You can also animate slits ie open and close them automatically - - / - Click on an edge of a box to slit. If a slit exists already, - it will close. - - Cannot slit if balls will escape the entire playing area. - Cannot slit corners. - - NUM_PAD + - Increase default slit size - NUM_PAD - - Decrease default slit size - Or Menu > Parameters > Change slit size - - To select slits, first change the selection target from balls - to slits and then you can use the same shortcuts you use for - selecting balls. - - g - change selection target from balls to slits and back. - - When slits are the selection target, - - l - select all slits - i - invert slit selection - k - select slits of box under cursor - hold SHIFT or CTRL to toggle selection - n - clear slit selection - - c - delete selected slits - - h - toggle slit animation - - INSERT: decrease slit open+close time of selected slits - DELETE: increase slit open+close time of selected slits - - Or from Menu > Tools or Menu > Parameters. - - To edit an existing slit, edit one of its two lips: - Click once on a lip, just move mouse to move the lip and click - again to stop. - - Also, - - F9 - remove all slits on the edge under cursor - F10 - remove all slits in the box under cursor - F11 - remove all slits in the box with a [selected] ball - F12 - remove all slits - -Balls: - -b - to launch bouncers or Menu > Tools > Add bouncers -SHIFT + b - to launch wreckers or Menu > Tools > Add wreckers -CTRL + b - to launch healers or Menu > Tools > Add healers - -Click, drag and release to launch with an initial velocity - -The shortcuts below affect selected balls, balls in box under cursor -or if cursor is outside all boxes, all the balls in Mondrian. - -[ - decrease speed -] - increase speed - -; - decrease attack time -' - increase attack time -SHIFT + ; - decrease attack time increment -SHIFT + ' - increase attack time increment - -, - decrease decay time -. - increase decay time -SHIFT + , - decrease decay time increment -SHIFT + . - increase decay time increment - -o - rotate direction anti-clockwise -p - rotate direction clockwise -SHIFT + o - decrease angle of rotation -SHIFT + p - increase angle of rotation -CTRL + o - toggle auto rotate direction anti-clockwise -CTRL + p - toggle auto rotate direction clockwise - -j - flip direction of travel - -SPACE - freeze or thaw balls -SHIFT + SPACE - freeze balls -CTRL + SPACE - thaw balls - -- - decrease trail length -= - increase trail length - -Ball types: - - A wrecking ball slits walls and ceilings. Colored red. - - A healing ball closes slits. Colored blue. - - A bouncing ball bounces when its hits wall or ceiling. - Coloring depends on modulation on the ball. See below. - - F3 - turns selected balls into wrecking balls - or wrecking balls into bouncing balls. - - F4 - turns selected balls into healing balls - or healing balls into bouncing balls. - - F5 - turns selected balls into bouncing balls. - - F6 - change all wrecking balls into healing balls - and vice-versa. - - F7 - select all wrecking balls. - - F8 - select all healing balls. - -Ball selection: - -Click once and just move mouse to draw a box to select -some balls. Click again to stop. - -Hold down SHIFT while boxing to add to existing selection -Hold down CTRL while boxing to toggle existing selection - -l - select all balls in all boxes -i - invert current selection -k - select all balls in box under cursor -n - clear selected balls - -to browse selected balls, - -LEFT_ARROW - select previous ball -RIGHT_ARROW - select next ball - -Ball manipulation: - -c - delete selected balls - -m - move selected balls - just move mouse to move balls, click or ESC or m to stop. - -Miscellaneous: - -1 - switch instrument or Menu > Instrument -2 - edit waveform -3 - edit attack curve -4 - edit decay curve - -z - shift instrument or selected balls an octave down -x - shift instrument or selected balls an octave up - balls are gray if they trigger notes without modulation (default) - balls are black if they trigger notes shifted down - balls are white if they trigger notes shifted up - -y - decrease number of voices -u - increase number of voices - -Visual: - -Mondrian draws a regular polygon when & where it triggers a note. - -9 - decrease points in note polygon -0 - increase points in note polygon -SHIFT + 9 - decrease radius of note polygon -SHIFT + 0 - increase radius of note polygon - -F2 - Turn the UI ON or OFF -See Menu > Misc for more visual options. - -w, a, s, d - move viewpoint - -q, e - zoom in and out - -Recording: - -CTRL + ENTER - to start/stop sound recording -or Click on the Record button at the bottom of the microtonal-keyboard - -ALT + ENTER - clear existing recording -or choose Menu > File > Clear - -Menu > File > Save to save the recording as a .WAV file on the desktop. - -Console: - -TAB : enter/leave command mode -UP_ARROW / DOWN_ARROW: scroll up/down -SHIFT + UP_ARROW / DOWN_ARROW: scroll up/down command history - -In command mode, type help to reveal available commands. Or type -help command_name to get help for a particular command. - -PgUp, PgDn: page up, page down -BACKSPACE : delete all text in console -` : fold/unfold console +DIN Is Noise +Copyright (c) 2006-2022 Jagannathan Sampath . + +--------------- +| Mondrian |--| +--------------- + +Inspired by the work of Dutch artist Piet Mondrian. + +Balls bounce in boxes. +Pass thru slits. +Voice on impact. +Pitch from point of impact. + +Initial volume from Menu > Parameters > Min Voices + More voices means less volume per voice and vice-versa. + +Horizontal goes from Key note to octave above. +Vertical goes Key note to octave above. +All notes of the tuning are marked. + +Set Key note and choose notes of the scale from Settings screen. + +Boxes: + +Create boxes within boxes. + +r - split box under cursor into two new vertical boxes + Menu > Tools > Split box vertically into 2 boxes + + SHIFT + r - split box under cursor into vertical boxes + on the notes of the scale. Or Menu > Tools > + Split box vertically at notes + + CTRL + r - split box under cursor vertically into N boxes. + or Menu > Tools > Split box vertically into N boxes + + Set N from Tools menu. + +f - split box under cursor into two new horizontal boxes + Or Menu > Tools > Split box horizontally into 2 boxes + + SHIFT + f - split box under cursor into horizontal boxes + on the notes of the scale Or Menu > Tools > + Split box horizontally at notes + + CTRL + f - split box under cursor horizontally into N boxes. + or Menu > Tools > Split box horizontally into N boxes + + Set N from tools menu. + +v - delete box under cursor or Menu > Tools > Delete box + + SHIFT + v - delete all boxes in Mondrian + or Menu > Tools > Delete all boxes + +t - make a grid of boxes on the notes of the scale + or Menu > Tools > Make note grid + + SHIFT + t - make an N x N grid of boxes. + or Menu > Tools > Make N x N grid + + Set N from tools menu. + +Click on a box's edge and just move mouse to move the edge. +Click again or ESC to stop. + +Balls: + + Ball types: + + A bouncing ball bounces when its hits wall or ceiling. + Coloring depends on modulation on the ball. See below. + + A wrecking ball slits walls and ceilings. Colored red. + + A healing ball closes slits. Colored blue. + + F3 - turns selected balls into wrecking balls + or wrecking balls into bouncing balls. + + F4 - turns selected balls into healing balls + or healing balls into bouncing balls. + + F5 - turns selected balls into bouncing balls. + + F6 - change all wrecking balls into healing balls + and vice-versa. + + F7 - select all wrecking balls. + + F8 - select all healing balls. + + +b - to launch bouncers or Menu > Tools > Add bouncers +SHIFT + b - to launch wreckers or Menu > Tools > Add wreckers +CTRL + b - to launch healers or Menu > Tools > Add healers + +Click, drag and release to launch a ball with an initial velocity + +The shortcuts below affect selected balls, balls in box under cursor +or if cursor is outside all boxes, all the balls in Mondrian. + +[ - decrease speed +] - increase speed + +; - decrease attack time +' - increase attack time +SHIFT + ; - decrease attack time increment +SHIFT + ' - increase attack time increment + +, - decrease decay time +. - increase decay time +SHIFT + , - decrease decay time increment +SHIFT + . - increase decay time increment + +o - rotate direction anti-clockwise +p - rotate direction clockwise +SHIFT + o - decrease angle of rotation +SHIFT + p - increase angle of rotation +CTRL + o - toggle auto rotate direction anti-clockwise +CTRL + p - toggle auto rotate direction clockwise + +j - flip direction of travel + +SPACE - freeze or thaw balls +SHIFT + SPACE - freeze balls +CTRL + SPACE - thaw balls + +- - decrease trail length += - increase trail length + +Ball selection: + +Click once and just move mouse to draw a box to select +some balls. Click again to stop. + +Hold down SHIFT while boxing to add to existing selection +Hold down CTRL while boxing to toggle existing selection + +l - select all balls in all boxes +i - invert current selection +k - select all balls in box under cursor +n - clear selected balls + +to browse selected balls, + +LEFT_ARROW - select previous ball +RIGHT_ARROW - select next ball + +Ball manipulation: + +c - delete selected balls + +m - move selected balls + just move mouse to move balls, click or ESC or m to stop. + +Slits: + + Slits let balls of a box pass thru its walls or ceilings into + other boxes. + + You can make or close slits or let wrecking and healing balls + [see above] make and close them automatically. + + You can also animate slits ie open and close them automatically + + / - Click on an edge of a box to slit. If a slit exists already, + it will close. + + Cannot slit if balls will escape the entire playing area. + Cannot slit corners. + + NUM_PAD + - Increase default slit size + NUM_PAD - - Decrease default slit size + Or Menu > Parameters > Change slit size + + To select slits, first change the selection target from balls + to slits and then you can use the same shortcuts you use for + selecting balls. + + g - change selection target from balls to slits and back. + + When slits are the selection target, + + l - select all slits + i - invert slit selection + k - select slits of box under cursor + hold SHIFT or CTRL to toggle selection + n - clear slit selection + + c - delete selected slits + + h - toggle slit animation + + INSERT: decrease slit open+close time of selected slits + DELETE: increase slit open+close time of selected slits + + Or from Menu > Tools or Menu > Parameters. + + To edit an existing slit, edit one of its two lips: + Click once on a lip, just move mouse to move the lip and click + again to stop. + + Also, + + F9 - remove all slits on the edge under cursor + F10 - remove all slits in the box under cursor + F11 - remove all slits in the box with a [selected] ball + F12 - remove all slits + +Miscellaneous: + +1 - switch instrument or Menu > Instrument + +2 - edit waveform +3 - edit attack curve +4 - edit decay curve + +or choose from Menu > Editors + +z - shift whole instrument or selected balls an octave down +x - shift whole instrument or selected balls an octave up + balls are gray if they trigger notes without modulation (default) + balls are black if they trigger notes shifted down + balls are white if they trigger notes shifted up + +y - decrease number of voices +u - increase number of voices + +Visual: + +Mondrian draws a (regular) polygon (= the note polygon) when & where +it triggers a note. + +9 - decrease points in note polygon +0 - increase points in note polygon +SHIFT + 9 - decrease radius of note polygon +SHIFT + 0 - increase radius of note polygon + +F2 - Turn the UI ON or OFF +See Menu > Misc for more visual options. + +w, a, s, d - move viewpoint + +q, e - zoom in and out + +Recording: + +to start recording, click on the Record button at the bottom right + +to clear existing recording, choose Menu > File > Clear + +to save the recording as a .WAV file on the desktop, +choose Menu > File > Save. + +Console: + +TAB : enter/leave command mode +UP_ARROW / DOWN_ARROW: scroll up/down +SHIFT + UP_ARROW / DOWN_ARROW: scroll up/down command history + +In command mode, type help to reveal available commands. Or type +help command_name to get help for a particular command. + +PgUp, PgDn: page up, page down +BACKSPACE : delete all text in console +` : fold/unfold console diff -Nru din-55/src/factory/mondrian_waveform.ed din-56/src/factory/mondrian_waveform.ed --- din-55/src/factory/mondrian_waveform.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/mondrian_waveform.ed 2022-10-24 06:38:44.000000000 +0000 @@ -26,3 +26,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/morse-code.ed din-56/src/factory/morse-code.ed --- din-55/src/factory/morse-code.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/morse-code.ed 2022-10-24 06:38:44.000000000 +0000 @@ -20,3 +20,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/noiser.ed din-56/src/factory/noiser.ed --- din-55/src/factory/noiser.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/noiser.ed 2022-10-24 06:38:44.000000000 +0000 @@ -22,3 +22,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/octave-shift.ed din-56/src/factory/octave-shift.ed --- din-55/src/factory/octave-shift.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/octave-shift.ed 2022-10-24 06:38:44.000000000 +0000 @@ -24,3 +24,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/pitch-vol.ed din-56/src/factory/pitch-vol.ed --- din-55/src/factory/pitch-vol.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/pitch-vol.ed 2022-10-24 06:38:44.000000000 +0000 @@ -22,3 +22,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/point-modulation.ed din-56/src/factory/point-modulation.ed --- din-55/src/factory/point-modulation.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/point-modulation.ed 2022-10-24 06:38:44.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/range-modulation.ed din-56/src/factory/range-modulation.ed --- din-55/src/factory/range-modulation.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/range-modulation.ed 2022-10-24 06:38:44.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/range-width-height.ed din-56/src/factory/range-width-height.ed --- din-55/src/factory/range-width-height.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/range-width-height.ed 2022-10-24 06:38:44.000000000 +0000 @@ -22,3 +22,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/rose_milker_cos.ed din-56/src/factory/rose_milker_cos.ed --- din-55/src/factory/rose_milker_cos.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/rose_milker_cos.ed 2022-10-24 06:38:44.000000000 +0000 @@ -23,3 +23,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/rose_milker_radius.ed din-56/src/factory/rose_milker_radius.ed --- din-55/src/factory/rose_milker_radius.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/rose_milker_radius.ed 2022-10-24 06:38:44.000000000 +0000 @@ -22,3 +22,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/rose_milker_sin.ed din-56/src/factory/rose_milker_sin.ed --- din-55/src/factory/rose_milker_sin.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/rose_milker_sin.ed 2022-10-24 06:38:44.000000000 +0000 @@ -23,3 +23,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/save_settings.tcl din-56/src/factory/save_settings.tcl --- din-55/src/factory/save_settings.tcl 2022-04-04 15:48:09.000000000 +0000 +++ din-56/src/factory/save_settings.tcl 2022-11-08 09:19:07.000000000 +0000 @@ -44,7 +44,6 @@ {"set-scope right" "format {{%s}} [get-scope right]"} {"set-var show_parameters" "get-var show_parameters"} {set-kb-layout set-kb-layout} - {"set-var fft" "get-var fft"} {"set-var current_plugin" "get-var current_plugin"} {"set-var mondrian.delta_attack_time" "get-var mondrian.delta_attack_time"} {"set-var mondrian.delta_decay_time" "get-var mondrian.delta_decay_time"} diff -Nru din-55/src/factory/seed.ed din-56/src/factory/seed.ed --- din-55/src/factory/seed.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/seed.ed 2022-10-24 06:38:44.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/settings.tcl din-56/src/factory/settings.tcl --- din-55/src/factory/settings.tcl 2022-09-19 01:46:31.000000000 +0000 +++ din-56/src/factory/settings.tcl 2022-11-09 19:59:46.000000000 +0000 @@ -9,7 +9,7 @@ set-var fm_depth 0 set-delay left 1000.00 set-delay right 1000.00 -set-var version 55 +set-var version 56 notation 1 tuning set equal-temperament load-scale microtonal_keyboard blues @@ -37,7 +37,6 @@ set-scope right {1.000000 1.000000 0.000000} set-var show_parameters 1 set-kb-layout us -set-var fft 0 set-var current_plugin 1 set-var mondrian.delta_attack_time 0.01 set-var mondrian.delta_decay_time 0.01 diff -Nru din-55/src/factory/sine_mixer_sin.ed din-56/src/factory/sine_mixer_sin.ed --- din-55/src/factory/sine_mixer_sin.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/sine_mixer_sin.ed 2022-10-24 06:38:44.000000000 +0000 @@ -23,3 +23,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/spinners din-56/src/factory/spinners --- din-55/src/factory/spinners 2022-06-06 20:53:02.000000000 +0000 +++ din-56/src/factory/spinners 2022-11-28 02:17:04.000000000 +0000 @@ -1 +1 @@ -0 0 1 1 0.05 1 0 0 1 0 0.5 1 0 0 1 0 0 1 0 0 1 0 0 1 0 0 1 0 0 1 0 0 1 1 0.01 1 0 0.5 1 0 0.5 1 0 0.5 1 0 0.5 1 0 0 1 0 0.5 1 0 0.5 1 +0 0 1 1 0.05 1 0 0 1 0 0.5 1 0 0 1 0 0 1 0 0 1 0 0 1 0 0 1 0 0 1 0 0 1 1 0.01 1 0 0.5 1 0 0.5 1 0 0.5 1 0 0.5 1 0 0 1 0 0.5 1 0 0.5 1 0 0 1 0 0 1 0 0 1 diff -Nru din-55/src/factory/spiraler_cos.ed din-56/src/factory/spiraler_cos.ed --- din-55/src/factory/spiraler_cos.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/spiraler_cos.ed 2022-10-24 06:38:44.000000000 +0000 @@ -23,3 +23,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/spiraler_radius.ed din-56/src/factory/spiraler_radius.ed --- din-55/src/factory/spiraler_radius.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/spiraler_radius.ed 2022-10-24 06:38:44.000000000 +0000 @@ -22,3 +22,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/spiraler_sin.ed din-56/src/factory/spiraler_sin.ed --- din-55/src/factory/spiraler_sin.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/spiraler_sin.ed 2022-10-24 06:38:44.000000000 +0000 @@ -23,3 +23,4 @@ overlay 1 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/velocity.ed din-56/src/factory/velocity.ed --- din-55/src/factory/velocity.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/velocity.ed 2022-10-24 06:38:44.000000000 +0000 @@ -22,3 +22,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/factory/warper.ed din-56/src/factory/warper.ed --- din-55/src/factory/warper.ed 2022-02-10 15:37:11.000000000 +0000 +++ din-56/src/factory/warper.ed 2022-10-24 06:38:44.000000000 +0000 @@ -23,3 +23,4 @@ overlay 0 mirror_axis 0 draw_plugin_output 0 +rotatingcurves 0 diff -Nru din-55/src/fft.cc din-56/src/fft.cc --- din-55/src/fft.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/fft.cc 2022-12-22 06:10:23.000000000 +0000 @@ -32,13 +32,14 @@ widget* ctrls [] = {&ab_fold, &lev, &l_title}; widget_load ("d_fft", ctrls, 3); - ab_fold.set_dir (arrow_button::down); + ab_fold.set_dir (arrow_button::right); ab_fold.set_listener (this); l_title.set_text ("FFT"); l_title.add_child (&ab_fold); l_title.add_child (&lev); l_title.set_moveable (1); + lev.hide (); } diff -Nru din-55/src/field.cc din-56/src/field.cc --- din-55/src/field.cc 2022-09-04 09:43:21.000000000 +0000 +++ din-56/src/field.cc 2022-11-01 16:34:12.000000000 +0000 @@ -158,8 +158,7 @@ glVertex2i (cx, y); glVertex2i (cx, y + fnt.charheight.max); glEnd (); - /* - static int pts [4] = {0}; + /*static int pts [4] = {0}; pts[0]=cx;pts[1]=y; pts[2]=cx;pts[3]=y+fnt.charheight.max; glVertexPointer (2, GL_INT, 0, pts); diff -Nru din-55/src/gravity.cc din-56/src/gravity.cc --- din-55/src/gravity.cc 2022-08-20 10:43:03.000000000 +0000 +++ din-56/src/gravity.cc 2022-12-05 02:26:09.000000000 +0000 @@ -31,7 +31,7 @@ makefam (&lbl, &w[1], 14); const char* txt [] = { "Gravity", "", "0", "", "", "", "", - "Base to manual", "Base to drone", "Tip to manual", "Tip to drone", "Select base", "Select tip", "Select both", "Reset" + "Base to manual", "Base to drone", "Tip to manual", "Tip to drone", "Select base", "Select tip", "Select both", "Here!" }; for (int i = 0; i < 15; ++i) { label* lbl = dynamic_cast(w[i]); @@ -168,7 +168,7 @@ textpos.y = view.midy; } - static const int ds = 20, ds2 = ds / 2; + static const int ds = 15, ds2 = ds / 2; textpos.x += ds; @@ -333,6 +333,6 @@ float wx, wy; view2win (vx, vy, wx, wy, view, d.win); static const int h3 = 3 * g.handlesize; - wx -= h3; + wx = wx - g.base2tip.x - h3; g.move (wx, wy); } diff -Nru din-55/src/help.cc din-56/src/help.cc --- din-55/src/help.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/help.cc 2022-11-03 13:34:14.000000000 +0000 @@ -14,10 +14,14 @@ help::help (const string& fname) { string s; ifstream file ((user_data_dir + fname).c_str(), ios::in); - if (!file) text.push_back (fname); else while (getline(file, s)) text.push_back (s); + if (!file) lines.push_back (fname); else while (getline(file, s)) lines.push_back (s); + dlog << "help file: " << fname << " loaded, num_lines = " << lines.size () << endl; } void help::operator() () { cons.rollup (0); - for (int i = 0, j = text.size(); i < j; ++i) cons << console::cyan << text[i] << eol; + for (int i = 0, j = lines.size(); i < j; ++i) { + dlog << lines[i] << endl; + cons << CYAN << lines[i] << eol; + } cons.last (); } diff -Nru din-55/src/help.h din-56/src/help.h --- din-55/src/help.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/help.h 2022-11-03 13:10:18.000000000 +0000 @@ -10,7 +10,7 @@ #include #include struct help { - std::vector text; + std::vector lines; help (const std::string& fname); void operator() (); }; diff -Nru din-55/src/keyboard_keyboard.cc din-56/src/keyboard_keyboard.cc --- din-55/src/keyboard_keyboard.cc 2022-09-05 09:22:55.000000000 +0000 +++ din-56/src/keyboard_keyboard.cc 2022-11-08 09:01:34.000000000 +0000 @@ -286,11 +286,11 @@ for (triggered_note_iterator i = triggered_notes.begin (), j = triggered_notes.end (); i != j; ++i) (*i).decay.update (); } -void keyboard_keyboard::update_waveform (multi_curve& crv) { +void keyboard_keyboard::update_waveform (multi_curve& src) { static const string nam ("keyboard-keyboard-waveform"); for (triggered_note_iterator i = triggered_notes.begin (), j = triggered_notes.end (); i != j; ++i) - (*i).update_solver (crv, nam); - uis.cd_waveform_display.calc_bbox (); + (*i).update_solver (src, nam); + uis.cd_waveform_display.setbbox (wave.shapeform); } int keyboard_keyboard::render_audio (float* L, float* R) { @@ -499,14 +499,6 @@ triggered_notes.push_back (triggered_note (n, velsol(vel) * NOTE_VOLUME, keys[0].x + i12 * spacing, keys[0].y, trig_what, id, marker_x)); triggered_note& last_triggered_note = *(--triggered_notes.end()); last_triggered_note.setup (&wave, &attackcrv, &decaycrv); - - /*int ci = color_index [i12]; - float r = note_color[ci].r; - float g = note_color[ci].g; - float b = note_color[ci].b; - last_triggered_note.r = r; last_triggered_note.g = g; last_triggered_note.b = b;*/ - - ++num_triggered_notes; } diff -Nru din-55/src/keyboard_keyboard.h din-56/src/keyboard_keyboard.h --- din-55/src/keyboard_keyboard.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/keyboard_keyboard.h 2022-11-08 08:57:07.000000000 +0000 @@ -104,7 +104,6 @@ // MIDI // static const int MIDI_MAX = 128; - static color note_color [2]; static const int color_index []; note midi_notes [MIDI_MAX]; void setup_midi_notes (); diff -Nru din-55/src/listeners.cc din-56/src/listeners.cc --- din-55/src/listeners.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/listeners.cc 2022-11-08 08:49:41.000000000 +0000 @@ -34,9 +34,7 @@ switch (which) { case MICROTONAL_KEYBOARD: din0.wavsol.update (); - if (ed->mix.num_vertices) { - din0.wavplay.set_mix (ed->mix, "microtonal_keyboard_waveform"); - } + if (ed->mix.num_vertices) din0.wavplay.set_mix (ed->mix, "microtonal_keyboard_waveform"); break; case KEYBOARD_KEYBOARD: keybd2.update_waveform (ed->mix); @@ -47,7 +45,7 @@ case MONDRIAN: mondrian0.update_waveform (ed->mix); } - if (fft0.folded () == 0) fft0.go (ed->curveinfo[i].curve); + uis.dofft (); curve_listener::edited (ed, i); } diff -Nru din-55/src/main.cc din-56/src/main.cc --- din-55/src/main.cc 2022-09-03 14:32:14.000000000 +0000 +++ din-56/src/main.cc 2022-12-18 13:27:39.000000000 +0000 @@ -143,7 +143,7 @@ widget* widget::next_focus = 0; // widget waiting to have focus // see spinner.h, spinner2.h -int SPACING = 5; +int SPACING = 6; int VAR_MIN = -100, VAR_MAX = 100; // for variance @ spinner.h int VAR_MIN2 = 0, VAR_MAX2 = 100; // for variance @ spinner2.h string VARSTR, VARSTR2; @@ -505,7 +505,7 @@ float slit::HALF_SIZE = 20; float slit::MIN_HALF_SIZE = 1; float slit::MIN_SIZE = 2 * slit::MIN_HALF_SIZE; -const char* ball::types_str [4] = {"bouncer", "wrecker", "healer", "bouncer or wrecker or healer"}; +const char* ball::types_str [4] = {" bouncer", " wrecker", " healer", " bouncer or wrecker or healer"}; float ball::recent_attack_time = 0.01f; // secs float ball::recent_decay_time = 2.0f; // secs float ball::recent_pitch_mult = 1.0f; // modulation @@ -545,8 +545,6 @@ float DECAY_TIME = 5.0f; float DELTA_TIME = 0.025f; -color keyboard_keyboard::note_color[2]; // midi keybd note color -const int keyboard_keyboard::color_index [] = {0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0}; // 0 - white, 1 - black; 1 octave keyboard_keyboard keybd2; gotog _gotog (1, &keybd2.attacked); // default sustain (see keyboard-keyboard.cc) @@ -885,8 +883,6 @@ mouse_slider mouse_slider0; -const char* menu::defvelaccelui::autorotatet::diropts [] = {" Clockwise", " Anti clockwise", " Clockwise or Anti-clockwise"}; -const char* menu::defvelaccelui::autorotatet::movopts [] = {" Ticked", " Smooth", " Smooth or Ticked"}; ui_list uis; curve_editor drone::modvt::ed ("modv.ed"); @@ -1332,10 +1328,6 @@ int main (int argc, char** argv) { - // MIDI note colors - keyboard_keyboard::note_color [0] = color (0.9f, 0.9f, 0.9f); // white - keyboard_keyboard::note_color [1] = color (0.2f, 0.2f, 0.2f); // black - dlog << "*** Starting DIN Is Noise " << VERSION_NUMBER << " ***" << endl; @@ -1501,7 +1493,6 @@ MENU.cb_show_gravity.set_state (din0.dinfo.gravity.visible); MENU.dcl.changed (MENU.cb_show_gravity); - MENU.choutline.set_state (drone::chuckt::outline); MENU.chautoresettrails.set_state (drone::chuckt::autoresettrails); diff -Nru din-55/src/Makefile.am din-56/src/Makefile.am --- din-55/src/Makefile.am 2022-09-22 14:07:29.000000000 +0000 +++ din-56/src/Makefile.am 2022-12-19 17:48:01.000000000 +0000 @@ -5,8 +5,8 @@ bin_PROGRAMS = din -din_SOURCES = alarm.cc arrow_button.cc audio.cc authors_note.cc autoflip.cc autorotator.cc ball.cc ball_ops.cc basic_editor.cc beat2value.cc binaural_drone.cc binaural_drones.cc bit_display.cc box_selector.cc button.cc capturer.cc checkbutton.cc chrono.cc circler.cc command.cc compressor.cc console.cc console_iterator.cc countries.cc cross_button.cc curve.cc curve_display.cc curve_editor.cc curve_library.cc curve_mixer.cc curve_picker.cc curve_samples.cc custom_periodic.cc defvelaccel.cc delay.cc din.cc din_info.cc drawrrow.cc drone.cc eval.cc fader.cc fft.cc field.cc filled_button.cc font.cc font_editor.cc fractaliser.cc globals.cc glyph.cc gravity.cc help.cc hit.cc item_list.cc keyboard_keyboard.cc label.cc levels.cc line.cc lissajous.cc listeners.cc main.cc menu.cc mesh.cc midi_in.cc minus_button.cc mocap.cc modulator.cc mondrian.cc morpher.cc morse_code.cc mouse_slider.cc multi_curve.cc noiser.cc note.cc number.cc oscilloscope.cc phrasor.cc play.cc plugin_browser.cc plugin.cc plus_button.cc point_modulator.cc range.cc recorder.cc rect.cc rose_milker.cc scale_info.cc scalelist.cc scale_notes.cc separator.cc settings.cc sine_mixer.cc slit.cc solver.cc spiraler.cc starrer.cc superformula.cc tap_bpm.cc tcl_interp.cc textboard.cc tokenizer.cc trail.cc triggered_note.cc ui.cc ui_sin_cos_radius.cc viewwin.cc warper.cc widget.cc RtAudio.cpp RtMidi.cpp kiss_fft.c +din_SOURCES = alarm.cc arrow_button.cc audio.cc authors_note.cc autoflip.cc autopause.cc autorotator.cc ball.cc ball_ops.cc basic_editor.cc beat2value.cc binaural_drone.cc binaural_drones.cc bit_display.cc box_selector.cc button.cc capturer.cc checkbutton.cc chrono.cc circler.cc command.cc compressor.cc console.cc console_iterator.cc countries.cc cross_button.cc curve.cc curve_display.cc curve_editor.cc curve_library.cc curve_mixer.cc curve_picker.cc curve_samples.cc custom_periodic.cc defvelaccel.cc delay.cc din.cc din_info.cc drawrrow.cc drone.cc eval.cc fader.cc fft.cc field.cc filled_button.cc font.cc font_editor.cc fractaliser.cc globals.cc glyph.cc gravity.cc help.cc hit.cc item_list.cc keyboard_keyboard.cc label.cc levels.cc line.cc lissajous.cc listeners.cc main.cc menu.cc mesh.cc midi_in.cc minus_button.cc mocap.cc modulator.cc mondrian.cc morpher.cc morse_code.cc mouse_slider.cc multi_curve.cc noiser.cc note.cc number.cc oscilloscope.cc phrasor.cc play.cc plugin_browser.cc plugin.cc plus_button.cc point_modulator.cc range.cc recorder.cc rect.cc rose_milker.cc scale_info.cc scalelist.cc scale_notes.cc separator.cc settings.cc sine_mixer.cc slit.cc solver.cc spiraler.cc starrer.cc superformula.cc tap_bpm.cc tcl_interp.cc textboard.cc tokenizer.cc trail.cc triggered_note.cc ui.cc ui_sin_cos_radius.cc viewwin.cc warper.cc widget.cc RtAudio.cpp RtMidi.cpp kiss_fft.c -dist_include = alarm.h angle.h arrow_button.h audio.h authors_note.h autoflip.h autorotator.h ball.h ball_ops.h basic_editor.h beat2value.h binaural_drone.h binaural_drones.h bit_display.h box.h box_selector.h button.h capturer.h checkbutton.h chrono.h circler.h color.h command.h compressor.h console.h console_iterator.h constant_radius.h container.h cosine.h countries.h cross_button.h crvpt.h curve_display.h curve_editor.h curve.h curve_library.h curve_listener.h curve_mixer.h curve_picker.h curve_samples.h custom_periodic.h defvelaccel.h delay.h dingl.h din.h din_info.h drawrrow.h drone.h fader.h fft.h field.h file-utils.h filled_button.h font_editor.h font.h fractaliser.h funktion.h globals.h glyph.h gravity.h help.h hit.h input.h instrument.h item_list.h keyboard_keyboard.h _kiss_fft_guts.h kiss_fft.h label_field.h label_field_slider.h label.h levels.h line.h lissajous.h listeners.h log.h main.h menu.h mesh.h midi_in.h minus_button.h mocap.h mod_params.h modulator.h mondrian.h morpher.h morse_code.h mouse_slider.h multi_curve.h noiser.h note.h number.h octave_shift_data.h options_list.h osc.h oscilloscope.h phrasor.h play.h plugin_browser.h plugin.h plus_button.h point.h point_modulator.h random.h range.h recorder.h rect.h rose_milker.h RtAudio.h RtError.h RtMidi.h scale_info.h scalelist.h scale_notes.h separator.h settings.h sine.h sine_mixer.h slider.h slit.h solver.h spinner2.h spinner.h spiraler.h starrer.h state_button.h strength_editor.h superformula.h tap_bpm.h tcl_interp.h textboard.h tick.h tokenizer.h trail.h triggered_note.h ui.h ui_list.h ui_sin_cos_radius.h utils.h vector2d.h viewwin.h warper.h wav.h widget.h +dist_include = alarm.h angle.h arrow_button.h audio.h authors_note.h autoflip.h autopause.h autorotator.h ball.h ball_ops.h basic_editor.h beat2value.h binaural_drone.h binaural_drones.h bit_display.h box.h box_selector.h button.h capturer.h checkbutton.h chrono.h circler.h color.h command.h compressor.h console.h console_iterator.h constant_radius.h container.h cosine.h countries.h cross_button.h crvpt.h curve_display.h curve_editor.h curve.h curve_library.h curve_listener.h curve_mixer.h curve_picker.h curve_samples.h custom_periodic.h defvelaccel.h delay.h dingl.h din.h din_info.h drawrrow.h drone.h fader.h fft.h field.h file-utils.h filled_button.h font_editor.h font.h fractaliser.h funktion.h globals.h glyph.h gravity.h help.h hit.h input.h instrument.h item_list.h keyboard_keyboard.h _kiss_fft_guts.h kiss_fft.h label_field.h label_field_slider.h label.h levels.h line.h lissajous.h listeners.h log.h main.h menu.h mesh.h midi_in.h minus_button.h mocap.h mod_params.h modulator.h mondrian.h morpher.h morse_code.h mouse_slider.h multi_curve.h noiser.h note.h number.h octave_shift_data.h options_list.h osc.h oscilloscope.h phrasor.h play.h plugin_browser.h plugin.h plus_button.h point.h point_modulator.h random.h range.h recorder.h rect.h rose_milker.h RtAudio.h RtError.h RtMidi.h scale_info.h scalelist.h scale_notes.h separator.h settings.h sine.h sine_mixer.h slider.h slit.h solver.h spinner2.h spinner.h spiraler.h starrer.h state_button.h strength_editor.h superformula.h tap_bpm.h tcl_interp.h textboard.h tick.h tokenizer.h trail.h triggered_note.h ui.h ui_list.h ui_sin_cos_radius.h utils.h vector2d.h viewwin.h warper.h wav.h widget.h EXTRA_DIST = $(dist_include) diff -Nru din-55/src/Makefile.in din-56/src/Makefile.in --- din-55/src/Makefile.in 2022-09-22 14:07:38.000000000 +0000 +++ din-56/src/Makefile.in 2022-12-24 03:16:45.000000000 +0000 @@ -103,8 +103,8 @@ PROGRAMS = $(bin_PROGRAMS) am_din_OBJECTS = alarm.$(OBJEXT) arrow_button.$(OBJEXT) \ audio.$(OBJEXT) authors_note.$(OBJEXT) autoflip.$(OBJEXT) \ - autorotator.$(OBJEXT) ball.$(OBJEXT) ball_ops.$(OBJEXT) \ - basic_editor.$(OBJEXT) beat2value.$(OBJEXT) \ + autopause.$(OBJEXT) autorotator.$(OBJEXT) ball.$(OBJEXT) \ + ball_ops.$(OBJEXT) basic_editor.$(OBJEXT) beat2value.$(OBJEXT) \ binaural_drone.$(OBJEXT) binaural_drones.$(OBJEXT) \ bit_display.$(OBJEXT) box_selector.$(OBJEXT) button.$(OBJEXT) \ capturer.$(OBJEXT) checkbutton.$(OBJEXT) chrono.$(OBJEXT) \ @@ -309,19 +309,19 @@ top_srcdir = @top_srcdir@ AM_CXXFLAGS = -I /usr/include/tcl8.6 -Wall -D_THREAD_SAFE -DHAVE_OPENGL -D__LICENSED__ -D__SVG__ -D__GPL20__ -D__BOOST_TIME__ -DPREFIX=\"@prefix@\" din_SOURCES = alarm.cc arrow_button.cc audio.cc authors_note.cc \ - autoflip.cc autorotator.cc ball.cc ball_ops.cc basic_editor.cc \ - beat2value.cc binaural_drone.cc binaural_drones.cc \ - bit_display.cc box_selector.cc button.cc capturer.cc \ - checkbutton.cc chrono.cc circler.cc command.cc compressor.cc \ - console.cc console_iterator.cc countries.cc cross_button.cc \ - curve.cc curve_display.cc curve_editor.cc curve_library.cc \ - curve_mixer.cc curve_picker.cc curve_samples.cc \ - custom_periodic.cc defvelaccel.cc delay.cc din.cc din_info.cc \ - drawrrow.cc drone.cc eval.cc fader.cc fft.cc field.cc \ - filled_button.cc font.cc font_editor.cc fractaliser.cc \ - globals.cc glyph.cc gravity.cc help.cc hit.cc item_list.cc \ - keyboard_keyboard.cc label.cc levels.cc line.cc lissajous.cc \ - listeners.cc main.cc menu.cc mesh.cc midi_in.cc \ + autoflip.cc autopause.cc autorotator.cc ball.cc ball_ops.cc \ + basic_editor.cc beat2value.cc binaural_drone.cc \ + binaural_drones.cc bit_display.cc box_selector.cc button.cc \ + capturer.cc checkbutton.cc chrono.cc circler.cc command.cc \ + compressor.cc console.cc console_iterator.cc countries.cc \ + cross_button.cc curve.cc curve_display.cc curve_editor.cc \ + curve_library.cc curve_mixer.cc curve_picker.cc \ + curve_samples.cc custom_periodic.cc defvelaccel.cc delay.cc \ + din.cc din_info.cc drawrrow.cc drone.cc eval.cc fader.cc \ + fft.cc field.cc filled_button.cc font.cc font_editor.cc \ + fractaliser.cc globals.cc glyph.cc gravity.cc help.cc hit.cc \ + item_list.cc keyboard_keyboard.cc label.cc levels.cc line.cc \ + lissajous.cc listeners.cc main.cc menu.cc mesh.cc midi_in.cc \ minus_button.cc mocap.cc modulator.cc mondrian.cc morpher.cc \ morse_code.cc mouse_slider.cc multi_curve.cc noiser.cc note.cc \ number.cc oscilloscope.cc phrasor.cc play.cc plugin_browser.cc \ @@ -333,34 +333,35 @@ triggered_note.cc ui.cc ui_sin_cos_radius.cc viewwin.cc \ warper.cc widget.cc RtAudio.cpp RtMidi.cpp kiss_fft.c dist_include = alarm.h angle.h arrow_button.h audio.h authors_note.h \ - autoflip.h autorotator.h ball.h ball_ops.h basic_editor.h \ - beat2value.h binaural_drone.h binaural_drones.h bit_display.h \ - box.h box_selector.h button.h capturer.h checkbutton.h \ - chrono.h circler.h color.h command.h compressor.h console.h \ - console_iterator.h constant_radius.h container.h cosine.h \ - countries.h cross_button.h crvpt.h curve_display.h \ - curve_editor.h curve.h curve_library.h curve_listener.h \ - curve_mixer.h curve_picker.h curve_samples.h custom_periodic.h \ - defvelaccel.h delay.h dingl.h din.h din_info.h drawrrow.h \ - drone.h fader.h fft.h field.h file-utils.h filled_button.h \ - font_editor.h font.h fractaliser.h funktion.h globals.h \ - glyph.h gravity.h help.h hit.h input.h instrument.h \ - item_list.h keyboard_keyboard.h _kiss_fft_guts.h kiss_fft.h \ - label_field.h label_field_slider.h label.h levels.h line.h \ - lissajous.h listeners.h log.h main.h menu.h mesh.h midi_in.h \ - minus_button.h mocap.h mod_params.h modulator.h mondrian.h \ - morpher.h morse_code.h mouse_slider.h multi_curve.h noiser.h \ - note.h number.h octave_shift_data.h options_list.h osc.h \ - oscilloscope.h phrasor.h play.h plugin_browser.h plugin.h \ - plus_button.h point.h point_modulator.h random.h range.h \ - recorder.h rect.h rose_milker.h RtAudio.h RtError.h RtMidi.h \ - scale_info.h scalelist.h scale_notes.h separator.h settings.h \ - sine.h sine_mixer.h slider.h slit.h solver.h spinner2.h \ - spinner.h spiraler.h starrer.h state_button.h \ - strength_editor.h superformula.h tap_bpm.h tcl_interp.h \ - textboard.h tick.h tokenizer.h trail.h triggered_note.h ui.h \ - ui_list.h ui_sin_cos_radius.h utils.h vector2d.h viewwin.h \ - warper.h wav.h widget.h + autoflip.h autopause.h autorotator.h ball.h ball_ops.h \ + basic_editor.h beat2value.h binaural_drone.h binaural_drones.h \ + bit_display.h box.h box_selector.h button.h capturer.h \ + checkbutton.h chrono.h circler.h color.h command.h \ + compressor.h console.h console_iterator.h constant_radius.h \ + container.h cosine.h countries.h cross_button.h crvpt.h \ + curve_display.h curve_editor.h curve.h curve_library.h \ + curve_listener.h curve_mixer.h curve_picker.h curve_samples.h \ + custom_periodic.h defvelaccel.h delay.h dingl.h din.h \ + din_info.h drawrrow.h drone.h fader.h fft.h field.h \ + file-utils.h filled_button.h font_editor.h font.h \ + fractaliser.h funktion.h globals.h glyph.h gravity.h help.h \ + hit.h input.h instrument.h item_list.h keyboard_keyboard.h \ + _kiss_fft_guts.h kiss_fft.h label_field.h label_field_slider.h \ + label.h levels.h line.h lissajous.h listeners.h log.h main.h \ + menu.h mesh.h midi_in.h minus_button.h mocap.h mod_params.h \ + modulator.h mondrian.h morpher.h morse_code.h mouse_slider.h \ + multi_curve.h noiser.h note.h number.h octave_shift_data.h \ + options_list.h osc.h oscilloscope.h phrasor.h play.h \ + plugin_browser.h plugin.h plus_button.h point.h \ + point_modulator.h random.h range.h recorder.h rect.h \ + rose_milker.h RtAudio.h RtError.h RtMidi.h scale_info.h \ + scalelist.h scale_notes.h separator.h settings.h sine.h \ + sine_mixer.h slider.h slit.h solver.h spinner2.h spinner.h \ + spiraler.h starrer.h state_button.h strength_editor.h \ + superformula.h tap_bpm.h tcl_interp.h textboard.h tick.h \ + tokenizer.h trail.h triggered_note.h ui.h ui_list.h \ + ui_sin_cos_radius.h utils.h vector2d.h viewwin.h warper.h \ + wav.h widget.h EXTRA_DIST = $(dist_include) all: all-am @@ -455,6 +456,7 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/audio.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authors_note.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/autoflip.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/autopause.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/autorotator.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ball.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ball_ops.Po@am__quote@ diff -Nru din-55/src/menu.cc din-56/src/menu.cc --- din-55/src/menu.cc 2022-09-21 06:24:15.000000000 +0000 +++ din-56/src/menu.cc 2022-12-22 05:45:41.000000000 +0000 @@ -158,7 +158,7 @@ &ol_fm_style, &cb_mkb_drone_tools, &ol_add_wand, - &b_move_drones, + &moverailstrafe, &b_delete_drones, &b_select_all_drones, &b_invert_drone_selection, @@ -601,6 +601,24 @@ &am2fm, &fm2am, &scopacity, + &cb_ed_curves, + &ed_flip_rotation, + &cb_ed_autoflip, + &sp_curve_every, + &ed_autoflip_reset, + &dva.autopause.cb, + &dva.autopause.every, + &dva.autopause.f0r, + &autorotate.autopause.lbl, + &autorotate.autopause.set, + &autorotate.autopause.unset, + &autorotate.autopause.toggle, + &autorotate.autopause.every, + &autorotate.autopause.f0r, + &autorotate.rndflipause.whichl, + &autorotate.rndflipause.set, + &autorotate.rndflipause.unset, + &autorotate.rndflipause.toggle, // next item here }; @@ -659,6 +677,7 @@ &cb_mon_misc, &cb_binaural_drones_tools, &cb_binaural_drones_edit, + &cb_ed_curves, }; static const char* const cb_tab_lbls [] = { @@ -677,10 +696,11 @@ "Box Ops", "Misc", "Create", - "Edit" + "Edit", + "Curves", }; - for (int i = 0; i < 16; ++i) { + for (int i = 0; i < 17; ++i) { checkbutton* ci = cb_tabs[i]; ci->set_text (cb_tab_lbls[i]); ci->set_listener (this); @@ -732,7 +752,6 @@ &b_range_pitch_vol, &b_gater, &b_point_modulation, - &b_noise_interpolator, &b_drone_pend, &edlife2vel, &b_mondrian_waveform, @@ -743,6 +762,7 @@ &b_octave_shift, &b_compressor, &b_morse_code, + &b_noise_interpolator, }; widget* wvoice [] = { @@ -799,7 +819,7 @@ &l_apply_to, &b_set_to_mesh_rows, &b_set_to_mesh_cols, - &b_move_drones, + &moverailstrafe, &b_scale_drones, &b_rotate_drones, &b_connect, @@ -831,7 +851,8 @@ #ifndef __WIDGET_MOVE__ LISTEN(b_scale_drones,&bsdl) LISTEN(b_rotate_drones,&brdl) - LISTEN(b_move_drones,&bmdl) + LISTEN(moverailstrafe, &mrsl) + LISTEN(moverailstrafe.option, &bmdl) LISTEN(balloon,&dugl) LISTEN(b_mute,&mul) LISTEN(b_unmute,&umul) @@ -851,6 +872,9 @@ LISTEN(chautoresettrails,&aurl) #endif + raill1.name = "Rail"; + strafel1.name = "Strafe"; + sp_stiff.set ("Connection stiffness", 0.001f, 0.0f, 1.0f, &stiffl); gabt.set (0.1f, 0, MILLION, &gabtl); gabt.set_text ("In", SECONDS); @@ -1001,7 +1025,7 @@ sp_lev_sz.set ("Level size", 1, 1, MILLION, &pvdl); - widget* wetools [] = { // curve editors tools + widget* wedtools [] = { // curve editors tools &abe_left, &abe_right, &abe_up, @@ -1049,7 +1073,10 @@ &sp_curve_rpm, &b_stop_rotating, &cb_overlay, - &b_swap_curves + &ed_flip_rotation, + &cb_ed_autoflip, + &sp_curve_every, + &ed_autoflip_reset, }; widget* wmon [] = { // mondrian tools @@ -1184,8 +1211,8 @@ for (int i = 1; i < 7; ++i) static_cast(wmon_misc[i])->set_listener (&monl); for (int i = 7; i < 15; ++i) static_cast(wmon_misc[i])->set_listener (&monl); for (int i = 0; i < 33; ++i) static_cast(wmon[i])->set_listener (&monl); - for (int i = 0; i < 6; ++i) static_cast(wetools[i])->set_listener (&pzl); - for (int i = 7; i < 11; ++i) static_cast(wetools[i])->set_listener (&snl); + for (int i = 0; i < 6; ++i) static_cast(wedtools[i])->set_listener (&pzl); + for (int i = 7; i < 11; ++i) static_cast(wedtools[i])->set_listener (&snl); button* crvops [] = { &b_pick_curve, @@ -1207,9 +1234,12 @@ &b_delete_curve, &b_start_capture, &b_assign_capture, + &b_stop_rotating, + &ed_flip_rotation, + &ed_autoflip_reset, }; - for (int i = 0; i < 19; ++i) crvops[i]->set_listener (&col); + for (int i = 0; i < 22; ++i) crvops[i]->set_listener (&col); #endif @@ -1230,10 +1260,12 @@ ol_mirror.set_listener (this); lf_curve_name.set_listener (&col); #ifndef __WIDGET_MOVE__ - cb_label_vertices.set_listener (&col); - cb_mark_segments.set_listener (&col); - cb_overlay.set_listener (&col); - cb_draw_curve.set_listener (&col); + checkbutton* cbed [] = {&cb_label_vertices,&cb_mark_segments,&cb_overlay,&cb_draw_curve,&cb_ed_autoflip, &sp_curve_every.variance.cb, 0}; + checkbutton** cp = cbed; + while (*cp != 0) { + (*cp)->set_listener (&col); + cp++; + } #endif widget* wbd [] = { // binaural drones @@ -1333,14 +1365,15 @@ wdrone_params, wranges, wmisc, - wetools, + wedtools, wmon, wmon_pars, wmon_ballops, wmon_boxops, wmon_misc, wbd, - wbde + wbde, + 0 }; int numw [] = { 10, @@ -1351,14 +1384,15 @@ DRONE_PARAMS_N, 35, 20, - 47, + 51, 38, 17, 26, 9, 15, 10, - 23 + 23, + 0 }; lf_conn_steps.set_label ("Steps"); @@ -1398,10 +1432,10 @@ si.set_name (sepsn[i]); } - for (int i = 0; i < 16; ++i) { + for (int i = 0; i < 17; ++i) { + vector& vw = tab_members[cb_tabs[i]]; int n = numw[i]; widget** wmi = wmap[i]; - vector& vw = tab_members[cb_tabs[i]]; for (int m = 0; m < n; ++m) { vw.push_back (wmi[m]); #ifdef __WIDGET_MOVE__ @@ -1442,7 +1476,7 @@ int wek [] = {7, 13, 2, 3, 6, 3, 3, 3, 2}; for (int i = 0, j = 4, k = 0; i < 9; ++i) { k = wek[i]; - makehier (&wetools[j], k); + makehier (&wedtools[j], k); j += k; } @@ -1539,7 +1573,7 @@ widget* w[] = { &ol_add_wand, &b_delete_drones, - &b_move_drones, + &moverailstrafe, &b_scale_drones, &b_rotate_drones, &b_set_xform_center, @@ -1564,12 +1598,14 @@ widget* w[] = { &b_launch_drones, &b_stop_launching_drones, + &balloon, + &chuck, &b_orbit_selected_drones, &b_track_drones, &b_set_targets, &b_clear_targets, 0, }; - makehier (w); + makehier(w); } { @@ -1780,9 +1816,11 @@ sp_curve_rpm.set ("RPM", 1.0f, 0.0f, MILLION, &col); sp_curve_rpm.set_value (0.0f); + sp_curve_every.set (1.0f, 0, MILLION, &col); + sp_curve_every.set_listener (&col, 2); // variance + sp_curve_every.set_text ("Every", DEGREES); #ifndef __WIDGET_MOVE__ - b_stop_rotating.set_listener (&col); cb_show_waveform_samples.set_listener (&col); #endif @@ -1816,7 +1854,7 @@ "Morse Code", "Exit DIN Is Noise", "Show anchors", - "Move", + " Move", "Delete", "Select all", "Invert selected", @@ -2010,8 +2048,16 @@ "Reset every tick", "Reset every tick", "Drone velocity modulation", - "X", "Y", "Both", "None", - "Set AM BPM to FM BPM", "Set FM BPM to AM BPM", + "X", + "Y", + "Both", + "None", + "Set AM BPM to FM BPM", + "Set FM BPM to AM BPM", + "Flip", + "Autoflip", + "Reset", + "Auto pause", // next label }; @@ -2036,7 +2082,7 @@ &b_morse_code, &b_exit_din, &cb_show_anchors, - &b_move_drones, + &moverailstrafe.option, &b_delete_drones, &b_select_all_drones, &b_invert_drone_selection, @@ -2230,12 +2276,22 @@ &dva.autorotate.uet.deg, &dva.autorotate.uet.tps, &edlife2vel, - &b_snapx, &b_snapy, &b_snapboth, &b_snapnone, - &am2fm, &fm2am + &b_snapx, + &b_snapy, + &b_snapboth, + &b_snapnone, + &am2fm, + &fm2am, + &ed_flip_rotation, + &cb_ed_autoflip, + &ed_autoflip_reset, + &dva.autopause.cb, // next button }; - for (int i = 0; i < 220; ++i) { + dlog << "+++ Labeling buttons +++" << endl; + + for (int i = 0; i < 224; ++i) { button* bi = buttons[i]; bi->set_text (labels[i]); } @@ -2390,7 +2446,9 @@ static const int lines = 4; int targety = view.ymax - lines * line_height; int dy = targety - cb_file.extents.bottom; - for (int p = 0; p < nitems; ++p) items[p]->move (0, dy, 0); + for (int p = 0; p < nitems; ++p) { + items[p]->move (0, dy, 0); + } } void menu::loadspinners () { @@ -2400,7 +2458,7 @@ f >> dva.autorotate.rpm >> dva.autorotate.dps >> dva.autorotate.tps >> dva.autoflip.deg >> gabt; f >> riset >> fallt; f >> sp_bounces >> sp_rebound; - f >> gens >> dpm >> ddpl; + f >> gens >> dpm >> ddpl >> sp_curve_every >> dva.autopause.every >> dva.autopause.f0r; } void menu::savespinners () { @@ -2408,7 +2466,7 @@ ofstream& f = fo (); f << handlesize << trailsize << dva.mag << lifetime << dronearrowdefaults.neck << dronearrowdefaults.shoulder.width << dronearrowdefaults.shoulder.position; f << dva.autorotate.rpm << dva.autorotate.dps << dva.autorotate.tps << dva.autoflip.deg << gabt; - f << riset << fallt << sp_bounces << sp_rebound << gens << dpm << ddpl << endl; + f << riset << fallt << sp_bounces << sp_rebound << gens << dpm << ddpl << sp_curve_every << dva.autopause.every << dva.autopause.f0r << endl; } @@ -2456,32 +2514,37 @@ } void menu::setup_tabs (ui* scr) { - checkbutton* com [] = {&cb_file, &cb_instrument, &cb_editors}; - checkbutton* mkb [] = {&cb_mkb_voice, &cb_mkb_drone_tools, &cb_mkb_drone_params, &cb_mkb_ranges, &cb_mkb_misc}; - checkbutton* eds [] = {&cb_ed_tools}; - checkbutton* mon [] = {&cb_mon_tools, &cb_mon_parameters, &cb_mon_ballops, &cb_mon_boxops, &cb_mon_misc}; - checkbutton* bd [] = {&cb_binaural_drones_tools, &cb_binaural_drones_edit}; + checkbutton* com [] = {&cb_file, &cb_instrument, &cb_editors, 0}; + checkbutton* mkb [] = {&cb_mkb_voice, &cb_mkb_drone_tools, &cb_mkb_drone_params, &cb_mkb_ranges, &cb_mkb_misc, 0}; + checkbutton* eds [] = {&cb_ed_tools, &cb_ed_curves, 0}; + checkbutton* mon [] = {&cb_mon_tools, &cb_mon_parameters, &cb_mon_ballops, &cb_mon_boxops, &cb_mon_misc, 0}; + checkbutton* bd [] = {&cb_binaural_drones_tools, &cb_binaural_drones_edit, 0}; int clear_existing_tabs = 1; - setup_tabs (com, 3, clear_existing_tabs); + setup_tabs (com, clear_existing_tabs); if (scr == &din0) { // microtonal keyboard - setup_tabs (mkb, 5); + setup_tabs (mkb); } else if (scr == &keybd2) { // keyboard-keyboard } else if (scr == &mondrian0) { // mondrian - setup_tabs (mon, 5); + setup_tabs (mon); } else if (scr == &binaural_drones0) { // binaural drones - setup_tabs (bd, 2); + setup_tabs (bd); } else { // is an editor - setup_tabs (com, 3, clear_existing_tabs); - setup_tabs (eds, 1); + setup_tabs (com, clear_existing_tabs); + setup_tabs (eds); next_tab = &cb_ed_tools; next_tab_instr = get_current_instrument (); } position_tabs (); } -void menu::setup_tabs (checkbutton** tlist, int n, int clear) { +void menu::setup_tabs (checkbutton** tlist, int clear) { if (clear) tabs.clear (); - for (int i = 0; i < n; ++i) tabs.push_back (tlist[i]); + int i = 0; + checkbutton* ci = tlist[i]; + while (ci) { + tabs.push_back (ci); + ci = tlist[++i]; + } num_tabs = tabs.size (); } @@ -2523,6 +2586,34 @@ if (i == end) tw.push_back (w); } +void menu::populatecurvestab (curve_editor* ed) { + destroycurvestab (); + vector& cis = ed->curveinfo; + vector& tc = tab_members [&cb_ed_curves]; + int lh = line_height, x = cb_file.extents.left, y = separators.main.extents.bottom - lh; + for (int i = 0, j = ed->curves; i < j; ++i) { + curve_info& ci = cis[i]; + checkbutton* cb = new checkbutton; + tc.push_back (cb); + cb->id = i; + cb->set_text (ci.curve->name); + cb->set_state (ci.visible, 0); + cb->set_pos (x, y); + cb->set_listener (&curvesl); + y -= lh; + } +} + +void menu::destroycurvestab () { + vector& tw = tab_members [&cb_ed_curves]; + for (int i = 1, j = tw.size (); i < j; ++i) { + widget* wi = tw[i]; + delete wi; + } + tw.clear (); + tw.push_back (&separators.main); +} + void menu::set_drone_params_items (int s, int e) { vector& tw = tab_members[&cb_mkb_drone_params]; tw.clear (); @@ -2582,6 +2673,7 @@ static int removedpluginbrowser; show = !show; + if (show) { b_menu.set_text ("Close menu"); @@ -2600,6 +2692,7 @@ uis.remove (&CRVED->pomo); removedpluginbrowser = uis.remove (&uis.plugin__browser); if (CRVED->fft_enabled) uis.remove (&fft0); + if (CRVED->curcrvchgd) CRVED->setup_tools_menu (); } style_listener* sl [] = {&gater_style_lis, &am_style_lis, &fm_style_lis}; @@ -2714,6 +2807,13 @@ widget* wi = items[i]; wi->move (dx, dy, 0); } + + if (CRVED) { + vector& vc = tab_members[&cb_ed_curves]; + int n = vc.size (); + for (int i = 1; i < n; ++i) vc[i]->move (dx, dy, 0); + } + calc_bg (); } @@ -2735,8 +2835,8 @@ // save last tab to reload when loading new instrument extern checkbutton* LAST_TABS []; - checkbutton* com [] = {&cb_file, &cb_instrument, &cb_editors, &cb_ed_tools}; // ignore these tabs - for (int i = 0; i < 4; ++i) if (com[i] == cur_tab) return; + checkbutton* com [] = {&cb_file, &cb_instrument, &cb_editors, &cb_ed_tools, &cb_ed_curves}; // ignore these tabs + for (int i = 0; i < 5; ++i) if (com[i] == cur_tab) return; LAST_TABS [CURRENT_INSTRUMENT] = cur_tab; } @@ -3007,8 +3107,8 @@ void menu::show_editors (ui* inst) { // refer to weds - int starts [] = {0, 4, 16, 19}; - int ends [] = {4, 16, 19, 20}; + int starts [] = {0, 4, 15, 18}; + int ends [] = {4, 15, 18, 19}; int starti = starts[CURRENT_INSTRUMENT], endi = ends[CURRENT_INSTRUMENT]; vector& tw = tab_members [&cb_editors]; for (int i = starti; i < endi; ++i) { @@ -3019,7 +3119,7 @@ void menu::hide_editors () { vector& tw = tab_members [&cb_editors]; - for (int i = 0; i < 20; ++i) { + for (int i = 0; i < 19; ++i) { widget* ei = editors[i]; vector::iterator itr = find (tw.begin(), tw.end(), ei); if (itr != tw.end()) tw.erase (itr); @@ -3049,6 +3149,7 @@ widget_save ("d_menu", items, nitems); savespinners (); savecolorsliders (); + destroycurvestab (); dlog << "--- destroyed menu ---" << endl; } @@ -3535,6 +3636,18 @@ CRVED->insert_using_menu (); } else if (&b == MENUP.b_delete_vertex) { CRVED->remove_using_menu (); + } else if (&b == MENUP.b_stop_rotating) { + MENU.sp_curve_rpm.set_value (0); + CRVED->set_rpm (0); + cons << "Stopped rotating curve" << eol; + } else if (&b == MENUP.ed_flip_rotation) { + int& dir = CRVED->curveinfo[CRVED->curcrv].dir; + dir *= -1; + static const char* cac [] = {"clockwise", "", "anti-clockwise"}; + cons << "Curve rotation is " << cac[dir+1] << eol; + } else if (&b == MENUP.ed_autoflip_reset) { + CRVED->curveinfo[CRVED->curcrv].totang = 0.0f; + cons << "Autoflip reset on curve rotation" << eol; } else if (&b == MENUP.b_fold_tangents) { CRVED->fold_tangents_using_menu (); } else if (&b == MENUP.b_unfold_tangents) { @@ -3563,27 +3676,32 @@ CRVED->start_mouse_capture_from_menu (); } else if (&b == MENUP.b_assign_capture) { CRVED->assign_mouse_capture_from_menu (); - } else if (&b == MENUP.b_stop_rotating) { - MENU.sp_curve_rpm.set_value (0); - CRVED->set_rpm (0); } if (toggle) TOGGLEMENU } void menu::curve_ops_listener::changed (checkbutton& cb) { int tog = 0; - if (&cb == MENUP.cb_mark_segments) { - CRVED->mark_segments = cb.state; + int cbstate = cb.state; + if (&cb == MENUP.cb_ed_autoflip) { + curve_info& ci = CRVED->curveinfo[CRVED->curcrv]; + ci.autoflip = cbstate; + ci.totang = 0.0f; + } else if (&cb == MENUP.sp_curve_every.variance.cb) { + curve_info& ci = CRVED->curveinfo[CRVED->curcrv]; + ci.randoflip = cbstate; + } else if (&cb == MENUP.cb_mark_segments) { + CRVED->mark_segments = cbstate; } else if (&cb == MENUP.cb_label_vertices) { - CRVED->label_vertices = cb.state; + CRVED->label_vertices = cbstate; } else if (&cb == MENUP.cb_show_waveform_samples) { CRVED->toggle_waveform_samples_display (); } else if (&cb == MENUP.cb_draw_curve) { - CRVED->draw_curve_only = cb.state; + CRVED->draw_curve_only = cbstate; } else { - CRVED->overlay = cb.state; + CRVED->overlay = cbstate; string n (get_current_instrument()->name); - if (cb.state) + if (cbstate) cons << GREEN << "Overlaid the " << n << eol; else cons << RED << "Removed " << n << " from overlay." << eol; @@ -3593,17 +3711,30 @@ } void menu::curve_ops_listener::changed (field& f) { - if (&f == MENUP.sp_waveform_hz.f_value) { + if (&f == MENUP.sp_curve_rpm.f_value) { + CRVED->set_rpm (f); + } else if (&f == MENUP.sp_curve_every.f_value) { + curve_info& ci = CRVED->curveinfo[CRVED->curcrv]; + ci.every0 = f; + ci.every = ci.every0.deg; + static const char* ae = "Autoflip every ", *deg = DEGREES; + cons << ae << ci.every0.deg << deg << eol; + } else if (&f == MENUP.sp_curve_every.variance.fld) { + curve_info& ci = CRVED->curveinfo[CRVED->curcrv]; + ci.rd = MENU.sp_curve_every.variance.rd; + } else if (&f == MENUP.sp_waveform_hz.f_value) { CRVED->set_hz (f); } else if (&f == MENUP.sp_waveform_periods.f_value) { CRVED->set_periods (f); - } else if (&f == MENUP.sp_curve_rpm.f_value) { - CRVED->set_rpm (f); } else if (&f == MENUP.sp_curve_limit.f_value) { CRVED->set_limit (f); } else { if (f.text == "") f.set_text ("nameless"); CRVED->set_picked_curve_name (f.text); + vector& tc = MENU.tab_members [MENUP.cb_ed_curves]; + widget* wcc = tc [1 + CRVED->curcrv]; // 0 = separator + checkbutton* cb = dynamic_cast(wcc); + cb->set_text (f.text); } } @@ -4289,11 +4420,35 @@ activate_mouse_slider (shift, scalestyle); } -CLICKED_BUTTON (menu, b_move_drones_lis) { +CLICKED_BUTTON (menu, movlis) { din0.start_moving_drones (); - TOGGLEMENU + TOGGLEMENU +} + +CLICKED_BUTTON (menu, raillis) { + _SELECTED_DRONES_EXIST_ + mouse_slider0.add (MENUP.raill1); + activate_mouse_slider (); +} + +MOUSED (menu, raillis1) { + din0.rail (dir, scl); +} + +AFTER_SLIDE(menu, raillis1) {} + +CLICKED_BUTTON (menu, strafelis) { + _SELECTED_DRONES_EXIST_ + mouse_slider0.add (MENUP.strafel1); + activate_mouse_slider (); +} + +MOUSED (menu, strafelis1) { + din0.strafe (dir, scl); } +AFTER_SLIDE(menu, strafelis1) {} + CLICKED_BUTTON (menu, b_set_xform_center_lis) { din0.calc_drones_centroid (); TOGGLEMENU @@ -4452,7 +4607,7 @@ MENU.cb_chuck.set_state (0,0); MENU.cb_defaults.set_state (0,0); cb.set_state (1, 0); - MENU.set_drone_params_items (27, 62); + MENU.set_drone_params_items (27, 72); } CLICKED_CHECKBUTTON (menu,cb_defaults_lis) { @@ -4461,7 +4616,7 @@ MENU.cb_motion.set_state (0,0); MENU.cb_chuck.set_state (0,0); cb.set_state (1, 0); - MENU.set_drone_params_items (62, 103); + MENU.set_drone_params_items (72, 116); } CLICKED_CHECKBUTTON (menu,cb_chuck_lis) { @@ -4470,7 +4625,7 @@ MENU.cb_motion.set_state (0,0); MENU.cb_defaults.set_state (0,0); cb.set_state (1, 0); - MENU.set_drone_params_items (103, 111); + MENU.set_drone_params_items (116, 124); } CLICKED_CHECKBUTTON (menu,cb_visual_lis) { @@ -4479,7 +4634,7 @@ MENU.cb_chuck.set_state (0,0); MENU.cb_defaults.set_state (0,0); cb.set_state (1, 0); - MENU.set_drone_params_items (111, DRONE_PARAMS_N); + MENU.set_drone_params_items (124, DRONE_PARAMS_N); } CLICKED_BUTTON (menu, b_abort_octave_shift_lis) { @@ -4605,43 +4760,6 @@ l.set_text (lbl[what]); } -void menu::autorott::setup () { - - title.set_text ("Auto rotate"); - which = VELOCITY; - whichl.option.set_text (" Velocity"); - mov.set_text ("Movement?"); - whichl.set_listener (this); - button* b[] = {&start, &stop, &toggle, &clockwise, &anticlockwise, &autoflip.set, &autoflip.unset, &autoflip.toggle, &smooth, &tick}; - const char* l [] = {"Start", "Stop", "Toggle", "Clockwise", "Anti-clockwise", "Set", "Unset", "Toggle", "Smooth", "Ticked"}; - click_listener* clk [] = {&startl, &stopl, &togl, &clkl, &aclkl, &autoflip.setl, &autoflip.unsetl, &autoflip.togl, this, this}; - for (int i = 0; i < 10; ++i) { - button& bi = *b[i]; - bi.set_text (l[i]); -#ifndef __WIDGET_MOVE__ - bi.set_listener (clk[i]); -#endif - } - - autoflip.lbl.set_text ("Auto flip"); - rpm.set ("RPM", 1.0f, 0.0f, MILLIONF, &rpml); - deg.set ("Degrees per Tick", 1.0f, -MILLIONF, MILLIONF, °l); - tps.set ("Ticks per Second", 1.0f, -MILLIONF, MILLIONF, &tpsl); - autoflip.angle.set (1.0f, 0.0f, MILLIONF, &autoflip.angl); - autoflip.angle.set_text ("Every", DEGREES); - -#ifdef __WIDGET_MOVE__ - widget* w[] = { - &title, &whichl, - &start, &stop, &toggle, - &mov, &smooth, &tick, - &rpm, °, &tps, &clockwise, &anticlockwise, - &autoflip.lbl, &autoflip.set, &autoflip.unset, &autoflip.toggle, &autoflip.angle, - 0 - }; - makehier (w); -#endif -} void menu::autorott::clicked (button& b) { if (&b == &smooth) { @@ -4668,6 +4786,79 @@ } } + +void menu::autorott::setup () { + + title.set_text ("Auto rotate"); + which = VELOCITY; + whichl.option.set_text (" Velocity"); + mov.set_text ("Movement?"); + whichl.set_listener (this); + { + button* b[] = {&start, &stop, &toggle, &clockwise, &anticlockwise, &smooth, &tick}; + static const char* l [] = {"Start", "Stop", "Toggle", "Clockwise", "Anti-clockwise", "Smooth", "Ticked"}; + click_listener* clk [] = {&startl, &stopl, &togl, &clkl, &aclkl, this, this}; + for (int i = 0; i < 7; ++i) { + button& bi = *b[i]; + bi.set_text (l[i]); +#ifndef __WIDGET_MOVE__ + bi.set_listener (clk[i]); +#endif + } + } + { + widget* af [] = {&autoflip.lbl, &autoflip.unset, &autoflip.set, &autoflip.toggle, &autoflip.angle, 0}; + widget* ap [] = {&autopause.lbl, &autopause.unset, &autopause.set, &autopause.toggle, &autopause.every, &autopause.f0r, 0}; + widget* rfp [] = {&rndflipause.whichl.option, &rndflipause.unset, &rndflipause.set, &rndflipause.toggle, 0}; + static const char* l [] = {"Unset", "Set", "Toggle"}; + for (int i = 0, j = 1; i < 3; ++i, ++j) { + button& bf = (button&) *af[j]; + button& bp = (button&) *ap[j]; + button& brfp = (button&) *rfp[j]; + bf.set_text (l[i]); + bp.set_text (l[i]); + brfp.set_text (l[i]); +#ifndef __WIDGET_MOVE__ + bf.id = bp.id = brfp.id = i; + bf.set_listener (&autoflip.sutl); + bp.set_listener (&autopause.sutl); + brfp.set_listener (&rndflipause.sutl); +#endif + } +#ifdef __WIDGET_MOVE__ + makehier (af); + makehier (ap); + makehier (rfp); +#endif + rndflipause.optl.picked (rndflipause.whichl.option, 0); + rndflipause.whichl.set_listener (&rndflipause.optl); + } + + rpm.set ("RPM", 1.0f, 0.0f, MILLIONF, &rpml); + deg.set ("Degrees per Tick", 1.0f, -MILLIONF, MILLIONF, °l); + tps.set ("Ticks per Second", 1.0f, -MILLIONF, MILLIONF, &tpsl); + autoflip.lbl.set_text ("Auto flip"); + autoflip.angle.set (1.0f, 0.0f, MILLIONF, &autoflip.angl); + autoflip.angle.set_text ("Every", DEGREES); + autopause.lbl.set_text ("Auto pause"); + autopause.every.set (0.1f, 0.0f, MILLIONF, &autopause.everyl); + autopause.f0r.set (0.1f, 0.0f, MILLIONF, &autopause.f0rl); + autopause.every.set_text ("Every", SECONDS); + autopause.f0r.set_text ("For", SECONDS); + +#ifdef __WIDGET_MOVE__ + widget* w[] = { + &title, &whichl, + &start, &stop, &toggle, + &mov, + &smooth, &tick, &clockwise, &anticlockwise, + &rpm, °, &tps, + 0 + }; + makehier (w); +#endif +} + void menu::defvelaccelui::setup () { whichl.set_listener (this); @@ -4678,6 +4869,8 @@ &autorotate.dps, &autorotate.tps, &autoflip.deg, + &autopause.every, + &autopause.f0r, }; const char* nam [] = { @@ -4685,7 +4878,9 @@ "RPM", "Degrees per Tick", "Ticks Per Second", - "Every" + "Every", // autoflip (degrees) + "Every", // autopause (seconds) + "For", }; change_listener* chgl [] = { @@ -4693,15 +4888,18 @@ &rpml, &dpsl, &tpsl, - °l + °l, + &everyl, + &f0rl }; - float mins [] = {0.0f, 0.0f, 0.0f, 1.0f, 0.0f}; + float mins [] = {0.0f, 0.0f, 0.0f, 1.0f, 0.0f, 0.0f, 0.0f}; + float dels [] = {1.0f, 1.0f, 1.0f, 1.0f, 1.0f, 0.01f, 0.01f}; - int nsp = 5; + int nsp = 7; for (int i = 0; i < nsp; ++i) { spinner2& spi = *sp[i]; - spi.set (nam[i], 1.0f, mins[i], MILLIONF, chgl[i]); + spi.set (nam[i], dels[i], mins[i], MILLIONF, chgl[i]); spi.lis[2] = &varl; spi.variance.cb.id = i; spi.variance.fld.id = i; @@ -4713,6 +4911,8 @@ clockwise.set_text ("Clockwise", DEGREES); anticlockwise.set_text ("Anti-clockwise", DEGREES); autoflip.deg.set_text ("Every", DEGREES); + autopause.every.set_text ("Every", SECONDS); + autopause.f0r.set_text ("For", SECONDS); ldir.set_text ("Direction"); odir.set_listener (&dirl); @@ -4723,10 +4923,11 @@ &autorotate.cb, &autorotate.uet.deg, &autorotate.uet.tps, - &autoflip.cb + &autoflip.cb, + &autopause.cb, }; - for (int i = 0, j = nsp; i < 6; ++i, ++j) { + for (int i = 0, j = 7; i < 7; ++i, ++j) { checkbutton& cbi = *cb[i]; cbi.id = j; cbi.set_listener (&chkl); @@ -4736,6 +4937,7 @@ #ifdef __WIDGET_MOVE__ autoflip.setup (); + autopause.setup (); widget* w[] = { &whichl, &mag, @@ -4765,11 +4967,13 @@ sync.set_state (cur->sync, 0); spinner2* sp [] = { - &MENU.dva.mag, - &MENU.dva.autorotate.rpm, - &MENU.dva.autorotate.dps, - &MENU.dva.autorotate.tps, - &MENU.dva.autoflip.deg, + MENUP.dva.mag, + MENUP.dva.autorotate.rpm, + MENUP.dva.autorotate.dps, + MENUP.dva.autorotate.tps, + MENUP.dva.autoflip.deg, + MENUP.dva.autopause.every, + MENUP.dva.autopause.f0r, }; valt* vt [] = { @@ -4778,9 +4982,11 @@ &cur->autos.rot.dps, &cur->autos.rot.tps, &cur->autos.flip.deg, + &cur->autos.pause.every, + &cur->autos.pause.f0r, }; - for (int i = 0; i < 5; ++i) { + for (int i = 0; i < 7; ++i) { spinner2& spi = *sp[i]; valt& vti = *vt[i]; spi.set_value (vti.val); @@ -4790,8 +4996,10 @@ } autorotate.load (); + autoflip.cb.set_state (cur->autos.flip.yes); + autopause.cb.set_state (cur->autos.pause.yes); } @@ -4802,11 +5010,13 @@ VALUE_CHANGED (menu::defvelaccelui, varlis) { spinner2* sp [] = { - &MENU.dva.mag, - &MENU.dva.autorotate.rpm, - &MENU.dva.autorotate.dps, - &MENU.dva.autorotate.tps, - &MENU.dva.autoflip.deg, + MENUP.dva.mag, + MENUP.dva.autorotate.rpm, + MENUP.dva.autorotate.dps, + MENUP.dva.autorotate.tps, + MENUP.dva.autoflip.deg, + MENUP.dva.autopause.every, + MENUP.dva.autopause.f0r, }; defvelaccel& dva = *MENU.dva.cur; @@ -4816,6 +5026,8 @@ &dva.autos.rot.dps, &dva.autos.rot.tps, &dva.autos.flip.deg, + &dva.autos.pause.every, + &dva.autos.pause.f0r, }; int id = f.id; @@ -4860,6 +5072,20 @@ cons << dva.name << " Auto flip every " << v << DEGREES << eol; } +VALUE_CHANGED (menu::defvelaccelui, everylis) { + float v = f; + defvelaccel& dva = getdva (); + dva.autos.pause.every = v; + cons << dva.name << " Auto pause every " << v << SECONDS << eol; +} + +VALUE_CHANGED (menu::defvelaccelui, f0rlis) { + float v = f; + defvelaccel& dva = getdva (); + dva.autos.pause.f0r = v; + cons << dva.name << " Auto pause for " << v << SECONDS << eol; +} + VALUE_CHANGED (menu::defvelaccelui, clocklis) { float v = float (f); MENU.dva.cur->clock = v; @@ -4924,12 +5150,15 @@ &dva.autos.rot.dps.rndrd, &dva.autos.rot.tps.rndrd, &dva.autos.flip.deg.rndrd, + &dva.autos.pause.every.rndrd, + &dva.autos.pause.f0r.rndrd, &dva.neg, &dva.rndrot, &dva.autos.rot.yes, &dva.autos.rot.uet.deg, &dva.autos.rot.uet.tps, &dva.autos.flip.yes, + &dva.autos.pause.yes, }; *val[cb.id] = cb.state; } @@ -4966,20 +5195,44 @@ din0.setautorotparam (MENU.autorotate.which, menu::autorott::TPS); } -CLICKED_BUTTON (menu::autorott::autoflipt, setlis) { - din0.setautoflip (MENU.autorotate.which, 1); +CLICKED_BUTTON (menu::autorott::autoflipt, sutlis) { + static int togs [] = {0, 0, 1}; + din0.setautoflip (MENU.autorotate.which, b.id, togs[b.id]); } -CLICKED_BUTTON (menu::autorott::autoflipt, unsetlis) { - din0.setautoflip (MENU.autorotate.which, 0); +VALUE_CHANGED (menu::autorott::autoflipt, anglis) { + din0.setautoflipangle (MENU.autorotate.which); } -CLICKED_BUTTON (menu::autorott::autoflipt, toglis) { - din0.setautoflip (MENU.autorotate.which, 0, 1); +VALUE_CHANGED (menu::autorott::autopauset, everylis) { + din0.setautopauseparam (MENU.autorotate.which, 0); } -VALUE_CHANGED (menu::autorott::autoflipt, anglis) { - din0.setautoflipangle (MENU.autorotate.which); +VALUE_CHANGED (menu::autorott::autopauset, f0rlis) { + din0.setautopauseparam (MENU.autorotate.which, 1); +} + +CLICKED_BUTTON (menu::autorott::autopauset, sutlis) { + static int togs[] = {0, 0, 1}; + din0.setautopause (MENU.autorotate.which, b.id, togs[b.id]); +} + +CLICKED_BUTTON (menu::autorott::rndflipauset, sutlis) { + static int togs[] = {0, 0, 1}; + menu::autorott& ar = MENU.autorotate; + din0.setrndflipause (ar.which, ar.rndflipause.which, b.id, togs[b.id]); +} + +PICKED_OPTION (menu::autorott::rndflipauset, rndflipauselis) { + static const char* opts [] = { + " Randomize Auto Flip Degrees", + " Randomize Auto Pause : Every", + " Randomize Auto Pause : For" + }; + int& which = MENU.autorotate.rndflipause.which; + which += dir; + wrap (0, which, 2); + MENU.autorotate.rndflipause.whichl.set_text (opts[which]); } PICKED_OPTION (menu, ol_add_wand_lis) { @@ -5133,6 +5386,8 @@ cb.set_state (rot.yes, 0); uet.deg.set_state (rot.uet.deg, 0); uet.tps.set_state (rot.uet.tps, 0); + static const char* diropts [] = {" Clockwise", " Anti clockwise", " Clockwise or Anti-clockwise"}; + static const char* movopts [] = {" Smooth", " Ticked", " Smooth or Ticked"}; dir.set_text (diropts[rot.dir]); mov.set_text (movopts[rot.mov]); } @@ -5146,6 +5401,16 @@ }; makehier (w); } + +void menu::defvelaccelui::autopauset::setup () { + widget* w[] = { + &cb, + &every, + &f0r, + 0 + }; + makehier (w); +} #endif PICKED_OPTION (menu::defvelaccelui::autorotatet, dirlis) { @@ -5159,8 +5424,8 @@ PICKED_OPTION (menu::defvelaccelui::autorotatet, movlis) { defvelaccel& dva = getdva (); dva.autos.rot.mov += dir; - wrap (autorotator::TICK, dva.autos.rot.mov, autorotator::RANDOM); - static const char* opts [] = {" Ticked", " Smooth", " Smooth or Ticked"}; + wrap (autorotator::SMOOTH, dva.autos.rot.mov, autorotator::RANDOM); + static const char* opts [] = {" Smooth", " Ticked", " Smooth or Ticked"}; l.set_text (opts[dva.autos.rot.mov]); } @@ -5169,11 +5434,6 @@ dva.autos.rot.yes = cb.state; } -CLICKED_CHECKBUTTON (menu::defvelaccelui::autoflipt, chklis) { - defvelaccel& dva = getdva (); - dva.autos.flip.yes = cb.state; -} - drone::bouncet::bouncet () { n = 0; max = -1; @@ -5231,3 +5491,40 @@ CLICKED_BUTTON (menu, am2fm2amlis) { din0.set_drone_am2fm2am_bpm (b.id); } + + +CLICKED_CHECKBUTTON (menu, curveslistl) { + if (!CRVED->setcrvvis (cb.id, cb.state)) cb.turn_on (DONT_CALL_LISTENER); +} + +void curve_editor::setup_tools_menu () { + curve_info& ci = curveinfo [curcrv]; + multi_curve* crv = ci.curve; + MENU.sp_curve_rpm.set_value (ci.lastrpm); + MENU.sp_curve_every.variance.cb.set_state (ci.randoflip); + MENU.sp_curve_every.variance.rd = ci.rd; + MENU.sp_curve_every.variance.setfld (); + MENU.sp_curve_every.set_value (ci.every0.deg); + MENU.cb_ed_autoflip.set_state (ci.autoflip); + MENU.lf_curve_name.set_text (crv->name); + MENU.sp_curve_limit.set_value (crv->limit); + MENU.picked (MENU.ol_mirror.option, 0); + set_curve_style (crv); + curcrvchgd = 0; +} + + +PICKED_OPTION (menu, moverailstrafelis) { + static const char* opts [] = {" Move", " Rail", " Strafe"}; + click_listener* clk [] = {MENUP.bmdl, MENUP.raill, MENUP.strafel}; + int& id = MENU.moverailstrafe.id; + button& option = MENU.moverailstrafe.option; + id += dir; + wrap (0, id, 2); + option.set_text (opts[id]); + LISTEN(option, clk[id]); + static widget* w[] = {MENUP.b_scale_drones, MENUP.b_rotate_drones, MENUP.b_set_xform_center, MENUP.b_freeze_drones, MENUP.b_thaw_drones}; + static const int xspc = 15; + int dx = MENU.moverailstrafe.option.extents.right + xspc - MENU.b_scale_drones.extents.left; + for (int i = 0; i < 5; ++i) w[i]->move(dx, 0); +} diff -Nru din-55/src/menu.h din-56/src/menu.h --- din-55/src/menu.h 2022-09-04 09:26:30.000000000 +0000 +++ din-56/src/menu.h 2022-12-19 16:07:56.000000000 +0000 @@ -258,7 +258,7 @@ DECL_CLICK_LISTENER (misc_listener) -#define DRONE_PARAMS_N 133 +#define DRONE_PARAMS_N 146 #define DECL_DRONE_PARAMS \ widget* wdrone_params [] = { \ &sp_drone_master_vol,\ @@ -301,11 +301,21 @@ &autorotate.mov,\ &autorotate.smooth,\ &autorotate.tick,\ - &autorotate.autoflip.lbl,\ &autorotate.autoflip.angle,\ + &autorotate.autoflip.lbl,\ &autorotate.autoflip.set,\ &autorotate.autoflip.unset,\ &autorotate.autoflip.toggle,\ + &autorotate.autopause.lbl,\ + &autorotate.autopause.set,\ + &autorotate.autopause.unset,\ + &autorotate.autopause.toggle,\ + &autorotate.autopause.every,\ + &autorotate.autopause.f0r,\ + &autorotate.rndflipause.whichl,\ + &autorotate.rndflipause.set,\ + &autorotate.rndflipause.unset,\ + &autorotate.rndflipause.toggle,\ &sva.lbl,\ &sva.whats,\ &sva.neg,\ @@ -350,6 +360,9 @@ &dva.autorotate.uet.tps,\ &dva.autoflip.cb,\ &dva.autoflip.deg,\ + &dva.autopause.cb,\ + &dva.autopause.every,\ + &dva.autopause.f0r,\ &anchored,\ &dronearrowdefaults.lbl,\ &dronearrowdefaults.neck,\ @@ -418,7 +431,7 @@ , cb_file, cb_instrument, cb_editors, cb_parameters, cb_mkb_drone_tools, \ cb_mkb_drone_params, cb_mkb_voice, cb_mkb_ranges, cb_mkb_misc, \ cb_ed_tools, cb_mon_parameters, cb_mon_tools, cb_mon_misc, cb_mon_boxops, \ - cb_mon_ballops, cb_binaural_drones_tools, cb_binaural_drones_edit\ + cb_mon_ballops, cb_binaural_drones_tools, cb_binaural_drones_edit, cb_ed_curves\ , cb_label_vertices\ , cb_mark_segments\ , cb_selection_only\ @@ -447,16 +460,17 @@ , b_microtonal_keyboard, b_keyboard_keyboard, b_mondrian, b_binaural_drones\ , cb_show_anchors, cb_show_vel, cb_show_accel, cb_show_gravity, cb_conn_wrap\ , cb_modulation, cb_motion, cb_visual, cb_defaults, cb_chuck, choutline, chautoresettrails\ - , trackcon, velgt0, accelgt0; + , trackcon, velgt0, accelgt0, cb_ed_autoflip; MAKE_STATE_LISTENER (cb_conn_wrap_lis, wrapl) MAKE_STATE_LISTENER (autoresettrailslis, aurl) + MAKE_STATE_LISTENER (curveslistl, curvesl) button \ bbd_select_all, bbd_select_none, bbd_invert_select, bbd_select, bbd_select2, bbd_sync, bbd_delete, bbd_modulate, bbd_flip\ , b_create_binaurals_on_notes, b_create_binaurals_from_pitch\ , b_pick_curve, b_swap_curves, b_insert_vertex, b_delete_vertex, b_undo, b_redo, b_copy, b_paste, b_fold_tangents, b_unfold_tangents\ - , b_draw_replacement_curve, b_add_curve, b_replace_curve, b_delete_curve, b_start_capture, b_assign_capture, b_stop_rotating\ + , b_draw_replacement_curve, b_add_curve, b_replace_curve, b_delete_curve, b_start_capture, b_assign_capture, b_stop_rotating, ed_flip_rotation\ , b_turn_off_ui, b_exit_din, b_clear_record\ , b_save, b_close\ , l_draw_ball, b_add_balls, b_move_selected_balls, b_select_all_targets, b_invert_selected_targets\ @@ -487,7 +501,7 @@ , b_set_to_mesh_cols\ , b_set_to_mesh_rows\ , b_record_phrase, b_clear_phrases\ - , b_move_drones, b_delete_drones\ + , b_delete_drones\ , b_select_all_drones, b_invert_drone_selection\ , balloon\ , b_select_launchers\ @@ -502,7 +516,7 @@ b_arrow_reset, b_mute, b_unmute, drone2noise, noise2drone,\ immortalize, mortalize, reincarnate,\ chuck, chflip, chtog, edlife2vel,\ - b_snapx, b_snapy, b_snapboth, b_snapnone, am2fm, fm2am; + b_snapx, b_snapy, b_snapboth, b_snapnone, am2fm, fm2am, ed_autoflip_reset; MAKE_CLICK_LISTENER(am2fm2amlis, am2fm2aml) @@ -658,7 +672,7 @@ , sp_wand_dist, chtrail, dpl; spinner2 handlesize, trailsize, sp_bounces, sp_rebound, gens, dpm, ddpl; - spinner2 lifetime, gabt, riset, fallt; + spinner2 lifetime, gabt, riset, fallt, sp_curve_every; MAKE_FIELD_LISTENER(genslis, gensl) MAKE_FIELD_LISTENER(ddpmlis, ddpml) @@ -701,13 +715,21 @@ , ol_color\ , ol_add_wand\ , ol_drones_are\ - , anchored; + , anchored\ + , moverailstrafe; MAKE_OPTION_LISTENER (ol_color_lis, ocoll) MAKE_OPTION_LISTENER (ol_add_wand_lis, awdl) MAKE_OPTION_LISTENER (ol_drones_are_lis, darl) MAKE_OPTION_LISTENER (anchoredl, ancl) + MAKE_OPTION_LISTENER (moverailstrafelis, mrsl) + MAKE_CLICK_LISTENER(movlis, bmdl) + MAKE_CLICK_LISTENER(raillis, raill) + MAKE_MOUSE_SLIDER_LISTENER (raillis1, raill1) + MAKE_CLICK_LISTENER(strafelis, strafel) + MAKE_MOUSE_SLIDER_LISTENER (strafelis1, strafel1) + octave_shift_listener osl; style_listener gater_style_lis; @@ -726,7 +748,6 @@ style_listener am_style_lis, fm_style_lis; MAKE_CLICK_LISTENER(b_set_unset_toggle_lis, sutl) MAKE_CLICK_LISTENER(b_scale_drones_lis, bsdl) - MAKE_CLICK_LISTENER(b_move_drones_lis, bmdl) MAKE_CLICK_LISTENER(b_move_drones_under_gravity_lis, dugl) MAKE_MOUSE_SLIDER_LISTENER(ms_scale_drones_lis, ms_sdl) MAKE_CLICK_LISTENER(b_rotate_drones_lis, brdl) @@ -855,7 +876,7 @@ std::map< checkbutton*, std::vector > tab_members; checkbutton *last_tab, *cur_tab, *next_tab; void setup_tabs (ui* scr); - void setup_tabs (checkbutton** tl, int n, int clear = 0); + void setup_tabs (checkbutton** tl, int clear = 0); void add_to_tab (checkbutton* cb, widget* w); void remove_from_tab (checkbutton* cb, widget* w); void position_tabs (); @@ -885,7 +906,7 @@ void changed (tap_display& tb); void picked (label& lbl, int dir); - static const int nitems = 495; + static const int nitems = 513; static const int n_inst_ed = 28; widget* items [nitems]; void loadspinners (); @@ -919,6 +940,9 @@ ~menu (); + void populatecurvestab (curve_editor* ed); + void destroycurvestab (); + struct autorott : option_listener, click_listener { label title; @@ -953,15 +977,37 @@ void clicked (button& b); struct autoflipt { + label lbl; button set, unset, toggle; + MAKE_CLICK_LISTENER(sutlis, sutl) + spinner angle; - MAKE_CLICK_LISTENER(setlis, setl) - MAKE_CLICK_LISTENER(unsetlis, unsetl) - MAKE_CLICK_LISTENER(toglis, togl) MAKE_FIELD_LISTENER (anglis, angl) + } autoflip; + struct autopauset { + + label lbl; + button set, unset, toggle; + MAKE_CLICK_LISTENER(sutlis, sutl) + + spinner every, f0r; + MAKE_FIELD_LISTENER (everylis, everyl) + MAKE_FIELD_LISTENER (f0rlis, f0rl) + + } autopause; + + struct rndflipauset { + button set, unset, toggle; + MAKE_CLICK_LISTENER(sutlis, sutl) + int which; + options_list whichl; + MAKE_OPTION_LISTENER (rndflipauselis, optl) + rndflipauset() : which (0) {} + } rndflipause; + } autorotate; @@ -992,9 +1038,7 @@ spinner2 mag; spinner clockwise, anticlockwise; checkbutton neg; - checkbutton randomize; - checkbutton sync; void checksync (float v, anglet& t, spinner& sp); @@ -1016,13 +1060,21 @@ struct autoflipt { checkbutton cb; - MAKE_STATE_LISTENER (chklis, chkl) spinner2 deg; #ifdef __WIDGET_MOVE__ void setup (); #endif } autoflip; + struct autopauset { + checkbutton cb; + spinner2 every; + spinner2 f0r; +#ifdef __WIDGET_MOVE__ + void setup (); +#endif + } autopause; + void picked (label&, int); MAKE_OPTION_LISTENER (dirlis, dirl) MAKE_FIELD_LISTENER (maglis, magl) @@ -1030,6 +1082,8 @@ MAKE_FIELD_LISTENER (dpslis, dpsl) MAKE_FIELD_LISTENER (tpslis, tpsl) MAKE_FIELD_LISTENER (deglis, degl) + MAKE_FIELD_LISTENER (everylis, everyl) + MAKE_FIELD_LISTENER (f0rlis, f0rl) MAKE_FIELD_LISTENER (varlis, varl) MAKE_STATE_LISTENER (chklis, chkl) MAKE_FIELD_LISTENER (clocklis, clockl) diff -Nru din-55/src/morse_code.cc din-56/src/morse_code.cc --- din-55/src/morse_code.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/morse_code.cc 2022-10-09 08:23:51.000000000 +0000 @@ -165,7 +165,7 @@ point vlast (m.vertices[last]); float factor = 1.0f; - if (vlast.x != 0); factor = tox / vlast.x; + if (vlast.x != 0) ; else factor = tox / vlast.x; for (int i = 0; i < n; ++i) { diff -Nru din-55/src/multi_curve.cc din-56/src/multi_curve.cc --- din-55/src/multi_curve.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/multi_curve.cc 2022-10-26 14:59:55.000000000 +0000 @@ -43,12 +43,7 @@ limit = 0.001f; shapeform = 0; - - centroid_style = CALC; - scx = 0.5f; - scy = 0.0f; - cx = scx; - cy = scy; + cx = cy = 0.0f; } @@ -250,17 +245,6 @@ } } -void multi_curve::calc_centroid () { - if (centroid_style == SET) { - cx = scx; - cy = scy; - } else { - box b; calc_bbox (b); - cx = (b.left + b.right) / 2.; - cy = (b.bottom + b.top) / 2.; - } -} - void multi_curve::calc_bbox (box& b) { int num_curves = curv.size (); if (num_curves) { @@ -323,6 +307,7 @@ set_color (ir, ig, ib); file >> ignore >> shapeform; + setcentroid (shapeform); point& lt0 = left_tangents[0]; point& v0 = vertices[0]; @@ -434,13 +419,20 @@ if (shapeform) return curv[i].dpts; else return curv[i].vpts; } +void multi_curve::setcentroid (int shapeform) { + static const float CX [] = {0.0f, 0.5f}; + cx = CX[shapeform]; + cy = 0.0f; +} + void multi_curve::set_shapeform (int what) { shapeform = what; + setcentroid (shapeform); require_eval (); evaluate (); } -void multi_curve::rotate (float angle) { // rotate curve about centroid +void multi_curve::rotate (float angle) { for (int i = 0; i < num_vertices; ++i) { point& vi = vertices[i]; point& lt = left_tangents[i]; diff -Nru din-55/src/multi_curve.h din-56/src/multi_curve.h --- din-55/src/multi_curve.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/multi_curve.h 2022-10-26 14:59:48.000000000 +0000 @@ -57,6 +57,7 @@ void set_limit (float d); int shapeform; // shapeform? + void setcentroid (int _shapeform); void set_shapeform (int yesno); void check_shapeform (); void get_xy (double d, float& x, float& y); @@ -70,12 +71,7 @@ int get_total_points (); // xform - enum {SET=1, CALC}; - int centroid_style; - float scx, scy; // set centroid - float cx, cy; // calced centroid - void calc_centroid (); - inline void set_centroid (float x, float y) { cx = x; cy = y; } + float cx, cy; // centroid void calc_bbox (box& b); void rotate (point& p, float angle); void rotate (float angle); diff -Nru din-55/src/options_list.h din-56/src/options_list.h --- din-55/src/options_list.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/options_list.h 2022-11-28 09:57:55.000000000 +0000 @@ -37,10 +37,8 @@ option_listener* olis; options_list (int show_apply = 0) { - option.add_child (this); - option.add_child (&left); - option.add_child (&right); - option.add_child (&apply); + widget* w[] = {&option, this, &left, &right, &apply, 0}; + makefam (w); left.set_dir (arrow_button::left); right.set_dir (arrow_button::right); left.set_listener (this); diff -Nru din-55/src/plugin.cc din-56/src/plugin.cc --- din-55/src/plugin.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/plugin.cc 2022-10-18 21:35:06.000000000 +0000 @@ -84,7 +84,6 @@ } void plugin::try_auto_apply () { - //if (cb_auto_apply.state) uis.crved->apply_plugin (this); if (cb_auto_apply.state) ed->apply_plugin (this); } diff -Nru din-55/src/point_modulator.cc din-56/src/point_modulator.cc --- din-55/src/point_modulator.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/point_modulator.cc 2022-11-01 20:36:37.000000000 +0000 @@ -395,25 +395,26 @@ state_button* sb = md.sb; if (sb->visible) sb->draw (); } - glEnable (GL_LINE_STIPPLE); - glLineStipple (1, 0xf00f); - for (int i = 0; i < nlst; ++i) { - mod_dat& md = lst[i]; - state_button* sb = md.sb; - const point& p = md.hit.get (); - int vx, vy; ed->obj2view (p.x, p.y, vx, vy); - if (sb->state) glColor3f (0, 1, 0); else glColor3f (1, 0, 0); - glBegin (GL_LINES); - glVertex2i (vx, vy); - glVertex2i (sb->extents.midx, sb->extents.midy); - glEnd (); - } - glDisable (GL_LINE_STIPPLE); } else { fold.draw (); title.draw (); } + glEnable (GL_LINE_STIPPLE); + glLineStipple (1, 0xf00f); + for (int i = 0; i < nlst; ++i) { + mod_dat& md = lst[i]; + state_button* sb = md.sb; + const point& p = md.hit.get (); + int vx, vy; ed->obj2view (p.x, p.y, vx, vy); + if (sb->state) glColor3f (0, 1, 0); else glColor3f (1, 0, 0); + glBegin (GL_LINES); + glVertex2i (vx, vy); + glVertex2i (sb->extents.midx, sb->extents.midy); + glEnd (); + } + glDisable (GL_LINE_STIPPLE); + } void point_modulator::moved () { @@ -453,7 +454,7 @@ void point_modulator::bg () { if (nlst) { - int ncrvs = ed->num_curves; + int ncrvs = ed->curves; int evals [ncrvs]; int nevals = 0; for (int i = 0; i < nlst; ++i) { diff -Nru din-55/src/sine_mixer.cc din-56/src/sine_mixer.cc --- din-55/src/sine_mixer.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/sine_mixer.cc 2022-11-09 19:28:00.000000000 +0000 @@ -44,6 +44,8 @@ static const float fac = 0.6; phase.set_color (1.0f - fac * harms.clr.r, 1.0f - fac * harms.clr.g, 1.0f - fac * harms.clr.b); paintphase = 0; + + titlemoving = 0; } void sine_mixer::load_params () { @@ -139,7 +141,7 @@ for (int i = 0; i < ns; ++i) { point& ni = norm[i]; point& pi = points[i]; - pi.x = ni.x; + pi.x = 0.5f + ni.x; // shapeforms centered at 0.5, 0 pi.y = ni.y; } } else { @@ -178,7 +180,7 @@ load_params (); - sp_points.set ("Points", 1, 1, MILLION, this, 0); + sp_points.set ("Points", 1, 0, MILLION, this, 0); sp_points.set_value (num_points); cb_make_shapeform.set_text ("Make shapeform"); @@ -356,3 +358,21 @@ plb->szr.setpos2 (pla->szr); plb->moved (); } + +MOVESTART (sine_mixer, szrmov) { + if (uis.plugin__browser.l_title.movr.move) { + sine_mixer* sm = (sine_mixer*) data; + sm->titlemoving = 1; + sm->harms.szr.movlis = 0; + sm->phase.szr.movlis = 0; + } +} + +MOVEEND (sine_mixer, szrmov) { + sine_mixer* sm = (sine_mixer*) data; + if (sm->titlemoving) { + sm->titlemoving = 0; + sm->harms.szr.movlis = &sm->szm; + sm->phase.szr.movlis = &sm->szm; + } +} diff -Nru din-55/src/sine_mixer.h din-56/src/sine_mixer.h --- din-55/src/sine_mixer.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/sine_mixer.h 2022-11-09 19:21:47.000000000 +0000 @@ -104,6 +104,8 @@ int handle_input (); int paintphase; + + int titlemoving; MAKE_MOVE_LISTENER (szrmov, szm) }; diff -Nru din-55/src/solver.cc din-56/src/solver.cc --- din-55/src/solver.cc 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/solver.cc 2022-11-09 19:36:38.000000000 +0000 @@ -41,7 +41,7 @@ } void solver::update () { - + // curve valid? vector& curv = mcrv->curv; ncurvs = curv.size (); @@ -109,29 +109,16 @@ for (int p = 0; p < q; ++p) { x += (mod[p] + dx); check (x, dx, xmin, xmax); - - /*if (x < startx) { - if (!searchleft (x)) xmin (*this, x, dx); - } else if (x > endx) { - if (!searchright (x)) xmax (*this, x, dx); - }*/ - y[p] = ycomp + m * x; } } void solver::operator() (float& x, float* pdx, int q, float* mod, float* y, xhandler& xmin, xhandler& xmax) { + float dx; for (int p = 0; p < q; ++p) { - float dx = pdx[p]; + dx = pdx[p]; x += (mod[p] + dx); check (x, dx, xmin, xmax); - - /*if (x < startx) { - if (!searchleft (x)) xmin (*this, x, dx); - } else if (x > endx) { - if (!searchright (x)) xmax (*this, x, dx); - }*/ - y[p] = ycomp + m * x; } } @@ -141,13 +128,6 @@ for (int p = 0; p < q; ++p) { x += dx; check (x, dx, xmin, xmax); - - /*if (x < startx) { - if (!searchleft (x)) xmin (*this, x, dx); - } else if (x > endx) { - if (!searchright (x)) xmax (*this, x, dx); - }*/ - y[p] = ycomp + m * x; } } @@ -159,13 +139,6 @@ dx = pdx[p]; x += dx; check (x, dx, xmin, xmax); - - /*if (x < startx) { - if (!searchleft (x)) xmin (*this, x, dx); - } else if (x > endx) { - if (!searchright (x)) xmax (*this, x, dx); - }*/ - y[p] = ycomp + m * x; } } @@ -176,13 +149,6 @@ for (int p = 0; p < q; ++p) { x = ax[p]; check (x, dx, xmin, xmax); - - /*if (x < startx) { - if (!searchleft (x)) xmin (*this, x, dx); - } else if (x > endx) { - if (!searchright (x)) xmax (*this, x, dx); - }*/ - ax[p] = ycomp + m * x; } } @@ -240,11 +206,17 @@ int solver::findseg (float x) { int fcurv = 0, fseg = 0, nsegs = numsegs (fcurv); while (1) { - if (seg_lte_right (x, fcurv, fseg)) return 1; else { + if (seg_lte_right (x, fcurv, fseg)) + return 1; + else { ++fseg; if (fseg >= nsegs) { - if (++fcurv >= ncurvs) { - setseg (ncurvs - 1, nsegs - 1); + if (++fcurv >= ncurvs) { + // bad news + // setseg (ncurvs - 1, nsegs - 1); + // setseg (0, 0); + ycomp = 0; + m = 0; break; } fseg = 0; diff -Nru din-55/src/spinner2.h din-56/src/spinner2.h --- din-55/src/spinner2.h 2022-01-12 14:13:08.000000000 +0000 +++ din-56/src/spinner2.h 2022-11-25 08:49:03.000000000 +0000 @@ -159,6 +159,10 @@ } } variance; + T variedval () { + return variance.rd () * value; + } + int limits; T lo, hi; diff -Nru din-55/src/spinner.h din-56/src/spinner.h --- din-55/src/spinner.h 2022-01-12 04:04:49.000000000 +0000 +++ din-56/src/spinner.h 2022-11-02 16:15:14.000000000 +0000 @@ -240,8 +240,9 @@ int i = 0; if (draw_more == 0 || variance.ui == 0) i = 1; widget* w [] = {&variance.cb, &lbl, &dec, &inc, &f_value, &more, &l_delta, &f_delta, &variance.lbl, &variance.fld}; - int xshift [] = {0, 0, 0, -1, 0, -1, 5, 1, 0, 0}; - int lft [] = {0, 0, fnt.lift, fnt.lift, 0, fnt.lift, 0, 0, 0, 0}; + int xshift [] = {0, 0, 0, -1, 0, 0, SPACING, 1, 0, 0}; + int fl = fnt.lift+1; + int lft [] = {0, 0, fl, fl, 0, fl, 0, 0, 0, 0}; for (; i < 10; ++i) { x += xshift [i]; widget* wi = w[i]; @@ -464,7 +465,7 @@ } T operator() (float dirdelta) { - float var = 1; + float var = 1.0f; if (variance.cb.state) var += variance.rd (); return dirdelta * var; } diff -Nru din-55/src/ui.cc din-56/src/ui.cc --- din-55/src/ui.cc 2022-06-06 20:16:46.000000000 +0000 +++ din-56/src/ui.cc 2022-11-09 19:29:42.000000000 +0000 @@ -22,7 +22,6 @@ #include "capturer.h" #include "fractaliser.h" #include "warper.h" -#include "recorder.h" #include "mondrian.h" #include "binaural_drones.h" #include "spiraler.h" @@ -403,7 +402,7 @@ } void ui_list::dofft () { - if (crved && crved->num_curves && !fft0.folded ()) fft0.go (crved->curveinfo[0].curve); + if (!fft0.folded () && crved == current) fft0.go (crved->curveinfo[0].curve); } void fade_button_listener::after_fade (fader& f) { @@ -542,7 +541,7 @@ } else { ab_fold.set_dir (arrow_button::down); l_title.show (); - uis.dofft (); + fft0.go (uis.crved->curveinfo[0].curve); } } @@ -620,13 +619,13 @@ int ret = 1; if (UI_OFF) turn_on_ui (); + else if (mouse_slider0.deactivate ()) ; + else if (current->ed) ret = current->esc(); else if (mkb_selector()) mkb_selector.abort (); else if (mon_selector()) mon_selector.abort (); - else if (mouse_slider0.deactivate ()) ; else if (esc_octave_shift (get_current_instrument())); else if (main_menu.b_close.visible) main_menu.b_close.call_listener (); else if (main_menu.show) main_menu.toggle (); - else if (current->ed) ret = current->esc(); else if (current == &din0) { if (din0.gab.n) din0.gab.abort (); else if (din0.moving_drones) din0.toggle_moving_drones (); diff -Nru din-55/src/widget.cc din-56/src/widget.cc --- din-55/src/widget.cc 2022-03-17 07:09:10.000000000 +0000 +++ din-56/src/widget.cc 2022-11-28 08:28:14.000000000 +0000 @@ -127,11 +127,9 @@ } void widget::move (int dx, int dy, int mc) { - if (mc) { // move children - if (numchil) for (int i = 0; i < numchil; ++i) children[i]->move (dx, dy); - } + if (mc && numchil) + for (int i = 0; i < numchil; ++i) children[i]->move (dx, dy); set_pos (posx + dx, posy + dy); - if (movlis) movlis->moved (); } void widget::show () { @@ -182,11 +180,15 @@ move = 0; widget::focus = 0; ret = 1; + move_listener* wm = w->movlis; + if (wm) wm->endmove (); } else if (w->hover) { move = 1; widget::focus = w; prevx = mousex; prevy = mouseyy; + move_listener* wm = w->movlis; + if (wm) wm->movestart (); ret = 1; } mb_clicked = 1; @@ -201,6 +203,8 @@ else w->move (dx, dy); prevx = mousex; prevy = mouseyy; + move_listener* wm = w->movlis; + if (wm) wm->moved (); ret = 1; } mb_clicked = 0; @@ -305,7 +309,7 @@ widget* p = wa[0]; for (widget** q = ++wa;;) { widget* c = *q++; - if (c == 0) break; else p->add_child(c); + if (c) p->add_child (c); else break; } } diff -Nru din-55/src/widget.h din-56/src/widget.h --- din-55/src/widget.h 2022-03-17 07:16:22.000000000 +0000 +++ din-56/src/widget.h 2022-11-27 07:44:24.000000000 +0000 @@ -38,6 +38,8 @@ struct move_listener : voiddata { virtual void moved () = 0; + virtual void movestart () {} + virtual void endmove () {} }; struct nullt { @@ -45,13 +47,15 @@ nullt () : null(0) {} }; -#define MAKE_MOVE_LISTENER(name,var) struct name : move_listener { void moved (); } ; name var; +#define MAKE_MOVE_LISTENER(name,var) struct name : move_listener { void movestart (); void moved (); void endmove (); } ; name var; #define MOVED(scope,name) void scope::name::moved () +#define MOVESTART(scope,name) void scope::name::movestart () +#define MOVEEND(scope,name) void scope::name::endmove () struct mover { - widget* w; // target widget + widget* w; // widget moved int* pmb; // mouse button that moves widget - int mb_clicked; // is mouse button clicked + int mb_clicked; // is that mouse button clicked int move; // 1 - widget is moving, 0 - not int prevx, prevy; // previous mouse position mover (widget* ww, int* pb = &lmb);