[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18934] trunk/blender/release/scripts/ export_fbx.py: According to Amir Ebrahimi, fbx vertex color is supposed to be between 0.0 and 1.0 rather then 0-255

Campbell Barton ideasman42 at gmail.com
Thu Feb 12 02:46:38 CET 2009


Revision: 18934
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18934
Author:   campbellbarton
Date:     2009-02-12 02:46:38 +0100 (Thu, 12 Feb 2009)

Log Message:
-----------
According to Amir Ebrahimi, fbx vertex color is supposed to be between 0.0 and 1.0 rather then 0-255
At the moment I dont have a way to test this.

Modified Paths:
--------------
    trunk/blender/release/scripts/export_fbx.py

Modified: trunk/blender/release/scripts/export_fbx.py
===================================================================
--- trunk/blender/release/scripts/export_fbx.py	2009-02-12 01:11:29 UTC (rev 18933)
+++ trunk/blender/release/scripts/export_fbx.py	2009-02-12 01:46:38 UTC (rev 18934)
@@ -1446,13 +1446,13 @@
 				for f in me.faces:
 					for col in f.col:
 						if i==-1:
-							file.write('%i,%i,%i,255' % (col[0], col[1], col[2]))
+							file.write('%.4f,%.4f,%.4f,1' % (col[0]/255.0, col[1]/255.0, col[2]/255.0))
 							i=0
 						else:
 							if i==7:
 								file.write('\n\t\t\t\t')
 								i=0
-							file.write(',%i,%i,%i,255' % (col[0], col[1], col[2]))
+							file.write(',%.4f,%.4f,%.4f,1' % (col[0]/255.0, col[1]/255.0, col[2]/255.0))
 						i+=1
 						ii+=1 # One more Color
 				





More information about the Bf-blender-cvs mailing list