浏览代码

tidy up new nodes for upgrading.

/main
Tim Cooper 8 年前
当前提交
d88535a5
共有 90 个文件被更改,包括 431 次插入96 次删除
  1. 2
      MaterialGraphProject/Assets/SphereDent.ShaderGraph
  2. 2
      MaterialGraphProject/Assets/SphereDent.ShaderGraph.meta
  3. 2
      MaterialGraphProject/Assets/UnityShaderEditor/Editor.meta
  4. 66
      MaterialGraphProject/Assets/GeneratedShader.shader
  5. 10
      MaterialGraphProject/Assets/GeneratedShader.shader.meta
  6. 333
      MaterialGraphProject/Assets/GraphFramework/SerializableGraph/Editor/Drawing/AbstractGraphEditWindow.cs.orig
  7. 9
      MaterialGraphProject/Assets/NewNodes/Keep.meta
  8. 9
      MaterialGraphProject/Assets/NewNodes/Kill.meta
  9. 9
      MaterialGraphProject/Assets/NewNodes/WIP.meta
  10. 73
      MaterialGraphProject/Assets/UnityShaderEditor/Editor/HelperShader.shader
  11. 12
      MaterialGraphProject/Assets/UnityShaderEditor/Editor/HelperShader.shader.meta
  12. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ParallaxNode.cs
  13. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ParallaxNode.cs.meta
  14. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/MultiLayerParallaxNode.cs
  15. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/MultiLayerParallaxNode.cs.meta
  16. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/POMNode.cs.meta
  17. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/AACheckerBoardNode.cs.meta
  18. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/RadialShearNode.cs
  19. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/RadialShearNode.cs.meta
  20. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ScaleOffsetNode.cs
  21. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ScaleOffsetNode.cs.meta
  22. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/SphereWarpNode.cs
  23. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/SphereWarpNode.cs.meta
  24. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/SphericalIndentationNode.cs.meta
  25. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/AACheckerBoard3dNode.cs.meta
  26. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/POMNode.cs
  27. 0
      /MaterialGraphProject/Assets/NewNodes/Editor
  28. 0
      /MaterialGraphProject/Assets/NewNodes/ChannelBlendNode.cs
  29. 0
      /MaterialGraphProject/Assets/NewNodes/ChannelBlendNode.cs.meta
  30. 0
      /MaterialGraphProject/Assets/NewNodes/ConstantType.cs
  31. 0
      /MaterialGraphProject/Assets/NewNodes/ConstantType.cs.meta
  32. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ConstantsNode.cs.meta
  33. 0
      /MaterialGraphProject/Assets/NewNodes/FunctionNAddNode.cs
  34. 0
      /MaterialGraphProject/Assets/NewNodes/FunctionNAddNode.cs.meta
  35. 0
      /MaterialGraphProject/Assets/NewNodes/FunctionNInNOut.cs
  36. 0
      /MaterialGraphProject/Assets/NewNodes/FunctionNInNOut.cs.meta
  37. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/HeightToNormalNode.cs
  38. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/HeightToNormalNode.cs.meta
  39. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ReciprocalSqrtNode.cs
  40. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ReciprocalSqrtNode.cs.meta
  41. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/VertexNormalNode.cs
  42. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/VertexNormalNode.cs.meta
  43. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/VertexPositionNode.cs
  44. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/VertexPositionNode.cs.meta
  45. 0
      /MaterialGraphProject/Assets/NewNodes/CommonMatrixType.cs
  46. 0
      /MaterialGraphProject/Assets/NewNodes/CommonMatrixType.cs.meta
  47. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/TangentToWorldNode.cs
  48. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/TangentToWorldNode.cs.meta
  49. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/BlendModeNode.cs
  50. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/BlendModeNode.cs.meta
  51. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/BlendModesEnum.cs
  52. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/BlendModesEnum.cs.meta
  53. 0
      /MaterialGraphProject/Assets/NewNodes/FractalNode.cs
  54. 0
      /MaterialGraphProject/Assets/NewNodes/FractalNode.cs.meta
  55. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/SamplerStateNode.cs.meta
  56. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/Texture2DNode.cs.meta
  57. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/TextureSamplerNode.cs
  58. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/TextureSamplerNode.cs.meta
  59. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/UVTriPlanar.cs
  60. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/UVTriPlanar.cs.meta
  61. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ColorBalanceNode.cs
  62. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ColorBalanceNode.cs.meta
  63. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/GradientNode.cs
  64. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/GradientNode.cs.meta
  65. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/RandomRangeNode.cs
  66. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/RandomRangeNode.cs.meta
  67. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/ScatterNode.cs
  68. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/ScatterNode.cs.meta
  69. 0
      /MaterialGraphProject/Assets/NewNodes/Editor.meta
  70. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/LightProbeNode.cs
  71. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/LightProbeNode.cs.meta
  72. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ReflectionProbeNode.cs
  73. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ReflectionProbeNode.cs.meta
  74. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/ToggleNode.cs
  75. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/ToggleNode.cs.meta
  76. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/TransformNode.cs
  77. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/TransformNode.cs.meta
  78. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/GradientField.cs
  79. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/GradientField.cs.meta
  80. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/GradientWrapper.cs
  81. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/GradientWrapper.cs.meta
  82. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/AACheckerBoard3dNode.cs
  83. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/AACheckerBoardNode.cs
  84. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/ConstantsNode.cs
  85. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/SamplerStateNode.cs
  86. 0
      /MaterialGraphProject/Assets/NewNodes/Kill/SphericalIndentationNode.cs
  87. 0
      /MaterialGraphProject/Assets/NewNodes/Keep/Texture2DNode.cs

2
MaterialGraphProject/Assets/SphereDent.ShaderGraph
文件差异内容过多而无法显示
查看文件

2
MaterialGraphProject/Assets/SphereDent.ShaderGraph.meta


fileFormatVersion: 2
guid: b63da350811f7ba48914e852a299204c
timeCreated: 1500715026
timeCreated: 1500770532
licenseType: Pro
ShaderImporter:
defaultTextures: []

2
MaterialGraphProject/Assets/UnityShaderEditor/Editor.meta


folderAsset: yes
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

66
MaterialGraphProject/Assets/GeneratedShader.shader


Shader "Hidden/PreviewShader/Sin_5540BA00_result" {
Properties {
}
SubShader {
// inside SubShader
Tags
{
"Queue"="Geometry"
"RenderType"="Opaque"
"IgnoreProjector"="True"
}
// inside Pass
ZWrite On
Blend One Zero
Pass {
CGPROGRAM
#pragma vertex vert
#pragma fragment frag
#include "UnityCG.cginc"
struct v2f
{
float4 pos : SV_POSITION;
float4 color : COLOR;
};
void Unity_Sin_float(float argument, out float result)
{
result = sin(argument);
}
v2f vert (appdata_full v)
{
v2f o = (v2f)0;
o.pos = UnityObjectToClipPos(v.vertex);;
float3 worldPos = mul(unity_ObjectToWorld, v.vertex).xyz;
float3 viewDir = UnityWorldSpaceViewDir(worldPos);
float4 screenPos = ComputeScreenPos(UnityObjectToClipPos(v.vertex));
float3 worldNormal = UnityObjectToWorldNormal(v.normal);
return o;
}
half4 frag (v2f IN) : COLOR
{
float Sin_5540BA00_result;
Unity_Sin_float(_Time.y, Sin_5540BA00_result);
return half4(Sin_5540BA00_result, Sin_5540BA00_result, Sin_5540BA00_result, 1.0);
}
ENDCG
}
}
Fallback Off
}

10
MaterialGraphProject/Assets/GeneratedShader.shader.meta


fileFormatVersion: 2
guid: 4afc3341bed83d34cb1aebb7e98d8751
timeCreated: 1500713419
licenseType: Pro
ShaderImporter:
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

333
MaterialGraphProject/Assets/GraphFramework/SerializableGraph/Editor/Drawing/AbstractGraphEditWindow.cs.orig


