1. IMPORTANT:
    We launched a new online community and this space is now closed. This community will be available as a read-only resources until further notice.
    JOIN US HERE

Change sample start in all zones?

Discussion in 'KONTAKT' started by audionomio, Aug 14, 2006.

Thread Status:
Not open for further replies.
  1. audionomio

    audionomio Forum Member

    Messages:
    20
    Hi,
    is there a way to edit the sample start position for all selected zones at once?

    Thanks and bests,
    - Mathis
     
  2. Thonex

    Thonex NI Product Owner

    Messages:
    208
    That is something I'd like to know too....

    anyone?

    T
     
  3. kotori

    kotori NI Product Owner

    Messages:
    1,153
    I would also like to be able to do this.
     
  4. gislemm

    gislemm NI Product Owner

    Messages:
    204
    i dont think you can do it in kontakt by zone editing. howeveri think you can trick around it by scripting

    here is a script i made for random sample starts

    you could use this to change the start position for all playing zones, if you set both Random min and Random max to the same value (the position you want to start the sample, in milliseconds - note that the sample editor operates in samples, you have to translate)

    its not an elegant solution, you could probably change or write your own dedicated script, and maybe add the option to only affect selected groups

    Code:
    on init
    	declare ui_knob $RandMin (0,10000,1)
    	declare ui_knob $RandMax (0,10000,1)
    	declare ui_label $Info (3, 2)
    	make_persistent ($RandMin)
    	make_persistent ($RandMax)
    	$RandMax := 0
    	set_text ($Info, "Values in millisceonds.")
    	add_text_line ($Info, "Ex: If sample is 8.42s, set RandMax to 8420.")
    end on
    
    on note
    		ignore_event($EVENT_ID)
    		play_note($EVENT_NOTE,$EVENT_VELOCITY,random($RandMin*1000,$RandMax*1000),-1)
    end on
    
    
     
  5. audionomio

    audionomio Forum Member

    Messages:
    20
    Thank you for the suggestion with the script. But I guess it works the same way as the other scripts I know which apply some sample start offset. The problem is they rely on sampler-mode "sampler", but I need to use DFD. That's why I have to alter sample start in the loop editor.

    But thanks anyway!
    Any more takers?
    - Mathis
     
  6. kotori

    kotori NI Product Owner

    Messages:
    1,153
    Being able to do this is useful for skipping the attack of a note without having to resort to loading an instrument in Sampler mode. This would be useful for scripts designed for legato transitions, crossfading using polyphony-saving techniques, etc. One could duplicate all groups of an instrument, offset the Sample Start of all zones of the new set in one go and then let scripts switch between these sets for notes with/without attack. There may also be other betters ways so that one wouldn't have to change the group structure.

    An alternative way, easier for looped samples but not applicable to non-looped ones, would be to let scripts start the playback at sample offsets corresponding to loop points. K2 already has a preload buffer for these offsets, so it shouldn't be a problem in DFD mode, eg it could look like: play_note(60, 100, $LOOP1, -1)
     
  7. audionomio

    audionomio Forum Member

    Messages:
    20
    Thank you, Nils, for explaining.

    The idea with the loop point would indeed be great, since then no reprogramming of the groups would be necessary, right?
     
  8. kotori

    kotori NI Product Owner

    Messages:
    1,153
    Yes, that's right.
    I really think this is the way to go, and NI already has the whole infrastructure there for jumping to the start offsets of loops so I think very little work would be needed to implement it. I added this as a feature request, so all of who would like to see this implemented please express your support in this thread.
     
Thread Status:
Not open for further replies.