Jump to content

glslangValidator with global include paths?


SpiderPig
 Share

Go to solution Solved by SpiderPig,

Recommended Posts

I wanted to try and compile some shaders in a location away from the validator and the .glsl files.  It compiles fine so long as I don't try to include anything in the shader.

The BAT file;

C:\UltraEngine\Tools\glslangValidator.exe "C:\_output\Test.frag" -V -o "C:\_output\Test.frag.spv"

The Shader;

#version 450
#extension GL_GOOGLE_include_directive : enable
#extension GL_ARB_separate_shader_objects : enable
#extension GL_EXT_multiview : enable

//Compiles if this line is commented out
#include "C:\UltraEngine\Templates\Common\Shaders\Base\Materials.glsl"

layout(location = 0) out vec4 outColor;

void main()
{
	outColor = vec4(0.0f, 1.0f, 1.0f, 1.0f);
}

Does the validator only use relative paths somhow?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...