[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [25317] branches/sculpt25/source/blender: Sculpt Branch: revert minor code changes that didn't turn out to be needed .

Brecht Van Lommel brecht at blender.org
Fri Dec 11 16:02:46 CET 2009


Revision: 25317
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=25317
Author:   blendix
Date:     2009-12-11 16:02:46 +0100 (Fri, 11 Dec 2009)

Log Message:
-----------
Sculpt Branch: revert minor code changes that didn't turn out to be needed.

Modified Paths:
--------------
    branches/sculpt25/source/blender/blenkernel/BKE_DerivedMesh.h
    branches/sculpt25/source/blender/blenkernel/BKE_mesh.h
    branches/sculpt25/source/blender/blenkernel/intern/pointcache.c
    branches/sculpt25/source/blender/blenlib/BLI_string.h
    branches/sculpt25/source/blender/blenlib/intern/math_matrix.c
    branches/sculpt25/source/blender/blenlib/intern/string.c
    branches/sculpt25/source/blender/editors/space_view3d/view3d_draw.c
    branches/sculpt25/source/blender/makesrna/intern/rna_modifier.c
    branches/sculpt25/source/blender/makesrna/intern/rna_object.c

Modified: branches/sculpt25/source/blender/blenkernel/BKE_DerivedMesh.h
===================================================================
--- branches/sculpt25/source/blender/blenkernel/BKE_DerivedMesh.h	2009-12-11 14:38:02 UTC (rev 25316)
+++ branches/sculpt25/source/blender/blenkernel/BKE_DerivedMesh.h	2009-12-11 15:02:46 UTC (rev 25317)
@@ -86,7 +86,6 @@
 	int needsFree; /* checked on ->release, is set to 0 for cached results */
 	int deformedOnly; /* set by modifier stack if only deformed from original */
 	BVHCache bvhCache;
-
 	struct GPUDrawObject *drawObject;
 
 	/* Misc. Queries */

Modified: branches/sculpt25/source/blender/blenkernel/BKE_mesh.h
===================================================================
--- branches/sculpt25/source/blender/blenkernel/BKE_mesh.h	2009-12-11 14:38:02 UTC (rev 25316)
+++ branches/sculpt25/source/blender/blenkernel/BKE_mesh.h	2009-12-11 15:02:46 UTC (rev 25317)
@@ -47,7 +47,6 @@
 struct MTFace;
 struct VecNor;
 struct CustomData;
-struct Scene;
 
 #ifdef __cplusplus
 extern "C" {

Modified: branches/sculpt25/source/blender/blenkernel/intern/pointcache.c
===================================================================
--- branches/sculpt25/source/blender/blenkernel/intern/pointcache.c	2009-12-11 14:38:02 UTC (rev 25316)
+++ branches/sculpt25/source/blender/blenkernel/intern/pointcache.c	2009-12-11 15:02:46 UTC (rev 25317)
@@ -1075,11 +1075,12 @@
 	}
 	if(strcmp(pid->cache->name, "")==0 && (pid->cache->flag & PTCACHE_EXTERNAL)==0) {
 		idname = (pid->ob->id.name+2);
-
 		/* convert chars to hex so they are always a valid filename */
-		BLI_strhex(newname, MAX_PTCACHE_FILE - len, idname);
-		len += strlen(newname);
-		newname = filename + len;
+		while('\0' != *idname) {
+			snprintf(newname, MAX_PTCACHE_FILE, "%02X", (char)(*idname++));
+			newname+=2;
+			len += 2;
+		}
 	}
 	else {
 		int temp = (int)strlen(pid->cache->name); 

Modified: branches/sculpt25/source/blender/blenlib/BLI_string.h
===================================================================
--- branches/sculpt25/source/blender/blenlib/BLI_string.h	2009-12-11 14:38:02 UTC (rev 25316)
+++ branches/sculpt25/source/blender/blenlib/BLI_string.h	2009-12-11 15:02:46 UTC (rev 25317)
@@ -123,9 +123,6 @@
 
 void BLI_timestr(double _time, char *str); /* time var is global */
 
-	/* Convert to hex string valid for file writing (2x length of original) */
-void BLI_strhex(char *hex, int maxlen, const char *str);
-
 #ifdef __cplusplus
 }
 #endif

Modified: branches/sculpt25/source/blender/blenlib/intern/math_matrix.c
===================================================================
--- branches/sculpt25/source/blender/blenlib/intern/math_matrix.c	2009-12-11 14:38:02 UTC (rev 25316)
+++ branches/sculpt25/source/blender/blenlib/intern/math_matrix.c	2009-12-11 15:02:46 UTC (rev 25317)
@@ -1129,4 +1129,3 @@
 	printf("\n");
 }
 
