View Single Post
Old 10-10-2016, 12:00 PM   #61
Sju
Human being with feelings
 
Join Date: Jun 2015
Posts: 686
Default

I spent quite some time trying to get this to work when the Master Playrate has been changed (I like to sometimes slow the project down to jam on some trickier stuff).

I'm not sure if it's possible to get this to work without changes to the JSFX code?

The problems are

1. REAPER's glue applies the current playrate to the pitch of the item.

-> compensate for this before gluing the item by applying a pitch offset to the item.

2. The item length as exported from the JSFX buffer is too long when the playrate is slowed down

-> take playrate into account in the item length calculation in Implode_Glued_Items()

I didn't get very far, but here are maybe some useful snippets of code if anyone's interested:

Playrate = Master_GetPlayRate(0);
Pitch_Offset = (12/log(2)) * log(Playrate); // <- taken from "Multiply selected items rate by X and adjust length.lua" by X-Raym
New_Lenght=(Max_Pos-Min_Pos)*Playrate;

hmm.. I'll have a go at it when I'm not busy with other stuff and post the results (if any)

Cheers
Sju is offline   Reply With Quote