diff options
Diffstat (limited to 'io_scene_x3d/import_x3d.py')
-rw-r--r-- | io_scene_x3d/import_x3d.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/io_scene_x3d/import_x3d.py b/io_scene_x3d/import_x3d.py index 5a1a4b32..653b8d9f 100644 --- a/io_scene_x3d/import_x3d.py +++ b/io_scene_x3d/import_x3d.py @@ -2043,6 +2043,12 @@ def importMesh_IndexedFaceSet(geom, ancestry): t_min = mins[t_axis] dt = deltas[t_axis] + # Avoid divide by zero T76303. + if not (ds > 0.0): + ds = 1.0 + if not (dt > 0.0): + dt = 1.0 + def generatePointCoords(pt): return (pt[s_axis] - s_min) / ds, (pt[t_axis] - t_min) / dt loops = [co for f in faces |