Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2007-04-29 17:39:46 +0400
committerCampbell Barton <ideasman42@gmail.com>2007-04-29 17:39:46 +0400
commit99135b0674830528eaed3067c40905af8e4557a9 (patch)
tree604d8d7713c8e8f35111b9cc507f42944eb468f3 /release/scripts/uvcalc_quad_clickproj.py
parent243d1a28c0635a85c2dca9a23e9465b170b0ba3a (diff)
dont use tface hide or select anymore, since maintaining 2 sets of hide/select data for each face is annoying.
using mface->flag for both. Also found that the cdDM_drawMappedFaces and cdDM_drawFacesTex_common could get normals mixed up when rendering hidden faces. because hidden/invisible faces used continue without advancing to the next normal.
Diffstat (limited to 'release/scripts/uvcalc_quad_clickproj.py')
-rw-r--r--release/scripts/uvcalc_quad_clickproj.py15
1 files changed, 3 insertions, 12 deletions
diff --git a/release/scripts/uvcalc_quad_clickproj.py b/release/scripts/uvcalc_quad_clickproj.py
index 84c54ae30da..67b58885f9d 100644
--- a/release/scripts/uvcalc_quad_clickproj.py
+++ b/release/scripts/uvcalc_quad_clickproj.py
@@ -47,8 +47,8 @@ import BPyWindow
mouseViewRay= BPyWindow.mouseViewRay
from Blender import Mathutils, Window, Scene, Draw, sys
from Blender.Mathutils import CrossVecs, Vector, Matrix, LineIntersect, Intersect #, AngleBetweenVecs, Intersect
-LMB= Window.MButs['L']
-RMB= Window.MButs['R']
+LMB= Window.MButs.L
+RMB= Window.MButs.R
def using_modifier(ob):
for m in ob.modifiers:
@@ -168,17 +168,8 @@ def main():
def get_face_coords(f):
f_uv = f.uv
return [(v.co-face_corner_main, f_uv[i]) for i,v in enumerate(f.v)]
-
-
-
- SELECT_FLAG = Blender.Mesh.FaceFlags.SELECT
- HIDE_FLAG = Blender.Mesh.FaceFlags.HIDE
- def use_face(f_flag):
- if f_flag & HIDE_FLAG: return False
- elif f_flag & SELECT_FLAG: return True
- else: return False
- coords = [ (co,uv) for f in me.faces if use_face(f.flag) for co, uv in get_face_coords(f)]
+ coords = [ (co,uv) for f in me.faces if f.sel for co, uv in get_face_coords(f)]
coords_orig = [uv.copy() for co, uv in coords]
USE_MODIFIER = using_modifier(ob)