#I'm stuck on shaders and materials
1 messages · Page 1 of 1 (latest)
You've started a thread so why not discuss it here.
But you didn't really explain what you problem is, so maybe start with that ?
I have cards that display normal images without any problems. When I apply a material with a shader, the image appears correctly, but it's misaligned and overlaps all the other elements (like the text). I'd like to understand why this happens and how to keep the image and shader properly aligned, without them overlapping everything else.
I didn't know what a thread was, but yes, let's talk here
Could you share screenshots of :
The correct rendering
The wrong one
The material inspector when it is not working properly.
yep
the 2 firsts image is without Material (with/o hover and with hover), the screenshot 3 is with only 1 card drawn anda mat, the 4 is with 2 cards and the mat.
If I hover the card with the mat, the picture dispawn
And I have the impression that it covers all this material, but that nothing remains when I hover
Can you also share the inspector of the material itself ?
Also, I see that you're a fellow 🥖 🇫🇷 dev.
I'm runnin a small French speaking discord about Unity, so if you feel like ranting in the spell of Molière I can send you an invite 🙂
Hum, could you also share a screenshot of the full shadergraph ?
If possible, with readable node names, if needed you can make the shadergraph window fullscreen with shift+space
What is the object type you're applying the material to ?
A mesh renderer ? Sprite renderer ?
A look at the inspector of the card object would answer that 🙂
If you are assigning the material with this shader to a sprite renderer, the shadergraph target should be set to "sprite" type
here ?
Yes !
But confirm first that the object is actually a sprite renderer, and that you are in Universal2D mode, that's what the Sprite Material type is for (first setting)
I just did it! The material was unlit and I changed the setting to unlit sprite
Worked ?
yep