|
|
|
|
|
|
using System.IO; |
|
|
|
using System.Linq; |
|
|
|
using System.Text; |
|
|
|
using System.Text.RegularExpressions; |
|
|
|
using UnityEngine.Graphing; |
|
|
|
|
|
|
|
namespace UnityEngine.MaterialGraph |
|
|
|
|
|
|
template = template.Replace("${VertexShaderBody}", vertexShaderBody); |
|
|
|
} |
|
|
|
|
|
|
|
return template; |
|
|
|
return Regex.Replace(template, @"\r\n|\n\r|\n|\r", Environment.NewLine); |
|
|
|
} |
|
|
|
|
|
|
|
public static string GenerateSurfaceShader(PixelShaderNode node, MaterialOptions options, string shaderName, bool isPreview, out List<PropertyGenerator.TextureInfo> configuredTextures) |
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
configuredTextures = shaderPropertiesVisitor.GetConfiguredTexutres(); |
|
|
|
return resultShader; |
|
|
|
|
|
|
|
return Regex.Replace(resultShader, @"\r\n|\n\r|\n|\r", Environment.NewLine); |
|
|
|
} |
|
|
|
|
|
|
|
public int numberOfChunks |
|
|
|