using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using RMGUI.GraphView;
using UnityEngine;
using UnityEngine.Graphing;
using UnityEngine.Experimental.UIElements;
using UnityEngine.MaterialGraph;
using Object = UnityEngine.Object;
namespace UnityEditor.Graphing.Drawing
{
public abstract class AbstractGraphEditWindow : EditorWindow, ISerializationCallbackReceiver
{
public abstract IGraphAsset inMemoryAsset { get; set; }
public abstract Object selected { get; set; }
public static bool allowAlwaysRepaint = true;
private bool shouldRepaint
{
get
{
return allowAlwaysRepaint && inMemoryAsset != null && inMemoryAsset.shouldRepaint;
}
}
protected GraphView graphView
{
get { return m_GraphEditorDrawer.graphView; }
}
private GraphEditorDrawer m_GraphEditorDrawer;
public virtual AbstractGraphPresenter CreateDataSource()
{
return CreateInstance<SerializedGraphPresenter>();
}
public virtual GraphView CreateGraphView()
{
return new SerializableGraphView();
}
void OnEnable()
{
m_GraphEditorDrawer = new GraphEditorDrawer(CreateGraphView());
rootVisualContainer.AddChild(m_GraphEditorDrawer);
var source = CreateDataSource();
source.Initialize(inMemoryAsset, this);
m_GraphEditorDrawer.presenter = source;
}
void OnDisable()
{
rootVisualContainer.ClearChildren();
}
void Update()
{
if (shouldRepaint)
Repaint();
}
public void PingAsset()
{
if (selected != null)
EditorGUIUtility.PingObject(selected);
}
public void UpdateAsset()
{
if (selected != null && inMemoryAsset != null)
{
var path = AssetDatabase.GetAssetPath(selected);
if (string.IsNullOrEmpty(path) || inMemoryAsset == null)
{
return;
}
var masterNode = ((MaterialGraphAsset)inMemoryAsset).materialGraph.masterNode;
if (masterNode == null)
return;
List<PropertyGenerator.TextureInfo> configuredTextures;
<<<<<<< HEAD
masterNode.GetFullShader(GenerationMode.ForReals, "NotNeeded", out configuredTextures);
=======
masterNode.GetFullShader(GenerationMode.ForReals, out configuredTextures);
>>>>>>> hackweek2017
var shaderImporter = AssetImporter.GetAtPath(path) as ShaderImporter;
if (shaderImporter == null)
return;
var textureNames = new List<string>();
var textures = new List<Texture>();
foreach (var textureInfo in configuredTextures.Where(
x => x.modifiable == TexturePropertyChunk.ModifiableState.Modifiable))
{
var texture = EditorUtility.InstanceIDToObject(textureInfo.textureId) as Texture;
if (texture == null)
continue;
textureNames.Add(textureInfo.name);
textures.Add(texture);
}
shaderImporter.SetDefaultTextures(textureNames.ToArray(), textures.ToArray());
textureNames.Clear();
textures.Clear();
foreach (var textureInfo in configuredTextures.Where(
x => x.modifiable == TexturePropertyChunk.ModifiableState.NonModifiable))
{
var texture = EditorUtility.InstanceIDToObject(textureInfo.textureId) as Texture;
if (texture == null)
continue;
textureNames.Add(textureInfo.name);
textures.Add(texture);
}
shaderImporter.SetNonModifiableTextures(textureNames.ToArray(), textures.ToArray());
File.WriteAllText(path, EditorJsonUtility.ToJson(inMemoryAsset.graph));
shaderImporter.SaveAndReimport();
AssetDatabase.ImportAsset(path);
}
}
public virtual void ToggleRequiresTime()
{
allowAlwaysRepaint = !allowAlwaysRepaint;
}
public void ChangeSelction(Object newSelection)
{
if (!EditorUtility.IsPersistent (newSelection))
return;
if (selected == newSelection)
return;
if (selected != null)
{
if (EditorUtility.DisplayDialog ("Save Old Graph?", "Save Old Graph?", "yes!", "no")) {
UpdateAsset ();
}
}
selected = newSelection;
var mGraph = CreateInstance<MaterialGraphAsset>();
var path = AssetDatabase.GetAssetPath(newSelection);
var textGraph = File.ReadAllText(path, Encoding.UTF8);
mGraph.materialGraph = JsonUtility.FromJson<UnityEngine.MaterialGraph.MaterialGraph>(textGraph);
inMemoryAsset = mGraph;
var graph = inMemoryAsset.graph;
graph.OnEnable ();
graph.ValidateGraph ();
var source = CreateDataSource ();
source.Initialize (inMemoryAsset, this) ;
m_GraphEditorDrawer.presenter = source;
<<<<<<< HEAD
//m_GraphView.StretchToParentSize();
Repaint ();
if (refocus)
{
focused = false;
m_GraphEditorDrawer.graphView.Schedule (Focus).StartingIn (1).Until (() => focused);
}
}
=======
Repaint();
}
>>>>>>> hackweek2017
public void OnBeforeSerialize()
{
//m_ToLoad = m_Selected as ScriptableObject;
}
public void OnAfterDeserialize()
{}
/*
private void ConvertSelectionToSubGraph()
{
if (m_Canvas.presenter == null)
return;
var presenter = m_Canvas.presenter as GraphDataSource;
if (presenter == null)
return;
var asset = presenter.graphAsset;
if (asset == null)
return;
var targetGraph = asset.graph;
if (targetGraph == null)
return;
if (!m_Canvas.selection.Any())
return;
var serialzied = CopySelected.SerializeSelectedElements(m_Canvas);
var deserialized = CopySelected.DeserializeSelectedElements(serialzied);
if (deserialized == null)
return;
string path = EditorUtility.SaveFilePanelInProject("Save subgraph", "New SubGraph", "ShaderSubGraph", "");
path = path.Replace(Application.dataPath, "Assets");
if (path.Length == 0)
return;
var graphAsset = CreateInstance<MaterialSubGraphAsset>();
graphAsset.name = Path.GetFileName(path);
graphAsset.PostCreate();
var graph = graphAsset.subGraph;
if (graphAsset.graph == null)
return;
var nodeGuidMap = new Dictionary<Guid, Guid>();
foreach (var node in deserialized.GetNodes<INode>())
{
var oldGuid = node.guid;
var newGuid = node.RewriteGuid();
nodeGuidMap[oldGuid] = newGuid;
graph.AddNode(node);
}
// remap outputs to the subgraph
var inputEdgeNeedsRemap = new List<IEdge>();
var outputEdgeNeedsRemap = new List<IEdge>();
foreach (var edge in deserialized.edges)
{
var outputSlot = edge.outputSlot;
var inputSlot = edge.inputSlot;
Guid remappedOutputNodeGuid;
Guid remappedInputNodeGuid;
var outputRemapExists = nodeGuidMap.TryGetValue(outputSlot.nodeGuid, out remappedOutputNodeGuid);
var inputRemapExists = nodeGuidMap.TryGetValue(inputSlot.nodeGuid, out remappedInputNodeGuid);
// pasting nice internal links!
if (outputRemapExists && inputRemapExists)
{
var outputSlotRef = new SlotReference(remappedOutputNodeGuid, outputSlot.slotId);
var inputSlotRef = new SlotReference(remappedInputNodeGuid, inputSlot.slotId);
graph.Connect(outputSlotRef, inputSlotRef);
}
// one edge needs to go to outside world
else if (outputRemapExists)
{
inputEdgeNeedsRemap.Add(edge);
}
else if (inputRemapExists)
{
outputEdgeNeedsRemap.Add(edge);
}
}
// we do a grouping here as the same output can
// point to multiple inputs
var uniqueOutputs = outputEdgeNeedsRemap.GroupBy(edge => edge.outputSlot);
var inputsNeedingConnection = new List<KeyValuePair<IEdge, IEdge>>();
foreach (var group in uniqueOutputs)
{
var inputNode = graph.inputNode;
var slotId = inputNode.AddSlot();
var outputSlotRef = new SlotReference(inputNode.guid, slotId);
foreach (var edge in group)
{
var newEdge = graph.Connect(outputSlotRef, new SlotReference(nodeGuidMap[edge.inputSlot.nodeGuid], edge.inputSlot.slotId));
inputsNeedingConnection.Add(new KeyValuePair<IEdge, IEdge>(edge, newEdge));
}
}
var uniqueInputs = inputEdgeNeedsRemap.GroupBy(edge => edge.inputSlot);
var outputsNeedingConnection = new List<KeyValuePair<IEdge, IEdge>>();
foreach (var group in uniqueInputs)
{
var outputNode = graph.outputNode;
var slotId = outputNode.AddSlot();
var inputSlotRef = new SlotReference(outputNode.guid, slotId);
foreach (var edge in group)
{
var newEdge = graph.Connect(new SlotReference(nodeGuidMap[edge.outputSlot.nodeGuid], edge.outputSlot.slotId), inputSlotRef);
outputsNeedingConnection.Add(new KeyValuePair<IEdge, IEdge>(edge, newEdge));
}
}
AssetDatabase.CreateAsset(graphAsset, path);
var subGraphNode = new SubGraphNode();
targetGraph.AddNode(subGraphNode);
subGraphNode.subGraphAsset = graphAsset;
foreach (var edgeMap in inputsNeedingConnection)
{
targetGraph.Connect(edgeMap.Key.outputSlot, new SlotReference(subGraphNode.guid, edgeMap.Value.outputSlot.slotId));
}
foreach (var edgeMap in outputsNeedingConnection)
{
targetGraph.Connect(new SlotReference(subGraphNode.guid, edgeMap.Value.inputSlot.slotId), edgeMap.Key.inputSlot);
}
var toDelete = m_Canvas.selection.Where(x => x is DrawableNode).ToList();
presenter.DeleteElements(toDelete);
targetGraph.ValidateGraph();
m_Canvas.ReloadData();
m_Canvas.Invalidate();
m_Canvas.selection.Clear();
var toSelect = m_Canvas.elements.OfType<DrawableNode>().FirstOrDefault(x => x.m_Node == subGraphNode);
if (toSelect != null)
{
toSelect.selected = true;
m_Canvas.selection.Add(toSelect);
}
m_Canvas.Repaint();
}*/
}
}

