gilescoope / shader-graph-nodes

Custom Nodes for Unity Shader Graph
MIT License
587 stars 52 forks source link

error CS0122: 'CodeFunctionNode' is inaccessible due to its protection level #3

Open nukadelic opened 5 years ago

nukadelic commented 5 years ago

The code looks very good, was very hyped to try it but I'm primarily using unity version above 2019.1 and it seems like shader graph classes are now internally implemented is internal and no longer work.

https://forum.unity.com/threads/unable-to-create-custom-shader-graph-node-due-to-inaccessibility-of-customfunctionnode-class.586876/

But there is hope for the upcoming version 7.0.0 https://github.com/Unity-Technologies/ScriptableRenderPipeline/blob/master/com.unity.shadergraph/CHANGELOG.md

gilescoope commented 5 years ago

Yeah unfortunately Unity removed this method of generating shader nodes. There is now a custom function node where custom shaders can be typed in. It isn't as robust however as the old method. In any case you should be able to copy the code for any of the shader nodes I've written here and set up the inputs and outputs correctly yourself.

neon-age commented 3 years ago

I've added support for newer Unity versions by using AsmRef! See #5 🙂