feat: quantize MIDI clips with deterministic swing and strength
This commit is contained in:
parent
b0dbf6905f
commit
2ba14f6728
9 changed files with 97 additions and 5 deletions
|
|
@ -15,6 +15,19 @@ extern "C" {
|
|||
typedef enum { XTC_CLIPS_MOVE, XTC_CLIPS_DUPLICATE, XTC_CLIPS_DELETE, XTC_CLIPS_ALIGN, XTC_CLIPS_SLIP } xtc_clip_operation;
|
||||
xtc_result xtc_project_transform_clips(xtc_project *project,const uint64_t *ids,size_t count,
|
||||
xtc_clip_operation operation,int64_t amount,uint64_t *out_ids);
|
||||
/* MIDI transforms affect ALL source notes in selected MIDI clips, including
|
||||
* notes hidden by trims. Mixed audio/MIDI selections reject; IDs and unaffected
|
||||
* fields persist. No matching notes returns NOT_FOUND. Edits are atomic.
|
||||
* Swing: grid 1..3840, swing 0..100 delays alternate grid points by up to half
|
||||
* a grid; strength 0..100 blends toward the nearest swung point (ties later).
|
||||
* Durations stay fixed. Out-of-source results reject the complete operation. */
|
||||
typedef enum { XTC_MIDI_TRANSFORM_SWING } xtc_midi_transform_type;
|
||||
typedef struct {
|
||||
xtc_midi_transform_type type;
|
||||
uint64_t grid;
|
||||
unsigned int swing,strength;
|
||||
} xtc_midi_transform;
|
||||
xtc_result xtc_project_transform_midi(xtc_project *project,const uint64_t *ids,size_t count,const xtc_midi_transform *edit);
|
||||
/* Repeat the bounding phrase span, including gaps, 1..1024 additional copies.
|
||||
* Originals remain selected by the caller; all copies publish together. */
|
||||
xtc_result xtc_project_repeat_clips(xtc_project *project,const uint64_t *ids,size_t count,unsigned int copies);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue