fix [#25388] Export to X3D generates texture fields in X3D file for objects
use vertex color paint setting to export vertex colors when a material is assigned.
This commit is contained in:
@@ -466,7 +466,7 @@ class x3d_class:
|
||||
#--- output textureCoordinates if UV texture used
|
||||
if mesh.uv_textures.active:
|
||||
self.writeTextureCoordinates(mesh)
|
||||
if mesh.vertex_colors.active:
|
||||
if mesh.vertex_colors.active and (mat_first is None or mat_first.use_vertex_color_paint):
|
||||
self.writeFaceColors(mesh)
|
||||
#--- output coordinates
|
||||
self.writeCoordinates(ob, mesh, meshName, EXPORT_TRI)
|
||||
@@ -479,7 +479,7 @@ class x3d_class:
|
||||
#--- output textureCoordinates if UV texture used
|
||||
if mesh.uv_textures.active:
|
||||
self.writeTextureCoordinates(mesh)
|
||||
if mesh.vertex_colors.active:
|
||||
if mesh.vertex_colors.active and (mat_first is None or mat_first.use_vertex_color_paint):
|
||||
self.writeFaceColors(mesh)
|
||||
#--- output vertexColors
|
||||
|
||||
|
||||
Reference in New Issue
Block a user