/** * {@inheritDoc} * * if the declaration contains no code nothing is done, else it's appended */ @Override protected void generateDeclarativeSection(StringBuilder source, ShaderNode shaderNode, String nodeSource, ShaderGenerationInfo info) { if (nodeSource.replaceAll("\\n", "").trim().length() > 0) { nodeSource = updateDefinesName(nodeSource, shaderNode); source.append("\n"); unIndent(); startCondition(shaderNode.getCondition(), source); source.append(nodeSource); source.append("\n"); endCondition(shaderNode.getCondition(), source); indent(); } }
startCondition(var.getCondition(), source); appendIndent(source); if (modifier != null) {
final String rightExpression = mapping.getRightExpression(); startCondition(mapping.getCondition(), source); appendIndent(source); if (!leftVariable.isShaderOutput() && declare) {
source.append("\n"); comment(source, shaderNode, "Begin"); startCondition(shaderNode.getCondition(), source);
/** * {@inheritDoc} * * if the declaration contains no code nothing is done, else it's appended */ @Override protected void generateDeclarativeSection(StringBuilder source, ShaderNode shaderNode, String nodeSource, ShaderGenerationInfo info) { if (nodeSource.replaceAll("\\n", "").trim().length() > 0) { nodeSource = updateDefinesName(nodeSource, shaderNode); source.append("\n"); unIndent(); startCondition(shaderNode.getCondition(), source); source.append(nodeSource); source.append("\n"); endCondition(shaderNode.getCondition(), source); indent(); } }
startCondition(var.getCondition(), source); appendIndent(source); if (modifier != null) {
startCondition(mapping.getCondition(), source); appendIndent(source); if (!mapping.getLeftVariable().isShaderOutput()) {
source.append("\n"); comment(source, shaderNode, "Begin"); startCondition(shaderNode.getCondition(), source);