zynaddsubfx / zyn-fusion-issues

Issue Only Repo
31 stars 0 forks source link

Windows Build does not take Keyboard focus in Cakewalk #283

Open mnstine opened 3 years ago

mnstine commented 3 years ago

There is a switch button on the VST panel to give the plugin focus but I still cannot type anything into search.

fundamental commented 3 years ago

As mentioned on IRC it looks like this issue may be a result of the old version of DPF which is going to be the code which handles the initial reception of keyboard events when in VST2 or LV2 plugin modes. There's plenty of host specific quirks, so it's entirely possible that this is somehow still a zyn bug, but it seems wise to have DPF upgraded first.

https://github.com/zynaddsubfx/zynaddsubfx/ is currently using https://github.com/DISTRHO/DPF/tree/e0d8e14a14d407648768da7e34bcf31812245387 which is a few years out-of-date. Right now the upstream DPF is in the midst of some refactoring and upgrading of parts of their codebase.

@falkTX The refactoring work is still ongoing, right?

falkTX commented 3 years ago

Yes, still ongoing. Very close to being final, mostly blocked by me not having tested on macOS and Windows yet.

This is happening on Windows or macOS? I want to add some test code so we can confirm the issue, behaviour and fix.

fundamental commented 3 years ago

Windows builds are back to mostly working, though I keep saying I need to get automated nightly builds sorted. MacOS it's been a while since I've compiled for that system. It should be a lot easier with my desktop upgrades, but I haven't sorted through the VMs to do so.

falkTX commented 3 years ago

I mean, testing against Cakewalk, should that be done on Window or macOS? In which system does the issue happen? I want to be able to reproduce the issue with a generic DPF plugin, so I can have a test-case in the core code.

fundamental commented 3 years ago

Windows if I'm not mistaken.

mnstine commented 3 years ago

Hello,

I can only test in Windows and that is where i am experiencing it.

Thanks Mark

On Fri, May 21, 2021, 8:01 AM Mark McCurry @.***> wrote:

Windows if I'm not mistaken.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/zynaddsubfx/zyn-fusion-issues/issues/283#issuecomment-845933926, or unsubscribe https://github.com/notifications/unsubscribe-auth/APWK3VQH7GEU2WPIC3PXVRTTOZKS7ANCNFSM45JBGI5A .

mnstine commented 2 years ago

Hello Team,

I have been testing in Ardour demo for Windows and have the same issue. I have not compiled a new version since arround July. Any chance a new compile might fix this?

fundamental commented 2 years ago

The DPF update hasn't happened yet, so I wouldn't expect the behavior to have changed. It is still pending, though I don't have any specific date to expect it on.

falkTX commented 2 years ago

We can begin the update process at any point now actually. I made it as backwards compatible as possible, so it should be pretty straight forward. There are going to be some deprecated warnings, but these will indicate what to use as replacement.

fundamental commented 2 years ago

Last time I recall things going horribly wrong in an upgrade and you saying something about it not being backwards compatible since zyn was using a very old version. Has that changed in some way? Either which way it would be great to have that updated to hopefully resolve some lingering host issues. Per the windows build side of things I know there's at least one unresolved windows issue with the recent MRuby upgrades.

One user mentioned some issue building in IRC, but it was a driveby comment and nothing got filed on the issue tracker. Should be a quick fix though, or at worst another hacky patch on a lib until I can let upstream know about the problem.

falkTX commented 2 years ago

Last time I recall things going horribly wrong in an upgrade and you saying something about it not being backwards compatible since zyn was using a very old version. Has that changed in some way?

Yes, the external ui stuff works again, and a few backwards compat things got added.

I think we just have to try it and see.

fundamental commented 2 years ago

Windows build should now be fixed through some MRuby hackery, Now I guess it's just a matter of doing the DPF update and fighting with the system for a while. If it's as described, then it should be relatively low friction.

falkTX commented 2 years ago

Note that VST2 in DPF now correctly gets keyboard events from either the host native events or host VST2 special keyDown/keyUp opcodes. That said, the VST2 special opcodes are not sent to the external window (if that is how the plugin decides to go, afaik it is the case for zynaddsubfx).

While not a quick thing to do, updating zyn-fusion to use the regular UI class that DPF provides will very much likely fix this issue of keyboard input/focus.

falkTX commented 2 years ago

Note: it is still possible to use a custom pugl, but has to be done in a way that is compatible with updated DPF's TopLevelWidget class, see https://distrho.github.io/DPF/classTopLevelWidget.html

fundamental commented 2 years ago

As long as it works I've got no interest in having a custom version of PUGL, just one that works in the environments it gets deployed to with minimal fuss.

