Module: Musa::Transcriptors::FromGDV
- Defined in:
- lib/musa-dsl/transcription/from-gdv.rb,
lib/musa-dsl/transcription/from-gdv-to-midi.rb,
lib/musa-dsl/transcription/from-gdv-to-musicxml.rb
Overview
GDV (Grade-Duration-Velocity) base transcriptor for processing fundamental features.
Provides the foundational transcriptor for handling base/rest events in GDV notation. GDV is Musa-DSL's internal representation for musical events with grade (pitch), duration, and velocity information.
GDV Format
GDV events are hashes with musical attributes:
{
grade: 0, # Scale degree
duration: 1r, # Rational duration
velocity: 0.8, # Note velocity (0.0-1.0)
base: true # Mark as base/rest (zero duration)
}
This module contains the base transcriptor (Base) for handling base/rest
markers in GDV events, converting them to zero-duration structural markers.
Format-specific transcriptors are in submodules:
- ToMIDI - MIDI playback transcription (expands ornaments)
- ToMusicXML - MusicXML notation transcription (preserves ornaments)
Base/Rest Processing
The .base (or .b) attribute marks an event as a base or rest, which is
converted to a zero-duration event. This is useful for representing rests
or structural markers in the musical timeline.
Transcriptor Pattern
All transcriptors follow the same pattern:
- Extract specific features from GDV hash
- Process/transform the event based on those features
- Return modified event(s) or array of events
Defined Under Namespace
Modules: ToMIDI, ToMusicXML Classes: Base