Quick Sign In:  

Forum: VirtualDJ 8.1 Technical Support

Topic: Mapping syntax question

This topic is old and might contain outdated or incorrect information.

mcs1234PRO InfinityMember since 2010
VDJ8.1 using Behringer CMD DC1 controller. Looking to modify the action of the Load buttons.
Currently loads tracks and turns on pitch_lock. I'd like to change it to turn on pitch_lock for .mp3's but not .mp4's.
I tried...
Deck left (or right) load & file ends with 'mp3' ? pitch_lock on : pitch_lock off
But it won't turn pitch_lock on in any circumstance.
Ideas as to what the correct syntax would be here? Thanks!
 

Posted Wed 27 Jan 16 @ 1:48 pm
param_equal "`get_browsed_song 'extension' & param_uppercase`" "MP3" ? load & pitch_lock on : load & pitch_lock off
That script works BEFORE you load the deck by checking the song in the browser.

Similar result can be achieved after loading the song with this script:
load & param_equal "`get_loaded_song 'extension' & param_uppercase`" "MP3" ? pitch_lock on : pitch_lock off

For several reasons I recommend to use the FIRST way
 

Posted Wed 27 Jan 16 @ 6:43 pm
mcs1234PRO InfinityMember since 2010
Ugh. Both methods loaded the track but neither turned on the pitch_lock.
Because of the 'uppercase' thing maybe?
 

Posted Wed 27 Jan 16 @ 8:22 pm
No, the uppercase is needed to ensure both .mp3 and .MP3 files are taken into account.
That being said, the script works fine here...
 

Posted Wed 27 Jan 16 @ 9:35 pm
Did you made an exact copy of the script ? (Copy / Paste) ?

Notice reverse apostrophe on script ( ` ) It's mandatory...
 

Posted Wed 27 Jan 16 @ 9:37 pm
mcs1234PRO InfinityMember since 2010
Oh crap, I was doing the (') thing. I'll try again. Thanks. :-)
 

Posted Wed 27 Jan 16 @ 9:41 pm
mcs1234PRO InfinityMember since 2010
Perfection. Is there anything you guys *don't* know how to do?
Thanks!
 

Posted Thu 28 Jan 16 @ 12:22 am


(Old topics and forums are automatically closed)