Karya, built on Mon Jul 24 11:39:07 PDT 2017 (patch 33511aca01257b76b88de7c7a2763b7a965c084e)

Safe HaskellNone

Derive.EnvKey

Contents

Description

Define a few inhabitants of Environ which are used by the built-in set of calls. Expected types are in hardcoded_types.

Synopsis

directly supported by core derivers

args :: Key Source #

VList: arguments for a requires_postproc call. Also see make_delayed.

attributes :: Key Source #

VAttributes: Default set of attrs.

block_end :: Key Source #

ScoreTime: the block deriver sets it to the ScoreTime end of the block. Blocks always start at zero, but this is the only way for a call to know if an event is at the end of the block.

control :: Key Source #

VSymbol: Set to the control that is being derived, inside of a control track.

instrument :: Key Source #

VInstrument: Default instrument.

key :: Key Source #

VSymbol: Many scales use this for scale-specific configuration. Some scales conceptually have a separate key and mode, e.g. C minor, in which case they're combined into key.

note_end :: Key Source #

VNum (ScoreTime): End time of the note event. This is set when evaluating note events so that inverted control tracks know when their parent event ends.

note_start :: Key Source #

This is just like note_end, except, you know, the other end.

merge :: Key Source #

VSymbol: Set along with control to the Merge function which will be used for this control track. Calls can use this to subvert the merge function and emit an absolute value.

Values are compose for tempo tracks, set, or any of the names from ControlOp.

scale :: Key Source #

VSymbol: Default scale, used by pitch tracks with a * title.

seed :: Key Source #

VNum: Random seed used by randomization functions. Can be explicitly initialized to capture a certain "random" variation.

This is rounded to an integer, so only integral values make sense.

srate :: Key Source #

VNum: Sampling rate used by signal interpolators.

tempo :: Key Source #

VNum: Set the default tempo, overriding default_tempo. This only applies if there is no toplevel tempo track, and generally only has an effect if the block is played as a toplevel block since it's a constant tempo.

Previously I would directly set the tempo warp in the equal call, but tempo setting has to be at the toplevel tempo track for it to interact properly with block call stretching.

track_voice :: Key Source #

VNum: this is the count of the tracks with the same instrument, starting from 0 on the left. So three tracks named >pno would be 0, 1, and 2, respectively. Used with Derive.Call.InferTrackVoice.

internal

suppress_until :: Key Source #

RealTime: suppress other notes until this time, inclusive. Only events without a suppress-until will be retained. Applied by infer-duration, see Derive.Call.Post.Move.

dynamic_val :: Key Source #

VNum: This is a bit of a hack for the dynamic to velocity conversion in Perform.Midi.Convert. The default note deriver stashes the control function output here so it can use it for note on velocity. Otherwise I couldn't use ControlFunctions (e.g. randomization) for note on velocity because control functions don't exist after MIDI conversion.

Details in NOTE [EnvKey.dynamic_val].

release_val :: Key Source #

Like dynamic_val, but for the release velocity. Set from release_velocity.

attack_val :: Key Source #

VNum: Set from attack_velocity in the same way as release_val.

start_offset_val :: Key Source #

RealTime: This stores the RealTime sum of start_s and start_t, and is later applied by the apply-start-offset postproc.

supported by not so core derivers

instrument_top :: Key Source #

VNotePitch or VNum (NN): The top of the instrument's range.

It's a VNotePitch for instruments that are tied to a particular family of scales, and have an upper note that is independent of any particular frequency. For instance, a kantilan's top note will have a different NoteNumber depending on its scale, or even within a single scale, depending if it is pengumbang or pengisep.

For instruments with less complicated scale requirements, NoteNumber is simpler.

open_strings :: Key Source #

List VPitch: tuning of open strings for this instrument. The pitches should be probably absolute NNs, not in any scale, so they work regardless of which scale you happen to be in.

TODO maybe it should be VNotePitch as with instrument_top?

tuning :: Key Source #

VSymbol: Kind of tuning for the scale in scope. The meaning is dependent on the scale, e.g. ngumbang ngisep for Balinese scales.

voice :: Key Source #

VNum: Separate notes into different voices. This is used by integrate to put them on their own tracks, and by the lilypond backend to split them into their own voices. Should be an integer from 1 to 4.

hand :: Key Source #

VSymbol: right, r, left, or l. Used by the lilypond backend, and also by any call that relies on an instrument's parts being divided by hand.

hold :: Key Source #

VNum: hold the start of a call for a certain amount of ScoreTime or RealTime.

values

polos :: Text Source #

Instrument role.

sangsih :: Text Source #

Instrument role.