Coming over from Kontakt? Read this!
-
As pointed out a by Chris, here's a thread for everyone who came over from Kontakt and faced issues with HISE paradigms.
This will not go into all the stuff HISE can do that Kontakt cannot, but rather explain the differences in the workflow for different goals, and maybe point out that there's another option in HISE which you would then go explore (e.g. you don't have to use filmstripped UI, you can write vector graphics in a similar way to postscript).
Resources
Some time ago, NI published the great KSP reference website. https://www.native-instruments.com/ni-tech-manuals/ksp-manual/en/welcome-to-ksp
But even before that, the docs were in a pretty good state, though it was a chunky PDF. Almost every functionality has an example that you can pop right into Kontakt and see it at work. That's amazing.
In HISE town, the docs are a bit of a mess and the search is not very good as it does not search the entire text body. Use the github version for searching instead. Here are the links you'll want to bookmark:
https://docs.hise.audio/
https://github.com/christophhart/hise_documentation
https://github.com/christoph-hart/hise_laf_library/tree/main
https://github.com/christophhart/hise_tutorial
https://www.youtube.com/@DHealey/videosBefore you attempt making anything in HISE, take a day or two and read the entire docs thoroughly. From the start to the end, read it all. Read the entire API reference. At best, you'll remember 30% and for the other stuff you'll be able to vaguely recall reading about it, and then know where to find it when you need it.
Some of the docs are outdated or incomplete, so you'll have to come here and look on the forum. Either use the forum search (which is a lot better than the docs.hise.audio search) or use this in Google and search there:
site: https://forum.hise.audio/ myKeywordsHereAlso, watch David's videos as he goes over and mentions a bunch of stuff that's usually scattered all over the forum and the docs, like the Sampler workspace video or some of the more niche ones like rlottie, keyboard modification etc.
Hopefully one day the docs will be awesome, well structured and complete. Until that day, the experience will be like the early days of Unreal Engine 4, which means spending a decent amount of time here on the forum until you get the hang of things. Hopefully this thread speeds up your onboarding.
Setup and Delivery
Kontakt is plug and play. You install the plugin, open it, create a new patch and start working.
HISE needs to be built from source because you'll use the same compiler to build the final VST plugins.
In Kontakt, you save the patch, create the container if you have images, IRs or scripts, zip the whole folder and ship it over to the end user.
In HISE, you have two options. One is to export a RHAPSODY expansion (for the free RHAPSODY player by LibreWave) and the end user loads it as they would a Kontakt patch. You don't worry about system compatibility and compiling. The catch is that the end user will be able to open up your project and take a peek inside, and there's no AAX. You can ship this under the commercial license, which lets you not have to license your project under GPL, but the end user will still, by going through the HISE setup, be able to take a peek inside. If you had no trouble shipping for full Kontakt, this can be a good option if you don't wish to deal with compiling on different systems. Whether to license under the commercial/paid license or GPL is up to you.
The other one is to export a native VST/AU/AAX plugin. VST and AU SDKs come with HISE, for AAX you have to register with AVID. Exported plugins, along with samples and anything else you wish to ship will then have to be packaged into a system-specific installer of your choice, and you'll have to codesign the MAC one to prevent the user warning popup. Apple Developer account is $99.
You'll also have to sign the AAX plugin with AVID's own tool. This is a pain in the ass for the first time, but the second time is easier and you can then add it to your CV.
@Christoph-Hart I think there's a need for a definitive step-by-step guide for this, including signing Apple, AAX, and packaging installers.
Groups
Kontakt has GROUPS, each being like its own folder, with its own unique 0-based identifier, and each can hold 128x127 samples. 128 notes, 127 velocities. Each Kontakt group has slots for Kontakt's built-in effects, and most are available there. Each group has its own set of modulators for the Amplifier and the Pitch.
The modulators include AHDSR, LFOs, constants, random, FLEX ENVELOPE, script modualtors etc. These are all specific to that group. You can add multiple to multiple groups by first selecting the groups and then adding the modulators.
You could use groups however you wanted. You can use one RR per group, one articulation per group, or cram it all in and script the correct velocity to be played.
HISE has a layer above this. There are modules. One of the modules is a sampler. A sampler has a mapping space that is the same as Kontakt's, so a 128x127 grid. A sampler has RR Groups, which by default act as round robin groups, each note triggering the next one.
This is disabled in the script by creating a reference to the sampler (either in the sampler itself or in a Scripting Processor hierarchically above the sampler) and calling the method to disable this. You then call a different method to enable the group you want, or multiple. The index is 1-based.
In HISE, you can drag&drop import more than 128 samples at once.
The token parser is used for auto-mapping based on file naming. It's a lot more powerful than the one in Kontakt, though the LUA workflow in Creator Tools is a whole other story.
In HISE, you would import multimic samples into the same sampler, same group, and use the built-in multimic monolith functionality to map them to a 4th axis of the whole map. In Kontakt, this would likely be done by separating them in different groups. The benefit of doing it in HISE is that any changes you make in the powerful sample editor are then made to all the mics.
This entire setup within the sampler, including multimic samples and groups is then called a SAMPLE MAP. The sample map can be saved as a human-readable XML file and and changes you wish to make can also be done in a text editor outside of HISE. Loading a sample map is asynchronous and not something you wish to do in real-time, i.e. by DAW automation. Think of it as a way for storing different collections of samples, as in presets.
Modulation and FX in HISE are done at sampler-level.
If you wish to have multiple articulations, you have many options here: one articulation per RR group, switch groups based on keyswitches, stick all round robins in a single group. Or use the RR groups for round robins, and stick all articulations in a single group, spread out over the velocity range. If you wish to use velocity crossfading, this idea is off and you'll have to use different samplers (and as such, sample maps) for each articulation. If you want to do layer crossfading, that's done between different RR groups by enabling this behavior in the sampler settings and then creating a curve for each individual group right there in the interface.
Note: There's currently a bug with the RR groups where the index goes haywire for more than 10 groups, and the little circle icon visually breaks for selection, along with the dropdown menu. Also, anything you import with the token parser will go straight into RR group 1. Until this gets changed, you can then immediately change the group using the button in the sampler.
FX
Kontakt comes with many high quality effects including a number of compressors, reverbs, delays, a bunch of distortion units and pedals and a whole collection of IRs for the convolution reverb. HISE comes with stock JUCE effects. The filters are great, but if you got used to Kontakt's distortion units, Supercharger, SSL compressor emulation etc, you'll miss that here.
The good thing is that in HISE you can create your own. Either via ScriptNode using low-level building blocks, writing some higher level code in FAUST (which has a library of fantastic effects that you can use, depending on the license for each - check the FAUST website) or writing them entirely in C++ and including that in your HISE project.
GUI
In Kontakt, you would either use the default Kontakt-looking controls or have to skin them using filmstrips. Adding new controls in Kontakt always requires scripting them entirely and setting up the accompanying image properties file. Since Kontakt 6, you could also make a GUI in Creator Tools.
In HISE, you either use filmstrips, or you can write vector graphics for your controls using a similar concept to something like PostScript - you're effectively painting from the bottom-up, and changing colors of the brush as you go).
You can use OPEN GL and write the shaders there, in that case the limits are only what you set for yourself.
You can also use rlottie.
You can create controls using code, or you can create controls in the interface designer. Nevertheless ,the component list is always there and the hierarchy of controls will be visible there. You can click on a control to adjust its properties in the property editor. These include adding a filmstrip, so if you just want a make a filmstripped UI like in Kontakt, you can do so without writing a line of code.
The controls each have a value which is pulled by calling a getValue() method on the control reference. In script, you store the reference of a control in a variable, and call the method using myControl.getValue(). Similar to how the controls in Kontakt are referred to using a variable that you use when creating them, the difference being that here it's a class with a bunch of methods that you can use to manipulate it with. You then use the value however you want.
The panels are pretty much the same, except the panel class in HISE is like an omni-widget with a bunch of methods that other controls don't have, letting you create any kind of control imaginable.
Well, almost, it's still missing DAW Automation that you don't have to hack together, you need to supply your own algorithm for logarithmic output if you don't wish to have a linear output (which is the same as for Kontakt, but HISE's Slider component lets you set a midpoint and as such have an logarithmic output, which is a must for filters and volume sliders), and there's no mouse scroll callback.
In HISE, you can create right-click menus for anything. Panels have their own, but you can use a broadcaster to implement it anywhere for any kind of situation.
For any kind of automated animation, create a timer object and use its methods to set the timer rate, start and stop it, as there's no wait() method that pauses the execution of the script. For event processing you can delay the event, but more on that later.
Time is often measured in samples. On a sampler level (note start offset) it's in the sampling rate of the sample itself. On an event level, it's the sampling rate that the plugin is running at. For standalone, it's what you set up in the settings, and for the plugin it's the sampling rate of the DAW. So if you wanted to talk in milliseconds, you would say Engine.getSampleRate()/1000.
The timer objects run in milliseconds. The timer callback (on timer, for each MIDI processor) runs in seconds. I never asked why, and at this point I'm afraid to.
Timer objects run until you stop them. The panels come with a built-in timer object which only runs while the plugin GUI is open. Keep that in mind.
You don't need to have a virtual keyboard if you don't want to. If you want to, there's a Floating Tile component where there's a pre-build keyboard functionality. There's also a bunch of other pre-built stuff there including a preset manager, analyzer, etc. Check the docs.
Events
This is similar, but again different. Events in HISE are called Messages (in Kontakt, you would use message() to print stuff to the console; in HISE, you have the Console class for that, including benchmarking).
There's the on note on, on note off (in Kontakt called on release), on timer and on control. The timer is self explanatory and was covered in the previous chapter. it's like Kontakt's listener when you set it to a certain interval.
The biggest change from Kontakt, along with how the sampler is organized, is the signal flow of a MIDI message. In HISE, it goes from one script processor to the next, from the top down in your plugin architecture.
If your interface script is the very first one, when you play a note, it'll first go there. If there's nothing in the on note on callback there, it proceeds to the next.
If you now have another script processor, let's call it Playback Logic, and in the note on callback you say Message.ignoreEvent(true), the note on in any of the following processors will not be triggered. If your Playback Logic then says Synth.playNote() (this returns the ID, just like in Kontakt, so you can store it in a variable), the following processors will again have a note on. The difference is that this one will be artificial.
This is the same as in Kontakt's 5 script processors. The difference is that there's no real limitation to how many of these you have in HISE, and the tree structure opens up a lot of possibilities (for example, if you use a Container module and inside you have multiple different samplers/modules, events will go into each of these samplers individually without being affected by the MIDI processing or ignoring done by each individual module).
In Kontakt, events have data slots where you can store the artificial flag either in $EVENT_PAR_CUSTOM, or using set_event_mark().
You can query artificial notes in HISE with Message.isArtificial().
In Kontakt, you could do panning and tuning per-event, by using the event ID. In HISE, you do it using the Stereo FX and its Pan Modulation, where you add a Script Voice Start Modulator, and return a value on voice start. You can also query the event ID there. Same goes for the pitch modulation.
Scripting
KSP is similar to PASCAL. HISEScript is similar to Javascript.
KSP is a strictly typed language. You have to declare variables and declare a type while doing so. In HISE, any of the available variables (const, var, global, reg) can be an int, a double, a string or an object, or an array where any index can be any of these things. In case of an array or an object, you just have to do an assignment before using it that way, i.e. variable = [];, and then you can say variable[1] = 45;. For objects, it's variable = {};.
Like in Javascript, you can dynamically create object properties with object[property] = 45, which then be accessed with object.property (return here is 45). This is great for functions and unlocks a completely new dimension in available data models that you can choose for your project.
In KSP, new line separates commands. In HISE, you use a semicolon.
-
-
Good topic, got pinned :)
I think the most important change (at least what I've heard from people coming over) is the change from the linear list of groups to the tree structure of HISE. This has deep implications of how to build up the architecture of the project, so if you have a few examples of projects that you've converted to HISE, it would great to hear how you managed this step (without spilling too much internal obviously).
-
Ok first welcome to all you Kontakt people.. and lets start with one of the conceptual changes:
Groups
There are no groups in HISE, yeah sounds mad doesn't it... instead there are Sample Maps that do exactly the same thing (well actually a fair bit more but lets stick with this first thing).
Now you can only load one Sample Map into a sampler at any one time. Wha!?? Yeah the important new idea there is "load" - you can dynamically load and unload Sample Maps (Groups to you..)
So where in Kontakt you had to have 299 groups to have all your sounds available - now you have 299 Sample Maps on disk - and you load them when you need them.
Well its of course a lot more complex than that (or it can be) but go with that to start with....
-
This post is deleted! -
@Lindon But there are groups, and for some things like basic rr you can use them just like in Kontakt.
-
@d-healey said in Coming over from Kontakt? Read this!:
@Lindon But there are groups, and for some things like basic rr you can use them just like in Kontakt.
they live in inside Sample Maps right? So day1 this (granted) simplified message might be useful? If not please feel free not to use it.
-
@Lindon They live inside Kontakt's sample map too, it's just that with Kontakt there is only one sample map and it's part of the NKI.
I think the main different between Kontakt's groups and HISE's is that with Kontakt you can route them individually and apply effects and other processing to them individually which you can't do in HISE (yet...?).
In HISE the routing and modulation is at the sampler level rather than the group level.
-
@d-healey said in Coming over from Kontakt? Read this!:
@Lindon They live inside Kontakt's sample map too, it's just that with Kontakt there is only one sample map and it's part of the NKI.
I think the main different between Kontakt's groups and HISE's is that with Kontakt you can route them individually and apply effects and other processing to them individually which you can't do in HISE (yet...?).
In HISE the routing and modulation is at the sampler level rather than the group level.
Absoloutely - valuable stuff to include - I guess I was thinking inside a group you see a mapping of sample audio files, inside a Sample Map you see....so (to start with) same same...as a starting point. But hey no problem.
-
-