Still problems with Message.sendToMidiOut();
-
@d-healey No, will do right away, thanks
-
@d-healey said in Still problems with Message.sendToMidiOut();:
@ulrik Did you try changing
Message.sendToMidiOut()
tom.sendToMidiOut()
?I did try to use the
Engine.createMessageHolder()
method but with no luck. What I ended up doing was to just use theSynth.addNoteOn|NoteOff|Controller()
and making a child script that had theMessage.sendToMidiOut()
in bothonNoteOn()
andonNoteOff()
andonController()
callbacks which would take all theSynth.add...
events and pass them to the midi output.What it looked like if I added it to your setup.
-
@jonhallur @d-healey @lalalandsynth @ps
Now we need to get rid of the NoteOn number 60 coming from the TransportHandler, see this thread
-
@ulrik I used the extra script processor as @jonhallur suggested and it works both in Live and Reaper :)
-
@ulrik so you are saying that you are getting different MIDI sent out than the input notes? I used to have it in my script processor before already - added the message to controller as well and hoped this did the trick. But still only getting the input messages to show up on the midi track I set my dummy plugin as midi input.
Getting a plugin to pass through the midi was possible also by setting the midi out flag even before sentToMidiOut() was implemented.I'm talking about getting artificial notes outputted.
The most simple scenario would be an instrument with a sine wave generator and an arpeggiator outputting the arpeggiator notes instead of the input notes.
If somebody get's that to work - this person will be forever my personal hero haha
-
@ps said in Still problems with Message.sendToMidiOut();:
@ulrik so you are saying that you are getting different MIDI sent out than the input notes?
I'm talking about getting artificial notes outputted.The most simple scenario would be an instrument with a sine wave generator and an arpeggiator outputting the arpeggiator notes instead of the input notes.
Yes I'm getting Artificial notes outputted, however I'm not using an Arpeggiator, I'm using the TransportHandlers onGridChange function so I don't know about Arps.
I'm modifying the pressed notes and output the modified notes, and the "real" events is ignored. -
@ulrik ok wow. can you send me the snippet that outputs artificial notes so I can see if there is anything different than in my approach that doesn't work?
-
@ps Yes, here it is, it's cluttered with logging functions and other stuff.
This is my setup
so in the "SendToMidiOut" scripts NoteOn, NoteOff & Controller callbacks I just set the
In Hise preferences
Beware of using "Synth.getNumPressedKeys()" though, because the TransportHandler sends a midi note 60 with eventId 0, and it's making the NumPressed function go +1
In this snippet I'm only transposing the pressed keys but I guess you can do whatever you want using Synth....... functions
A big thanks goes to @jonhallur for contributing with important information!!
HiseSnippet 2068.3oc6Y0saabbEdWIstlr1tNnE4phh0DHAqhYnIkbrUSpqokDkMg0OzkLBonn0YztyRNUKmgc1gxhMvEBEnuG8Qw.819FzaxiPdCZOmYWxcWRtTzJwEHAQvPF6Lmyb9luyOyYF0RJboggBogYgNiFPMLugU6QbUuc5QXbil6ZXdMqNMZ2wX6QCHggTOCSyUeJNmYg0Lz+7MOdaR.g6RSFxv3XAyktOqOSkLZq5OmEDrGwi1g0Okz2udSWAeGQfXHfiUspZLf3dJoK8PBJ1JV.HZ3wTBYaEQQCMLWaag2n18DuhGI+wrP1IAT7iZFsgEJZ38DAdHhwQM1oGKvq038anggoUqjc+pQ69eg0ALO1jwSXgaqmvNQiz7g4JYg2pYfWszvqZJ3MGHYlBRqEAo2ypsqjMPkLChmepUSthJ8I.smFJQxZrxKJZsi.jfqpzmbJcOI7wDMbdP0pksges9mUrHP8gJ6yHR6mJYd6K5t+IA1Oxdr1copcD8GH3vGNkRDoDnahpsjTDAOmNJbQpmUrrKwgG+bt3jbUMZ5rprOk2U0agpkHRVUOlFrP8hmOqRM4dLWB3n2m5kqloEZJ3J5VKefBSNi3arHw2XFw2bQhuIJd2.wIj.6NRBObfHjJyUiDQP8JJocsa87PP7+vebRPSmmAe2f2kwoUbkTH3OVKo5YDtW.U5.514YUBopFbBjBfwONJ4PZY6ZagqKiG.Za6Oj6pXBtcWP.Hqi2k5PjcqU1F98F5eu45E+phEBDt.9UfciBHPTeLIXHEsT7rX7WheedRbFHQrGN6zEKv7s0V19CPq7H6pqWr.X2BocqU7HJRERvfdDXgpUo5mMs.R5.nxgRulvhVHafOxGNkTzyUkJirZk+rfwcJUtz5ikOdiP4IDLfy1j9CBng6IjuXHQBIyaCbdnSs68qef8GAv8iru+5vuBhWDegz1gay3nMfsgdeDuzTjBzU5qP77NTnnGwc.5lae2TQGoHmx1mU1tpFeEhziiJ46uKMfLh5s8nFmAANM8bnff.x0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bH4srR2NY5Pf+R5bjCmFh6NCD2s9b3iYyAtYpTxZooDvIleN4EmtT4jUiS.rsl9dZg5K+uW7YAFTnPOQWK2b02ZXuQtvt42NX+KsvCQfqtPkirURVWcep32.19VA4MyCxyTp4sDx2ZbIM6SgZZ4BxbKIdMKrU2bQ2WME5dyeeNwcQHYEKiYg48qu7nHW25+7us7n3VVoZpo5khnBK2Yl4T4v9Uu0UN15MYpLu0kV4XwbVtwUe8EKOm8ysloyw4Sby91g21Btm7v.r7U5mxDe+13Ivr8zueHZFNTKeT5M72Yuu4xBw2ypES41a9Xbk4fQn6n2EXL9UguoUCeepqJAfqYs2W7t4IfSa9qmySxeC8a6BeQk09t3g4GrzOLu4puKdH909d7Cw+yrZS4dcDHpNZnZdOFu4+1x9RdGjvzqgyLWoKy80WRc9A00.uRWB5GKH9ChBhQuca2CHPKevwoXGDsgBRtT7YggF0wXPyUvnknuqheiL.lXp+3+B+DOYM7ay3IqMdx+uXi9DWo3ktQYWXMlqqGA12b8emyBVGfeaWa7a.XYUsRU7BVrW55hT7GCIIyWmMtB5r4UPm6eEz4StB57fqfNO7JnyVKTGr15SFpD8iR4fAZ0PWFxzL5OmkNR23+ANs.eUB
Let me know how it goes.
-
@ulrik proof of concept
-
@ulrik wait. what is happening here? Is this an audio effect? What I see on this video goes beyond any logic that I can come up with hahah
As I couldn't believe it I compiled your snippet as vst3 Effect with exact same settings and I couldn't replicate this crazy magic.So you have your effect on one Midi track set to IN and on the second one an Instrument with the channel (not the plugin) set as Midi input and record on the same track?
So basically you are modifying the midi stream for the whole project?
But I'm also wondering why this doesn't work here on my end.
-
@ps hmm..what extra definitions do you have in the Hise preferences?
I think I had the
ENABLE_ALL_PEAK_METERS=1
before, but I had to remove that to get it to work
-
@ulrik had nothing else in there :/
As I believe Midi Out is a pretty important topic - especially for commercial developers (A user / client will not understand why it's not possible as it is a pretty basic thing with most plugins eg. Kontakt) we have to have a "typical" case working in a DAW so we can say HISE can do MIDI OUT.
By typical case I mean a virtual instrument that is modifying the input midi and you are able to fetch that generated midi on another Midi track. This is at least what I got hundreds of request for.
So the most simple scenario would be a sine wave generator and for example an arpeggiator or any other artificial note generation - and what we wanna be able to record as midi is the notes that we hear not that we input.
I'm clearly failing to make it work and got left with maximum confusion as it works in the JUCE Plugin Host but not in the DAW.
@d-healey @Christoph-Hart @ulrik any pointers where the missing link might be? It seems to work in the JUCE plugin host but not in the DAW.
In the DAW I always get the input notes passed. (And I'm sure I'm routing it properly) -
@ps Agree, it's important, I wish it was easy and a no brainer to code.
-
@jonhallur I still can't get it to work. Could you try with this snippet and if you get it to work let me know what you changed? Also are you exporting as a MIDI FX?
HiseSnippet 1258.3oc6Xs0aaaCElxNrn1Y25VwvvdRnXO3fkEXklkKqXn4hsyBZbiQra5dYnfQh1lHxjZTTN0nnureY8w8vdX+T5+frCojijRU7xLVKVGZdHHma77QdtpzQJboggBIxpRuIATj0Gg6NgqFt2PBiiNnAx513NRZHUg1cR.ILj5grrJuuVpUkEPled8C2k3S3tzTVHzIBlK8P1HlJkamseDy2uEwi1iMJi1qs8AtB9dBeQDfjx35n.h6YjAzGSzpUBirtUSOlRH6pHJZHxZgcEdS5NTbNOV+SXgrS8oZBGTW3fhY2R36oQrlKZugLeuNSuwgHjEtS58ub78+t31LO1k7SeG9Li.6TKx9dXUJO7JmCdNYgW8Lvq.HYkARKDCo6f65JYApTIZ7rH9.thJ6Sfm8rPIVWj0qv6I.E3pUFQNi1RBDWZPs0qWeYa3WK8f9QbWESvsE7GKTzi30Vp5KpVo5KqZeUQ86WnLsajBeeprPw5HsbVFViGM5TpbY6wD+H5kJBW+7uo3q+MMaH2M9VmQQA+.NScT.kecIBnjmJ3udxAMHJhNPjvCzKfJULMDrZPGCY0wgkJ3FzvyTh.itiBDb8IXsnJIOJNPzxWPTL9fdL.pLHB8o3rrbPOOaQyjrDI.H1aUwOhN4TAQ5gNcvzJkJ2xyy6BstLEcTJ2Kt3huNO2USXaTVQetJU4otybuK8KV3WT019df2dJySM7d+fsyZqTeYMuFrv.exjibUjwzGahZf39D+PpQ9ghyAy.VaYH+IVLkypaXn2KJTIFsujDLj4FlyxFz9jHe0NAAThT2IAjpjQwB20GZF.G0wvql.DTek02x7ylaVeispugiQqdhAC7osEdzbmrtnEJh4bpuFJFdOIjdB0ERsxfkK8FHrkOQ0UMw+JmTmlSCAWkOjhJUodY0o7ax8x360q9Rz452zKCxu521F8l06PmFgWDfg7sez8bSD.0O4p40E17PlZR1dx+q0S5lBw6f6vTtCKFikJ.iPU1aCLlzI+iwM62GByo.bAbqe9sSa6rt+Shc+h3tLN0LL037uzPa+TnzwdeJmJ0OdNyXp5edSmpFbimpFW41CpvBCDg4N3tzQrdPKrvrL00BR5uZJ7x2YhHKTzqeXK3RVnMcIpHoIsXmQhHtJWZP4YMc2YNmtuv+8ltW5lNc+KR3lhnUKZJeoe2BaeMivaClAqPsBa.WHoMGCiRpo6xszCpVwW3R7scs+Q6oZMfNsAVsTE34UPe5ws8yny375bBEXCU4FMLY+qP77Rvk6xvQ9sv.AXX+x1v1GyZMi2QX7pnDbeFX9lX7Cq6fl+j36W3pp+weaNbHk60SnKQOJRUa14M2Pa9Pb78fUOx84PUlhwtrQA9zl7wPcLvQiwOGmrB4Tt4mr1VvEACEbla1wNGSUR1fATYVrW3EZGkB1AMkyc29XpOkjcD52r8gvnOhTuA5b9V37O9SCKLd8U3X3Zqygse+ckwx++dkwiEQ5uBrMARBgOBDCSs5Bap4RSlwo6cXURWkGSWWSGupF2yPn+dtDgNZZqDgNSE9NwGiHtRwybi6JpySusgCbu4l+6MUvs0z1NHSmRvNb8UpiFAMlelqq9I96flaEaypygM2eNrYs4vlueNrY84vlMlCa1bl1nmItSD7s3wkb.iNMMiOrrZxIP1qISG8W.T2wiNB
-
@ps Here's the project, try with that
TEST PROJECT -
@d-healey Do you have "JucePlugin_ProducesMidiOutput=1" as an extra definition in the preferences?
And I see you don't use "Message.sendToMidiOut()"?
-
JucePlugin_ProducesMidiOutput=1
Yes.
And I see you don't use "Message.sendToMidiOut()"?
Ah crap. Something went weird and it's duplicated my script. I'll fix it an update the snippet.
-
@d-healey I think for narrowing it down it would be important to know if Message.sendToMidiOut() equals for example what Message.getNoteNumber() is receiving at the same point of the midi signal flow. Or if the events need to be specified somehow.
EDIT:
Those are the callbacks that appear once I add sendtomidiout to a script processor - percentages that don't change value when I play notes... -
ok so i figured that my last tests in the JUCE plugin host didn't work anymore - now looking at the callback I realised why. I didn't kill the initial notes - so it seems there have to be artificial notes only in the midi buffer. So I have a very simple snippet now that does work in plugin host but in ableton I still get the input notes instead of the single artificial note the plugin is generating. If it does what it should in the plugin host we have to be so damn near to have it working in the daw...
HiseSnippet 1287.3oc6Xs0SibCE1CIyJRX6kc6ppp9znU8grRTTBkxkVUsPtQiVBDQBr8kpUlYbRrXF6od7.DsZeo+xp5uf9qnOu+CnG6IgYF1IozTPpEQd.w4l8m8wmui8zQvsIAAbAxnPuQ9DjwiM6NhIGVaHlxPspiLVzbmC6bvQ8PUG4iCBHNHCib6prZTHOR+68urJ1EyrIwpPni4TaxdTOpLVamseE00sI1gzi5kv601tkMmUi6xCAjjyrLxGaeJd.YerxsELQFOpgCUxEckXII.YjuJ2YT2g7yYQ9eLMfdhKQITA0EFnH0M4tNJDqzhpMj55zYxJN.gLL6Du9yEs9elYapC8J8w6Cep1fUbDI2OLVHM7xkBdURBuxIfWFPxHAjxGAomX10VP8kwVT3YIyVLIQzGCa6IgRjuHie2rFGbfIWwCeJoo.DtJfRqWt7xVvedw2WrX+PlsjxYVb19bI4.VoWT7sEKT7cEstto98yzlZhDbWWhHSypbsXVAVhE5cBQrr0YX2PxUNBa.o2UMm9tZxjtcz5NgibVKFUdfOgMsiBnwaVv+cTq5XIVkJFqC7ymHjTEDLpSNCNWGkXJXVmDbpj6q80ymyTifwRxwmjhREMc4XIkMnGEfJExQehYRUUPWjrrYTrP0sGCfnYqn4qHiNgiENnSFLoVovibbbtT4MUR7h0d4kW9ko0t5X0ZmkjKjwNOYt0q6E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