9
MaterialGraphProject/Assets/NewNodes/Keep.meta


fileFormatVersion: 2
guid: 46cda65b157b245ba8f0fe2271912a9c
folderAsset: yes
timeCreated: 1500793639
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

9
MaterialGraphProject/Assets/NewNodes/Kill.meta


fileFormatVersion: 2
guid: fb228c8240a06467bbf24021de179428
folderAsset: yes
timeCreated: 1500793644
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

9
MaterialGraphProject/Assets/NewNodes/WIP.meta


fileFormatVersion: 2
guid: 1035abaf40f232e4585818283e199b96
folderAsset: yes
timeCreated: 1495558038
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

73
MaterialGraphProject/Assets/UnityShaderEditor/Editor/HelperShader.shader


Shader "UnityEngine.MaterialGraph.ExportTextureMasterNode71166862-083a-4792-8c3a-4111b9dd9d37"
{
Properties
{
Texture_339414d4_3f08_4a60_b7de_60b5078454cd_Uniform("Texture", 2D) = "white" {}
}
SubShader
{
Tags { "Queue"="Geometry" "IgnoreProjector"="True" "RenderType"="Opaque" }
ZWrite Off
Blend One Zero
Pass
{
CGPROGRAM
#include "UnityCustomRenderTexture.cginc"
#pragma vertex CustomRenderTextureVertexShader
#pragma fragment frag
#pragma target 4.0
v2f_customrendertexture CustomRenderTextureVertexShader_Preview(appdata_base IN)
{
v2f_customrendertexture OUT;
OUT.vertex = UnityObjectToClipPos(IN.vertex);
OUT.primitiveID = 0;//TODO
OUT.localTexcoord = IN.texcoord;
OUT.globalTexcoord = IN.texcoord;
OUT.direction = CustomRenderTextureComputeCubeDirection(OUT.globalTexcoord.xy);
return OUT;
}
sampler2D Texture_339414d4_3f08_4a60_b7de_60b5078454cd_Uniform;
inline float3 unity_rgbtohsv_float (float3 arg1)
{
float4 K = float4(0.0, -1.0 / 3.0, 2.0 / 3.0, -1.0);
float4 P = lerp(float4(arg1.bg, K.wz), float4(arg1.gb, K.xy), step(arg1.b, arg1.g));
float4 Q = lerp(float4(P.xyw, arg1.r), float4(arg1.r, P.yzx), step(P.x, arg1.r));
float D = Q.x - min(Q.w, Q.y);
float E = 1e-10;
return float3(abs(Q.z + (Q.w - Q.y)/(6.0 * D + E)), D / (Q.x + E), Q.x);
}
inline float3 unity_hsvtorgb_float (float3 arg1)
{
float4 K = float4(1.0, 2.0 / 3.0, 1.0 / 3.0, 3.0);
float3 P = abs(frac(arg1.xxx + K.xyz) * 6.0 - K.www);
return arg1.z * lerp(K.xxx, saturate(P - K.xxx), arg1.y);
}
float4 frag(v2f_customrendertexture IN) : COLOR
{
half4 uv0 = float4(IN.localTexcoord.xyz,1.0);
float4 Split_81de5761_6b38_4350_8ede_9db8ac1d98d0 = float4(_SinTime);
float4 Texture_339414d4_3f08_4a60_b7de_60b5078454cd = tex2D (Texture_339414d4_3f08_4a60_b7de_60b5078454cd_Uniform, uv0.xy);
float3 RGBtoHSV_6b42522c_e2df_4b64_8142_be2f5cf24530_Output = unity_rgbtohsv_float (Texture_339414d4_3f08_4a60_b7de_60b5078454cd);
float4 Split_42661a92_b299_44b2_a9ad_e7a76a22817c = float4(RGBtoHSV_6b42522c_e2df_4b64_8142_be2f5cf24530_Output, 1.0);
float4 Combine_8b3bcdf1_2eeb_4f31_a5ca_a4796ceb5066_Output = float4(Split_81de5761_6b38_4350_8ede_9db8ac1d98d0.r,Split_42661a92_b299_44b2_a9ad_e7a76a22817c.g,Split_42661a92_b299_44b2_a9ad_e7a76a22817c.b,0.0);
float3 HSVtoRGB_e30c457c_26fb_4e7c_847e_fb4e9cb55bb6_Output = unity_hsvtorgb_float (Combine_8b3bcdf1_2eeb_4f31_a5ca_a4796ceb5066_Output);
float Vector1_a551547a_ba15_43fe_8319_a5f8dc3c4362_Uniform = 1;
float4 Combine_97922ab7_d2fa_4422_aae7_10b1f82228da_Output = float4(HSVtoRGB_e30c457c_26fb_4e7c_847e_fb4e9cb55bb6_Output,Vector1_a551547a_ba15_43fe_8319_a5f8dc3c4362_Uniform);
return Combine_97922ab7_d2fa_4422_aae7_10b1f82228da_Output;
}
ENDCG
}
}
Fallback Off
}

