Siccity / GLTFUtility

Simple GLTF importer for Unity

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

override Shaders, and HDRP Shader

rafaP opened this issue · comments

commented

How can I override the shaders used in the model with the import settings?

ImportSettings importSettings = new ImportSettings();
ShaderSettings shaderSettings = new ShaderSettings();

//But inside the shadersettings we can't define the shader to override. only read.
shaderSettings.Metallic = ShaderToOver;
importSettings.shaderOverrides = shaderSettings;
createdObject = Importer.LoadFromBytes(b3dm.GlbData, importSettings);

The URP shader that you have it works in HDRP.

#73 (comment)

Maybe you can add the HDRP folder and the shader to the project so when we load from git it won't get pink all the time