vscode-shader icon indicating copy to clipboard operation
vscode-shader copied to clipboard

Add support for Vulkan ray tracing shader types

Open Max1412 opened this issue 6 years ago • 2 comments

Hi, new shader file types are introduced in VK_NV_ray_tracing: .rgen = ray generation .rint = ray intersection .rahit = ray any hit .rchit = ray closest hit .rmiss = ray miss .rcall = ray callable (See: https://github.com/KhronosGroup/glslang/commit/b50c02ef53973e3e09565ed7066d2b39edc36b17)

Any chance those can be added to the list of supported shader files?

Max1412 avatar Nov 16 '18 13:11 Max1412

Seems some new keyword should be added in the syntax grammar, too.

If you can't wait for the next update, you can associate those files type in your VSCode user settings

Files: Associations
Configure file associations to languages (e.g. "*.usf": "hlsl"). These have precedence over the default associations of the languages installed.
Edit in settings.json

stef-levesque avatar Nov 16 '18 21:11 stef-levesque

Hi, thanks for the answer. If someone else wants to do this, they should use this:

"files.associations": {
        "*.rgen"  : "glsl",
        "*.rint"  : "glsl",
        "*.rahit" : "glsl",
        "*.rchit" : "glsl",
        "*.rmiss" : "glsl",
        "*.rcall" : "glsl"
}

It doesn't work without the asterisks for me.

Max1412 avatar Nov 22 '18 15:11 Max1412