Clock Sync my FX Plugin
-
Hi there, can anyone help me or tell me how I can Clock Sync my FX Plugin to the clock of my DAW? I'm using Timers to activate and deactivate functions but they are not in sync in my DAW. Thanks
-
@treynterrio What are you using the timers for?
-
@treynterrio Use the TransportHandler, it will sync very well to the daw
-
@d-healey the timers set a control from 0 to 1 (like on off)
-
@treynterrio said in Clock Sync my FX Plugin:
the timers set a control from 0 to 1 (like on off)
I don't think UI timers can be sync'd to anything since they are not realtime. There is the synth timer which runs in the audio thread - although I don't think it does in a deferred script, and I don't think it's sample accurate.
-
@ulrik do I just have to insert this line or do I have to connect it with the function
const var TransportHandler = Engine.createTransportHandler();
-
@d-healey said in Clock Sync my FX Plugin:
There is the synth timer which runs in the audio thread - although I don't think it does in a deferred script, and I don't think it's sample accurate.
is there a other way? it would work with the Macro Modulation but this doesn't work in a FX plugin
-
@treynterrio said in Clock Sync my FX Plugin:
is there a other way?
Not something I've looked into, but the transport handler sounds promising.
-
@d-healey Do I just have to copy this line into my script above or do I have to assign it to the functions?
const var TransportHandler = Engine.createTransportHandler();
in the HISE docs it says the following where he synced the clock with the line:
Grid events: (a synched timer with a customizable frequency)
-
@treynterrio I don't think I've ever used it. But you will definitely need to implement some of the callback functions. In addition to the docs see if you can find some examples on the forum or in the snippet browser.
https://docs.hise.audio/scripting/scripting-api/transporthandler/index.html
-
@treynterrio this is a small example with the transport handler
HiseSnippet 1135.3ocsV01aaaCDlJIpXVaCXEX+.NTfMnTDDam5l0hgf0kDmWPWRLl8J12JXnnrHhDoFIURLF1+4808osiTxuDmztTiMCj.Qd28vm6gGOxAZEiaLJMIn0nIkbRvWDNbhzlcPFUHImdHI3qBOHWwtBmkwSfi9Ux9SJoFCOgDDr9wNuBZsAw+6O+g8o4Tzu4SQHuSIX7eRTHrymcvadqHO+HZBejnXAu68lSYJ4ApbUExn0C6PJorqni4mSctsVHI3I8SDVkdnkZ4Fzm8UISFlotQV6+6DFwk4b2ftjgHP0SSNHSjmLXZ1ZHjfMFLO2WuN2+5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7L2XnKwexXQct.eDy6Yr6B08BbmUMvWrpA1aUC7kqZf6tpA9cqZfu5eOP2aL+wJqpn9XCgb1f99VIAA0upwWsR9G.auNcFA
-
@ulrik I don't know why but this doesn't work. The Buttons don't go on and off in time of my DAW
-
@treynterrio Do you have a snippet?
-
@ulrik I don't know what I've done here know but that's simply like I have it in my project:
HiseSnippet 2014.3ocuX8zaabbEeojVay0ME1.9XQwffjBJWAKRYIEGX3JZKQISXKYFQEiHXXDLZ2gjS0xY1r6rhhNv.4POzC8ZAZtz1OA8bOEjOBEHGJ5sjaA4T5Wf17dyrK2coHknERxBvEbdy7dueu+Lu8MSqPoKKJRFZUp7ACCXVk9E1sGJT81rGkKrZtkUoqXqXQJqGMLfFEw7rJUZ9cv4JUdAK8y2uwin9TgKKgzW+A+y+5FOWxcYOk2mqxVXq5Og66uM0ic.uOKi9p0a5JEaJ8kw.Nl2tpU.08XZW1dTbYyYCfngGWICaqn.XrJsvijdCa2SNPXV+y4Q7i7Y3fZVsAAYHusz2CQLR0ZydbeuVo1ajEHkVYV+7Fq+V16x83inm4EtgdBRFG48GklqH7lu.7pkGdUyAuI.oR4fzBFHcS61tg7.U1LHdttcSghE1gBt87PwrVq41or8lRXEB0c5SOlscHLXDGUta0pKQfWKdeGGv0GoHmPCIGfgExCHoL1ko1T1OPJfAUda8rucQNdTrRIEqOUdRleLt1Njwd0zUjY5w3YKlOcHvhN4DYnQmNLWX05IzK1Y4kK6FxfP.Q0C9EREQAxPEoGU34yBSj1AOFDSCQWtfcGyxOHckO1rvJnz.gEwTFIw.rQ3Bxfdb2dSV3jAPpMINHvCDHxbs6Q3Q50FAYwDZDo1xqu5AjJFgzmAB.H89qSjcHqR9jXZHDcHBIjAsnyAO9Nf1aHnPZyNgbuJpvX1RjZ2aLnEMT3R5K8.DIIAgrNfHXmBBRP8APx61EHTwiNHhD.9oif8UoBG7jt6BbVAF1RyYiDFSzAJeWpuOxjw75vCYDFEfu1VRWDPF7qzvtw8g.nYo8nmXB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mxI4Oph0LZclTooYc+t5Ev6g0mAXTvj.Er+Cat23VTevhlneS6QmjeapFmyEmpmyB1pn08lZNN16234a03oO7vhVz0r8BGNfolpQ80WFCHc2VN7+N4w+6TL5bqI53lFhVH03sKcJLL0vsKsBLBJn1FZ7LHZz5qeX87f9Jyvt7o.6O6ESSy+ZSkfYPIipELMc7AmqNN6I0ugMbdpXepp3EGf2VRxDnyK+o0wOpI.m5v7N6wuMgElsaS37uriYEt2ztEW41ax3ctIfWnf4O03M4tYdKayY9y.6B1a+Qm6Ew7FCkK7RYttAKW0TkUihz+m2Qoof66dJqSVkf5+s5ilX+B0HfY1FNtG1PVANfmT5EY.ddpbPKPgPR7mLh7e7qp+X9YnBUrvx+4ZQ3.7JMva.nPfb9Y9ZrpctWik09xXEb7wcov9ePu1PycskwgtL7XrBnCXbWzb3FUy3p3XDBsYBO8f+O7jLYMbbojIqkN4OK5nO0MT9wtl9JvTgqoo.1sPe0jks2EGSpUrSnu3Oca7K57O10snnNCiqTrQju6+s2Lx3cOS6SVyFiqdYYbsKKiqeYY78trLduKlQ71beXrR12TjCJhkc.BXWd9A1ktZw5Q4u6UsBaJ7XmlJ513ofx0tyW1P3UX+bru+YVCRbr009X1.b7e9WcyEu++85005DrKj1mdq+wNeyq9Ca7PEj7eTrhk0iYSwIPSqlxgVmiM47imMcX8YylNrdpMk9otKiMsaqF5F0KUxb8nFp+.bl47r.
-
@ulrik I also couldn't get it to sync via the clock in HISE. Its basically the same like in the snippet the Timer should activate and deactivate functions
-
@treynterrio Could you explain what you want to achieve when you say sync plugin, what exactly do you want to sync and with what?
-
@ulrik I want to sync the function that goes on and off by the timer to the bpm of my DAW
-
@treynterrio Try this and see if it suites your purpose
HiseSnippet 2466.3ocuYzzbaabEz1H1D1sicGeHG5gsZRaoTYLEHoYXGONh15CaN1RVwjwi835lABXoHh.2EA.TRzYzL4POzC8Zmo4Ra+Ezy8Tm9SnyjCc5szSsSOk9GnIu2aAH.3GRzZRCFQfce6662ae6GZ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