快速登录:  

Forum: VirtualDJ Plugins

话题: Script for checking Loops and Loop Rolls

由于该帖子已年深日久,可能包含陈旧过时或描述错误的信息。

DJDPrezzPRO Infinity(Soundswitch)Member since 2017
I'm looking for a way to check any current loop or loop roll.

In particular I want to know the length of the current loop or loop roll as well as whether they are active or not.

So far I can get all I need for loops with
deck 1 get_loop_out_time

which will give me 0 if the current loop is inactive and >0 if active.
I can also check the loop beat length with
deck 1 get_loop


As an aside I also tried
deck 1 get_active_loop

which gave me 1,2,4 for 1,2,4 beat length loops respectively when active and 0 when inactive but for <1 beat loops it did not work.
I got 1 for 1/2 beat loop when active and 0 when inactive but for <1/2 beat loops I got 0 for either active or inactive.
I'm not sure if that is just a bug with get_active_loop or whether it's doing the correct thing and I have misunderstood its purpose.

The main issue I'm having is getting loop roll info.

I can check for active loop roll with
deck 1 loop_roll_mode

this produces 1 when active and 0 when inactive.

I haven't been able to check the current active loop roll length.
I've tried
deck 1 loop_roll

but this doesn't produce anything.

Does anyone know if it's possible to get the beat length of the current active loop roll for a deck?

Thanks,
Ash

 

发表时间 Tue 02 Oct 18 @ 2:37 am
1) For loops you can just query the deck:
deck 1 loop ?

It will return true/false

2) For rolls you need to query all possible values:

deck 1 loop_roll 0.0125 ? on : deck 1 loop_roll 0.025 ? on : deck 1 loop_roll 0.5 ? on : deck 1 loop_roll 0.75 ? on : deck 1 loop_roll 1 ? on : deck 1 loop_roll 2 ? on : deck 1 loop_roll 4 ? on : off


Now, you can combine all these to a single query:
deck 1 loop ? on : deck 1 loop_roll 0.0125 ? on : deck 1 loop_roll 0.025 ? on : deck 1 loop_roll 0.5 ? on : deck 1 loop_roll 0.75 ? on : deck 1 loop_roll 1 ? on : deck 1 loop_roll 2 ? on : deck 1 loop_roll 4 ? on : off


This query will turn true (on) if a loop or loop roll is active, false (off) otherwise
 

发表时间 Tue 02 Oct 18 @ 9:01 am
AdionPRO InfinityCTOMember since 2006
You could also query if the loop roll effect is active
 

发表时间 Tue 02 Oct 18 @ 9:17 am
DJDPrezzPRO Infinity(Soundswitch)Member since 2017
Thanks very much.

I've got it working with:

"deck 1 loop_roll 0.03125 ? set '%deckRoll' 0.03125 : deck 1 loop_roll 0.0625 ? set '%deckRoll' 0.0625 : deck 1 loop_roll 0.125 ? set '%deckRoll' 0.125 : deck 1 loop_roll 0.25 ? set '%deckRoll' 0.25 : deck 1 loop_roll 0.5 ? set '%deckRoll' 0.5 : deck 1 loop_roll 0.75 ?  set '%deckRoll' 0.75 : deck 1 loop_roll 1 ? set '%deckRoll' 1 : deck 1 loop_roll 2 ? set '%deckRoll' 2 : deck 1 loop_roll 4 ? set '%deckRoll' 4 : set '%deckRoll' 0"


and then querying the var for beat length of the roll:

deck 1 get_var %deckRoll


It's a pity there doesn't appear to be a quicker way of querying the beat length of the roll - or maybe I just haven't found it yet.

Cheers.
 

发表时间 Wed 03 Oct 18 @ 12:44 am


(陈旧帖子或论坛版块会自动关闭)