Karya, built on 2018-05-31T02:46:59 (patch 0a1a35479c514820d77330ae8a978975ba22a47a)

Safe HaskellNone

Synth.Shared.Control

Description

Im-specific controls. Generally they are per-instrument, but like Derive.Controls, it's useful to have a standard vocabulary.

Synopsis

Documentation

newtype Control Source #

Unlike Control, pitch is just another control.

Constructors

Control Text 
Instances
Eq Control # 
Instance details

Defined in Synth.Shared.Control

Methods

(==) :: Control -> Control -> Bool #

(/=) :: Control -> Control -> Bool #

Ord Control # 
Instance details

Defined in Synth.Shared.Control

Show Control # 
Instance details

Defined in Synth.Shared.Control

String.IsString Control # 
Instance details

Defined in Synth.Shared.Control

CRC32.CRC32 Control # 
Instance details

Defined in Synth.Shared.Control

Pretty Control # 
Instance details

Defined in Synth.Shared.Control

Serialize.Serialize Control # 
Instance details

Defined in Synth.Shared.Control

dynamic :: Control Source #

This should come from c_dynamic. Unlike score-level dyn, whose meaning is abstract, this should be more or less on a dB scale, where 0 corresponds to minimumDb.

It can be more closely defined here because im instruments have direct control over the sound they produce, while other backends, like MIDI, are up to the whims of the synthesizer's interpretation.

volume :: Control Source #

This is similar to dynamic, but this always maps to physical volume, for the case where an instrument distinguishes between dynamic level and volume level. The score-level equivalent is vol which corresponds to MIDI cc7 in the MIDI backend.

minimumDb :: Double Source #

A dynamic of 1 maps to 0dB of attenuation, and 0 maps to this level. Humans maybe have a limit around 120dB, but 96 is a theoretical maximum for 16 bit audio, which is likely what this turns into anyway.

My manual experiment shows that -96 on a normalized sample is just about inaudible.

pitch :: Control Source #

Pitch in NoteNumbers.

gate :: Control Source #

Used by some synths to mark note start and end times. This should be used internally, not exposed.