UV Export: add option to export UV tiles #104940
@ -213,11 +213,11 @@ class ExportUVLayout(bpy.types.Operator):
|
||||
# Ignore UVs at corners - precisely touching the right or upper edge
|
||||
# of a tile should not load its right/upper neighbor as well.
|
||||
# From intern/cycles/scene/attribute.cpp
|
||||
u, v = (uv[0], uv[1])
|
||||
x, y = (floor(u), floor(v))
|
||||
if (x > 0 and (u < x + 1e-6)):
|
||||
u, v = uv[0], uv[1]
|
||||
x, y = floor(u), floor(v)
|
||||
if x > 0 and u < x + 1e-6:
|
||||
x -= 1
|
||||
if (y > 0 and (v < y + 1e-6)):
|
||||
if y > 0 and v < y + 1e-6:
|
||||
y -= 1
|
||||
tiles.add((x, y))
|
||||
return tiles
|
||||
|
Loading…
Reference in New Issue
Block a user