WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 03-07-2012, 05:45 AM
Joran Joran is offline
Member
 
Join Date: Jun 2006
Posts: 38
Send a message via Yahoo to Joran
OSG Exporter and no vertex colors

Hello,

I have problems with the exported models using the latest version of OSG Exporter (1.0.1). The exporter now seems to assign a white vertex color to all vertices for textured faces. This means I can not change the color anymore using the vizard commands (like <node3d>.color()). I could not find a method to turn this off or to work around this.

The change that added this can be found here: http://osgmaxexp.svn.sourceforge.net...26&pathrev=228

Greetings, Joran.
Reply With Quote
  #2  
Old 03-07-2012, 09:10 AM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
Hi Joran,

Yes, I made that change because if no vertex color was assigned to a model, it could inherit seemingly random colors, depending on the last applied vertex color value in the scene. This should only be the case if lighting is disabled on the model. With lighting enabled, the <node>.color() command should continue to work properly. Either way, you can use the <node>.clearAttribute() command to remove the vertex colors from a model:
Code:
node.clearAttribute(viz.ATTR_VERTEXCOLOR)
Do you think the exporter should be modified to not assign any vertex colors when the "Vertex Color" option is unchecked?
Reply With Quote
  #3  
Old 03-08-2012, 05:50 AM
Joran Joran is offline
Member
 
Join Date: Jun 2006
Posts: 38
Send a message via Yahoo to Joran
Hello,

Thank you, the clearAttribute works fine.

I tried out some other things. And if I turn on lighting for the complete model, the <node>.color() command works, as you said.

The clearAttribute solves my problem, but in the model I exported there are also objects without textures. These object are rendered white (with lighting off). So the results are not as expected. I can fix those using clearAttribute.

I am not sure what the behaviour of the exporter should be. I never use VertexColors myself. But I think I would like a way to turn of the this white VertexColor generation, so that even with LIGHTING off the <node>.color() can be used.
Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This 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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Big problem with OpenSG exporter for max to Vizard omadawn Vizard 5 06-09-2009 11:51 AM
cal3d exporter lqakane Vizard 0 03-02-2009 07:38 AM
cal3d exporter for 3ds max 2008? masaki Plug-in development 3 09-25-2008 10:48 AM
cal3d exporter problem visnova Vizard 1 06-15-2007 03:02 PM
At my Whits end with Cal 3D Exporter shivanangel Vizard 6 02-25-2007 03:00 PM


All times are GMT -7. The time now is 07:36 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Copyright 2002-2018 WorldViz LLC