[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [28235] branches/render25: Render Branch: svn merge https://svn.blender.org/svnroot/bf-blender/trunk/blender -r28211 :28234
Campbell Barton
ideasman42 at gmail.com
Fri Apr 16 17:24:01 CEST 2010
Revision: 28235
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=28235
Author: campbellbarton
Date: 2010-04-16 17:24:01 +0200 (Fri, 16 Apr 2010)
Log Message:
-----------
Render Branch: svn merge https://svn.blender.org/svnroot/bf-blender/trunk/blender -r28211:28234
Modified Paths:
--------------
branches/render25/release/scripts/modules/bpy/utils.py
branches/render25/source/blender/blenlib/intern/uvproject.c
Modified: branches/render25/release/scripts/modules/bpy/utils.py
===================================================================
--- branches/render25/release/scripts/modules/bpy/utils.py 2010-04-16 15:19:55 UTC (rev 28234)
+++ branches/render25/release/scripts/modules/bpy/utils.py 2010-04-16 15:24:01 UTC (rev 28235)
@@ -168,21 +168,20 @@
traceback.print_exc()
_loaded[:] = []
- for base_path in script_paths(user=False):
- for path_subdir in ("ui", "op", "io", "cfg", "keyingsets"):
+ user_path = user_script_path()
+
+ for base_path in script_paths():
+ for path_subdir in ("", "ui", "op", "io", "cfg", "keyingsets", "modules"):
path = _os.path.join(base_path, path_subdir)
if _os.path.isdir(path):
sys_path_ensure(path)
- for mod in modules_from_path(path, loaded_modules):
- test_register(mod)
+ # only add this to sys.modules, dont run
+ if path_subdir == "modules":
+ continue
- user_path = user_script_path()
- if user_path:
- for path_subdir in ("", "ui", "op", "io", "cfg", "keyingsets"):
- path = _os.path.join(user_path, path_subdir)
- if _os.path.isdir(path):
- sys_path_ensure(path)
+ if user_path != base_path and path_subdir == "":
+ continue # avoid loading 2.4x scripts
for mod in modules_from_path(path, loaded_modules):
test_register(mod)
Modified: branches/render25/source/blender/blenlib/intern/uvproject.c
===================================================================
--- branches/render25/source/blender/blenlib/intern/uvproject.c 2010-04-16 15:19:55 UTC (rev 28234)
+++ branches/render25/source/blender/blenlib/intern/uvproject.c 2010-04-16 15:24:01 UTC (rev 28235)
@@ -39,6 +39,9 @@
short do_persp, do_pano, do_rotmat;
} UvCameraInfo;
+/* ugly */
+extern float camera_get_angle(struct Camera *cam);
+
void project_from_camera(float target[2], float source[3], UvCameraInfo *uci)
{
float pv4[4];
@@ -135,7 +138,7 @@
uci.do_pano = (camera->flag & CAM_PANORAMA);
uci.do_persp = (camera->type==CAM_PERSP);
- uci.camangle= DEG2RAD(camera_get_angle(camera))/2.0f;
+ uci.camangle= camera_get_angle(camera)/2.0f;
uci.camsize= uci.do_persp ? uci.camsize= tanf(uci.camangle) : camera->ortho_scale;
if (invert_m4_m4(uci.caminv, ob->obmat)) {
More information about the Bf-blender-cvs
mailing list