Home Technical Talk

Maya 8 and above - render polygon edges to texture

grand marshal polycounter
Offline / Send Message
pior grand marshal polycounter
Hi!

There is something I would love to do in Maya (Max is fine too).

Basically I'd like to be able to select edges on a polygon object, and render them to texture with a preset for edge thickness. The reason is, I like to 'paint' darker values were some particular edges are located on the model (especially for mechanical stuff) to reinforce the readability of a shape, or to easily strengthen the edges where two materials meet. I know I could render AO with a tight spread and erase out what I dont want - but it would be a bit of an unnecessary pain!

I know Maya can render to wireframe easily - so I guess I just want to do that, only selectively, and with a simple control for thickness.

Thanks!

Replies

  • MoP
    Offline / Send Message
    MoP polycounter lvl 18
    Hmm, interesting idea! Could be good for "guide lines" etc. Like you say, I guess.
    I might look into it ;o
  • pior
    Offline / Send Message
    pior grand marshal polycounter
    Yeah exactly.

    You know how sometimes material edges are a pain to paint in and end up never really matching the UVs. With a script like that it would make it easy to 'extract' such lines straight from the edge geometry, and they would be very clean and precise. (ill try to attach an example later)

    The tricky part would be to have the script adjust the width of the baked edge line to compensate for UV compression... (otherwise the line would end up thickening and shrinking along the shape!)

    I mostly imagine that for normalmapped details not derived from highpoly geometry.

    Weird I know!
  • MoP
    Offline / Send Message
    MoP polycounter lvl 18
    Someone did something kinda similar to this in Max, where they'd send a face selection out to PS as a selection mask, looked pretty nifty.
    I guess I could look at doing something similar to that, ie. send a UV edge selection out as a PS path if PS is currently open, since paths are probably more versatile than baked-down pixels.
    I'll see what can be done ;)
  • Jeff
    Hi,


    Something we used all the way through our last 2 productions was a "Curvature baking" plugin.
    It definitely helps in lifting up the first diffuse pass in relation with the geometry. Used it as multiply pass for soft not-too-shiny organics as clothes, skins, woods ... or as color-burn and/or soft light layer with metals mostly.
    True you can get similar/close results with the baking of AO (normals inverted or not), and with a lot of post handwork, but well, you know it's not the sharp result you want in relation with the real geometry.

    So, may I advise you to test this one, if not done already ;o)

    Plug's here

    If you got some installation problems, what we had with a 8.5 version of Maya (had to develop a .mel internaly to get it working on a 7.0 version :o( ), I can prolly forward you sources. But, by the way, I'm pretty sure Brice installed it recently under 2k8 and got it workin' ;o)

    The script particularily fits for smoothed organic meshes. I mean, before baking the curves, smoothing all the meshes helps in getting rid of some loss artifacts and also helps like refining the geometry. If you don't , the baking will of course reveal more of the low poly geometry. So, smoothing firt. Appart from organics, using it for vehicles and buildings, with many coplanar sections, usually brings some triangular artifacts, easy to correct though.

    About the pre-selection, well, no solution for you but well, I guess this pre-treatment can help you in the process.


    I will also prolly test it tonight too under later version of Maya.


    Hope that helps, sorry if I missed smthg guys.
  • Jeff
    Got infos from Brice. He finally used 7.0 version of Maya to get it working.

    Sry, no other way than installing this one. But it really worths it ;)
  • whipSwitch
    Offline / Send Message
    whipSwitch polycounter lvl 8
    another option would be doing a uv snapshot of selected faces. No option for thickness and you'd have to erase the extraneous edge since you cant just snapshot edges, but its easier than searching for a particular edge in a normal uv bake.
  • gamedev
    Offline / Send Message
    gamedev polycounter lvl 12
    another option would be doing a uv snapshot of selected faces. No option for thickness and you'd have to erase the extraneous edge since you cant just snapshot edges, but its easier than searching for a particular edge in a normal uv bake.

    My guess is though with taking a UV snapshot, you'll get edges, but not where two objects / elements or edges might intersect in the geo.

    I've been looking for something like this too and would love a way to do this in 3ds Max. IE get nice lines where objets or elements intersect in to the geo to better make those intersections pop.
  • pior
    Offline / Send Message
    pior grand marshal polycounter
    Oh Gamedev you're right! I didn't think of it that way, but yeah that would be most useful too! (perhaps an option to take intersections into account or not?)
  • renderhjs
    Offline / Send Message
    renderhjs sublime tool
    gamedev wrote: »
    My guess is though with taking a UV snapshot, you'll get edges, but not where two objects / elements or edges might intersect in the geo.
    I've been looking for something like this too and would love a way to do this in 3ds Max. IE get nice lines where objets or elements intersect in to the geo to better make those intersections pop.
    check out
    Collision Map Generator
    This script generates maps based on the collision of an object with another object...i've included a pdf help file with it.
    Imagin a dirty character hand touches the wall it will leave some dirt on it...or may be a character walking on sand his feet will leave marks on the ground...you can use it in many things.

    http://scriptspot.com/3ds-max/collision-map-generator

    as for the other part- I might be able to do that in maxscript the way I did the script that renders the selected faces (see: http://boards.polycount.net/showthread.php?t=60553) is that I isolated the selection (there is a isolate icon in the uv-unwrap editor as well) and then rendered a UV template. The same could propably done with edges.
    The only thing I dont know to solve in maxscript though would be the line thickness - but alternativly some photoshop scripts woudl do the job (e.g blur 2 pix, copy paste layer ~ 20x times, merge them all together).
    It actually might be a nice addition to my uv-script collection
Sign In or Register to comment.