obsproject / obs-studio

OBS Studio - Free and open source software for live streaming and screen recording
https://obsproject.com
GNU General Public License v2.0
57.22k stars 7.72k forks source link

upgrade to NVidia 545.29.02 crashses OBS #9870

Open andyczerwonka opened 7 months ago

andyczerwonka commented 7 months ago

Operating System Info

Linux

OBS Studio Version

30.0.0

OBS Studio Version (Other)

No response

OBS Studio Log URL

it doesn't start up

OBS Studio Crash Log URL

No response

Expected Behavior

It should start up.

Current Behavior

When trying to start OBS, I get this error:

debug: Found portal inhibitor
debug: Attempted path: share/obs/obs-studio/locale/en-US.ini
debug: Attempted path: /usr/share/obs/obs-studio/locale/en-US.ini
debug: Attempted path: share/obs/obs-studio/locale.ini
debug: Attempted path: /usr/share/obs/obs-studio/locale.ini
debug: Attempted path: share/obs/obs-studio/themes/Grey.qss
debug: Attempted path: /usr/share/obs/obs-studio/themes/Grey.qss
warning: [Safe Mode] Unclean shutdown detected!
warning: [Safe Mode] User elected to launch normally.
info: Platform: Wayland
info: CPU Name: 13th Gen Intel(R) Core(TM) i9-13900HX
info: CPU Speed: 800.000MHz
info: Physical Cores: 24, Logical Cores: 32
info: Physical Memory: 64135MB Total, 50086MB Free
info: Kernel Version: Linux 6.5.6-76060506-generic
info: Distribution: "Ubuntu" "22.04"
info: Desktop Environment: ubuntu:GNOME (ubuntu-wayland)
info: Session Type: wayland
info: Qt Version: 6.2.4 (runtime), 6.2.4 (compiled)
info: Portable mode: false
info: OBS 30.0.0 (linux)
info: ---------------------------------
info: ---------------------------------
info: audio settings reset:
    samples per sec: 48000
    speakers:        2
    max buffering:   960 milliseconds
    buffering type:  dynamically increasing
info: ---------------------------------
info: Initializing OpenGL...
info: Using EGL/Wayland
info: Initialized EGL 1.5
info: Loading up OpenGL on adapter NVIDIA Corporation NVIDIA GeForce RTX 4060 Laptop GPU/PCIe/SSE2
info: OpenGL loaded successfully, version 3.3.0 NVIDIA 545.29.02, shading language 3.30 NVIDIA via Cg compiler
info: ---------------------------------
info: video settings reset:
    base resolution:   5120x2880
    output resolution: 1920x1080
    downscale filter:  Bicubic
    fps:               60/1
    format:            NV12
    YUV mode:          Rec. 709/Partial
info: NV12 texture support not available
info: P010 texture support not available
info: Audio monitoring device:
    name: Default
    id: default
info: ---------------------------------
warning: No AJA devices found, skipping loading AJA UI plugin
warning: Failed to initialize module 'aja-output-ui.so'
warning: No AJA devices found, skipping loading AJA plugin
warning: Failed to initialize module 'aja.so'
warning: Failed to load 'en-US' text for module: 'decklink-captions.so'
warning: Failed to load 'en-US' text for module: 'decklink-output-ui.so'
libDeckLinkAPI.so: cannot open shared object file: No such file or directory
warning: A DeckLink iterator could not be created.  The DeckLink drivers may not be installed
warning: Failed to initialize module 'decklink.so'
info: [pipewire] Available captures:
info: [pipewire]     - Desktop capture
info: [pipewire]     - Window capture
warning: v4l2loopback not installed, virtual camera disabled
info: [obs-browser]: Version 2.23.0
info: [obs-browser]: CEF Version 103.0.5060.134 (runtime), 103.0.0-5060-shared-textures.2594+g17f8588+chromium-103.0.5060.134 (compiled)
info: NVENC supported
info: VAAPI: API version 1.14
info: FFmpeg VAAPI H264 encoding supported
info: FFmpeg VAAPI HEVC encoding supported
info: [obs-websocket] [obs_module_load] you can haz websockets (Version: 5.3.3 | RPC Version: 1)
info: [obs-websocket] [obs_module_load] Qt version (compile-time): 6.2.4 | Qt version (run-time): 6.2.4
info: [obs-websocket] [obs_module_load] Linked ASIO Version: 101801
info: [obs-websocket] [obs_module_load] Module loaded.
info: [vlc-video]: VLC 3.0.16 Vetinari found, VLC video source enabled
info: ---------------------------------
info:   Loaded Modules:
info:     vlc-video.so
info:     text-freetype2.so
info:     rtmp-services.so
info:     obs-x264.so
info:     obs-websocket.so
info:     obs-vst.so
info:     obs-transitions.so
info:     obs-qsv11.so
info:     obs-outputs.so
info:     obs-libfdk.so
info:     obs-filters.so
info:     obs-ffmpeg.so
info:     obs-browser.so
info:     linux-v4l2.so
info:     linux-pulseaudio.so
info:     linux-pipewire.so
info:     linux-jack.so
info:     linux-capture.so
info:     linux-alsa.so
info:     image-source.so
info:     frontend-tools.so
info:     decklink-output-ui.so
info:     decklink-captions.so
info: ---------------------------------
info: ==== Startup complete ===============================================
info: All scene data cleared
info: ------------------------------------------------
info: pulse-input: Server name: 'pulseaudio 15.99.1'
info: pulse-input: Audio format: s32le, 44100 Hz, 2 channels
info: pulse-input: Started recording from 'alsa_output.usb-JDS_Labs_JDS_Labs_Element_III-00.analog-stereo.monitor' (default)
info: [Loaded global audio device]: 'Desktop Audio'
info: pulse-input: Server name: 'pulseaudio 15.99.1'
info: pulse-input: Audio format: s16le, 44100 Hz, 2 channels
info: pulse-input: Started recording from 'alsa_input.usb-BLUE_MICROPHONE_Blue_Snowball_201507-00.analog-stereo' (default)
info: [Loaded global audio device]: 'Mic/Aux'
error: alsa-input: Failed to open 'front:CARD=Snowball,DEV=0': Device or resource busy
info: v4l2-input: Start capture from /dev/video2
error: v4l2-input: Unable to set input 0
error: v4l2-input: Initialization failed, errno: Device or resource busy
info: PipeWire initialized
info: Switched to scene 'Scene 2'
info: ------------------------------------------------
info: Loaded scenes:
info: - scene 'Scene 2':
info:     - source: 'Audio Capture Device (ALSA)' (alsa_input_capture)
info:     - source: 'Screen Capture (PipeWire)' (pipewire-desktop-capture-source)
info:     - source: 'Video Capture Device (V4L2)' (v4l2_input)
info: ------------------------------------------------
warning: Wayland does not support QWindow::requestActivate()
info: [pipewire] Screencast session created
info: [pipewire] Asking for desktop
warning: The Wayland connection experienced a fatal error: Protocol error

Steps to Reproduce

I just try and start obs and it crashes.

Anything else we should know?

It was working fine before the driver update.

andyczerwonka commented 7 months ago

error.txt

kkartaltepe commented 7 months ago

If your drivers incorrectly implement wayland then there is not much we can do to prevent this error. Please run obs with WAYLAND_DEBUG=1 environment variable and provide the full output in a gist or attached in a reply as it should be quite large.

User also mentioned in support that nvidia 535 works. So likely you need to report this to nvidia to get it fixed.

tiberium-v commented 7 months ago

User downgraded the driver and the problem is gone #linux-support in Discord. Driver was also a -dev package: 545.29.02-1pop0~1699530170~22.04~77a5d6c~dev

andy.czerwonka — gestern um 20:31 Uhr was able to revert to the 535 Server Driver and it's back working again.

theHamsta commented 7 months ago

Is the pipewire capture required to trigger the bug?

theHamsta commented 7 months ago

If your drivers incorrectly implement wayland then there is not much we can do to prevent this error. Please run obs with WAYLAND_DEBUG=1 environment variable and provide the full output in a gist or attached in a reply as it should be quite large.

User also mentioned in support that nvidia 535 works. So likely you need to report this to nvidia to get it fixed.

Bug was reported to Nvidia by OBS maintainers. We failed to repro so far. Could you do run with WAYLAND_DEBUG=1 as previously mentioned and try to bisect, which component is causing the problem? Pipewire input is the last in log, but it would be important to know whether the crash can also be triggered without it.

theHamsta commented 7 months ago

I'm also seeing that you're running OBS on an older Qt version. Could you also try whether the issue is reproduceable using the OBS flatpak?

theHamsta commented 7 months ago

Could this be related https://github.com/obsproject/obs-studio/issues/9844 / https://github.com/obsproject/obs-studio/pull/9845/files? Crash of pipewire on X11. device_query_dmabuf_capabilities has different implementations for X11 and Wayland. The 0 is required for https://registry.khronos.org/EGL/extensions/EXT/EGL_EXT_image_dma_buf_import_modifiers.txt

kkartaltepe commented 7 months ago

The 0 is required for https://registry.khronos.org/EGL/extensions/EXT/EGL_EXT_image_dma_buf_import_modifiers.txt Crash of pipewire on X11. device_query_dmabuf_capabilities has different implementations for X11 and Wayland

Im not sure what you mean by "device_query_dmabuf_capabilities has different implementations" since we only have one implementation for both x11 and wayland, you can review it to see if it matches your expectations for the zero you are interested in https://github.com/obsproject/obs-studio/blob/master/libobs-opengl/gl-egl-common.c#L274

Could this be related https://github.com/obsproject/obs-studio/issues/9844 / https://github.com/obsproject/obs-studio/pull/9845/files?

I don't see how it could, can you be more specific in how you see the wayland protocol error occurring from this?

kolya25 commented 7 months ago

I managed to run obs, but I don't know exactly how lol I started with updating nvidia-utils sudo apt install nvidia-utils-535-server and all kinds of sudo apt update sudo apt upgrade sudo apt autoremove and obs started!

andyczerwonka commented 7 months ago

@kolya25 it works fine under 535. It’s 545 where it broke.

theHamsta commented 7 months ago

@kolya25 it works fine under 535. It’s 545 where it broke.

We're still struggling with a repro. Could you provide a WAYLAND_DEBUG=1 log and isolate whether this is related to pipewire and whether it can be also reproduced using the Flathub flatpak?

abchauhan-nv commented 3 months ago

Hi @andyczerwonka,

We have not been able to reproduce the issue on our test systems at NVIDIA. Do you see a crash on the latest drivers - 550.54.14?

Can you please collect a NVIDIA bug report (run nvidia-bug-report.sh as sudo/root user after the crash) and e-mail it to linux-bugs@nvidia.com whenever you have the time.

Thank you

andyczerwonka commented 3 months ago

@abchauhan-nv Here is what I get when I start OBS using l the 550 driver.

info: Platform: Wayland
info: CPU Name: 13th Gen Intel(R) Core(TM) i9-13900HX
info: CPU Speed: 800.000MHz
info: Physical Cores: 24, Logical Cores: 32
info: Physical Memory: 64144MB Total, 57363MB Free
info: Kernel Version: Linux 6.6.10-76060610-generic
info: Distribution: "Ubuntu" "22.04"
info: Desktop Environment: ubuntu:GNOME (ubuntu-wayland)
info: Session Type: wayland
info: Qt Version: 6.2.4 (runtime), 6.2.4 (compiled)
info: Portable mode: false
info: OBS 30.1.0 (linux)
info: ---------------------------------
info: ---------------------------------
info: audio settings reset:
    samples per sec: 48000
    speakers:        2
    max buffering:   960 milliseconds
    buffering type:  dynamically increasing
info: ---------------------------------
info: Initializing OpenGL...
info: Using EGL/Wayland
info: Initialized EGL 1.5
info: Loading up OpenGL on adapter NVIDIA Corporation NVIDIA GeForce RTX 4060 Laptop GPU/PCIe/SSE2
info: OpenGL loaded successfully, version 3.3.0 NVIDIA 550.54.14, shading language 3.30 NVIDIA via Cg compiler
info: ---------------------------------
info: video settings reset:
    base resolution:   5120x2880
    output resolution: 1920x1080
    downscale filter:  Bicubic
    fps:               60/1
    format:            NV12
    YUV mode:          Rec. 709/Partial
info: NV12 texture support enabled
info: P010 texture support not available
info: Audio monitoring device:
    name: Default
    id: default