-

Modified: branches/sculpt25/source/blender/blenlib/intern/string.c
===================================================================
--- branches/sculpt25/source/blender/blenlib/intern/string.c	2009-12-11 14:38:02 UTC (rev 25316)
+++ branches/sculpt25/source/blender/blenlib/intern/string.c	2009-12-11 15:02:46 UTC (rev 25317)
@@ -42,9 +42,6 @@
 
 #include "BLI_dynstr.h"
 #include "BLI_string.h"
-#ifdef WIN32
-#include "BLI_winstuff.h"
-#endif
 
 char *BLI_strdupn(const char *str, int len) {
 	char *n= MEM_mallocN(len+1, "strdup");
@@ -332,18 +329,3 @@
 	
 	str[11]=0;
 }
-
-void BLI_strhex(char *hex, int maxlen, const char *str)
-{
-	int len = 0;
-
-	while('\0' != *str && len+3 < maxlen) {
-		snprintf(hex, maxlen, "%02X", *str++);
-		hex += 2;
-		len += 2;
-	}
-
-	if(maxlen)
-		hex[0]= '\0';
-}
-

Modified: branches/sculpt25/source/blender/editors/space_view3d/view3d_draw.c
===================================================================
--- branches/sculpt25/source/blender/editors/space_view3d/view3d_draw.c	2009-12-11 14:38:02 UTC (rev 25316)
+++ branches/sculpt25/source/blender/editors/space_view3d/view3d_draw.c	2009-12-11 15:02:46 UTC (rev 25317)
@@ -1860,8 +1860,6 @@
 			mask |= CD_MASK_MCOL;
 		if(ob->mode & OB_MODE_WEIGHT_PAINT)
 			mask |= CD_MASK_WEIGHT_MCOL;
-		//if(ob->mode & OB_MODE_SCULPT)
-		//	mask |= CD_MASK_MDISPS;
 	}
 
 	return mask;

Modified: branches/sculpt25/source/blender/makesrna/intern/rna_modifier.c
===================================================================
--- branches/sculpt25/source/blender/makesrna/intern/rna_modifier.c	2009-12-11 14:38:02 UTC (rev 25316)
+++ branches/sculpt25/source/blender/makesrna/intern/rna_modifier.c	2009-12-11 15:02:46 UTC (rev 25317)
@@ -39,7 +39,6 @@
 
 #include "BKE_animsys.h"
 #include "BKE_bmesh.h" /* For BevelModifierData */
-#include "BKE_global.h"
 #include "BKE_smoke.h" /* For smokeModifier_free & smokeModifier_createType */
 
 #include "WM_api.h"
@@ -382,13 +381,6 @@
 	return strlen((external)? external->filename: "");
 }
 
-static int rna_MultiresModifier_external_editable(PointerRNA *ptr)
-{
-	MultiresModifierData *mmd = ptr->data;
-
-	return (G.save_over && mmd->totlvl > 0);
-}
-
 static void modifier_object_set(Object *self, Object **ob_p, int type, PointerRNA value)
 {
 	Object *ob= value.data;
@@ -596,7 +588,6 @@
 	prop= RNA_def_property(srna, "external", PROP_BOOLEAN, PROP_NONE);
 	RNA_def_property_clear_flag(prop, PROP_EDITABLE);
 	RNA_def_property_boolean_funcs(prop, "rna_MultiresModifier_external_get", NULL);
-	RNA_def_property_editable_func(prop, "rna_MultiresModifier_external_editable");
 	RNA_def_property_ui_text(prop, "External", "Store multires displacements outside the .blend file, to save memory.");
 
 	prop= RNA_def_property(srna, "filename", PROP_STRING, PROP_FILEPATH);

Modified: branches/sculpt25/source/blender/makesrna/intern/rna_object.c
===================================================================
--- branches/sculpt25/source/blender/makesrna/intern/rna_object.c	2009-12-11 14:38:02 UTC (rev 25316)
+++ branches/sculpt25/source/blender/makesrna/intern/rna_object.c	2009-12-11 15:02:46 UTC (rev 25317)
@@ -670,6 +670,7 @@
 	return PROP_EDITABLE;
 }
 
+
 static PointerRNA rna_MaterialSlot_material_get(PointerRNA *ptr)
 {
 	Object *ob= (Object*)ptr->id.data;





More information about the Bf-blender-cvs mailing list