[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [14604] branches/soc-2008-mxcurioni: Merged changes from trunk to soc-2008-mxcurioni, to revision 14603

Maxime Curioni maxime.curioni at gmail.com
Mon Apr 28 21:21:51 CEST 2008


Revision: 14604
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=14604
Author:   mxcurioni
Date:     2008-04-28 21:21:51 +0200 (Mon, 28 Apr 2008)

Log Message:
-----------
Merged changes from trunk to soc-2008-mxcurioni, to revision 14603

Revision Links:
--------------
    http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=14603

Modified Paths:
--------------
    branches/soc-2008-mxcurioni/SConstruct
    branches/soc-2008-mxcurioni/extern/x264/SConscript
    branches/soc-2008-mxcurioni/extern/xvidcore/SConscript
    branches/soc-2008-mxcurioni/release/scripts/bpymodules/paths_svg2obj.py
    branches/soc-2008-mxcurioni/release/scripts/raw_export.py
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/object.c
    branches/soc-2008-mxcurioni/source/blender/blenlib/intern/bpath.c
    branches/soc-2008-mxcurioni/source/blender/blenloader/intern/readfile.c
    branches/soc-2008-mxcurioni/source/blender/makesdna/intern/SConscript
    branches/soc-2008-mxcurioni/source/blender/python/api2_2x/MTex.c
    branches/soc-2008-mxcurioni/source/blender/python/api2_2x/doc/Texture.py
    branches/soc-2008-mxcurioni/source/blender/render/intern/source/rendercore.c
    branches/soc-2008-mxcurioni/source/blender/src/buttons_shading.c
    branches/soc-2008-mxcurioni/tools/btools.py

Modified: branches/soc-2008-mxcurioni/SConstruct
===================================================================
--- branches/soc-2008-mxcurioni/SConstruct	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/SConstruct	2008-04-28 19:21:51 UTC (rev 14604)
@@ -273,6 +273,14 @@
             if os.path.exists(confile):
                 print "clean file %s"%confile
                 os.remove(confile)
+
+        if platform in ('win32-vc', 'win32-mingw'):
+            makesdnafile = B.root_build_dir+'makesdna.exe'
+        else:
+            makesdnafile = B.root_build_dir+'makesdna'
+        if os.path.exists(makesdnafile):
+            print "removing", makesdnafile
+            os.remove(makesdnafile)
         print B.bc.OKGREEN+'...done'+B.bc.ENDC
     else:
         print B.bc.HEADER+'Already Clean, nothing to do.'+B.bc.ENDC

Modified: branches/soc-2008-mxcurioni/extern/x264/SConscript
===================================================================
--- branches/soc-2008-mxcurioni/extern/x264/SConscript	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/extern/x264/SConscript	2008-04-28 19:21:51 UTC (rev 14604)
@@ -84,7 +84,11 @@
 
 if not os.path.isfile(root + "/config.mak"):
     os.chdir(root);
-    os.system("sh -c './configure'")
+    code = -1
+    if x264_env['BF_X264_CONFIG'] != '':
+        code = os.system("sh -c './configure %s'"%x264_env['BF_X264_CONFIG'])
+    if code != 0:
+        os.system("sh -c './configure'")
     os.chdir("../..");
 else:
     print "(skipped, config.mak already exists)"

Modified: branches/soc-2008-mxcurioni/extern/xvidcore/SConscript
===================================================================
--- branches/soc-2008-mxcurioni/extern/xvidcore/SConscript	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/extern/xvidcore/SConscript	2008-04-28 19:21:51 UTC (rev 14604)
@@ -91,7 +91,12 @@
 
 if not os.path.isfile(buildroot + "/platform.inc"):
     os.chdir(buildroot);
-    os.system("sh -c './configure'")
+    code = -1
+    if xvidcore_env['BF_XVIDCORE_CONFIG'] != '':
+        code = os.system("sh -c './configure %s'"%xvidcore_env['BF_XVIDCORE_CONFIG'])
+    if code != 0:
+        os.system("sh -c './configure'")
+  
     os.chdir("../../../..");
 else:
     print "(skipped, build/generic/platform.inc already exists)"

Modified: branches/soc-2008-mxcurioni/release/scripts/bpymodules/paths_svg2obj.py
===================================================================
--- branches/soc-2008-mxcurioni/release/scripts/bpymodules/paths_svg2obj.py	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/release/scripts/bpymodules/paths_svg2obj.py	2008-04-28 19:21:51 UTC (rev 14604)
@@ -1309,8 +1309,9 @@
 			if not 'fill:none' in pr:
 				Courbe[n].fill=1
 				if USE_COLORS:
-					if '#' in pr:
-						i= pr.find('fill:#')+6
+					i= pr.find('fill:#')
+					if i != -1:
+						i= i+6
 						Courbe[n].color=[int(pr[i:i+2],16),int(pr[i+2:i+4],16),int(pr[i+4:i+6],16)]
 						Courbe[n].mat=1
 					elif ';fill-opacity' in pr: 

Modified: branches/soc-2008-mxcurioni/release/scripts/raw_export.py
===================================================================
--- branches/soc-2008-mxcurioni/release/scripts/raw_export.py	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/release/scripts/raw_export.py	2008-04-28 19:21:51 UTC (rev 14604)
@@ -2,9 +2,9 @@
 
 """
 Name: 'Raw Faces (.raw)...'
-Blender: 242
+Blender: 245
 Group: 'Export'
-Tooltip: 'Export selected mesh to Raw Triangle Format (.raw)'
+Tooltip: 'Export selected mesh to Raw Format (.raw)'
 """
 
 __author__ = "Anthony D'Agostino (Scorpius)"
@@ -13,10 +13,10 @@
 __version__ = "Part of IOSuite 0.5"
 
 __bpydoc__ = """\
-This script exports meshes to Raw Triangle file format.
+This script exports meshes to Raw file format.
 
 The raw triangle format is very simple; it has no verts or faces lists.
-It's just a simple ascii text file with the vertices of each triangle
+It's just a simple ascii text file with the vertices of each triangle or quad
 listed on each line. There were some very old utilities (when the PovRay
 forum was in existence on CompuServe) that preformed operations on these
 files.
@@ -65,24 +65,24 @@
 		filename += '.raw'
 	
 	scn= Blender.Scene.GetCurrent()
-	object= scn.getActiveObject()
-	if not object:
+	ob= scn.objects.active
+	if not ob:
 		Blender.Draw.PupMenu('Error%t|Select 1 active object')
 		return
 	
 	file = open(filename, 'wb')
 	
-	mesh = BPyMesh.getMeshFromObject(object, None, True, False, scn)
+	mesh = BPyMesh.getMeshFromObject(ob, None, True, False, scn)
 	if not mesh:
 		Blender.Draw.PupMenu('Error%t|Could not get mesh data from active object')
 		return
 	
-	mesh.transform(object.matrixWorld)
+	mesh.transform(ob.matrixWorld)
 	
 	
 	file = open(filename, "wb")
 	for f in mesh.faces:
-		for v in f.v:
+		for v in f:
 			file.write('%.6f %.6f %.6f ' % tuple(v.co))
 		file.write('\n')
 	file.close()

Modified: branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/object.c
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/object.c	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/object.c	2008-04-28 19:21:51 UTC (rev 14604)
@@ -1629,9 +1629,12 @@
 					}
 				}
 
-				if(count > 0) {
+				if (count==0) {
+					/* keep as 0,0,0 */
+				} else if(count > 0) {
 					VecMulf(vec, 1.0f / count);
 				} else {
+					/* use first index if its out of range */
 					dm->getVertCo(dm, 0, vec);
 				}
 			}

Modified: branches/soc-2008-mxcurioni/source/blender/blenlib/intern/bpath.c
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/blenlib/intern/bpath.c	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/source/blender/blenlib/intern/bpath.c	2008-04-28 19:21:51 UTC (rev 14604)
@@ -239,8 +239,10 @@
 				return seq;
 			} else {
 				/* keep looking through the next scene, reallocate seq array */
-				MEM_freeN((void *)bpi->seqdata.seqar);
-				bpi->seqdata.seqar = NULL;
+				if (bpi->seqdata.seqar) {
+					MEM_freeN((void *)bpi->seqdata.seqar);
+					bpi->seqdata.seqar = NULL;
+				}
 				bpi->seqdata.scene = bpi->seqdata.scene->id.next;
 			}
 		} else {

Modified: branches/soc-2008-mxcurioni/source/blender/blenloader/intern/readfile.c
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/blenloader/intern/readfile.c	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/source/blender/blenloader/intern/readfile.c	2008-04-28 19:21:51 UTC (rev 14604)
@@ -7593,6 +7593,31 @@
 		idproperties_fix_group_lengths(main->brush);
 		idproperties_fix_group_lengths(main->particle);		
 	}
+	
+	/* only needed until old bad svn/RC1,2 files are saved with a > 17 version -dg */
+	if(main->versionfile == 245 && main->subversionfile < 17) {
+		ModifierData *md;
+		Object *ob;
+		
+		for(ob = main->object.first; ob; ob= ob->id.next) {
+			for(md=ob->modifiers.first; md; ) {
+				if(md->type==eModifierType_Cloth) {
+					ModifierData *next;
+					MEM_freeN(((ClothModifierData *)md)->sim_parms);
+					MEM_freeN(((ClothModifierData *)md)->coll_parms);
+					MEM_freeN(((ClothModifierData *)md)->point_cache);
+					((ClothModifierData *)md)->sim_parms = NULL;
+					((ClothModifierData *)md)->coll_parms = NULL;
+					((ClothModifierData *)md)->point_cache = NULL;
+					next=md->next;
+					BLI_remlink(&ob->modifiers, md);
+					md = next;
+				}
+				else
+					md = md->next;
+			}
+		}
+	}
 
 	/* WATCH IT!!!: pointers from libdata have not been converted yet here! */
 	/* WATCH IT 2!: Userdef struct init has to be in src/usiblender.c! */

Modified: branches/soc-2008-mxcurioni/source/blender/makesdna/intern/SConscript
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/makesdna/intern/SConscript	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/source/blender/makesdna/intern/SConscript	2008-04-28 19:21:51 UTC (rev 14604)
@@ -25,6 +25,7 @@
     makesdna_tool.Append (CCFLAGS = cflags)
 makesdna_tool.Append (CPPDEFINES = defines)
 makesdna_tool.Append (LIBPATH = '#'+root_build_dir+'/lib')
+makesdna_tool.Append (LINKFLAGS = env['PLATFORM_LINKFLAGS'])
 if env['BF_PROFILE']:
 	makesdna_tool.Append (LINKFLAGS = env['BF_PROFILE_FLAGS'])
 

Modified: branches/soc-2008-mxcurioni/source/blender/python/api2_2x/MTex.c
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/python/api2_2x/MTex.c	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/source/blender/python/api2_2x/MTex.c	2008-04-28 19:21:51 UTC (rev 14604)
@@ -143,8 +143,11 @@
 		"Correct normal mapping for Texture space and Object space",
 		(void*) MTEX_VIEWSPACE },
 	{ "fromDupli", (getter) MTex_getFlag, (setter) MTex_setFlag,
-		"If object is duplicated by vertices, faces or particles, inherit texture coordinate from parent object",
+		"Dupli's instanced from verts, faces or particles, inherit texture coordinate from their parent",
 		(void*) MTEX_DUPLI_MAPTO },
+	{ "fromOrig", (getter) MTex_getFlag, (setter) MTex_setFlag,
+		"Dupli's derive their object coordinates from the original objects transformation",
+		(void*) MTEX_OB_DUPLI_ORIG },
 	{ "xproj", (getter) MTex_getProjX, (setter) MTex_setProjX,
 		"Projection of X axis to Texture space", NULL },
 	{ "yproj", (getter) MTex_getProjY, (setter) MTex_setProjY,

Modified: branches/soc-2008-mxcurioni/source/blender/python/api2_2x/doc/Texture.py
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/python/api2_2x/doc/Texture.py	2008-04-28 19:13:38 UTC (rev 14603)
+++ branches/soc-2008-mxcurioni/source/blender/python/api2_2x/doc/Texture.py	2008-04-28 19:21:51 UTC (rev 14604)
@@ -515,7 +515,8 @@
 	@ivar neg: Negate texture values mode
 	@ivar noRGB: Convert texture RGB values to intensity values
 	@ivar correctNor: Correct normal mapping for Texture space and Object space
-	@ivar fromDupli: If object is duplicated by vertices, faces or particles, inherit texture coordinate from parent object
+	@ivar fromDupli: Dupli's instanced from verts, faces or particles, inherit texture coordinate from their parent

@@ Diff output truncated at 10240 characters. @@




More information about the Bf-blender-cvs mailing list