Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add common raytrace shader extensions to GLSL #5566

Merged
merged 2 commits into from
Oct 19, 2021
Merged

Add common raytrace shader extensions to GLSL #5566

merged 2 commits into from
Oct 19, 2021

Conversation

spnda
Copy link
Contributor

@spnda spnda commented Sep 10, 2021

Description

This adds the commonly used rmiss, and rchit shader extensions to GLSL. With Vulkan Ray Tracing getting much more popular, these are being used in a lot of software. They are officially used by NVIDIA and Khronos.
These extensions are also listed as the default extensions for ray tracing related shaders inside of glslang, which is part of the Vulkan SDK.

Checklist:

@spnda spnda requested a review from a team as a code owner September 10, 2021 15:29
Copy link
Member

@lildude lildude left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this PR but unfortunately it looks like only .rchit and .rmiss meet our minimum usage requirement for inclusion right now; .rgen is close, but the others aren't anywhere near close:

.rahit:

Total files found: 975
Unique public user/repos: 51
Unique owners: 50

.rcall:

Total files found: 798
Unique public user/repos: 56
Unique owners: 54

.rchit:

Total files found: 2549
Unique public user/repos: 240
Unique owners: 203

.rgen:

Total files found: 3894
Unique public user/repos: 180
Unique owners: 165

.rint:

Total files found: 829
Unique public user/repos: 56
Unique owners: 54

.rmiss:

Total files found: 1643
Unique public user/repos: 237
Unique owners: 211

Please remove all but .rchit and .rmiss. These other extensions can be added as and when they reach sufficient usage levels.

I have not included a real-world sample as it is identical to the syntax of other GLSL files (they're just used with a extra GLSL extension that provides new structs and functions, which is the only difference), however if I have to, I'd happy to add something from the samples NVIDIA and Khronos provide (both are licensed under Apache-2.0).

Whilst the syntax may be the same, we will require samples if these files contain keywords/tokens that are unique to the files with these extensions when looked at in isolation, especially if they don't occur in any of our other GLSL samples. This is to train the classifier in the event another language starts using the same extensions.

If in doubt, always add a sample.

@spnda spnda requested a review from lildude October 18, 2021 17:38
Copy link
Member

@lildude lildude left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks.

@lildude lildude merged commit eba1afd into github-linguist:master Oct 19, 2021
@lildude lildude linked an issue Oct 20, 2021 that may be closed by this pull request
@github-linguist github-linguist deleted a comment from Laloves Oct 27, 2021
Alhadis added a commit to file-icons/atom that referenced this pull request Dec 28, 2021
Added:
* Config, Python: `.flake8`       (github-linguist/linguist#5669)
* C++:            `.ixx`          (github-linguist/linguist#5680)
* Database:       `MANIFEST.MF`   (github-linguist/linguist#5505)
* Docker:         `Containerfile` (github-linguist/linguist#5588)
* GLSL:           `.r{chit,miss}` (github-linguist/linguist#5566)
* HTML:           `.hta`          (github-linguist/linguist#5533)
* Makefile:       `.makefile`     (github-linguist/linguist#5526)
* Readme:         `CITATION.cff`  (github-linguist/linguist#5577)
* Shell:          `.kshrc`        (github-linguist/linguist#5685)
* TypeScript:     `.cts`, `.mts`  (github-linguist/linguist#5696)
* XML:            `.hzp`          (github-linguist/linguist#5626)
kalkin added a commit to kalkin/file-expert that referenced this pull request May 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

More file extension associations for GLSL shaders
2 participants