info: ---------------------------------
warning: No AJA devices found, skipping loading AJA UI plugin
warning: Failed to initialize module 'aja-output-ui.so'
warning: No AJA devices found, skipping loading AJA plugin
warning: Failed to initialize module 'aja.so'
warning: Failed to load 'en-US' text for module: 'decklink-captions.so'
warning: Failed to load 'en-US' text for module: 'decklink-output-ui.so'
libDeckLinkAPI.so: cannot open shared object file: No such file or directory
warning: A DeckLink iterator could not be created.  The DeckLink drivers may not be installed
warning: Failed to initialize module 'decklink.so'
info: [pipewire] Available captures:
info: [pipewire]     - Desktop capture
info: [pipewire]     - Window capture
warning: v4l2loopback not installed, virtual camera disabled
info: [obs-browser]: Version 2.23.4
info: [obs-browser]: CEF Version 103.0.5060.134 (runtime), 103.0.0-5060-shared-textures.2594+g17f8588+chromium-103.0.5060.134 (compiled)
info: NVENC supported
info: VAAPI: API version 1.14
info: FFmpeg VAAPI H264 encoding supported
info: FFmpeg VAAPI AV1 encoding not supported
info: FFmpeg VAAPI HEVC encoding supported
info: [obs-websocket] [obs_module_load] you can haz websockets (Version: 5.4.2 | RPC Version: 1)
info: [obs-websocket] [obs_module_load] Qt version (compile-time): 6.2.4 | Qt version (run-time): 6.2.4
info: [obs-websocket] [obs_module_load] Linked ASIO Version: 101801
info: [obs-websocket] [obs_module_load] Module loaded.
info: [vlc-video]: VLC 3.0.16 Vetinari found, VLC video source enabled
info: ---------------------------------
info:   Loaded Modules:
info:     vlc-video.so
info:     text-freetype2.so
info:     rtmp-services.so
info:     obs-x264.so
info:     obs-websocket.so
info:     obs-vst.so
info:     obs-transitions.so
info:     obs-qsv11.so
info:     obs-outputs.so
info:     obs-libfdk.so
info:     obs-filters.so
info:     obs-ffmpeg.so
info:     obs-browser.so
info:     linux-v4l2.so
info:     linux-pulseaudio.so
info:     linux-pipewire.so
info:     linux-jack.so
info:     linux-capture.so
info:     linux-alsa.so
info:     image-source.so
info:     frontend-tools.so
info:     decklink-output-ui.so
info:     decklink-captions.so
info: ---------------------------------
info: ==== Startup complete ===============================================
info: All scene data cleared
info: ------------------------------------------------
info: pulse-input: Server name: 'pulseaudio 15.99.1'
info: pulse-input: Audio format: s32le, 44100 Hz, 2 channels
info: pulse-input: Started recording from 'alsa_output.usb-JDS_Labs_JDS_Labs_Element_III-00.analog-stereo.monitor' (default)
info: [Loaded global audio device]: 'Desktop Audio'
info: pulse-input: Server name: 'pulseaudio 15.99.1'
info: pulse-input: Audio format: s16le, 44100 Hz, 2 channels
info: pulse-input: Started recording from 'alsa_input.usb-BLUE_MICROPHONE_Blue_Snowball_201507-00.analog-stereo' (default)
info: [Loaded global audio device]: 'Mic/Aux'
error: alsa-input: Failed to open 'front:CARD=Snowball,DEV=0': Device or resource busy
info: v4l2-input: Start capture from /dev/video2
info: v4l2-input: Input: 0
info: v4l2-input: Resolution: 320x240
info: v4l2-input: Pixelformat: H264
info: v4l2-input: Linesize: 640 Bytes
info: v4l2-input: Framerate: 30.00 fps
info: v4l2-input: /dev/video2: select timeout set to 166666 (5x frame periods)
info: PipeWire initialized
info: Switched to scene 'Scene 2'
info: ------------------------------------------------
info: Loaded scenes:
info: - scene 'Scene 2':
info:     - source: 'Audio Capture Device (ALSA)' (alsa_input_capture)
info:     - source: 'Screen Capture (PipeWire)' (pipewire-desktop-capture-source)
info:     - source: 'Video Capture Device (V4L2)' (v4l2_input)
info: ------------------------------------------------
warning: Wayland does not support QWindow::requestActivate()
info: [pipewire] Screencast session created
info: [pipewire] Asking for desktop
warning: The Wayland connection experienced a fatal error: Protocol error
erik-kz commented 3 months ago

Could you please try with WAYLAND_DEBUG=1? That should give more information about the source of the protocol error.

hasheddan commented 2 months ago

Posting here to help any other folks that run into this. With WAYLAND_DEBUG=1, you can see the following logs prior to crash:

[3039631.157]  -> zwp_linux_buffer_params_v1@36.create_immed(new id wl_buffer@30, 1071, 397, 875713089, 0)
[3039631.193]  -> zwp_linux_buffer_params_v1@36.destroy()
[3039631.210] zwp_primary_selection_offer_v1@4278190081.offer("UTF8_STRING")
[3039631.215]  -> wl_surface@29.attach(wl_buffer@30, 0, 0)
[3039631.252]  -> wl_surface@29.damage(0, 0, 1071, 397)
[3039631.277]  -> wl_surface@29.commit()
[3039631.293]  -> wl_display@1.sync(new id wl_callback@41)
[3039631.326] zwp_primary_selection_offer_v1@4278190081.offer("STRING")
[3039631.343] zwp_primary_selection_offer_v1@4278190081.offer("MULTIPLE")
[3039631.359] zwp_primary_selection_offer_v1@4278190081.offer("SAVE_TARGETS")
[3039631.376] zwp_primary_selection_offer_v1@4278190081.offer("TARGETS")
[3039631.394] zwp_primary_selection_offer_v1@4278190081.offer("TIMESTAMP")
[3039631.412] zwp_primary_selection_device_v1@17.selection(zwp_primary_selection_offer_v1@4278190081)
[3039631.433] wl_surface@27.enter(wl_output@6)
[3039631.458] wl_callback@40.done(394361)
[3039632.823] wl_display@1.error(nil, 7, "failed to import supplied dmabufs: Arguments are inconsistent (for example, a valid context requires buffers not supplied by a ")
warning: The Wayland connection experienced a fatal error: Protocol error

This is impacting a number of different applications, so I don't think it is a bug in OBS. In the short term, you can try running OBS with QT_QPA_PLATFORM=xcb obs.

erik-kz commented 2 months ago

@hasheddan I think you truncated the output right after the zwp_linux_buffer_params_v1_add request which would be helpful to see. Mainly the last two parameters which are the DRM format modifier.

hasheddan commented 2 months ago

@erik-kz sorry about that! I don't see that specific call, but here is the full wayland debug output:

