  | | | edge map | edge map 2005-04-08 - By Alan Jones
Back Here's a few random ideas.
Take the mi_tri_vectors and look at their similarity. If one is pointing in a different direction then the other two represent an edge where the angle changes - the difference should be half of the angle. Though this assumes a lot of things - like averaged normals rather than auto-discontinuity and that the width you want is no wider than a single triangle. So it's really pretty useless.
This one needs an XSI plugin as well as a shader though - pump some custom user data into mental ray with all the edges and their angles. Make some nice lookup structure to find the closest point on any of those edges when you render and use this distance in combination with the angle to drive your texture. Would need some more thought to make sure only closely physically connected triangles were affected.
Surface derivatives is another option, but you need some way to integrate them over the distance so it's not going to be a barrel of laughs either.
One more idea - hmm actually the more I think about it the more this one seems the best. If you made an ambient occlusion shader which sends samples inside rather than outside - give the samples a length to control how sensitive it is. It will also darken for thin parts of geometry though, but you could send a probe ray straight in along the normal first and use that length to adjust it so it automatically scales for thing geometry. (or just paint a weightmap/texturemap to use drive the length, but that kindof kills the point).
Hope this helps,
Alan.
On Apr 8, 2005 12:10 PM, Adrian Wyer <adrian@(protected)> wrote: > just throwing this out to the shader wranglers among us.... > > would it be difficult to rework Dirtmap to 'highlight' 'outside' edges as > opposed to inside ones? > > could be really useful to blend through 'chipped/damaged' textures on the > edges of geometry.... > > just a thought > > adrian wyer > head of 3d > milltv > adrian@(protected) > www.the-mill.com > t: +44 (0)20 7287 4041 > f: +44 (0)20 7915 0551 > > --- > Unsubscribe? Mail Majordomo@(protected) with the following text in body: > unsubscribe xsi > --- Unsubscribe? Mail Majordomo@(protected) with the following text in body: unsubscribe xsi
|
|
 |