mnstine commented 2 years ago

I may not be much help but if there are any assignments you need some remedial labor for a want-to-be programmer let me know.

Mark N. Stine (918) 808-5152 @.***

On Sun, Sep 26, 2021 at 2:39 PM Mark McCurry @.***> wrote:

As long as it works I've got no interest in having a custom version of PUGL, just one that works in the environments it gets deployed to with minimal fuss.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/zynaddsubfx/zyn-fusion-issues/issues/283#issuecomment-927359075, or unsubscribe https://github.com/notifications/unsubscribe-auth/APWK3VXM5BDQY7UHRDVXLLTUD5ZGTANCNFSM45JBGI5A . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

fundamental commented 2 years ago

Thanks for the offer. If you want to get involved there are a number of issues on this tracker with the 'good-first-issue' label. Those should be a good starting point. Outside of the issue tracker I've tried to summarize some of the different ways people help out at https://zynaddsubfx.sourceforge.io/contribute.html .

mnstine commented 2 years ago

I have changed my testing platform so I can only say that it now works in Ardour. The version of fusion has not changed from 3.06 that I can see. Was this just a change in dependencies? I did follow the new build instructions which are different than those I was using before. That might have had something to do with it. Also on the instructions, a couple of lines on why I should (or should not) choose Msys would be nice. I did the Cross Compile instead. I need to restore some backup files so I can retest in Cakewalk. As soon as I do I will report here. Thanks for all the work put into this!

fundamental commented 2 years ago

The DPF changes were a dependency version update where DPF is responsible for translating events from the plugin host into the plugin itself. Per Msys, I think that makes more sense if you're primarily only on that platform, but personally I stick with the cross compile because my development systems are all Linux.

mnstine commented 2 years ago

Ok thanks,

From GitHub, how would I see this update took place. To me i did not see where there was an update to test. I just tried it.

Yea, I was not going to invest much time in learning what Msys was.

Thanks Mark

On Sun, Oct 10, 2021, 2:55 PM Mark McCurry @.***> wrote:

The DPF changes were a dependency version update where DPF is responsible for translating events from the plugin host into the plugin itself. Per Msys, I think that makes more sense if you're primarily only on that platform, but personally I stick with the cross compile because my development systems are all Linux.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/zynaddsubfx/zyn-fusion-issues/issues/283#issuecomment-939542727, or unsubscribe https://github.com/notifications/unsubscribe-auth/APWK3VS3XQI6MZU3VQAFP3DUGHVUTANCNFSM45JBGI5A . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

fundamental commented 2 years ago

https://github.com/zynaddsubfx/zynaddsubfx and https://github.com/mruby-zest/mruby-zest-build/ is where the backend (i.e. audio synthesis) and frontend (i.e. GUI) exist. Modifications to those repos are generally what you're interested in.

mnstine commented 2 years ago

Ok Thanks.

I am testing on Cakewalk. Getting a few crashes and keyboard is not working. Nothing consistent however. Will keep playing with it. Probably just need to buy Ardor or Ableton.

Thanks Mark

Mark N. Stine (918) 808-5152 @.***

On Sun, Oct 10, 2021 at 6:10 PM Mark McCurry @.***> wrote:

https://github.com/zynaddsubfx/zynaddsubfx and https://github.com/mruby-zest/mruby-zest-build/ is where the backend (i.e. audio synthesis) and frontend (i.e. GUI) exist. Modifications to those repos are generally what you're interested in.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/zynaddsubfx/zyn-fusion-issues/issues/283#issuecomment-939569212, or unsubscribe https://github.com/notifications/unsubscribe-auth/APWK3VS2QYGG44A4DY6SIN3UGIMM7ANCNFSM45JBGI5A . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

fundamental commented 2 years ago

Drat. Thankfully keyboard events are needed relatively rarely, but I had hoped that this would resolve the input problem.

falkTX commented 2 years ago

I am quite sure the keyboard event handling is fixed if using the dpf provided pugl.

falkTX commented 2 years ago

Here is a testing plugin for windows 64bit that implements keyboard input, in the same manner as zynaddsubfx will eventually use. It works but is a bit finicky here, it doesnt always get the focus somehow. Clicking a few times it eventually does (tested in carla wine bridges, so might be a wine thing too).

d_ImGuiSimpleGain-vst.zip

mnstine commented 1 year ago

I tried a couple of weeks ago to build again. It built successfully on both Liniux (windows port) and Msys2. Any idea when the keyboard issue might get resolved? I need to open another issue for the voices not showing up at all in the executable version on Windows (Both Linux port and Msys2 builds).