Sign in to follow this  

access material property from INode in 3ds max

This topic is 2658 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

hi all:
i'm really sorry that it's not a problem related to DX or XNA, it's 3ds max plugin.

i want to access the material property of INode in 3ds max, but it seems that something is wrong.

There is a interface named getFaceMtlIndex() for Mesh. And there is a GetMtls() method in the INode.

I think i can access the material property through the two interfaces above, while it's not that simple....

Sometimes even if there is only one material assigned to the mesh, it could return 1 through getFaceMtlIndex(). It's a zero based index, and 1 means that it's the second material. But there is only ONE material in the INode.

If it's a teapot mesh, it returns 0. And if it's a sphere , it returns 1. Both of them is assigned only one material.....

I don't get it. It seems that they are not corresponding to each other.

Could any one offer me some ideas. Really appreciate!!

Thanks

Share this post


Link to post
Share on other sites
My exporters don't seem to make use of either getFaceMtlIndex() or GetMtls(), so can't help you with your approach.

When writing my exporters I used the asciiexp sample as a reference, have you looked at it and how it works?

[Edited by - starman2049 on September 2, 2010 12:47:51 PM]

Share this post


Link to post
Share on other sites

This topic is 2658 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this