Visual Studio 2019 Version (once publishing multiple files for different VS version is available, this won't be necessary): https://marketplace.visualstudio.com/items?itemName=kristian-r.inlineglsl19 This is a basic syntax highlighter(for now) for glsl code inside C/C++ string literals. It is still very much work-in-progress, so some features may not work and expect lots of bugs. It supports 3 different types of string literals - a single string with escaped newlines(above), multiple adjacent strings, and C++ raw strings:
With version 1.2 error detection is now supported: To enable the highlighting on a particular string, add before it, either in a block-comment(/**/) or a line-comment(//) the text "vertex/fragment/compute shader:" Down the road, I plan on including automatic addition of newline escape characters, intellisense, and, if it doesn't turn out to be too complicated, a window to visualise shaders and tweak inputs. This extension is fully open-source - the code can be found here: https://github.com/System10111/inline-glsl |