SHCdyna

Introduction

SHCdyna is a dynamic and interactive application for musical performance. It allows you to compile and execute code in the Faust programming language dynamically, interact with motion sensors, and create personalized tactile user interfaces.


Features

Dynamic Compilation

  • Description: Compile and run Faust code in real time for a dynamic and interactive musical performance.
  • Advantages: Easily switch from one Faust piece to another from the application, improving the flexibility and creativity of composition and musical performance.Language Faust: Faust

Creation of user interface: “touchUI”

  • Description: Create multitouch screen-based user interfaces for a personalized, intuitive and expressive music experience.

“touchUI” declaration format

In your .dsp file, declare the necessary [touchUI] interface via metadata, which will be positioned on the screen. [touchUI] interface types include standard types and special functions.

Metadata format [touchUI]:

[touchUI:TabTitle Type X Y W H R G B A]
  • TabTitle: [touchUI] can be put in multiple tabs or the same tab if they have the same title.

  • X Y W H R G B A:

    X Y : position in % of a point of the rectangle (top and left);

    W H : width height in % of the rectangle;

    R G B A : color and transparency of the rectangle [0-255]

  • Available “touchUI” types:

    • Standard UI:
      • button: pressed -> sends 1 and automatically returns to 0
      • checkbox: toggle state 0 or 1
      • hslider: horizontal movement in UI, scale from MIN to MAX
      • vslider: vertical movement in UI, scale from MIN to MAX
    • Special UI:
      • trigCounter: “button” type trigger, increment of a counter in a loop
      • pad: sends 1 if touched and X Y coordinates of position (X and Y coordinates sent to declared parameters with path extension _x/_y)
      • setRef: “button” type for initialization of angular coordinates “set Ref” (rotation matrix)
    • UI Cue system:
      • touchCueManager: default view list from 1 to 10, editable.
      • trigCue: type “button”, to advance in the “touchCueManager” list.

      • nextCue: type “button”, to advance the positioning in the “touchCueManager” list triggered at the next “trigCue”.

      • prevCue: type “button”, to move back the positioning in the list “touchCueManager” triggered at the next “trigCue”.

      • initCue: type “button”, to initialize the positioning in the “touchCueManager” list instantly.

// Example UI standard
  on_off = checkbox("[1]OnOff [touchUI:DEMO checkbox 0 0 50 50 255 0 255 255]");
// Example UI speciale
  touch01X = hslider("Pad1_X",0,0,1,0.001);
  touch01Y = hslider("Pad1_Y",0,0,1,0.001);
  touchGate01 = checkbox("Pad1 [touchUI: DEMO pad 0 0 50 50 0 255 255 200]");
// Example cue system
  select_sample = nentry("cue [touchUI:DEMO trigCue 50 0 50 30 255 0 0 255] [touchCueManager: {1:'Your sample1';2:'Your sample2';3:'Your sample3'}]", 1, 1, 3, 1);
  trigNextCue = button("goNext [touchUI: DEMO nextCue 50 30 50 30 255 255 0 150]");
  trigPrevCue = button("goPrev [touchUI: DEMO prevCue 0 30 50 30 255 255 0 150]");
  trigInitCue = button("initCue [touchUI: DEMO initCue 50 60 50 30 255 255 255 150]");

Motion capture: “motion.lib”

  • Description: Create interactions via motion sensors built into iOS. These descriptors can be used to modulate various audio parameters based on user movements.

  • Available types “motion.lib”: Inclinations, shock, rotation speed, angular captures…

“motion.lib” declaration format

In your .dsp file, declare the motion controllers you need, as follows:

//Support for «motion.lib»
  titi = hslider("titi[motion:ixp]",0,0,1,0.01);
  toto = hslider("toto[motion:totalMotion]",0,0,1,0.01);
  tata = hslider("tata[motion:totalaccel]",0,0,1,0.01);

Configuring “motion.lib” settings

Double-click “Setting” to configure the “motion.lib” settings from the application.

Gestion de communication : « osc »

  • Description: Permettre une interaction et un contrôle à distance des paramètres audio depuis d’autres applications musicales ou vice versa. Le protocole OSC (Open Sound Control) est utilisé pour la communication réseau entre les applications musicales.

“osc” declaration format

In your .dsp file, declare the necessary [osc:] interface in the metadata: Faust OSC web

//Support « osc »
touchGate = checkbox("SHC_Pad [touchUI: DEMO pad 0 0 100 100 0 255 0 200] [osc:/touchgate]");

Cofiguration « osc »

Make sure your iOS device is connected to the same network as your computer for example. Double-click “Setting” to configure OSC settings from the application.

Additional display of parameters: « showName »

  • Description: Display to adjust some parameters via setting user interface.

“showName” declaration format

In your .dsp file, declare the necessary [showName:] interface in the metadata:

//Support « showName »
parameter = nentry("UIparamName [showName:paramName]", def, min, max, step);

Configuration « showName »

Double-click “Setting” to configure the settings from the application.


Installation

Download and install the SHCdyna app from the App Store. App Strore: App Strore SHCdyna


Use

Integrated parts

  1. Double-click “Piece.”
  2. Double-click the SmartFaust piece to select it and play.

Nota:

  • You cannot delete built-in parts.

Create your instrument

  1. Prepare your “your Instrument.dsp” programmed in Faust language.
  2. Directly compress all source files (sounds, libraries) into a .zip file
  3. Rename this file to “yourInstrument.FaustPiece”
  4. Utilisez AirDrop pour transférer le fichier.
  5. Double-click “Load” to find and load your .FaustPiece from SHCdyna.
  6. Double-click the piece in the menu to play or delete.

Nota:

  • Make sure your .FaustPiece contains at least one “yourInstrument.dsp” file with the same name as the .zip file
  • No spaces in the name of your .FaustPiece, built-in part names are not allowed.
  • Be careful to maintain consistency in names when keeping old files.
  • The application will notify you of any problems encountered while verifying the file.

Demo

  • Example_1 sinusoide:

    • 2 Sinusoides: “freq” & “vol” controlled by SHCdyna motion and touchUI
    • video: DEMO
    • FAUST code : sinusoide.dsp
    •  Screenshot of Example_1
  • Example_2 SoloDemo_touchUI_Cue:

    • 3 sound generators(Sinusoide, Wind, Rain): controlled by SHCdyna Cue System and touchUI
    • FAUST  code: SoloDemo_touchUI_Cue.dsp
    •  Screenshot of Example_2_1 Screenshot of Example_2_2

More information

The SHCdyna application is the continuation of the Open Source project ‘faust2smartphone’. ‘faust2smartphone’ allows you to generate standalone iOS/Android applications for Smart Hand Computer from the same code used for SHCdyna.

SHCdyna is currently not available for Android.

Github site faust2smartphone: faust2smartphone

Contact: For any questions or technical support, please contact the LiSiLoG development team

Developers: Allen Weng & Christophe Lebreton