12
MaterialGraphProject/Assets/UnityShaderEditor/Editor/HelperShader.shader.meta


fileFormatVersion: 2
guid: 9ab5e16c2083a4fe689209a8c1ae425e
timeCreated: 1495755323
licenseType: Pro
ShaderImporter:
defaultTextures:
- Texture_339414d4_3f08_4a60_b7de_60b5078454cd_Uniform: {fileID: 2800000, guid: 5485e2f56028a3c4cb54f5caa167377e,
type: 3}
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

/MaterialGraphProject/Assets/NewNodes/WIP/ParallaxNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/ParallaxNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ParallaxNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/ParallaxNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/MultiLayerParallaxNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/MultiLayerParallaxNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/MultiLayerParallaxNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/MultiLayerParallaxNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/POMNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/POMNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/AACheckerBoardNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/AACheckerBoardNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/RadialShearNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/RadialShearNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/RadialShearNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/RadialShearNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/ScaleOffsetNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/ScaleOffsetNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ScaleOffsetNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/ScaleOffsetNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/SphereWarpNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/SphereWarpNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/SphereWarpNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/SphereWarpNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/SphericalIndentationNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/SphericalIndentationNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/AACheckerBoard3dNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/AACheckerBoard3dNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/POMNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/POMNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/Editor → /MaterialGraphProject/Assets/NewNodes/Editor