[3039581.410]  -> wl_compositor@4.create_surface(new id wl_surface@27)
[3039581.494]  -> wl_compositor@4.create_surface(new id wl_surface@29)
[3039581.696]  -> wl_compositor@4.create_region(new id wl_region@30)
[3039581.710]  -> wl_region@30.add(4, 23, 1071, 624)
[3039581.723]  -> wl_surface@29.set_opaque_region(wl_region@30)
[3039581.731]  -> wl_region@30.destroy()
[3039581.748]  -> wl_subcompositor@12.get_subsurface(new id wl_subsurface@31, wl_surface@29, wl_surface@27)
[3039581.764]  -> wl_subsurface@31.set_desync()
[3039581.771]  -> wl_surface@29.set_buffer_scale(1)
[3039581.782]  -> wl_subsurface@31.set_position(4, 23)
[3039581.792]  -> wl_surface@29.set_buffer_transform(0)
[3039581.799]  -> wl_surface@29.commit()
[3039581.808] wl_seat@25.capabilities(3)
[3039581.817]  -> wl_seat@25.get_keyboard(new id wl_keyboard@32)
[3039581.828] wl_seat@25.name("seat0")
[3039581.844]  -> wl_subsurface@31.set_position(4, 23)
[3039582.978]  -> wl_registry@2.bind(10, "xdg_wm_base", 2, new id [unknown]@33)
[3039583.012]  -> xdg_wm_base@33.get_xdg_surface(new id xdg_surface@34, wl_surface@27)
[3039583.037]  -> xdg_surface@34.get_toplevel(new id xdg_toplevel@35)
[3039583.057]  -> xdg_toplevel@35.set_min_size(557, 137)
[3039583.073]  -> xdg_toplevel@35.set_max_size(0, 0)
[3039583.091]  -> xdg_toplevel@35.set_title("OBS 30.1.2 - Profile: Untitled - Scenes: Untitled")
[3039583.124]  -> xdg_toplevel@35.set_app_id("com.obsproject.Studio")
[3039583.142]  -> wl_surface@27.set_buffer_scale(1)
[3039583.648]  -> wl_subsurface@31.set_position(7, 53)
[3039583.678]  -> wl_surface@27.set_buffer_transform(0)
[3039583.694]  -> wl_surface@27.commit()
[3039583.725] wl_display@1.delete_id(30)
[3039583.738] wl_keyboard@32.keymap(1, fd 65, 68003)
[3039585.205] wl_keyboard@32.repeat_info(33, 500)
[3039585.246]  -> wl_compositor@4.create_region(new id wl_region@30)
[3039585.260]  -> wl_region@30.add(3, 30, 1079, 729)
[3039585.283]  -> wl_surface@27.set_opaque_region(wl_region@30)
[3039585.296]  -> wl_region@30.destroy()
[3039591.384]  -> xdg_toplevel@35.set_min_size(557, 265)
[3039591.400]  -> xdg_toplevel@35.set_max_size(0, 0)
[3039591.418]  -> wl_surface@27.commit()
[3039592.202]  -> xdg_toplevel@35.set_min_size(557, 279)
[3039592.216]  -> xdg_toplevel@35.set_max_size(0, 0)
[3039592.228]  -> wl_surface@27.commit()
[3039592.406]  -> xdg_toplevel@35.set_min_size(859, 364)
[3039592.414]  -> xdg_toplevel@35.set_max_size(0, 0)
[3039592.420]  -> wl_surface@27.commit()
[3039592.916]  -> xdg_toplevel@35.set_min_size(707, 364)
[3039592.925]  -> xdg_toplevel@35.set_max_size(0, 0)
[3039592.931]  -> wl_surface@27.commit()
[3039593.473]  -> wl_subsurface@31.set_position(7, 53)
[3039593.483]  -> wl_compositor@4.create_region(new id wl_region@36)
[3039593.490]  -> wl_region@36.add(4, 23, 1071, 378)
[3039593.500]  -> wl_surface@29.set_opaque_region(wl_region@36)
[3039593.506]  -> wl_region@36.destroy()
warning: Wayland does not support QWindow::requestActivate()
warning: Wayland does not support QWindow::requestActivate()
[3039604.591] xdg_toplevel@35.configure(0, 0, array[0])
[3039604.619] xdg_surface@34.configure(54)
[3039604.639]  -> xdg_surface@34.set_window_geometry(0, 0, 1085, 762)
[3039604.652]  -> xdg_surface@34.ack_configure(54)
[3039605.235]  -> xdg_toplevel@35.set_min_size(876, 364)
[3039605.247]  -> xdg_toplevel@35.set_max_size(0, 0)
[3039605.259]  -> wl_surface@27.commit()
[3039605.763]  -> wl_subsurface@31.set_position(7, 53)
[3039605.776]  -> wl_compositor@4.create_region(new id wl_region@37)
[3039605.785]  -> wl_region@37.add(4, 23, 1071, 397)
[3039605.808]  -> wl_surface@29.set_opaque_region(wl_region@37)
[3039605.823]  -> wl_region@37.destroy()
[3039608.328]  -> wl_shm@5.create_pool(new id wl_shm_pool@38, fd 66, 3307080)
[3039608.352]  -> wl_shm_pool@38.create_buffer(new id wl_buffer@39, 0, 1085, 762, 4340, 0)
[3039615.395]  -> wl_surface@27.damage_buffer(0, 0, 1085, 30)
[3039615.417]  -> wl_surface@27.damage_buffer(0, 30, 3, 729)
[3039615.439]  -> wl_surface@27.damage_buffer(1082, 30, 3, 729)
[3039615.456]  -> wl_surface@27.damage_buffer(0, 759, 1085, 3)
[3039615.478]  -> wl_surface@27.damage_buffer(0, 762, 3, 30)
[3039615.569]  -> wl_surface@27.frame(new id wl_callback@40)
[3039615.585]  -> wl_surface@27.attach(wl_buffer@39, 0, 0)
[3039615.600]  -> wl_surface@27.damage_buffer(3, 30, 1079, 729)
[3039615.620]  -> wl_surface@27.commit()
[3039619.069] wl_display@1.delete_id(30)
[3039619.074] wl_display@1.delete_id(36)
[3039619.109] wl_buffer@39.release()
[3039619.085] wl_display@1.delete_id(37)
[3039624.453]  -> wl_surface@29.frame(new id wl_callback@37)
[3039630.587] wl_display@1.delete_id(40)
[3039630.599] xdg_toplevel@35.configure(1085, 762, array[4])
[3039630.641] xdg_surface@34.configure(56)
[3039630.668] wl_keyboard@9.modifiers(592, 0, 0, 0, 0)
[3039630.694] wl_keyboard@9.enter(592, wl_surface@27, array[0])
[3039630.722] wl_keyboard@32.modifiers(592, 0, 0, 0, 0)
[3039630.747] wl_keyboard@32.enter(592, wl_surface@27, array[0])
[3039630.770] wl_data_device@16.data_offer(new id wl_data_offer@4278190080)
[3039630.805] wl_data_offer@4278190080.offer("text/plain;charset=utf-8")
[3039630.826] wl_data_offer@4278190080.offer("text/plain")
[3039630.846] wl_data_offer@4278190080.offer("text/html")
[3039630.866] wl_data_offer@4278190080.offer("TEXT")
[3039630.885] wl_data_offer@4278190080.offer("UTF8_STRING")
[3039630.904] wl_data_offer@4278190080.offer("STRING")
[3039630.921] wl_data_offer@4278190080.offer("MULTIPLE")
[3039630.938] wl_data_offer@4278190080.offer("SAVE_TARGETS")
[3039630.957] wl_data_offer@4278190080.offer("TARGETS")
[3039630.975] wl_data_offer@4278190080.offer("TIMESTAMP")
[3039630.992] wl_data_device@16.selection(wl_data_offer@4278190080)
[3039631.012] zwp_primary_selection_device_v1@17.data_offer(new id zwp_primary_selection_offer_v1@4278190081)
[3039631.033] zwp_primary_selection_offer_v1@4278190081.offer("text/plain;charset=utf-8")
[3039631.050] zwp_primary_selection_offer_v1@4278190081.offer("text/plain")
[3039631.068]  -> zwp_linux_dmabuf_v1@28.create_params(new id zwp_linux_buffer_params_v1@36)
[3039631.100] zwp_primary_selection_offer_v1@4278190081.offer("TEXT"[3039631.106]  -> zwp_linux_buffer_params_v1@36.add(fd 69, 0)
, 0, 4288, 50331648, 6316052)
[3039631.157]  -> zwp_linux_buffer_params_v1@36.create_immed(new id wl_buffer@30, 1071, 397, 875713089, 0)
[3039631.193]  -> zwp_linux_buffer_params_v1@36.destroy()
[3039631.210] zwp_primary_selection_offer_v1@4278190081.offer("UTF8_STRING")
[3039631.215]  -> wl_surface@29.attach(wl_buffer@30, 0, 0)
[3039631.252]  -> wl_surface@29.damage(0, 0, 1071, 397)
[3039631.277]  -> wl_surface@29.commit()
[3039631.293]  -> wl_display@1.sync(new id wl_callback@41)
[3039631.326] zwp_primary_selection_offer_v1@4278190081.offer("STRING")
[3039631.343] zwp_primary_selection_offer_v1@4278190081.offer("MULTIPLE")
[3039631.359] zwp_primary_selection_offer_v1@4278190081.offer("SAVE_TARGETS")
[3039631.376] zwp_primary_selection_offer_v1@4278190081.offer("TARGETS")
[3039631.394] zwp_primary_selection_offer_v1@4278190081.offer("TIMESTAMP")
[3039631.412] zwp_primary_selection_device_v1@17.selection(zwp_primary_selection_offer_v1@4278190081)
[3039631.433] wl_surface@27.enter(wl_output@6)
[3039631.458] wl_callback@40.done(394361)
[3039632.823] wl_display@1.error(nil, 7, "failed to import supplied dmabufs: Arguments are inconsistent (for example, a valid context requires buffers not supplied by a ")
warning: The Wayland connection experienced a fatal error: Protocol error
erik-kz commented 2 months ago

Thanks! It looks like the log for zwp_linux_buffer_params_v1_add got scrambled up with another event, but it's on line [3039631.100].

So the format of the failing buffer if DRM_FORMAT_ARGB8888 and the format modifier is 0x300000000606014. Our EGL driver should have no trouble importing that buffer.

Yet the protocol error indicates that eglCreateImageKHR is failing with EGL_BAD_MATCH for some reason. May I ask if you have more than one GPU installed in your system? That would include a hybrid-graphics laptop with both an integrated and dedicated GPU.

[edit] Two follow-up questions if you are using a hybrid-graphics laptop... are you intentionally running OBS on the NVIDIA GPU, e.g. by setting __NV_PRIME_RENDER_OFFLOAD=1 or using the prime-run script? and do you happen to have an external display attached?