Work around wrong offset in plugin windows - #462
Conversation
|
Great job! There is one small bug—in REAPER, when moving a window with a plugin, the offsets are not recalculated. |
|
The moving a window bug was present in Ardour as well. I debugged it a bit and discovered that there wasn't a I created this patch to fix the offset bug when moving a window. It uses an alternative method of finding the host window when a reparenting occurs if the original method fails. Seemed to work in Reaper, Carla and Ardour with various plugins. |
Thanks!
I can confirm that I also have this effect in REAPER (but not Ardour for some reason) and that the patch from @Desidiosus fixes it for me. |
|
Thanks a lot for this PR! With the patch from @Desidiosus applied onto @trurli 's branch, I'm noticing the following regressions in Reaper:
Is anyone else able to confirm these regressions? |
|
@Schroedingers-Cat Could you provide some more information about your setup? I tested plugins by the companies you mentioned by name aside from Kontakt 5 and these were my findings:
If you export these env vars and run Reaper from the same terminal, you could send the log output if you can reproduce the issues easily. |
|
I tested it on Reaper with MeldaProd plugins and TDR nova and it's working ! Thank you so much ! |
|
@trurli do you intend to merge this patch from @Desidiosus into this PR so that @robbert-vdh can pick them both up? |
Done. |
|
Thanks so much for looking into this! Great find. I'm still seeing some issues with respect to sizing compared to the old Wine 9.x behavior with specific plugins , and from a very brief test run it seems like there are still some resizing issues in Ardour that need to be solved before finally tagging a release, but this is a massive improvement! I'll merge this into |
|
i hate to be the bearer of bad news, but this pr doesn't work for me. vst2 plugins load fine, but vst3 and clap plugins give me a stack overflow and cause plugins to hang in bitwig studio. |
What is the rest of your setup? Distro, desktop environment, X or Wayland? |
cachyos, kde plasma, xwayland. i actually was able to get a working build by building directly from the github repo, and not from the bespoke aur package that was set up for this branch. so, it's an issue with that and not this pr most likely. |
|
Thank you so much! Massive quality of life improvement! Running on cachy, cosmic de, reaper. |
|
I think I found a regression when building yabridge from this branch. The following is happening with both, Wine 9.21 and Wine 11: Omnisphere 2 VST3 opens a blank UI in Reaper's FX Chain window but opens its actual UI as a borderless window behind Reaper at the top-left. This does not happen with Wine v9.21 and yabridge 5.1.1.
@Desidiosus thanks for looking into this! I wanted to catch yabridge regressions early on so my findings were made still with wine 9.21. I'm not sure if it is intentional or known that this branch breaks compatibility with that versions below 9.22? The plugins showing a blank gray UI window was related to VST2 plugins on Wine 9.21 using this yabridge branch. When switching to Wine 11, those VST2 plugins work. So I guess these changes are simply incompatible with Wine 9.21?
There's a bug in yabridgectrl that makes it fail handling vst3s if the actual binary in the .vst3 directory has a different name than the .vst3 directory which keeps yabridgectrl in eternal "purging leftover vst3". So after renaming either the binary or the .vst3 directory to match each other, yabridgectrl handles that plugin correctly. However, Sumu VST3 works fine this time with yabridge built from the tip of the new-wine10-embedding branch. Also, native Win32 context menus work fine with both Wine v9.21 and Wine 11 as well as painted context menus such as UVI Falcon. |
|
More on the regression of this branch with Omnisphere 2, the log shows this during UI start:
The Wine version doesn't matter, happens with 9.21 and 11.0. The only thing that matters is yabridge stable vs this branch. With yabridge stable:
Reparenting twice is intentional? Her are the full logs: |
|
@Schroedingers-Cat My latest commit in #463 should fix the regression with Omnisphere 2. Thanks for reporting it! Reparenting twice is intentional and the code comments explain it well: yabridge/src/wine-host/editor.cpp Lines 374 to 399 in 945528c |
Fantastic, can confirm it's working!
Interesting, thanks for sharing. Do you think wine devs would be up for making this workaround not necessary? |
This PR works around the issue of wrong mouse cursor positions as mentioned in #409 by getting the parent window offset via xcb and using that when no "synthetic" ConfigureNotify event with absolute coordinates is present.
Tested this with wine-10.20 and various (mostly VST3) plugins in Bitwig, Carla, Reaper and Ardour using gnome with Xwayland.