(Sorry for the long explanation, but it will be difficult for me to send you an example where you can test all this to see what I mean!) So what I am wondering is, do generated shaders get different property names dependent on the platform maybe? In both cases the assetBundle containing the shader also automatically includes 'TCP2_PBS_ShadowMeta', 'TCP2_Standard PBS Outline', 'TCP2_Outline_SM2', 'TCP2_Outline' which both my shader and TCP2's own PBS shader are apparently dependent on. If I use the TCP2 Standard PBS shader things work even if I load that from an assetBundle. This all works fine in the editor (when loading the shader from the project) but when I try to load the shader from the assetBundle UMA tells me that (for example) 'Material Channel 0 refers to material property '_MainTex' but no such property exists' (in that message 'Material Channel 0 refers to the channel that is set up on a thing called an 'UMA Material' rather than anything like the shader property ID so its not to do with whether its Material Channel 0 or Material Channel 2 etc)īut this only seems to happen if I use my generated shader. So I have a material defined that uses the TCP shader I generated, and UMA is trying to assign the generated textures it has made to '_MainTex', '_BumpMap', '_MetallicGlossMap'' I'm using the TCP2 shader I shared with you before on a material for an UMA character (I'm one of the devs for UMA so I know quite a bit about that at least!) What UMA does when it generates is it creates a copy of the material you have defined and atlasses all the textures for all the parts of the character together as textures for that material. I'm really not knowledgeable at all when it comes to shaders so thats just a guess! The problem I am having is that the properties that you see in the editor when inspecting the shader dont actually seem to be on the shader thats generated for Android and put in the bundle. Thanks Jean, I went with what you suggested and that works fineīut now I'm having an issue with getting that generated shader to work from an assetBundle for Android (probably iOS too but I havent gotten to building that yet). That being said, it will require a rewrite from scratch at least for the shaders part, so in the end this might end up being Toony Colors Pro 3! It'll all depend on how much work it will require to adapt each pipeline, but from the sound of it it is meant to be easy enough, so I'm opitmistic about it! I think a first step would be to derive from the Lightweight pipeline and make a Toony Colors pipeline, basically.Īlthough it could also be a good way to make TCP2 support deferred rendering, which isn't available in Lightweight, so I don't know. I would also like to know how shader keywords are handled and if any changes are expected in this system. what happens to surface shaders? will we be able to write shader graphs as shader code?), and I'll have to learn about it a bit more and then do tests, but it's definitely on my mind. Some parts of the final system are still unclear (e.g. Click to expand.No concrete plans currently, but I am definitely interested in it.
0 Comments
|
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |