What is KVR Audio? | Submit News | Advertise | Developer Account

Options (Affects News & Product results only):

OS:
Format:
Include:
Quick Search KVR

"Quick Search" KVR Audio's Product Database, News Items, Developer Listings, Forum Topics and videos here. For advanced Product Database searching please use the full product search. For the forum you can use the phpBB forum search.

To utilize the power of Google you can use the integrated Google Site Search.

Products 0

Developers 0

News 0

Forum 0

Videos 0

Search  

yet another noob KSP question

Sampler and Sampling discussion (techniques, tips and tricks, etc.)

Moderator: Moderators (Main)

User avatar
Zombie Queen
KVRAF
 
3388 posts since 1 Aug, 2005, from where butter flies

Postby Zombie Queen; Sat Mar 08, 2014 2:06 pm yet another noob KSP question

A question about Kontakt scripting. I wonder, if anyone has some experience in this. Is there a way to trigger a callback event within one script, not counting psg and listener callbacks? I thought a controller or rpn callback would do this, but it looks like the script does not react to controller changes it generates itself.
User avatar
EvilDragon
KVRAF
 
10015 posts since 6 Jan, 2009, from Croatia

Postby EvilDragon; Sat Mar 08, 2014 11:17 pm Re: yet another noob KSP question

If you need to trigger various stuff, usually you'd use a user function, then trigger it from wherever you want. Other than that, no, you cannot trigger different callbacks at will (except triggering note callback with play_note() and triggering ui_control callback of ui_file_selector with fs_navigate() in K5...)
User avatar
Zombie Queen
KVRAF
 
3388 posts since 1 Aug, 2005, from where butter flies

Postby Zombie Queen; Sun Mar 09, 2014 4:18 am Re: yet another noob KSP question

This is something I really miss in KSP. I wanted to trigger some animated event from another script slot, it involved a lot of waiting in-between steps. I cannot call this from within "on psg change", because of the way it works, psg change will not be updated in any script slot, until current psg callback is executed, so it effectively blocks all communication until finished. I need to move it out of psg callback, but there is no other callback I can call from within a script. Workaround is having listener callback constantly check on some variable, but it's way tedious.
User avatar
EvilDragon
KVRAF
 
10015 posts since 6 Jan, 2009, from Croatia

Postby EvilDragon; Sun Mar 09, 2014 10:32 am Re: yet another noob KSP question

I don't see a reason why not to use PGS here... when you want to invoke the animation in another script slot, just send a dedicated PGS event from a different script slot to run it. Not a problem to do that at all.
User avatar
Zombie Queen
KVRAF
 
3388 posts since 1 Aug, 2005, from where butter flies

Postby Zombie Queen; Sun Mar 09, 2014 11:03 am Re: yet another noob KSP question

I have four script pages, which communicate via psg, Kontakt will not update 'psg changed status' until a psg callback ends, so if one psg callback is waiting for something, others will not trigger.
BTW. do you know if it's possible to assign midi channel to notes Kontakt is sending to outside world, that are generated by an instrument's ksp? I was trying $EVENT_PAR_MIDI_CHANNEL, but it seems it does not work from instrument level.
User avatar
EvilDragon
KVRAF
 
10015 posts since 6 Jan, 2009, from Croatia

Postby EvilDragon; Sun Mar 09, 2014 11:29 am Re: yet another noob KSP question

Zombie Queen wrote:BTW. do you know if it's possible to assign midi channel to notes Kontakt is sending to outside world, that are generated by an instrument's ksp? I was trying $EVENT_PAR_MIDI_CHANNEL, but it seems it does not work from instrument level.


Nope, not possible.


Regarding PGS, you can delimit when something needs or needs not to be done in a PGS callback by using pgs_key_exists() along with testing if the pgs key value has changed. I usually have multiple PGS keys for different stuff that needs to be done, and this helps in executing only parts of PGS callback, not the whole of it. So usually a key has two indices: one that is actually carrying the data value that needs to be transferred, and the other that is just a R/W flag, I set it to 1 when I want the PGS executed, and then in that branch within PGS callback I set it back to 0, denoting that it's finished with sending what's needed.
User avatar
Zombie Queen
KVRAF
 
3388 posts since 1 Aug, 2005, from where butter flies

Postby Zombie Queen; Sun Mar 09, 2014 12:23 pm Re: yet another noob KSP question

Yes. But, as I said, when one psg callback hasn't finish, another won't trigger, it won't detect any psg value changes until the last one comes to 'end on' line.
User avatar
EvilDragon
KVRAF
 
10015 posts since 6 Jan, 2009, from Croatia

Postby EvilDragon; Sun Mar 09, 2014 2:14 pm Re: yet another noob KSP question

In that case, I would use the listener callback instead, in a similar fashion as PGS example I laid out above. That should work.

Moderator: Moderators (Main)

Return to Samplers, Sampling & Sample Libraries