CGTalk > Software > Autodesk Maya
Login register
Thread Closed share thread « Previous Thread | Next Thread »
 
Thread Tools Search this Thread Display Modes
Old 10-23-2013, 09:06 AM   #1
joie
Lexus-friendly
 
joie's Avatar
portfolio
JOSE MIGUEL ARAGUES
3D Animatior and TD at www.vortice3d.com
Zaragoza, Spain
 
Join Date: Oct 2002
Posts: 1,416
Force Toon not to evaluate

Hi there guys;

I want to use maya toon for a project but my meshes come from CAD software and some of them are huge and high poly count.

So, MAYA toon is very low on those, also because I'm rendering with Mental Ray, so I need it to be converted to polygons.

I know Toon can be set not to appear in viewport, but it is still being evaluating in the background when I make big camera view changes or selecting the object.

So I want the toon effect not to evaluate at all until rendering. I've tried to change the node evaluation status from normal to waiting or blocking with no changes on the result.

Any ideas?.

Thank you.
__________________
3D Animator and TD at www.vortice3d.com

"Donīt trust on affemeral things, only love will last..."

Visit my BLOG: 3djoie.blogspot.com
 
Old 10-24-2013, 06:36 PM   #2
Robosity
Know-it-All
portfolio
Rob
Rochester, USA
 
Join Date: Nov 2009
Posts: 322
Could you perhaps reference in your toon shader on render and not have it in the actual scene that you are animating?

scene A: Geo and animations
scene B: Toon shaders
Scene C: refScene A + refScene B
__________________
noise Noise NOISE NOISE
 
Old 10-24-2013, 09:23 PM   #3
Duncan
Expert
 
Duncan's Avatar
Duncan Brinsmead
Principal Scientist
Autodesk
Canada
 
Join Date: Jun 2002
Posts: 2,984
If the toon is not displaying in the viewport it should not be evaluating.
Normally either turning off "display in viewport" or disabling "strokes" in your viewport "show" menu should work.

If you still want to see the lines but want faster tumble you could set paint effects to "interactive" in the performance settings window.

Note that these won't work if you have converted the toon to a poly mesh( pfx to poly ). In that case you need to hide the output mesh. However if you have anything downstream from this toon mesh that is using it( like a particle emit from mesh ) then the pull from that downstream object will still trigger the evaluation, even if it is hidden. (you would then need to hide whatever is downstream as well ).

I just tested all these, and they seem to correctly disable the evaluation for me.

There are things you can do to make the evaluation faster if you wan to see the lines in the view. The evaluation of the toon lines on tumble is only needed for profile lines. If the offsetMesh profile lines technique works for you, then you should be able to tumble and see the profile lines without any speed hit.

The other lines like creases should only regenerate when the object moves or deforms. If the object moves but does not deform you could make those faster by converting to poly with history off then parenting the resulting lines mesh to your object so they move with it.

Another thing that can sometimes speed things up... if you have a very high res mesh... is to resample the various lines(on toon node) , increasing the minSegmentLength as high as is acceptable.

Last edited by Duncan : 10-24-2013 at 09:27 PM.
 
Old 10-25-2013, 07:37 AM   #4
joie
Lexus-friendly
 
joie's Avatar
portfolio
JOSE MIGUEL ARAGUES
3D Animatior and TD at www.vortice3d.com
Zaragoza, Spain
 
Join Date: Oct 2002
Posts: 1,416
Hi there Duncan and thank you for reading this.

I do need to convert the toon lines to polys since I'm rendering with mental ray and I can't seem to find any setting in the contour rendering for border contours (it amazes me not to have this option in the contour rendering options in mental ray).

This is what I've done for now:
  • Create Toon for my object (comes from CAD software)
  • Convert to polygons
  • Disable toon visible in viewport
  • Hide the resulting poly toon so it doesn't evaluate
  • Create a pre render mel to make the poly toon lines visible
With all the above, now it works decently well.

Just to be sure, if I want to have the crease and border lines converted to polys without history, and only have the profile ones with history, I do need them in separate toon lines needn't I?, I mean two Toons applied to the same object.

Thank you.
__________________
3D Animator and TD at www.vortice3d.com

"Donīt trust on affemeral things, only love will last..."

Visit my BLOG: 3djoie.blogspot.com
 
Old 10-25-2013, 07:53 AM   #5
antweiler
Expert
 
antweiler's Avatar
Robert Kopf
Senior 3D-Artist
MBL Development
Hamburg, Germany
 
Join Date: Mar 2003
Posts: 545
Have you checked, whether rendering the Toonlines in Maya Software in a separate pass is an option? While the extra work is a pain it might render very fast
 
Old 10-25-2013, 08:18 AM   #6
joie
Lexus-friendly
 
joie's Avatar
portfolio
JOSE MIGUEL ARAGUES
3D Animatior and TD at www.vortice3d.com
Zaragoza, Spain
 
Join Date: Oct 2002
Posts: 1,416
Sorry I made a mistake.

Even if I hide the poly result of converting the toon lines, the scene is very slow. What I forgot to mention in the last post is that I've put "0" in both profile and border lines' size, so they don't evaluate at all.

Then in the pre render mel, I put a command to change their size to the desired one.

BTW, for some reason, MAYA software renderer is slower than Mental Ray, and I need depth and world point information passes, so I need to stick to Mental Ray anyway.
__________________
3D Animator and TD at www.vortice3d.com

"Donīt trust on affemeral things, only love will last..."

Visit my BLOG: 3djoie.blogspot.com
 
Old 10-25-2013, 07:36 PM   #7
Duncan
Expert
 
Duncan's Avatar
Duncan Brinsmead
Principal Scientist
Autodesk
Canada
 
Join Date: Jun 2002
Posts: 2,984
Quote:
Originally Posted by joie
..
Just to be sure, if I want to have the crease and border lines converted to polys without history, and only have the profile ones with history, I do need them in separate toon lines needn't I?, I mean two Toons applied to the same object.....


That's right. In some cases, especially when you have a lot of non-profile lines, it can be more efficient to break out the profiles lines into a second toon assigned to the same object.

I think I've had the update problem you've had where the toon seems to evaluate even when the toon to poly mesh is hidden, but I've not been able to get it to happen in simple tests.
Perhaps it would be more efficient to set toon.profileLines, borderLines etc in your script to 0 rather than the line width. With the zero line width it generates the lines, but does not make polys during the convert to poly. However it sounds like the time hit for you may be the convert to poly. Again... the line resampling might help speed up the mesh generation. Also if you enable outputQuads on the toon you will get half the poly count in the mesh, which might help a little.

If you have a relatively simple scene with the problem it might be good to submit a bug with it.

Last edited by Duncan : 10-25-2013 at 07:46 PM.
 
Old 10-26-2013, 08:50 AM   #8
tonytouch
it is a misery
 
tonytouch's Avatar
Simon Leykamm
Munich, DE
 
Join Date: Oct 2004
Posts: 325
hi joie,

we actually used Maya Toon Outlines in our shortfilm www.lostbox.de - you can also see a bit of the compositing and the render-layers in my short making of : https://vimeo.com/19702221

here is how i used them technically

1. for each outline-pass i created one renderlayer : ( in our film we used one mentalRay-contour and one mayaContour-layer )

actually only a few "organic"-objects were rendered with maya-software-renderer ( the characters have additional maya-software-contours , but e.g. "THE ROBOT" do not have them , and also not most parts of the backgrounds , those were done with mentalRay-contours )

one of the problems with the maya-toon-outlines , is the scaleability , if you need different linewidth in different camera-angles and perspectives ( e.g. if your character is in a closeup or just standind somewhere far in the background ) . therefore you would have to create a few multiply nodes ( e.g. one "multDoubleLinear" for each toon-attribute that you need to scale ) .

----------using renderlayers ------------------------------
- for the maya-toon-outline: set the proper "layer-overrides" for each toon_renderlayer:
a ) override "renderUsing" -> right click it and set an override on "Maya Software"-renderer ( this way you can render the the masterlayer with mentalRay , and the contour-layer with maya software renderer )
b ) create a global material-override for this layer ( a white surface-shader )
c ) create an override on the resolution ( double the resolution of the contour-layer , later in compositing , scale it down , this will give you a better resolution and will at leat avoid some of the "render-flickering" .
d ) you might also want to override the "background-color" of your render-cam , to white
e ) if you use "smooth-preview" ( hitting the "3" on certain polygon-meshes ) , you need to "additionally SMOOTH-geometry" your meshes , for the seperate layer . since maya will not do this automatically for you ) - and then override the smooth-iterations on this layer .

one thing about render layers : ( i would suggest , setting them up , in the last step - or at least keep them very simple , in order to be able to delete them and recreate them . since when you work with "renderlayers" and "file-referencing" , there is always a great chance to run into certain troubles . ( well , renderlayers always create certain problems , if you do not have a professional rendering-pipeline ) -


if you would create a pre-render-script , which does all of that prior to rendering , it would be the best possible solution .

Last edited by tonytouch : 10-26-2013 at 09:30 AM.
 
Old 10-26-2013, 09:28 AM   #9
tonytouch
it is a misery
 
tonytouch's Avatar
Simon Leykamm
Munich, DE
 
Join Date: Oct 2004
Posts: 325
2 years , after this shortfilm , i was working on a different project where they wanted to use contours . ( a german children-film ) . and there we just used mentalRay_contours . which btw. follows a complete different approach than using mayaContours , and you have to setup your shading differently in order to get them to work propperly in a rendering-pipeline .

sometimes with maya-toon-lines , in some shots you will have to adjust the linewidth , or even have to animate them , e.g. when a character walks towards the camera , or if the camera is heavily animated ( e.g. a flying_camera , that goes from the total outside of an environment , INTO the center . )

depending on the size of your project , this can be a lot of work !!! and i guess it cannot be handled without scripting and doing quite some research and a lot of tests - to figure out how it works in the best way . ( at least if is a project with more than 8 shots and 2 characters ). because creating renderings with contours is surely causing about 10-30% more work within the rendering-process . and maybe 10-30% more work in research and developement for the final shading . also it will add some 10-30% more work into your pipeline and scripting .

so the contours are actually not a thing , which come out for free . at least not , if you want to have some control over the outlines .

ah , and one last thing : the "maya-software-contour" pass ( is always rendering extremely fast !!! although if you render in double-resultion , it will render super-quick , when you just use a white surface-shader and not any textures and since you do not have to convert them to polygons , and can directly render them in maya-software .)

so once you have figured everything out and setup everything properly - the single contour-pass will render extremely fast .
 
Old 10-28-2013, 11:10 AM   #10
joie
Lexus-friendly
 
joie's Avatar
portfolio
JOSE MIGUEL ARAGUES
3D Animatior and TD at www.vortice3d.com
Zaragoza, Spain
 
Join Date: Oct 2002
Posts: 1,416
Thank you but, as I said, I can't render with MAYA since I need render passes.

Duncan, you are right, the line resampling helps a lot. BTW in the script I turned 0 the line size since it is what is said in the documentation about scene optimisation. I will try what you suggested and see if it helps.
__________________
3D Animator and TD at www.vortice3d.com

"Donīt trust on affemeral things, only love will last..."

Visit my BLOG: 3djoie.blogspot.com
 
Old 10-28-2013, 05:25 PM   #11
joie
Lexus-friendly
 
joie's Avatar
portfolio
JOSE MIGUEL ARAGUES
3D Animatior and TD at www.vortice3d.com
Zaragoza, Spain
 
Join Date: Oct 2002
Posts: 1,416
Duncan, in the toon line attributes I can switch the crease and intersection lines, not the profile or border ones..., am I missing something?.

Thanks.
__________________
3D Animator and TD at www.vortice3d.com

"Donīt trust on affemeral things, only love will last..."

Visit my BLOG: 3djoie.blogspot.com
 
Old 10-28-2013, 05:54 PM   #12
Duncan
Expert
 
Duncan's Avatar
Duncan Brinsmead
Principal Scientist
Autodesk
Canada
 
Join Date: Jun 2002
Posts: 2,984
I'm just guessing but perhaps you keyframed those attributes without realizing it? Are they greyed out or simply won't let you change the value?
 
Old 10-28-2013, 05:57 PM   #13
Duncan
Expert
 
Duncan's Avatar
Duncan Brinsmead
Principal Scientist
Autodesk
Canada
 
Join Date: Jun 2002
Posts: 2,984
Simon... it sounds like you had issues with controlling line width based on distance to the camera. Did you try the screenspace width control options on Maya toon? One can clamp min/max width in pixels, as well blend between fully 3D line widths( distance scaling = 1 ) and fully 2d ( distance scaling = 0 ).
 
Old 10-29-2013, 07:53 AM   #14
joie
Lexus-friendly
 
joie's Avatar
portfolio
JOSE MIGUEL ARAGUES
3D Animatior and TD at www.vortice3d.com
Zaragoza, Spain
 
Join Date: Oct 2002
Posts: 1,416
Duncan, I'm on 2013 and I can't find those attributes, I haven't animate anything either..., the only ticks I can choose are "crease" and "intersection" lines.
__________________
3D Animator and TD at www.vortice3d.com

"Donīt trust on affemeral things, only love will last..."

Visit my BLOG: 3djoie.blogspot.com
 
Old 10-29-2013, 12:32 PM   #15
tonytouch
it is a misery
 
tonytouch's Avatar
Simon Leykamm
Munich, DE
 
Join Date: Oct 2004
Posts: 325
Quote:
Originally Posted by Duncan
Simon... it sounds like you had issues with controlling line width based on distance to the camera. Did you try the screenspace width control options on Maya toon? One can clamp min/max width in pixels, as well blend between fully 3D line widths( distance scaling = 1 ) and fully 2d ( distance scaling = 0 ).


hi Duncan ,

actually it is already 3-4 yrs ago , when we were working on the project , so i don't remember so well about the maya-outlines . but yes , i tested and used the screenspace-linewith options . but i think , it never turned out for me , that i have full control , since you really want the outlines thicker in certain shots , than in others ( like dark or bright lighting of the environments ). i am not sure if i later used it that way or made it differently , but i remember , that i experimented quite a lot , and in the end , i could work through all the 105 shots of the film quite easily , without having to finetune a lot for the outlines .

maybe one method was to pointConstraint a helperLocator to the render-cam for each shot . and that one measured the distance to the character in order to multiply with the thickness . but i am not sure right now , if that technique made it into the final character-setup or not . but i think it was more or less not only about the linewidth , as far as i remember there have also been quite a few offset-values , some min-max values , that had to be scaled . but i am really not sure , since it has been a long time since then .

one thing i surely created was a global linewidth-mutiplicator attribute for the characters ( to have a better shot-by-shot control . i think we had about 10 different toon-lines for the characters , since we made 2 outlines for shirt , short , head and shoes . so we were able to have a crisp and sharper outline , and one , which looked more painted . and could make the outlines thinner for the head , than the oultine on the shirt or pants or shoes .

@joie:
those are in the "screenspace-width"-section of the "pfxToon"

Last edited by tonytouch : 10-29-2013 at 12:36 PM.
 
Thread Closed share thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright Đ2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 01:09 PM.


Powered by vBulletin
Copyright ©2000 - 2016, Jelsoft Enterprises Ltd.