I just noticed that mpv somehow managed to work with Vulkan without shaderc!

Here is my configuration in $HOME/.config/mpv/config

[gpu-vulkan]
vo=gpu-next
gpu-api=vulkan
hwdec=vaapi
gpu-context=waylandvk

[default]
profile=gpu-vulkan

Here is some of what I see when running with --msg-level=all=debug

[vo/gpu-next/vulkan] Initializing GPU context 'waylandvk'
...
[vo/gpu-next/libplacebo] Spent 2.067 ms creating vulkan instance
...
[vo/gpu-next/libplacebo] Requested alpha compositing mode:
VK_COMPOSITE_ALPHA_PRE_MULTIPLIED_BIT_KHR
[vo/gpu-next/libplacebo] Requested surface transform:
VK_SURFACE_TRANSFORM_IDENTITY_BIT_KHR
...
[vo/gpu-next] Loading hwdec driver 'vaapi'
...
[vo/gpu-next/libplacebo] vertex shader source:
[vo/gpu-next/libplacebo] [  1] #version 450
...
[vo/gpu-next/libplacebo] [ 38]
[vo/gpu-next/libplacebo] [ 39] void main() {
[vo/gpu-next/libplacebo] [ 40] out_color = _1();
[vo/gpu-next/libplacebo] [ 41] }
[vo/gpu-next/libplacebo] Spent 0.796 ms translating SPIR-V
[vo/gpu-next/libplacebo] Spent 0.802 ms translating SPIR-V
[vo/gpu-next/libplacebo] Spent 0.004 ms compiling shader
[vo/gpu-next/libplacebo] Spent 0.070 ms creating pipeline
[vo/gpu-next/libplacebo] Pass statistics: size 0, SPIR-V: vert 0 frag 0
comp 0
...

So it clearly somehow manages to compile shaders to SPIR-V without shaderc!
May be libplacebo has some built in compiler?

Just wanted to share if anyone was waiting to start using Vulkan with your
mpv.

Regards,
Shmerl.

Reply via email to