gfx-rs / portability

Vulkan Portability Implementation
Mozilla Public License 2.0
384 stars 25 forks source link

Issue running vkquake with portability (works ok with MoltenVK).. #150

Closed oscarbg closed 6 years ago

oscarbg commented 6 years ago

Hi, I tested vkquake 1.0 and sadly is also failing with shared portability binaries for rpcs3 & dolphin.. recompiled again with your library renamed and located as : /lib/libMoltenVK.dylib changed Makefile to: COMMON_LIBS:= -lm /lib/libMoltenVK.dylib you have to put in ID1 folder pak0.pak at least (I'm using it from shareware version)

first "lame" issue I found with "otool -L vkquake": /Users/dmalyshau/Code/portability/target/release/deps/libportability.dylib (compatibility version 1.0.0, current version 1.0.0) had to create this folders and copy library also there.. can you fix future binary libraries to not a fixed path (like for ex. @rpath I believe).. this issue isn't present on libMoltenVK dylib..

even then fails with: QUAKE ERROR: vkCreateGraphicsPipelines failed

full log:

./vkquake 
Command line: ./vkquake
Found SDL version 2.0.8
Detected 4 CPUs.
Quake 1.09 (c) id Software
GLQuake 1.00 (c) id Software
FitzQuake 0.85 (c) John Fitzgibbons
FitzQuake SDL port (c) SleepwalkR, Baker
QuakeSpasm 0.93.0 (c) Ozkan Sezer, Eric Wasylishen & others
vkQuake 1.00.0 (c) Axel Gneiting & others
Host_Init
Playing shareware version.
Console initialized.
UDP_Init: skipping gethostbyname for iMac.local
UDP Initialized
Server using protocol 666 (FitzQuake)
Exe: 15:10:12 Aug 28 2018
256.0 megabyte heap

Vulkan Initialization
Vendor: Unknown (0x0)
Device: AMD Radeon RX Vega 64
Using D32 depth buffer format
Creating command buffers
Initializing staging
Creating descriptor set layouts
Initializing dynamic vertex buffers
Initializing dynamic index buffers
Initializing dynamic uniform buffers
Initializing dynamic uniform buffers
Initializing samplers
Creating pipeline layouts
Using IMMEDIATE present mode
fpCreateSwapchainKHR
Creating color buffer
AA disabled
Creating depth buffer
Creating render passes
Creating frame buffers
Creating pipelines

ERROR-OUT BEGIN

QUAKE ERROR: vkCreateGraphicsPipelines failed

with moltenvk works ok by overwriting /Users/dmalyshau/Code/portability/target/release/deps/libportability.dylib with that dylib:

./vkquake
Found SDL version 2.0.8
Detected 4 CPUs.
Quake 1.09 (c) id Software
GLQuake 1.00 (c) id Software
FitzQuake 0.85 (c) John Fitzgibbons
FitzQuake SDL port (c) SleepwalkR, Baker
QuakeSpasm 0.93.0 (c) Ozkan Sezer, Eric Wasylishen & others
vkQuake 1.00.0 (c) Axel Gneiting & others
Host_Init
Playing shareware version.
Console initialized.
UDP_Init: skipping gethostbyname for iMac.local
UDP Initialized
Server using protocol 666 (FitzQuake)
Exe: 15:10:12 Aug 28 2018
256.0 megabyte heap

Vulkan Initialization
Vendor: NVIDIA
Device: AMD Radeon RX Vega 64
Using A2B10G10R10 color buffer format
Using D32 depth buffer format
Creating command buffers
Initializing staging
Creating descriptor set layouts
Initializing dynamic vertex buffers
Initializing dynamic index buffers
Initializing dynamic uniform buffers
Initializing dynamic uniform buffers
Initializing samplers
Creating pipeline layouts
Using IMMEDIATE present mode
fpCreateSwapchainKHR
Creating color buffer
AA disabled
Creating depth buffer
Creating render passes
Creating frame buffers
Creating pipelines

Sound Initialization
SDL audio spec  : 44100 Hz, 1024 samples, 2 channels
SDL audio driver: coreaudio - HDMI, 65536 bytes buffer
Audio: 16 bit, stereo, 44100 Hz
CDAudio disabled at compile time

========= Quake Initialized =========

execing quake.rc
execing default.cfg
execing config.cfg
Initializing samplers
couldn't exec autoexec.cfg
3 demo(s) in loop

FITZQUAKE 0.85 SERVER (24778 CRC)

Introduction
Using protocol 666
Couldn't find a cdrip for track 4
player entered the game
Client player removed
Shutting down SDL sound
kvark commented 6 years ago

Thanks for the report @oscarbg ! I also happened to test it yesterday, and we are currently missing support for named specialization constants if I'm not mistaken. This is solvable.

kvark commented 6 years ago

Ok, it wasn't named specialization constants but rather a miscommunication between gfx-hal and gfx-portability, which resulted in a loss of typing information for the constants. It is addressed by https://github.com/gfx-rs/gfx/pull/2381

However, the next blocker is sub-pass support, which vkQuake appears to be using.

kvark commented 6 years ago

Fix is coming in https://github.com/gfx-rs/gfx/pull/2387

oscarbg commented 6 years ago

nice! thanks.. will test soon and close issue..

kvark commented 6 years ago

We'll close the issue when the build containing the fix is available

On Sep 7, 2018, at 20:34, Oscar Barenys notifications@github.com wrote:

nice! thanks.. will test soon and close issue..

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.