Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
blender-addons-contrib
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
blender
blender-addons-contrib
Commits
7957437e
Commit
7957437e
authored
11 years ago
by
Eugenio Pignataro
Browse files
Options
Downloads
Patches
Plain Diff
BugFix Overlap Uvs
parent
32be0452
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
oscurart_tools/oscurart_meshes.py
+4
-4
4 additions, 4 deletions
oscurart_tools/oscurart_meshes.py
with
4 additions
and
4 deletions
oscurart_tools/oscurart_meshes.py
+
4
−
4
View file @
7957437e
...
@@ -278,7 +278,6 @@ class OscObjectToMesh(bpy.types.Operator):
...
@@ -278,7 +278,6 @@ class OscObjectToMesh(bpy.types.Operator):
def
DefOscOverlapUv
(
valprecision
):
def
DefOscOverlapUv
(
valprecision
):
inicio
=
time
.
time
()
inicio
=
time
.
time
()
mode
=
bpy
.
context
.
object
.
mode
mode
=
bpy
.
context
.
object
.
mode
bpy
.
ops
.
object
.
mode_set
(
mode
=
'
OBJECT
'
,
toggle
=
False
)
bpy
.
ops
.
object
.
mode_set
(
mode
=
'
OBJECT
'
,
toggle
=
False
)
ob
=
bpy
.
context
.
object
ob
=
bpy
.
context
.
object
...
@@ -297,13 +296,13 @@ def DefOscOverlapUv(valprecision):
...
@@ -297,13 +296,13 @@ def DefOscOverlapUv(valprecision):
dict
=
{
poly
.
index
:
{
ob
.
data
.
loops
[
vertex
].
vertex_index
:
vertex
for
vertex
in
poly
.
loop_indices
}
for
poly
in
ob
.
data
.
polygons
}
dict
=
{
poly
.
index
:
{
ob
.
data
.
loops
[
vertex
].
vertex_index
:
vertex
for
vertex
in
poly
.
loop_indices
}
for
poly
in
ob
.
data
.
polygons
}
for
poly
,
data
in
dict
.
items
():
for
poly
,
data
in
dict
.
items
():
if
ob
.
data
.
polygons
[
poly
].
center
.
x
<
0
and
poly
eq
.
get
(
poly
)
:
if
ob
.
data
.
polygons
[
poly
].
center
.
x
<
0
and
poly
in
poly
eq
:
for
vertice
,
vertex
in
data
.
items
():
for
vertice
,
vertex
in
data
.
items
():
if
len
(
dict
[
poly
])
==
len
(
dict
[
polyeq
[
poly
]])
and
vert
eq
.
get
(
vertice
)
:
# DEBUG
if
len
(
dict
[
poly
])
==
len
(
dict
[
polyeq
[
poly
]])
and
vert
ice
in
verteq
:
# DEBUG
source
,
target
=
dict
[
poly
][
vertice
]
,
dict
[
polyeq
[
poly
]][
verteq
[
vertice
]]
source
,
target
=
dict
[
poly
][
vertice
]
,
dict
[
polyeq
[
poly
]][
verteq
[
vertice
]]
uvm
.
data
[
target
].
uv
=
uvm
.
data
[
source
].
uv
uvm
.
data
[
target
].
uv
=
uvm
.
data
[
source
].
uv
bpy
.
ops
.
object
.
mode_set
(
mode
=
mode
,
toggle
=
False
)
bpy
.
ops
.
object
.
mode_set
(
mode
=
mode
,
toggle
=
False
)
print
(
"
Time elapsed: %4s seconds
"
%
(
time
.
time
()
-
inicio
))
print
(
"
Time elapsed: %4s seconds
"
%
(
time
.
time
()
-
inicio
))
...
@@ -406,3 +405,4 @@ class ModalIndexOperator(bpy.types.Operator):
...
@@ -406,3 +405,4 @@ class ModalIndexOperator(bpy.types.Operator):
return
{
'
CANCELLED
'
}
return
{
'
CANCELLED
'
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment