[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [12814] branches/pyapi_devel: applied outstanding changes to python api from trunk, also merged from trunk

Campbell Barton ideasman42 at gmail.com
Fri Dec 7 11:23:00 CET 2007


Revision: 12814
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=12814
Author:   campbellbarton
Date:     2007-12-07 11:23:00 +0100 (Fri, 07 Dec 2007)

Log Message:
-----------
applied outstanding changes to python api from trunk, also merged from trunk

Modified Paths:
--------------
    branches/pyapi_devel/intern/iksolver/intern/IK_QSegment.cpp
    branches/pyapi_devel/release/Makefile
    branches/pyapi_devel/source/blender/blenkernel/BKE_blender.h
    branches/pyapi_devel/source/blender/blenkernel/BKE_mesh.h
    branches/pyapi_devel/source/blender/blenkernel/BKE_particle.h
    branches/pyapi_devel/source/blender/blenkernel/intern/DerivedMesh.c
    branches/pyapi_devel/source/blender/blenkernel/intern/action.c
    branches/pyapi_devel/source/blender/blenkernel/intern/constraint.c
    branches/pyapi_devel/source/blender/blenkernel/intern/mesh.c
    branches/pyapi_devel/source/blender/blenkernel/intern/object.c
    branches/pyapi_devel/source/blender/blenkernel/intern/particle.c
    branches/pyapi_devel/source/blender/blenlib/intern/arithb.c
    branches/pyapi_devel/source/blender/blenloader/intern/readfile.c
    branches/pyapi_devel/source/blender/include/BIF_editaction.h
    branches/pyapi_devel/source/blender/include/BSE_editipo.h
    branches/pyapi_devel/source/blender/makesdna/DNA_nla_types.h
    branches/pyapi_devel/source/blender/python/api2_2x/bpy_gl.c
    branches/pyapi_devel/source/blender/python/api2_2x/sceneRender.c
    branches/pyapi_devel/source/blender/python/api2_2x/sceneSequence.c
    branches/pyapi_devel/source/blender/render/intern/source/convertblender.c
    branches/pyapi_devel/source/blender/render/intern/source/renderdatabase.c
    branches/pyapi_devel/source/blender/src/buttons_object.c
    branches/pyapi_devel/source/blender/src/drawipo.c
    branches/pyapi_devel/source/blender/src/drawnla.c
    branches/pyapi_devel/source/blender/src/drawobject.c
    branches/pyapi_devel/source/blender/src/drawview.c
    branches/pyapi_devel/source/blender/src/editaction.c
    branches/pyapi_devel/source/blender/src/editarmature.c
    branches/pyapi_devel/source/blender/src/editipo_mods.c
    branches/pyapi_devel/source/blender/src/editnla.c
    branches/pyapi_devel/source/blender/src/editparticle.c
    branches/pyapi_devel/source/blender/src/header_action.c
    branches/pyapi_devel/source/blender/src/meshtools.c
    branches/pyapi_devel/source/blender/src/transform.c
    branches/pyapi_devel/tools/Blender.py

Removed Paths:
-------------
    branches/pyapi_devel/release/scripts/import_dxf.py~
    branches/pyapi_devel/source/blender/cleanup2.patch

Modified: branches/pyapi_devel/intern/iksolver/intern/IK_QSegment.cpp
===================================================================
--- branches/pyapi_devel/intern/iksolver/intern/IK_QSegment.cpp	2007-12-07 09:51:02 UTC (rev 12813)
+++ branches/pyapi_devel/intern/iksolver/intern/IK_QSegment.cpp	2007-12-07 10:23:00 UTC (rev 12814)
@@ -61,11 +61,11 @@
 	MT_Scalar t = sqrt(R[0][0]*R[0][0] + R[0][1]*R[0][1]);
 
     if (t > 16.0*MT_EPSILON) {
-		if (axis == 0) return atan2(R[1][2], R[2][2]);
+		if (axis == 0) return -atan2(R[1][2], R[2][2]);
         else if(axis == 1) return atan2(-R[0][2], t);
-        else return atan2(R[0][1], R[0][0]);
+        else return -atan2(R[0][1], R[0][0]);
     } else {
-		if (axis == 0) return atan2(-R[2][1], R[1][1]);
+		if (axis == 0) return -atan2(-R[2][1], R[1][1]);
         else if(axis == 1) return atan2(-R[0][2], t);
         else return 0.0f;
     }

Modified: branches/pyapi_devel/release/Makefile
===================================================================
--- branches/pyapi_devel/release/Makefile	2007-12-07 09:51:02 UTC (rev 12813)
+++ branches/pyapi_devel/release/Makefile	2007-12-07 10:23:00 UTC (rev 12814)
@@ -44,7 +44,7 @@
    EXT1=".zip"
    COMPRESS=""
    EXT2=""
-   NOPLUGINS="true"
+   NOPLUGINS?=true
 endif
 
 ifeq ($(OS),$(findstring $(OS), "freebsd irix linux openbsd solaris"))
@@ -57,7 +57,7 @@
    EXT2=".bz2"
    ifeq ($(OS), solaris)
      ifeq ($(CPU), i386)
-       NOPLUGINS=true
+       NOPLUGINS?=true
      endif
    endif
 endif
@@ -67,8 +67,8 @@
    TARFLAGS="-r9"
    EXT0=".exe"
    EXT1=".zip"
-   NOPLUGINS="true"
-   NOSTRIP="true"
+   NOPLUGINS?=true
+   NOSTRIP?=true
 endif
 
 ifeq ($(OS),darwin)

Deleted: branches/pyapi_devel/release/scripts/import_dxf.py~
===================================================================
--- branches/pyapi_devel/release/scripts/import_dxf.py~	2007-12-07 09:51:02 UTC (rev 12813)
+++ branches/pyapi_devel/release/scripts/import_dxf.py~	2007-12-07 10:23:00 UTC (rev 12814)
@@ -1,4139 +0,0 @@
-#!BPY
-
-"""
-Name: 'Autodesk DXF (.dxf)'
-Blender: 244
-Group: 'Import'
-Tooltip: 'Import for DXF geometry data (Drawing eXchange Format).'
-"""
-__author__ = 'Kitsu(Ed Blake) & migius(Remigiusz Fiedler)'
-__version__ = '1.0.beta10 - 2007.09.09 by migius'
-__url__ = ["http://blenderartists.org/forum/showthread.php?t=84319",
-	 "http://wiki.blender.org/index.php/Scripts/Manual/Import/DXF-3D"]
-__email__ = ["Kitsune_e(at)yahoo.com", "migius(at)4d-vectors.de"]
-__bpydoc__ = """\
-This script imports DXF objects (2d/3d) into Blender.
-
-This script imports 2d and 3d Geometery from DXFr12 format files.
-This version is focused on import of 3d-objects.
-
-Supported DXF Objects:
-LINE
-POINT
-SOLID
-TRACE
-TEXT
-INSERT (=block)
-MINSERT (=array)
-CIRCLE
-ARC
-3DFACE
-2d-POLYLINE (=plane, incl. arc, variable-width, curve, spline)
-3d-POLYLINE (=no-plane)
-3d-POLYMESH
-3d-POLYFACE
-under construction, partly supported DXF>r12:
-LWPOLYLINE (LightWeight), MLINE, MTEXT, ELLIPSE
-
-Unsupported DXF Objects:
-DXF r12: DIMENSION, XREF (External Reference)
-DXF>r12: SPLINE, GROUP, RAY/XLINE, LEADER, 3DSOLID, BODY, REGION, dynamic BLOCK
-
-Supported Properties:
-Hierarchy: Entire DXF BLOCKs hierarchy is preserved after import into Blender
-visibility, frozen
-COLOR
-LAYER
-thickness
-width
-(todo: grouped, XDATA)
-It is recommended to use DXF-object properties for coding Blender materials.
-
-Notes:
-- Recommend that you run 'RemoveDoubles' on each imported mesh after using this script
-- Blocks are created on layer 19 then referenced at each insert point.
-* Big DXF-files (over 1500 objects) decrease import performance. The problem is not the inefficiency of python-scripting but Blenders performance in creating new objects in his database - probably a database management problem.
-* The Blender curves of imported ARCs and POLYLINE-arc-segments have light malformed ends.(to fix in beta10)
-	
-TODO:  
-- the new style object visibility
-- support for Spline-curves, Besier-curves
-- support for real 3d-solids (ACIS)
-- (to see more, search for "-todo-" in script)
-
-
-History:
- v1.0 - 2007.09 by migius: "full 3d"-release
- planned tasks:
- -- filtering of unused/not-inserted BLOCKs
- -- human-formating of data in INI-File
- -- suport for MLine
- -- suport for Ellipse
- -- suport for Mtext
- -- blender_object.ID.properties[dxf_layer_name]
- -- Configuration files(.ini) should/can handle various material setups
- -- added f_layerFilter
- -- to-check: obj/mat/group/_mapping-idea from ideasman42:
- -- better support for long dxf-layer-names 
- -- support width_force for LINEs/ARCs/CIRCLEs/ELLIPSEs = "solidify"
- -- curves: added fill/non-fill option for closed curves: CIRCLEs,ELLIPSEs,POLYLINEs
- -- bug:? object = Object.Get(obname) -> = SCENE.getChildren(obname)
- -- command-line-mode/batch-mode
- -- fixed malformed endpoints of Blender curves of imported ARCs and POLYLINE-arc segments. 
- beta10: 2007.09.09 by migius
- a1 added "fill_on" option to draw top and bottom sides of CIRCLEs and ELLIPSEs
- a1 rewrite f_CIRCLE.Draw: from Mesh.Primitive to Mesh
- a1 bugfix "newScene"-mode: Cylinders/Arcs were drawn at <0,0,0>location
- beta09: 2007.09.02 by migius
- g5 redesign UI: grouping of buttons
- g3 update multi-import-mode: <*.*> button
- g- added multi-import-mode: (path/*) for importing many dxf-files at once
- g- added import into newScene
- g- redesign UI: user presets, into newScene-import  
- f- cleanup code
- f- bugfix: thickness for Bezier/Bsplines into Blender-curves
- f- BlenderWiki documentation, on-line Manual
- f- added import POLYLINE-Bsplines into Blender-NURBSCurves
- f- added import POLYLINE-arc-segments into Blender-BezierCurves
- f- added import POLYLINE-Bezier-curves into Blender-Curves
- d5 rewrite: Optimization Levels, added 'directDrawing'
- d4 added: f_set_thick(cntrolled by ini-parameters)
- d4 bugfix: face-normals in objects with minus thickness
- d4 added: placeholder'Empty'-size in f_Insert.draw
- d3 rewrite f_Text.Draw: added suport for all Text's parameters
- d2 redesign: progressbar 
- e- tuning by ideasman42: better use of the Py API.
- c- tuning by ideasman42
- b- rewrite f_Text.Draw rotation/transform
- b- bugfix: POLYLINE-segment-intersection more reliable now
- b- bugfix: circle:_thic, 'Empties':no material_assignement
- b- added material assignment (from layer and/or color)
- a- added empty, cylinder and UVsphere for POINTs
- a- added support for 2d-POLYLINE: splines, fitted curves, fitted surfaces
- a- redesign f_Drawer for block_definitions
- a- rewrite import into Blender-Curve-Object
- beta08: 2007.07.27 by migius
- l- bugfix: solid_vgroups, clean:scene.objects.new()
- l- redesign UI to standard Draw.Register+FileSelector, advanced_config_option
- k- bugfix UI:fileSelect() for MacOSX os.listdir()
- k- added reset/save/load for config-data
- k- redesign keywords/drawTypes/Draw.Create_Buttons
- j- new interface using UIBlock() with own FileSelector, cause Window.FileSelector() too buggy
- i- rewritten Class:Settings for better config-parameter management
- h- bugfix: face-normals in objects with minus thickness
- h- added Vertex-Groups in polylines and solids generated Meshes, for easier material assignment
- h- beautify code, whitespace->tabs
- h- added settings.thic_force switch for forcing thickness
- h- added one Object/Mesh for all simple-entities from the same Layer,
-	sorted in Vertex-Groups(color_name)  (fewer objects = better import performance)
- g- rewrote: insert-point-handle-object is a small tetrahedron
- e- bugfix: closed-polymesh3d
- - rewrote: startUI, type_map.keys, f_drawer, for all class_f_draw(added "settings" as attribut)
- - added 2d/3d-support for Polyline_Width incl. angleintersection
- beta07: 2007.06.19 by migius
- - added 3d-support for LWPolylines
- - added 2d/3d-support for Points
- beta06: 2007.06.15 by migius
- - cleanup code
- - added 2d/3d-support for MINSERT=BlockArray in f_drawer, added f_rotXY_Vec
- beta05: 2007.06.14 by migius
- - added 2d/3d-support for 3d-PolyLine, PolyMesh and PolyFace
- - added Global-Scale for size control of imported scenes
- beta04: 2007.06.12 by migius
- - rewrote the f_drawBulge for correct import the arc-segments of Polylines
- beta03: 2007.06.10 by migius
- - rewrote interface
- beta02: 2007.06.09 by migius
- - added 3d-support for Arcs and Circles
- - added support for Object_Thickness(=height)
- beta01: 2007.06.08 by migius
- - added 3d-support for Blocks/Inserts within nested-structures
- - rewrote f_transform for correct 3d-location/3d-rotation
- - added 3d-support Lines, 3dFaces
- - added 2d+3d-support for Solids and Traces
-
- v0.9 - 2007.01 by kitsu: (for 2.43)
- -
-
- v0.8 - 2006.12 by kitsu:
- -
-
- v0.5b - 2006.10 by kitsu: (for 2.42a)
- -
-
-"""
-
-# --------------------------------------------------------------------------
-# DXF Import v1.0 by Ed Blake (AKA kitsu) and Remigiusz Fiedler (AKA migius)
-# --------------------------------------------------------------------------
-# ***** BEGIN GPL LICENSE BLOCK *****
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License
-# as published by the Free Software Foundation; either version 2
-# of the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software Foundation,
-# Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
-#
-# ***** END GPL LICENCE BLOCK *****
-# --------------------------------------------------------------------------
-
-import Blender
-import bpy
-from Blender import *
-#from Blender.Mathutils import Vector, Matrix
-#import BPyMessages
-
-
-from dxfReader import readDXF	  # get_name, get_layer
-from dxfReader import Object as dxfObject
-from dxfColorMap import color_map
-from math import *
-
-try:
-	import os
-	if os.name:# != 'mac':
-		import psyco
-		psyco.log()
-		psyco.full(memory=100)
-		psyco.profile(0.05, memory=100)
-		psyco.profile(0.2)
-except ImportError:
-	pass
-
-print '\n\n\n\n'
-print 'Import DXF to Blender *** START ***'   #---------------------
-
-SCENE = None

@@ Diff output truncated at 10240 characters. @@




More information about the Bf-blender-cvs mailing list