Creative COW SIGN IN :: SPONSORS :: ABOUT US :: CONTACT US
MAYA: MAYA ForumMAYA TutorialsMAYA

Scripting bevel plus - how to get the caps?

Cow Forums : MAYA
VIEW POSTS   •   ADD A NEW POST   •   SEARCH   •   CHANGE FORUM
Respond to this post   •   Return to posts index


Scripting bevel plus - how to get the caps?
by Joe Wheeler on Aug 12, 2008 at 3:09:17 pm

Hi all,

I'm pretty new to Maya so forgive me if this is a dumb question...

Basically I'm trying to write a python script that will:
1. import an arbitrary ai file
2. extrude it (I'm using bevel plus)
3. assign different materials, front, back and side faces
4. export the model as a collada file

I've got the script working, except for the bit that applies the materials. The problem is I can't work out how to consistently assign materials to the caps bevel plus creates.

So far, I've worked out that bevel plus creates the caps last so I've been using polyEvaluate to get the face count and then using, face count -1 to get the front, and face count -2 to get the back. The problem is, this only works with simple, single shape curves. For example, if my initial curve is lower case "i", only the stork of gets the correct the materials assigned, the dot gets missed.

Thanks for reading.

J


Respond to this post   •   Return to posts index


Current Message Thread:
  • Scripting bevel plus - how to get the caps? by Joe Wheeler on Aug 12, 2008 at 3:09:17 pm




Note: If you are a registered user please click here to login before posting.

Your post will not be accepted if your name and email address are not registered in our database. Click here if you do not have an account.

Name
E-Mail Address
Subject
E-Mail me when someone responds
Just This Message   Entire Thread   None  

Message:

Add Bold Tag To Message (JavaScript required)

To put any item inside this tag:

1. Highlight the desired text
2.Click this buttonAdd Italic Tag To Message (JavaScript required)

To put any item inside this tag:

1. Highlight the desired text
2.Click this buttonAdd Underline Tag To Message (JavaScript required)

To put any item inside this tag:

1. Highlight the desired text
2.Click this buttonAdd Image Link Tag To Message (JavaScript required)

To put any item inside this tag:

1. Highlight the desired text
2.Click this buttonAdd URL Link Tag To Message (JavaScript required)

To put any item inside this tag:

1. Highlight the desired text
2.Click this button

Note: The following are HTML characters and may cause parts of your post to disappear if not used correctly: < > &
To include any portion of the post in your response, highlight the desired text and hit the "Q" key. Read more...



Add your message signature


 


Note: By clicking "Post Direct" button above, you are agreeing to the Creative Cow's Code of Conduct.



FORUMSTUTORIALSMAGAZINEDVDsBOOKSPODCASTSEVENTSSERVICESNEWSLETTERNEWSBLOGS

© CreativeCOW.net All rights are reserved.

[Top]