浏览代码
Merge branch 'hackweek2017' of https://github.com/stramit/MaterialGraph into hackweek2017
/main
Merge branch 'hackweek2017' of https://github.com/stramit/MaterialGraph into hackweek2017
/main
Florent Guinier
8 年前
当前提交
c51916c9
共有 17 个文件被更改,包括 1424 次插入 和 112 次删除
-
12MaterialGraphProject/Assets/Andre/CubemapNode.cs
-
181MaterialGraphProject/Assets/Matt&Andre/RemapNode.cs
-
2MaterialGraphProject/Assets/TestAssets/Sky1.jpg.meta
-
3MaterialGraphProject/Assets/UnityShaderEditor/Editor/Drawing/Presenters/NodePreviewPresenter.cs
-
9MaterialGraphProject/Assets/Andre.meta
-
12MaterialGraphProject/Assets/Andre/CubemapNode.cs.meta
-
1MaterialGraphProject/Assets/Andre/New Shader Graph.ShaderGraph
-
9MaterialGraphProject/Assets/Andre/New Shader Graph.ShaderGraph.meta
-
43MaterialGraphProject/Assets/Matt/LinearToRGB.cs
-
12MaterialGraphProject/Assets/Matt/LinearToRGB.cs.meta
-
43MaterialGraphProject/Assets/Matt/RGBtoLinear.cs
-
12MaterialGraphProject/Assets/Matt/RGBtoLinear.cs.meta
-
25MaterialGraphProject/obj/Debug/Assembly-CSharp.csproj.FilesWrittenAbsolute.txt
-
1001MaterialGraphProject/obj/Debug/Assembly-CSharp.dll
-
171MaterialGraphProject/obj/Debug/Assembly-CSharp.dll.mdb
|
|||
fileFormatVersion: 2 |
|||
guid: cd5688ca09d4248698f2b43253441000 |
|||
folderAsset: yes |
|||
timeCreated: 1495479128 |
|||
licenseType: Pro |
|||
DefaultImporter: |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|
|||
fileFormatVersion: 2 |
|||
guid: c184bca342bb146daa708a7ecda424fc |
|||
timeCreated: 1495482070 |
|||
licenseType: Pro |
|||
MonoImporter: |
|||
serializedVersion: 2 |
|||
defaultReferences: [] |
|||
executionOrder: 0 |
|||
icon: {instanceID: 0} |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
1
MaterialGraphProject/Assets/Andre/New Shader Graph.ShaderGraph
文件差异内容过多而无法显示
查看文件
文件差异内容过多而无法显示
查看文件
|
|||
fileFormatVersion: 2 |
|||
guid: 8c255d11f15384beb834142327f24126 |
|||
timeCreated: 1495482510 |
|||
licenseType: Pro |
|||
ScriptedImporter: |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|||
script: {fileID: 11500000, guid: 625f186215c104763be7675aa2d941aa, type: 3} |
|
|||
using UnityEngine.Graphing; |
|||
|
|||
namespace UnityEngine.MaterialGraph |
|||
{ |
|||
[Title ("Math/Color/LineartoRGB")] |
|||
public class LineartoRGBNode : Function1Input, IGeneratesFunction |
|||
{ |
|||
public LineartoRGBNode() |
|||
{ |
|||
name = "RGBtoLinear"; |
|||
} |
|||
|
|||
protected override string GetFunctionName () |
|||
{ |
|||
return "unity_lineartorgb_" + precision; |
|||
} |
|||
|
|||
protected override MaterialSlot GetInputSlot () |
|||
{ |
|||
return new MaterialSlot (InputSlotId, GetInputSlotName (), kInputSlotShaderName, SlotType.Input, SlotValueType.Vector3, Vector4.zero); |
|||
} |
|||
|
|||
protected override MaterialSlot GetOutputSlot () |
|||
{ |
|||
return new MaterialSlot (OutputSlotId, GetOutputSlotName (), kOutputSlotShaderName, SlotType.Output, SlotValueType.Vector3, Vector4.zero); |
|||
} |
|||
|
|||
public void GenerateNodeFunction (ShaderGenerator visitor, GenerationMode generationMode) |
|||
{ |
|||
var outputString = new ShaderGenerator (); |
|||
outputString.AddShaderChunk (GetFunctionPrototype ("arg1"), false); |
|||
outputString.AddShaderChunk ("{", false); |
|||
outputString.Indent (); |
|||
outputString.AddShaderChunk (precision + "3 sRGBLo = arg1 * 12.92;", false); |
|||
outputString.AddShaderChunk (precision + "3 sRGBHi = (pow(max(abs(arg1), 1.192092896e-07), "+precision+ "3(1.0 / 2.4, 1.0 / 2.4, 1.0 / 2.4)) * 1.055) - 0.055;", false); |
|||
outputString.AddShaderChunk ("return " + precision + "3(arg1 <= 0.0031308) ? sRGBLo : sRGBHi;", false); |
|||
outputString.Deindent (); |
|||
outputString.AddShaderChunk ("}", false); |
|||
|
|||
visitor.AddShaderChunk (outputString.GetShaderString (0), true); |
|||
} |
|||
} |
|||
} |
|
|||
fileFormatVersion: 2 |
|||
guid: 667e5671fc459344c889207ff866ab08 |
|||
timeCreated: 1444218016 |
|||
licenseType: Pro |
|||
MonoImporter: |
|||
serializedVersion: 2 |
|||
defaultReferences: [] |
|||
executionOrder: 0 |
|||
icon: {instanceID: 0} |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|
|||
using UnityEngine.Graphing; |
|||
|
|||
namespace UnityEngine.MaterialGraph |
|||
{ |
|||
[Title ("Math/Color/RGBtoLinear")] |
|||
public class RGBtoLinearNode : Function1Input, IGeneratesFunction |
|||
{ |
|||
public RGBtoLinearNode() |
|||
{ |
|||
name = "RGBtoLinear"; |
|||
} |
|||
|
|||
protected override string GetFunctionName () |
|||
{ |
|||
return "unity_rgbtolinear_" + precision; |
|||
} |
|||
|
|||
protected override MaterialSlot GetInputSlot () |
|||
{ |
|||
return new MaterialSlot (InputSlotId, GetInputSlotName (), kInputSlotShaderName, SlotType.Input, SlotValueType.Vector3, Vector4.zero); |
|||
} |
|||
|
|||
protected override MaterialSlot GetOutputSlot () |
|||
{ |
|||
return new MaterialSlot (OutputSlotId, GetOutputSlotName (), kOutputSlotShaderName, SlotType.Output, SlotValueType.Vector3, Vector4.zero); |
|||
} |
|||
|
|||
public void GenerateNodeFunction (ShaderGenerator visitor, GenerationMode generationMode) |
|||
{ |
|||
var outputString = new ShaderGenerator (); |
|||
outputString.AddShaderChunk (GetFunctionPrototype ("arg1"), false); |
|||
outputString.AddShaderChunk ("{", false); |
|||
outputString.Indent (); |
|||
outputString.AddShaderChunk (precision + "3 linearRGBLo = arg1 / 12.92;", false); |
|||
outputString.AddShaderChunk (precision + "3 linearRGBHi = pow(max(abs((arg1 + 0.055) / 1.055), 1.192092896e-07), "+precision+"3(2.4, 2.4, 2.4));", false); |
|||
outputString.AddShaderChunk ("return " + precision + "3(arg1 <= 0.04045) ? linearRGBLo : linearRGBHi;", false); |
|||
outputString.Deindent (); |
|||
outputString.AddShaderChunk ("}", false); |
|||
|
|||
visitor.AddShaderChunk (outputString.GetShaderString (0), true); |
|||
} |
|||
} |
|||
} |
|
|||
fileFormatVersion: 2 |
|||
guid: e282583a8fbbf2742bd10d617611c8b0 |
|||
timeCreated: 1444218016 |
|||
licenseType: Pro |
|||
MonoImporter: |
|||
serializedVersion: 2 |
|||
defaultReferences: [] |
|||
executionOrder: 0 |
|||
icon: {instanceID: 0} |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Assembly-CSharp.dll.mdb |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Assembly-CSharp.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/obj/Debug/Assembly-CSharp.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/obj/Debug/Assembly-CSharp.dll.mdb |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEngine.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEditor.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEngine.UI.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEngine.Networking.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEngine.PerformanceTesting.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEngine.TestRunner.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/nunit.framework.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEngine.Timeline.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEngine.UIAutomation.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEngine.Analytics.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/UnityEngine.HoloLens.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Mono.Cecil.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Unity.SerializationLogic.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Unity.DataContract.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/ExCSS.Unity.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Unity.Legacy.NRefactory.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Unity.UNetWeaver.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Unity.UNetWeaver.dll.mdb |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Unity.CecilTools.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Mono.Cecil.Pdb.dll |
|||
/Users/andremcgrail/Documents/UnityProjects/External Projects/MaterialGraph/MaterialGraphProject/Temp/bin/Debug/Mono.Cecil.Mdb.dll |
1001
MaterialGraphProject/obj/Debug/Assembly-CSharp.dll
文件差异内容过多而无法显示
查看文件
文件差异内容过多而无法显示
查看文件
171
MaterialGraphProject/obj/Debug/Assembly-CSharp.dll.mdb
文件差异内容过多而无法显示
查看文件
文件差异内容过多而无法显示
查看文件
撰写
预览
正在加载...
取消
保存
Reference in new issue