HiddenMonk / Unity3DRuntimeTransformGizmo

A runtime transform gizmo similar to unitys editor so you can translate (move, rotate, scale) objects at runtime.
MIT License
707 stars 129 forks source link

Shaders not working in URP. #33

Open peter5885 opened 3 years ago

peter5885 commented 3 years ago

It seems like the shader for the outline is not working for URP. Version 10.3.2, Unity 2020.3.1f1

The gizmo seems to work well but I get the pink default material when selecting an object to transform. Any help would be appreciated.

image

HiddenMonk commented 3 years ago

I havent gotten into the new render stuff. Maybe what this person did would fix the issue https://github.com/HiddenMonk/Unity3DRuntimeTransformGizmo/issues/27#issuecomment-622356990

peter5885 commented 3 years ago

Yeah, I look at the existing issues and tried what is suggested, doesn't work. I think it specifically the Outline shader as the Lines shader seems to work as expected. Thanks for getting back in touch and suggesting some work arounds. I'll keep trying and feedback if I find anything.

sagarmicronixsystem commented 3 years ago

Yeah, I look at the existing issues and tried what is suggested, doesn't work. I think it specifically the Outline shader as the Lines shader seems to work as expected. Thanks for getting back in touch and suggesting some work arounds. I'll keep trying and feedback if I find anything.

just change the tags of you subshader from Tags {"LightMode" = "Always" } to Tags {"LightMode" = "UniversalForward" }

peter5885 commented 3 years ago

@sagarmicronixsystem Awesome! Works perfectly, thank you very much!

miccall commented 3 years ago

why gizmo seems to not work for me ? URP. Version 10.4.0

nfynt commented 1 year ago

After setting the "LightMode" to "UniversalForward", also make sure to enable the Post-Processing for your main camera. This was the reason I found that the gizmo was behaving wierdly at runtime.

image