Fix T91113: printf in X3D Importer causes NameError

This commit is contained in:
Campbell Barton 2021-09-02 17:30:47 +10:00
parent 59c8409947
commit eecf14222b
Notes: blender-bot 2023-02-14 18:32:29 +01:00
Referenced by issue #91113, printf in X3D Importer causes NameError
1 changed files with 4 additions and 2 deletions

View File

@ -1622,8 +1622,10 @@ def importMesh_ApplyColors(bpymesh, geom, ancestry):
elif len(rgb) == len(bpymesh.loops):
rgb = tuple(chain(*rgb))
else:
printf("WARNING not applying vertex colors, non matching numbers of vertices or loops (%d vs %d/%d)"
"" % (len(rgb), len(bpymesh.vertices), len(bpymesh.loops)))
print(
"WARNING not applying vertex colors, non matching numbers of vertices or loops (%d vs %d/%d)" %
(len(rgb), len(bpymesh.vertices), len(bpymesh.loops))
)
return
lcol_layer.data.foreach_set("color", rgb)