Enable BuiltIn input in the shader graph builder
BuiltIn inputs shouldnt be translated into a code input. We comment the input line for this variables Change-Id: I3b7d2fd06afc6a122d90a999fc5a5246fc93234e Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
This commit is contained in:
parent
436a6fbb83
commit
95c8f24b71
@ -61,6 +61,8 @@ namespace
|
|||||||
return ""; // Although fragment shaders for <=2 only have fixed outputs
|
return ""; // Although fragment shaders for <=2 only have fixed outputs
|
||||||
case QShaderLanguage::Uniform:
|
case QShaderLanguage::Uniform:
|
||||||
return "uniform";
|
return "uniform";
|
||||||
|
case QShaderLanguage::BuiltIn:
|
||||||
|
return "//";
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
switch (qualifier) {
|
switch (qualifier) {
|
||||||
@ -72,6 +74,8 @@ namespace
|
|||||||
return "out";
|
return "out";
|
||||||
case QShaderLanguage::Uniform:
|
case QShaderLanguage::Uniform:
|
||||||
return "uniform";
|
return "uniform";
|
||||||
|
case QShaderLanguage::BuiltIn:
|
||||||
|
return "//";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -64,6 +64,7 @@ namespace QShaderLanguage
|
|||||||
enum StorageQualifier : char {
|
enum StorageQualifier : char {
|
||||||
Const = 1,
|
Const = 1,
|
||||||
Input,
|
Input,
|
||||||
|
BuiltIn,
|
||||||
Output,
|
Output,
|
||||||
Uniform
|
Uniform
|
||||||
};
|
};
|
||||||
|
@ -372,6 +372,8 @@ namespace {
|
|||||||
return "const";
|
return "const";
|
||||||
case QShaderLanguage::Input:
|
case QShaderLanguage::Input:
|
||||||
return "varying";
|
return "varying";
|
||||||
|
case QShaderLanguage::BuiltIn:
|
||||||
|
return "//";
|
||||||
case QShaderLanguage::Output:
|
case QShaderLanguage::Output:
|
||||||
return ""; // Although fragment shaders for <=2 only have fixed outputs
|
return ""; // Although fragment shaders for <=2 only have fixed outputs
|
||||||
case QShaderLanguage::Uniform:
|
case QShaderLanguage::Uniform:
|
||||||
@ -383,6 +385,8 @@ namespace {
|
|||||||
return "const";
|
return "const";
|
||||||
case QShaderLanguage::Input:
|
case QShaderLanguage::Input:
|
||||||
return "in";
|
return "in";
|
||||||
|
case QShaderLanguage::BuiltIn:
|
||||||
|
return "//";
|
||||||
case QShaderLanguage::Output:
|
case QShaderLanguage::Output:
|
||||||
return "out";
|
return "out";
|
||||||
case QShaderLanguage::Uniform:
|
case QShaderLanguage::Uniform:
|
||||||
|
Loading…
Reference in New Issue
Block a user