/MaterialGraphProject/Assets/NewNodes/WIP/ChannelBlendNode.cs → /MaterialGraphProject/Assets/NewNodes/ChannelBlendNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ChannelBlendNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/ChannelBlendNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/ConstantType.cs → /MaterialGraphProject/Assets/NewNodes/ConstantType.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ConstantType.cs.meta → /MaterialGraphProject/Assets/NewNodes/ConstantType.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/ConstantsNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/ConstantsNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/FunctionNAddNode.cs → /MaterialGraphProject/Assets/NewNodes/FunctionNAddNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/FunctionNAddNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/FunctionNAddNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/FunctionNInNOut.cs → /MaterialGraphProject/Assets/NewNodes/FunctionNInNOut.cs

/MaterialGraphProject/Assets/NewNodes/WIP/FunctionNInNOut.cs.meta → /MaterialGraphProject/Assets/NewNodes/FunctionNInNOut.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/HeightToNormalNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/HeightToNormalNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/HeightToNormalNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/HeightToNormalNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/ReciprocalSqrtNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/ReciprocalSqrtNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ReciprocalSqrtNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/ReciprocalSqrtNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/VertexNormalNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/VertexNormalNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/VertexNormalNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/VertexNormalNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/VertexPositionNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/VertexPositionNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/VertexPositionNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/VertexPositionNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/CommonMatrixType.cs → /MaterialGraphProject/Assets/NewNodes/CommonMatrixType.cs

