Debugging VK_ERROR_DEVICE_LOST with Nvidia Device Diagnostics

Published on . Filed under debugging graphics vulkan

If you are working with Vulkan, chances are that at some point you’ll run into a VK_ERROR_DEVICE_LOST error. It’s the worst kind of error, chances are that your GPU choked on some data sometime about a frame or two ago and the position where you received the error is nowhere near where the GPU actually decided to throw up its hands and give up. This is of course because GPUs and CPUs are inherently decoupled from each other, and when you submit your work from the CPU to the GPU, the GPU will start crunching your numbers while in the meantime the CPU goes on with its busy life doing other things. Read post

Fragment shader based interior mapping

Published on . Filed under programming graphics

Seems like everybody is excited about the fake interior mapping in Spiderman these days. Here is a Kotaku video showing them off: Now, the technique itself is nothing new, it’s been proposed by Joost van Dongen who published a paper about it here. The idea is to divide the space into evenly sized “rooms” and then cast a ray in the fragment shader to figure out whether the ceiling/floor or a wall was hit, and then map a texture on top. Read post