I just wanted to make a note on how helpful David Healey is in this community, and that his tireless efforts to upgrade everyone’s knowledge are noticed and appreciated!
Thank you, David :)
Happy New Year!
I just wanted to make a note on how helpful David Healey is in this community, and that his tireless efforts to upgrade everyone’s knowledge are noticed and appreciated!
Thank you, David :)
Happy New Year!
Christoph,
First off, I would like to thank you for this amazing development tool for music :)
I am quite happy to be taking the plunge and learning as much about coding in HISE every day since watching and following the David Healey tutorial video: "How to make a synth"
Now, my main goals with HISE involve making MIDI plugins; some to be released as free utilities, and others as a paid product.
In my tests it seems that HISE does not receive or pass (thru) some MIDI message types:
MIDI clock
MTC
MMC
SysEx
etc.
Then there is Program Change, which HISE can accept and use, but not generate or pass (thru).
My concern:
When using HISE to make MIDI plugins, blocking these messages may deny users access to certain features that are needed for the next plugin in the chain (often a VSTi).
Therefore, if I am to produce MIDI plugins I am apprehensive about blocking those messages, and I, myself as a MIDI plugin customer would not be happy if a plugin that I purchased were to deny the passage of those messages to the output stage.
Personally, I do a lot of orchestral template mockups in a system where the articulation switching of VSTis is managed by expression maps (in Dorico, Nuendo, Bidule and Reaper) which are changed via incoming program change messages. Currently, I can't actually use any of my HISE produced MIDI plugins within this system, as without PC messages, it blocks the articulation switching.
In addition, there are many VSTis that can utilize program change messages directly to change patches. Kontakt, Omnisphere and VSL for starters.
And from my observation, it seems that many electronic producers with outboard gear setups require MTC (MIDI time code) and/or MIDI clock to sync devices.
I also have use-cases for plugin designs involving MIDI clock, MTC and SysEx and would love to have access to them for making custom MIDI controller managers.
Given that, I would like to add a feature request of three different levels (sorted from lowest to highest complexity):
Thanks for your time,
Craig
@clevername27 Thank you very much for your time!
You have a lot of incite to provide and I found the instruction as well as conversation to be quite worthwhile. I would certainly sign up again for more!
@d-healey said in HISE Meet Up:
@HISEnberg said in HISE Meet Up:
I don't think you could do spectral morphing in realtime
https://www.zynaptiq.com/morph/
https://web.archive.org/web/20180705061655/http://www.hakenaudio.com/RealTimeMorph/
I find the Kyma to be rather convincing for smooth morphing:
I would love to hear this kind of thing used to interpolate between sample sets for articulations that have capabilities for continuous control of timbre:
bow position, fluttertongue, growl, stick position on percussion etc.
There are a few different algorithms to choose from for morphing on the Kyma, and I don't know the details, but I think these are precomputed FFTs for resynthesis.
I am not sure what is causing this, but sometimes when I open a project/preset I am not getting any MIDI input and when I check the settings the MIDI inputs have been turned off:
Whereas I am certain I have saved it like this:
Yes, you can send MIDI out from button clicks.
I am working on a series of MIDI plugins at the moment.
You need to enable MIDI out in settings:
When using UI components to generate MIDI notes, you need to use Synth.addNoteOn() and Synth.addNoteOff() on the callback to you component.
Here I have pads (made with panels) which play chords when you use a mouse click.
It turns the notes off when the mouse is up.
// mouse callbacks for the pads --
pad.setMouseCallback(function[unitSize](event)
{
var ps = this.data.pitchSet;
var l = ps.length;
if (event.clicked)
{
var velocity = Math.round(event.y / unitSize * 127);
for (k = 0; k < l; k++)
Synth.addNoteOn(1, ps[k], velocity, 0);
}
if (event.mouseUp)
{
for (k = 0; k < l; k++)
Synth.addNoteOff(1, ps[k], 0);
}
});
To get the MIDI to output from the plugin,
as others have said you must use Message.sendToMidiOut();
To make sure it catches everything (and not some intermediate stage of MIDI),
I always place these functions in a script processor and container after all of my other containers:
And place the Message.sendToMidiOut() on each of the three MIDI callbacks:
@HISEnberg said in Let’s Build the “League of Newbies”:
@HISEnberg Done, I created the group chat. I guess anyone else who is interested can post here and we can add them in.
Add me :)
I'll check it out.
@d-healey It needs both ceil and floor to work, so I wrote an inline function to do the job:
inline function roundFix(value)
{
local remainder = Math.fmod(value, 1.0);
local roundedValue;
remainder >= 0.5 ? roundedValue = Math.ceil(value) : roundedValue = Math.floor(value);
return roundedValue;
};
const testRound = roundFix(4.49);
Console.print("test round: " + testRound);
const testRound1 = roundFix(4.5);
Console.print("test round: " + testRound1);
@d-healey said in Is there a method to rotate a path?:
@VirtualVirgin Instead of making a function to rotate a path, why not make a function to create a rotated path. You can pass in the data you would have used to create the initial path.
So based on your suggestion I came up with this and it seems to work:
inline function createRotatedPath(pathArray, angle, area)
{
local rad = Math.toRadians(angle);
local cosA = Math.cos(rad);
local sinA = Math.sin(rad);
local path = Content.createPath();
local rotationCenterX = area[0] + (area[2] * 0.5);
local rotationCenterY = area[1] + (area[3] * 0.5);
for (i = 0; i < pathArray.length; i++)
{
local x = pathArray[i][0];
local y = pathArray[i][1];
local newX = (x - rotationCenterX) * cosA - (y - rotationCenterY) * sinA + rotationCenterX;
local newY = (x - rotationCenterX) * sinA + (y - rotationCenterY) * cosA + rotationCenterY;
if (i == 0)
path.startNewSubPath(newX, newY);
else
path.lineTo(newX, newY);
}
path.closeSubPath();
return path;
}
The pathArray is a 2D array of x,y points
i.e.
[[x,y],[x,y] etc..]
@d-healey I'm imagining that you answered that question before I even submitted it! Lightning fast response.
Is there a keyboard shortcut to selecting a whole block of code, similar to the way you can select a whole line by placing the cursor at the beginning of a line and using "Ctrl+Shift+right"? Just thinking it would be great to quickly select whole functions or a full namespace this way.
Ok, so I found an issue with the ZLevel for panels.
It seems it does not function when the panel is set to:
"allowDragging" "Disabled".
I found this snippet from @ustk which demonstrates the basic ZLevel change for panels when clicked:
HiseSnippet 929.3ocsVEsaaaCEkxIpnVctXEnOOH3mjAxBjSZZKPQ65hcRgwZRLp6BFZQWACEsEQnHEDoRlQP9W1+v9W56849x9C7tTxxRYQHM1.QuHcO26k5PxykWNLQRnJkLAY078SioHqevdzTgNrWHlIPC5irdn8AXkll3lCs6zXrRQCPVVq8FCfUy0QYO+6urKliEDZIDBcrjQnukEwzknCe8uw378wAz2yhpD8Sd8.hTzSxko.eVy1GEiImhmPODaBqgMx5d6EvzxjQZrlpPVquqLX5nP44h73OloXmvoFitnQv.kCuujGXXrAE0KjwCFVLuUHXTFVtJrV9pvisOfEvVfWtZ7iYNbKyn55gUiahdc+9zyuN5YUgdqmSuGYOhjvh0kdLb6A1CDvF0XLrETkV4whZ7SMr6IgHD5MivmR2OALVjg2S882vcGe+NuvwwA1GTZ2yvItwBtx8kterHyITcOYTrT.FdsGhET91s6rQKG2q8bCozc4SYq1c9zKZAbarLw0K1kIx3VmVNWjORwapn5CjoJZOLmeBHc7FmJHZlT3Q6jGyEk+T1XWO5lDNibJMnyUIiNjoLi1GdK8LJ2qc1RUaXkw37R38kNq7SAmbkhCkZ5QBuNNW3zDFR2+uqwiq0mYQJQx4zjZcaJpRtoD8DoQmPS1.1e4ozEABpqqJeevsS9Rx2ypDnTLPvzGESmaWs9qXVW30GsXxVEpbNVEMapUSXkPWu9AMWSAe86C5i0XSI0bLHtXZhlYlsV8omAmUkWf0ztOUcpVFCi5BgHxxQm4sUQ4mQWhXvL6914xZzegrrstD9WSMebL7w4r.cnw3afQHkMITar9avBjoxy6mfmLgIl.LnQFPg5UY9Q8L5Sk6QB9TDSSiJNcr48PnYyLmZVhtUUXzRP6sxo8WJn8+bWR6Y6TKsmCuLzd6bZ+mEz9q2gzdF5U0Q6BXz0OiF5THCR4X8UaeX5YN2ATTdkyoMmEKTL8zp8TWhdJ925Vd2V59H6gLMIrd91nF9B0V207cdG5V16MdLknKI6516+GqZ63kfJuSlpAAzAXcByn+NLMZDHGHTfIBPUpL5sFFkbtsuw1rxLhJBxLlAOyc10XaM2Y2BmnHLIQ9YR9gal6.b+LDfShrqB0DtSFX61EkcDNjms+l9nH3pIelPLKE+Lv85yYqUHmsWgbdxJjyNqPNOcEx4YqPNO+FywbqveMUKixKS.fg6k0rwxZOAFTYYJRz+ATnnDPF
but if you set "allowDragging" to "Disabled", the the ZLevel no longer changes when clicked:
HiseSnippet 952.3ocsV0saaaCElxIpnVatXEXO.B9J4hf.+eSPwVSiSRmwpSLl6JF1vPGCEUDQnHEDoRlQQeG1iPusWu2f8brGh8F3cnjUj7paWiQKuQ57cNGxOc3GOTSSjDpRISPVNOedLEY8k1ylKzgiBwLAZ7QHq6YOAqzzD2bnCmGiUJpOxxZqmZ.rpuMJa7OO9PLGKHzRHD5ERFg9LVDSWhN8fumw4mf8oOmEUI59GLlHEijbYJvmsraihwjKwWPOEaBqlM56vpPj0CrGzsGou+C861cv9CI3gz8CvAAc542u+v81uSu8w82aHs8.j0cN1mokIyzXMUgr19Po+7YgxqE4KvKXJ14bpwnCZFrx4vmH49lOQCJZTHi6OsnPoPvrLsrrsUdY6qsmv7Y2fWV99pLGtkYTs.ZUaU5s0JzqSU50tB8VCkrpPosyoz8smQRXw5ROF97E1iEvtY.F1mpRk7XQ0rqYORBQHz6FgujdRBXbSFdCa2dG2Asa25QNNNvlkR6dENwMVvUteiqyuTuH2Kn5QxnXo.L7ZNEKn7dMasSCGWX7ABpyGSPca1x4WeTCfBAxDWuXWlHiBsZ37p7ji2UQ0SjoJ5HLmeNHi7BREDMSJ7nsxiYYnlAKv0itKgyHWR8aUhaF5PlxLa+7ynWQ4dMypHMgBfw4qgmu1YiGEbxUJNUpomI7Z47Jm5vT59ecEDrVelpThjyoIq0s4.VxGJQOQZz4zjcfsQdJ8l.AQzpJS62uxr5AGR9lVk.khwBl9rXp38cbBsbmFd6GGeDViMx4kXPbwzDMyPAqinWAMSxE20sOhptTKigY8F4A.qy71nP5aTKHFHvuqct7B86v2h0eBq0byK6AubMyWGZL9avHjxtHTardCXAZG40EJHkYdGYzHJ2yD74HllFUzsp9cPnEKLcwJQ6VEFcKXY2bV9WEr7skrbYuxeK5fBlVz8z+faEaWLXsrcI7sgs8xY6eTv16Y8ImsKPe65XaAL5ca9Asck9obrd0dwlarV5.NFrRCPSSNghomW8FsOYMn+Xo38smxzjv0ywZqgivgkOGbb40ZMrONHfRzkDba6S9oOO2gg9AYplItXBVmvLRpSSilAa0DJr5BPnYZCYUyHNysaarMUfYTgelwBXrzYGis0RmcJbhhvjD4KI4M+LWbd2LDfShrexnN72NfsaGTVCwp04H3d7WRHqNUuShc2zD6soI1eSSbvll3vMMwGtoIt2+ehley5IoZYT9wFDZxziytMwx5XAFTfYpUz+BvtP6LB
@Chazrox I may be wrong, but I think that is only for keyboard input.
@d-healey Even if gets and loads the files using the "{PROJECT_FOLDER}" wildcard? That has to be used for Engine.loadFontAs anyway, so why wouldn't it also work for this?
Ok, sorry about that.
This one actually works:
// this will load all of your fonts which are stored in the projectFolder/Images/Fonts
inline function loadAllFontsFromProjectFolder()
{
local fontsFolder = FileSystem.getFolder("{PROJECT_FOLDER}").getParentDirectory().getChildFile("Images").getChildFile("Fonts");
local fontFiles = FileSystem.findFiles(fontsFolder, "*.ttf;*.otf", false);
for (file in fontFiles)
{
local fontPath = file.toString("FullPath");
local pathParts = fontPath.split("/");
local fontNameWithExtension = pathParts[pathParts.length - 1];
local targetName = "";
// if the file name suffix is "-Regular", loadAs will use just the prefix
if (fontNameWithExtension.contains("-Regular.ttf") || fontNameWithExtension.contains("-Regular.otf"))
targetName = fontNameWithExtension.substring(0, fontNameWithExtension.lastIndexOf("-Regular."));
else
targetName = fontNameWithExtension.substring(0, fontNameWithExtension.lastIndexOf("."));
Engine.loadFontAs("{PROJECT_FOLDER}Fonts/" + fontNameWithExtension , targetName);
}
}
Ok, well I made it to the Fonts folder by navigating form the Audio folder, back to the Project folder, then on down.
But now I'm having an issue with
File.toString();
which returns the path for "Filename" instead of just the filename:
The Docs says it should just return the file name and not the full path:
I've tried using File.Show() on each of these variations here and all three open to the Audio Files folder in the Project Folder instead of the Project Folder itself, so it seems like there is an error with the FileSystem processing of the wildcard?
Even if I use the AppData folder and let it search recursively in any child folders, it does not return any fonts: