Heavy curve - lots of curve shapes (takes an age to select and edit)

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

 
Thread Tools Search this Thread Display Modes
  1 Week Ago
Heavy curve - lots of curve shapes (takes an age to select and edit)

Hi all,

Anyone work with heavy detailed curves much in maya?   I need a bit of advice. 

I've been given a floor layout as a curve from another piece of software (see image below),  when i go to select it, it takes about 40 seconds to actually select the curve.
The attribute editor has a large amount of curve shapes. 

I was hoping to render the curve with Arnold but would be a bit tedious to go through each shape in the attribute editor and assign a flat curve shader to it.  Anyone have any ideas on a better approach?  Thanks


__________________
AI will never achieve Human Stupidity.
 
  1 Week Ago
You can assign materials with the script. Try Curve Editor of Asset Manager for that task.
Or select curve shapes and run Python script:


import pymel.core as pm
# Asign SHADER to CURVES
# select curves, SHIFT select shader, run
def shaderAsign():
    sel = pm.ls( sl=1 )
    mat = sel.pop( -1 ) 
    for i in sel:
        if i.nodeType() == 'transform':
            i = i.getShape()
        mat.outColor >> i.aiCurveShader
        
shaderAsign()
__________________
3D animation blog

Last edited by kiryha : 4 Days Ago at 12:52 PM.
 
  5 Days Ago
Hi kiryha, thanks for the suggestion,  I can't seem to get the script to work, I get this error returned: 

shaderAsign()
# Error: NameError: file <maya console> line 4: global name 'pm' is not defined # 

--//

Maybe there is another solution, as you can see in my example below, I have too many curve shapes under this one curve.  I've tried using the Curves>> attach tool but I end up with too many edges getting bridged across the original shape.

Maybe i'll just have to re-trace over all the curve shapes with a simpler design.  Another thing I could do is to just render a matte and adjust a flat colour in after effects afterwards... hmm.


__________________
AI will never achieve Human Stupidity.
 
  5 Days Ago
Try to add this line of code on very top of the script:


import pymel.core as pm


if above doesn’t work then:

import maya.cmds as pm


I am not sure if he used Pymel of Python and what is exact difference but one of those should work with the code i think.
__________________
ArtStation -- Facebook -- Gumroad (Maya scripts)
 
  4 Days Ago
Pymel, the first one is correct.
__________________
3D animation blog
 
  3 Days Ago
Thanks all  
__________________
AI will never achieve Human Stupidity.
 
reply share thread



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 10:45 AM.


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