/MaterialGraphProject/Assets/NewNodes/WIP/CommonMatrixType.cs.meta → /MaterialGraphProject/Assets/NewNodes/CommonMatrixType.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/TangentToWorldNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/TangentToWorldNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/TangentToWorldNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/TangentToWorldNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/BlendModeNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/BlendModeNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/BlendModeNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/BlendModeNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/BlendModesEnum.cs → /MaterialGraphProject/Assets/NewNodes/Keep/BlendModesEnum.cs

/MaterialGraphProject/Assets/NewNodes/WIP/BlendModesEnum.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/BlendModesEnum.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/FractalNode.cs → /MaterialGraphProject/Assets/NewNodes/FractalNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/FractalNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/FractalNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/SamplerStateNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/SamplerStateNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/Texture2DNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/Texture2DNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/TextureSamplerNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/TextureSamplerNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/TextureSamplerNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/TextureSamplerNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/UVTriPlanar.cs → /MaterialGraphProject/Assets/NewNodes/Keep/UVTriPlanar.cs

/MaterialGraphProject/Assets/NewNodes/WIP/UVTriPlanar.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/UVTriPlanar.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/ColorBalanceNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/ColorBalanceNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ColorBalanceNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/ColorBalanceNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/GradientNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/GradientNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/GradientNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/GradientNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/RandomRangeNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/RandomRangeNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/RandomRangeNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/RandomRangeNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/ScatterNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/ScatterNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ScatterNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/ScatterNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/Editor.meta → /MaterialGraphProject/Assets/NewNodes/Editor.meta

/MaterialGraphProject/Assets/NewNodes/WIP/LightProbeNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/LightProbeNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/LightProbeNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/LightProbeNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/ReflectionProbeNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/ReflectionProbeNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ReflectionProbeNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/ReflectionProbeNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/ToggleNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/ToggleNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ToggleNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Kill/ToggleNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/TransformNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/TransformNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/TransformNode.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/TransformNode.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/GradientField.cs → /MaterialGraphProject/Assets/NewNodes/Keep/GradientField.cs

/MaterialGraphProject/Assets/NewNodes/WIP/GradientField.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/GradientField.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/GradientWrapper.cs → /MaterialGraphProject/Assets/NewNodes/Keep/GradientWrapper.cs

/MaterialGraphProject/Assets/NewNodes/WIP/GradientWrapper.cs.meta → /MaterialGraphProject/Assets/NewNodes/Keep/GradientWrapper.cs.meta

/MaterialGraphProject/Assets/NewNodes/WIP/AACheckerBoard3dNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/AACheckerBoard3dNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/AACheckerBoardNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/AACheckerBoardNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/ConstantsNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/ConstantsNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/SamplerStateNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/SamplerStateNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/SphericalIndentationNode.cs → /MaterialGraphProject/Assets/NewNodes/Kill/SphericalIndentationNode.cs

/MaterialGraphProject/Assets/NewNodes/WIP/Texture2DNode.cs → /MaterialGraphProject/Assets/NewNodes/Keep/Texture2DNode.cs

正在加载...
取消
保存