Robbert van der Helm
e1e5a1588c
Unmap wine_window before reparenting back to root
2021-07-21 17:53:27 +02:00
Robbert van der Helm
d3d21c65f4
Change editor window destruction order
...
The wrapper window can only be removed after we reparented the Wine
window back to the root.
2021-07-21 17:50:29 +02:00
Robbert van der Helm
f6fb45fee3
Mention Ardour VST3 editor resizing
...
Ardour ignores the `IPlugView::resizeView()` and only listens to
`ConfigureNotify` events for growing its VST3 editorsZ, so now this
works.
2021-07-21 17:16:21 +02:00
Robbert van der Helm
e223c98b0d
Remove XEmbed testing todo
...
Still seems to work 'fine' (as in, not really).
2021-07-21 17:01:02 +02:00
Robbert van der Helm
e95f381fa0
Remove unnecessary unreparent check
...
Or at least, hopefully this is not needed.
2021-07-21 17:01:02 +02:00
Robbert van der Helm
f04bc7a07b
Mention the Carla VST3 regression
2021-07-21 17:01:02 +02:00
Robbert van der Helm
f3bce6ee15
Mention the embedding rewrite in the changelog
2021-07-21 17:01:02 +02:00
Robbert van der Helm
e28bc63f8d
Also resize the wrapper window for VST3 plugins
2021-07-21 17:01:02 +02:00
Robbert van der Helm
4277561aa4
Reorder Vst3Bridge methods
2021-07-21 17:01:02 +02:00
Robbert van der Helm
418cd68a81
Resize the new wrapper window for VST2 plugins
2021-07-21 17:01:02 +02:00
Robbert van der Helm
42762d1abe
💥 Use another layer of editor embedding
...
We still need to make sure this window resizes properly, but this should
prevent the host from interacting with the full screen `ConfigureNotify`
events we keep sending to `wine_window`.
2021-07-21 17:01:02 +02:00
Robbert van der Helm
75ab133adb
Change ProxyWindow into a more generic X11Window
2021-07-21 14:37:52 +02:00
Robbert van der Helm
a38e7c3588
Rename DeferredWindow to DeferredWin32Window
2021-07-21 14:26:34 +02:00
Robbert van der Helm
68d4a6610e
Don't reparent when the parent gets reparented
...
Some hosts, like Carla 2.3.1, will resize their windows to match the
reparented window's client area. This messes with our ConfigureNotify
setup.
2021-07-21 13:20:39 +02:00
Robbert van der Helm
1ee1229e47
Only show reparent message with editor tracing
2021-07-21 13:20:05 +02:00
Robbert van der Helm
acfceaa93f
Reuse the reparenting tracing in XEmbed
2021-07-20 23:13:23 +02:00
Robbert van der Helm
a749faa17f
Don't trace the start of every X11 event
...
We'll already print the event anyways.
2021-07-20 23:08:44 +02:00
Robbert van der Helm
ca6fc3a453
Fix typo in log message
2021-07-20 23:06:59 +02:00
Robbert van der Helm
b1fc5233d1
Add missing copyright headers
2021-07-20 17:33:26 +02:00
Robbert van der Helm
ff76e482f2
Inhibit the event loop during VST3 editor init
...
This should in theory prevent Nimble Kick from triggering a stack
overflow when the event loop timer procs before `IPlugView::attached()`
gets called and the plugin hasn't been registered yet. I haven't seen
any other VST3 plugins trigger a race condition here.
2021-07-20 16:24:25 +02:00
Robbert van der Helm
640c188338
Fix duplicate timestamps in Wine log messages
...
Regression caused by the merging of these two functions in a1cb3b6 .
2021-07-20 04:09:19 +02:00
Robbert van der Helm
22be79aa0d
Move X11 event tracing behind +editor debug flag
2021-07-20 03:15:39 +02:00
Robbert van der Helm
a1cb3b614b
Add a +editor flag to YABRIDGE_DEBUG_LEVEL
2021-07-20 03:01:16 +02:00
Robbert van der Helm
9fcf91dc72
Oops. (fix inverted conditional from last commit)
2021-07-20 02:39:17 +02:00
Robbert van der Helm
138dfb3284
Fix regression in pid_running from d99f571
...
In some cases we would treat dead processes as not running (we could
also get EAVAIL instead of EINVAL, so it's better to just check the one
thing we should treat as a success instead).
2021-07-20 02:35:24 +02:00
Robbert van der Helm
fae8314017
Merge branch 'removeme/reparenting-tracing'
2021-07-20 02:18:55 +02:00
Robbert van der Helm
6d76daff80
[yabridgectl] Print yabridge host paths in status
2021-07-20 02:02:39 +02:00
Robbert van der Helm
db8eb5b678
Add a todo about the editor debug level
2021-07-20 01:31:24 +02:00
Robbert van der Helm
f2ffb68b55
Attempt to fix rare multiple displays issue
...
(cherry picked from 1950206159fbc830718803fa152b636b2a914a95)
Under certain DEs/WMs, the window might not render at all when using
multiple displays and the primary display is set to the rightmost
display.
This seems like a reasonably candidate for fixing this.
https://github.com/robbert-vdh/yabridge/issues/89
https://github.com/robbert-vdh/yabridge/issues/104
2021-07-20 01:10:31 +02:00
Robbert van der Helm
8fbc13fc25
Steal the window back when the WM reparents it
...
I've seen this happen once or twice. Earlier on (in #40 ) we could get
away with just reparenting the window another time. But here both
reparents succeed, and the issue still happens. But a reparent notify
for `parent_window` did appear on system affected by this issue, which
is very odd. Hopefully this will help.
2021-07-20 01:10:31 +02:00
Robbert van der Helm
0f75461379
Check the windows IDs when handling X11 events
...
This seems like a good idea now that we're listening to more and more
events.
2021-07-20 01:00:03 +02:00
Robbert van der Helm
906ead26fd
Perform some more diagnostics when reparent fails
2021-07-20 00:43:57 +02:00
Robbert van der Helm
ca883da5b2
Add tracing for the various X11 events
2021-07-19 12:59:16 +02:00
Robbert van der Helm
503720a9ca
In the issue template, suggest clearing log first
...
I get quite a few logs with a ton of cruft prepended to them, maybe this
will help.
2021-07-19 11:40:21 +02:00
Robbert van der Helm
0e57f410a9
Warn on startup if RLIMIT_MEMLOCK is set too low
...
This should diagnose issues like #119 .
2021-07-18 23:13:51 +02:00
Robbert van der Helm
5bce89d50b
Suggest troubleshooting from a terminal
...
This makes sure that the user sees all errors and warnings coming from
yabridge, including that `mmap()` error message from the previous
commit.
2021-07-18 23:13:51 +02:00
Robbert van der Helm
fe61a28524
Print a distinct error when mmap() returns EAGAIN
...
As mentioned in #119 .
2021-07-18 23:13:42 +02:00
Robbert van der Helm
3c14f0391b
Move memory mapping setup to a function
...
So we don't need to repeat this twice.
2021-07-18 22:40:04 +02:00
Robbert van der Helm
a02dcbdb5a
Fix an...interesting spelling correction
...
I might have accidentally hit `z=` at some point.
2021-07-18 19:48:16 +02:00
Robbert van der Helm
28ab46e3c1
Explicitly check for CF_HDROP
...
We should of course not expect all global memory to be a HDROP, oops.
Apparently REAKTOR sometimes uses the drag-and-drop system for its own
internal data.
2021-07-18 19:20:44 +02:00
Robbert van der Helm
0d02951886
Build a 32-bit version of yabridge on the CI
...
Specially for @AVLinux. We currently don't build a 32-bit version of
yabridgectl though, so you'd still need that if you want to use yabridge
on an _actual_ 32-bit system.
2021-07-18 15:27:07 +02:00
Robbert van der Helm
103b2cb46a
Remove duplicate comments in the CI definition
2021-07-18 15:26:40 +02:00
Robbert van der Helm
d99f571c05
Treat EACCES for pid_running() as alive
...
When the user has some sort of hardening going on, we might not be able
to read the Wine process's memory. In that case this check would return
`false` even though the process is still running. To combat this, we
should explicitly check for `EINVAL` which is returned when the file
doesn't exist at all or when it's a broken 'symlink' (even though it
isn't really a symlink).
2021-07-18 14:54:12 +02:00
Robbert van der Helm
4fc683188b
Use std::this_thread::sleep_for instead of usleep
...
This is a bit cleaner.
2021-07-18 14:14:23 +02:00
Robbert van der Helm
8c285688e8
Remove unnecessary function call
2021-07-17 22:57:50 +02:00
Robbert van der Helm
f75cdc9019
Mention FrozenPlain Obelisk in the changelog
2021-07-17 22:02:25 +02:00
Robbert van der Helm
5f5a7bbdd2
Only call ftruncate() when size > 0
...
Either Boost or Linux really doesn't like it if you ftruncate() shared
memory down to 0 bytes.
2021-07-17 22:01:29 +02:00
Robbert van der Helm
f43e9c2153
Only consider host windows with WM_STATE set
...
This is the same way (minus the mapping check part) that `xprop` and
`xwininfo` filter windows when clicking on them. REAPER's toplevel
window apparently doesn't process any keyboard input when the mouse
cursor is located outside of that window.
2021-07-17 21:05:27 +02:00
Robbert van der Helm
b99f03cf64
Rename topmost_window to host_window
...
Since apparently to keep REAPER happy we shouldn't take the _very_
topmost window.
2021-07-17 19:11:29 +02:00
Robbert van der Helm
e4f2e8c27f
Add a separate audio thread mutual recursion stack
...
This should fix #118 without breaking our _other_ workaround from
yabridge 3.4.0 to fix the issue where a plugin would freeze if it would
try to resize itself while at the same time it sent parameter changes
from the audio thread. (and both of these issues of course are caused by
the same JUCE bug)
2021-07-15 21:05:36 +02:00