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

Users gets confused when running shader examples #16125

Open
Larpon opened this issue Oct 20, 2022 · 2 comments
Open

Users gets confused when running shader examples #16125

Larpon opened this issue Oct 20, 2022 · 2 comments
Labels
Bug This tag is applied to issues which reports bugs.

Comments

@Larpon
Copy link
Contributor

Larpon commented Oct 20, 2022

Related: #16113

Users sometimes trip when trying to run V code that uses shaders. The main reason seems to be the error message about the missing header #include that contains all the platform specific boilerplate code for bringing the shader into V/C code.

It would be nice to either be able to give a better error message or let the compiler handle everything needed seamlessly.

@Larpon Larpon added the Bug This tag is applied to issues which reports bugs. label Oct 20, 2022
@JalonSolov
Copy link
Contributor

It might be more than we want, but... some code could be added to vinit() when the compiler sees the "#include glsl.h" line...

@Larpon
Copy link
Contributor Author

Larpon commented Oct 21, 2022

But we'd need heuristics to determine if the header is shader code (not all files have a sane name), and heuristics tend to be fragile and error prone. The include directive could maybe be expanded with specific support for .glsl file endings?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug This tag is applied to issues which reports bugs.
Projects
None yet
Development

No branches or pull requests

2 participants