.NET

Reply
Valued Contributor
base2
Posts: 80
Registered: ‎04-20-2005
Message 1 of 3 (148 Views)

Material Object (render) with c#

148 Views, 2 Replies
12-18-2006 10:49 AM
Hi guys..
I'm going to build with code a material..in c#.

I have a serious problem with the diffuse assignment...
MaterialMap constructor assigned with "New" don't run correctly...IMHO.

please take a look at the material3.jpg !
Here the constructor MaterialMap with the parameters "source = 1" (file) perform the constructor...and the result is source = "scene" (0)

So i'm not able to use a texture for the Diffuse material's component :smileysad: :smileysad:

What can I do ?

is there a my wrong ? where is it ? I ' can't see it!
what
Valued Contributor
base2
Posts: 80
Registered: ‎04-20-2005
Message 2 of 3 (148 Views)

Re: Material Object (render) with c#

12-18-2006 10:51 AM in reply to: base2
please take a look here! this is my debug window
New Member
jstergar
Posts: 2
Registered: ‎08-30-2007
Message 3 of 3 (148 Views)

Re: Material Object (render) with c#

08-30-2007 10:43 PM in reply to: base2
This is kindof late, however, somebody searching for the answer in the future could make use of this:

Don't use MaterialTexture, use:

GraphicsInterface.ImageFileTexture

if the diffuse source is from an image file. You would use the MarbleTexture class for marble, and WoodTexture class for wood.
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.