#Get mesh edges with shader

8 messages · Page 1 of 1 (latest)

clear surge
#

I'm wondering how I would use a shader to detect (proximity to) the edges of a mesh. I know I could use a post-processing shader to acheive this, but since I'm just trying to create a procedural material and not a visual effect, I feel like it's a little overkill.

I've been looking for options to the effect of getting the derivative of the mesh normal (which would (maybe?) be the ideal solution), but I haven't found anything so far.

I feel like there might be something obvious I'm missing here, but I can't think of it.

light cypress
#

For toon shading? Or something like a Sobel?

clear surge
light cypress
#

weathering shader? to make materials look 'older' 'weather' exposed kinda thing?

#

if you want it to be geometrically aware you'll need to detect edges, or pass additional info to the fragment from the vertex (hard within bevy)

clear surge
#

yeah with further research that's about what i found, bevy limitations are what's getting me here

#

I've been working on other stuff and this is low priority so I'll probably put it off until it's a little more possible 😅

#

otherwise if needs be I'll just use a post process shader and try not to tear my hair out when it causes problems lol