-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'release/v1.2.0' into main
- Loading branch information
Showing
13 changed files
with
516 additions
and
153 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
189 changes: 189 additions & 0 deletions
189
src/Pianobook Piano Template - UI (with Mic Levels).ksp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,189 @@ | ||
{ | ||
|
||
PIANOBOOK PIANO TEMPLATE - UI SCRIPT (WITH MIC LEVEL SLIDERS) | ||
|
||
There are two scripts in this template. The first script is the UI Portion. | ||
The second script controls the triggering of piano groups. The two scripts | ||
can be used independently of eachother. There are also two versions of the UI script: | ||
a simple version and a multiple mic version. This is the multiple mic version. | ||
|
||
UI scripts by Dave Hilowitz & Angus-Roberts Carey (ARC Samples) | ||
|
||
} | ||
|
||
on init | ||
|
||
{ These variables are used by the Notes, RT, and Pedal knobs. Make sure you include | ||
the groups for all the mics. Remember to change the size of the arrays (the number | ||
in brackets after the array name) if you add multiple groups to any of these.} | ||
|
||
{ Groups for Mic 1 Groups for Mic 2 Groups for Mic 3 } | ||
{ vvvvvvvvvvvvvvvv vvvvvvvvvvvvvvvv vvvvvvvvvvvvvvvv } | ||
declare %note_groups[24] := (0,1,2,3,4,5,6,7, 20,21,22,23,24,25,26,27, 40,41,42,43,44,45,46,47) | ||
declare %release_trigger_groups[12] := (8,9,10,11, 28,29,30,31, 48,49,50,51) | ||
declare %pedal_groups[24] := (12,13,14,15,16,17,18,19, 32,33,34,35,36,37,38,39, 52,53,54,55,56,57,58,59) | ||
|
||
{ This controls how responsive the knobs are. Make sure to keep this negative if you want this to be controllable via vertical dragging. } | ||
declare $controlSensitivity := -500 | ||
|
||
{ DON'T EDIT BELOW THIS POINT UNLESS YOU KNOW WHAT YOU'RE DOING } | ||
|
||
message("") | ||
|
||
{ UI Stuff } | ||
{ Tell Kontakt we want a visible Performance View } | ||
make_perfview | ||
|
||
{ Set the UI height and width for a our Performance View } | ||
set_ui_height_px(360) | ||
set_ui_width_px(633) | ||
|
||
set_control_par_str($INST_ICON_ID,$CONTROL_PAR_PICTURE,"BLANK_ICON") | ||
set_control_par_str($INST_WALLPAPER_ID,$CONTROL_PAR_PICTURE,"Template_Skin_with_Mic_Levels") | ||
|
||
{ This variable will be used for setting volumes in the knob handlers below. } | ||
declare $count | ||
|
||
{ Declare top row of controls. These control volumes for the three busses. } | ||
declare ui_slider $MicOneSlider(1, 500000) | ||
make_persistent($MicOneSlider) | ||
declare $MicOneSliderId | ||
$MicOneSliderId := get_ui_id($MicOneSlider) | ||
set_control_par_str($MicOneSliderId, $CONTROL_PAR_PICTURE, "Vertical_Slider") | ||
set_control_par($MicOneSliderId,$CONTROL_PAR_MOUSE_BEHAVIOUR, $controlSensitivity) | ||
|
||
declare ui_slider $MicTwoSlider(1, 500000) | ||
make_persistent($MicTwoSlider) | ||
declare $MicTwoSliderId | ||
$MicTwoSliderId := get_ui_id($MicTwoSlider) | ||
set_control_par_str($MicTwoSliderId, $CONTROL_PAR_PICTURE, "Vertical_Slider") | ||
set_control_par($MicTwoSliderId,$CONTROL_PAR_MOUSE_BEHAVIOUR, $controlSensitivity) | ||
|
||
declare ui_slider $MicThreeSlider(1, 500000) | ||
make_persistent($MicThreeSlider) | ||
declare $MicThreeSliderId | ||
$MicThreeSliderId := get_ui_id($MicThreeSlider) | ||
set_control_par_str($MicThreeSliderId, $CONTROL_PAR_PICTURE, "Vertical_Slider") | ||
set_control_par($MicThreeSliderId,$CONTROL_PAR_MOUSE_BEHAVIOUR, $controlSensitivity) | ||
|
||
{ Positions the top row of controls } | ||
move_control_px($MicOneSlider, 128, 205) | ||
move_control_px($MicTwoSlider, 173, 205) | ||
move_control_px($MicThreeSlider,218, 205) | ||
|
||
{ Declare knobs for the middle row of controls } | ||
declare ui_slider $NotesSlider(1, 630000) | ||
|
||
make_persistent($NotesSlider) | ||
declare $NotesSliderId | ||
$NotesSliderId := get_ui_id($NotesSlider) | ||
set_control_par_str($NotesSliderId, $CONTROL_PAR_PICTURE, "ARC_Knob") | ||
set_control_par($NotesSliderId,$CONTROL_PAR_MOUSE_BEHAVIOUR, $controlSensitivity) | ||
|
||
declare ui_slider $RTSlider(1, 630000) | ||
make_persistent($RTSlider) | ||
declare $RTSliderId | ||
$RTSliderId := get_ui_id($RTSlider) | ||
set_control_par_str($RTSliderId, $CONTROL_PAR_PICTURE, "ARC_Knob") | ||
set_control_par($RTSliderId,$CONTROL_PAR_MOUSE_BEHAVIOUR, $controlSensitivity) | ||
|
||
declare ui_slider $PedalsSlider(1, 630000) | ||
make_persistent($PedalsSlider) | ||
declare $PedalsSliderId | ||
$PedalsSliderId := get_ui_id($PedalsSlider) | ||
set_control_par_str($PedalsSliderId, $CONTROL_PAR_PICTURE, "ARC_Knob") | ||
set_control_par($PedalsSliderId,$CONTROL_PAR_MOUSE_BEHAVIOUR, $controlSensitivity) | ||
|
||
{ Positions the top row of controls } | ||
move_control_px($NotesSlider, 295, 160) | ||
move_control_px($RTSlider, 395, 160) | ||
move_control_px($PedalsSlider, 495, 160) | ||
|
||
{ Declare knobs for the bottom row of controls } | ||
declare ui_slider $Vol(1,500000) | ||
make_persistent($Vol) | ||
declare $VolId | ||
$VolId := get_ui_id($Vol) | ||
set_control_par_str($VolId, $CONTROL_PAR_PICTURE, "ARC_Knob") | ||
set_control_par($VolId,$CONTROL_PAR_MOUSE_BEHAVIOUR,$controlSensitivity) | ||
|
||
declare ui_slider $FxOne(1, 1000000) | ||
make_persistent($FxOne) | ||
declare $FxOneId | ||
$FxOneId := get_ui_id($FxOne) | ||
set_control_par_str($FxOneId, $CONTROL_PAR_PICTURE, "ARC_Knob") | ||
set_control_par($FxOneId,$CONTROL_PAR_MOUSE_BEHAVIOUR,$controlSensitivity) | ||
|
||
declare ui_slider $FxTwo(1, 500000) | ||
make_persistent($FxTwo) | ||
declare $FxTwoId | ||
$FxTwoId := get_ui_id($FxTwo) | ||
set_control_par_str($FxTwoId, $CONTROL_PAR_PICTURE, "ARC_Knob") | ||
set_control_par($FxTwoId,$CONTROL_PAR_MOUSE_BEHAVIOUR,$controlSensitivity) | ||
|
||
{ Positions the bottom row of controls } | ||
move_control_px($Vol, 295, 250) | ||
move_control_px($FxOne, 395, 250) | ||
move_control_px($FxTwo, 495, 250) | ||
|
||
end on | ||
|
||
on ui_control($MicOneSlider) | ||
{ Sets the volume of the `Group 1` bus. } | ||
set_engine_par($ENGINE_PAR_VOLUME, $MicOneSlider,-1,-1,$NI_BUS_OFFSET + 0) | ||
end on | ||
|
||
on ui_control($MicTwoSlider) | ||
{ Sets the volume of the `Group 2` bus. } | ||
set_engine_par($ENGINE_PAR_VOLUME, $MicTwoSlider,-1,-1,$NI_BUS_OFFSET + 1) | ||
end on | ||
|
||
on ui_control($MicThreeSlider) | ||
{ Sets the volume of the `Group 3` bus. } | ||
set_engine_par($ENGINE_PAR_VOLUME, $MicThreeSlider,-1,-1,$NI_BUS_OFFSET + 2) | ||
end on | ||
|
||
on ui_control($NotesSlider) | ||
{ Sets the volume of the `Notes` groups. } | ||
$count := 0 | ||
while($count < num_elements(%note_groups)) | ||
set_engine_par($ENGINE_PAR_VOLUME, $NotesSlider, %note_groups[$count], -1, -1) | ||
inc($count) | ||
end while | ||
end on | ||
|
||
on ui_control($RTSlider) | ||
{ Sets the volume of the `Release Trigger` groups. } | ||
$count := 0 | ||
while($count < num_elements(%release_trigger_groups)) | ||
set_engine_par($ENGINE_PAR_VOLUME, $RTSlider, %release_trigger_groups[$count], -1, -1) | ||
inc($count) | ||
end while | ||
end on | ||
|
||
on ui_control($PedalsSlider) | ||
{ Sets the volume of the `Pedal` groups. } | ||
$count := 0 | ||
while($count < num_elements(%pedal_groups)) | ||
set_engine_par($ENGINE_PAR_VOLUME, $PedalsSlider, %pedal_groups[$count], -1, -1) | ||
inc($count) | ||
end while | ||
end on | ||
|
||
on ui_control($Vol) | ||
{ This loops through all groups and sets their volume according to the $Vol knob. } | ||
$count := 0 | ||
while ($count < $NUM_GROUPS) | ||
set_engine_par($ENGINE_PAR_VOLUME, $Vol, $count, -1, -1) | ||
inc($count) | ||
end while | ||
end on | ||
|
||
on ui_control($FxOne) | ||
set_engine_par($ENGINE_PAR_CUTOFF, $FxOne, -1,0,1) | ||
end on | ||
|
||
on ui_control($FxTwo) | ||
set_engine_par($ENGINE_PAR_SENDLEVEL_0, $FxTwo,-1,7 ,0) | ||
end on | ||
|
Oops, something went wrong.