Karya, built on 2023-08-29T07:47:28 (patch 7a412d5d6ba4968ca4155ef276a062ccdeb9109a)
Safe HaskellSafe-Inferred

Derive.C.Post.Idiom

Description

Idiomatic things for various instruments.

Synopsis

Documentation

pizz arp

map_simultaneous Source #

Arguments

:: RealTime.RealTime

events starting closer than this amount are considered simultaneous

-> (Score.Event -> Bool)

only process events that pass this predicate

-> (NonEmpty Score.Event -> Deriver [Score.Event])

process simultaneous events

-> Stream.Stream Score.Event 
-> NoteDeriver 

avoid overlap

next_same_pitch :: Stream.Stream Score.Event -> Stream.Stream (Score.Event, [Score.Event]) Source #

For each event, get the next events with the same instrument and starting pitch.

zero dur mute

c_zero_duration_mute :: Transformer Note Source #

See DUtil.zero_duration for a version that can apply any kind of transformation. This one is limited to attrs because it's a postproc, and it's a postproc because otherwise it's hard to tell if a note is really zero duration and not just an infer-duration note.

extend duration

extend_duration :: [Attrs.Attributes] -> RealTime.RealTime -> Stream.Stream Score.Event -> Stream.Stream Score.Event Source #

Don't overlap with another note with the same pitch, as in avoid_overlap.

apply attributes

apply_attributes :: Score.Event -> Score.Event Source #

For all controls that start with control_prefix and are positive during the event start, add those attributes to the event.

TODO a possible variation would be to take 0<v<1 as a probability of applying the attribute.