[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [55843] branches/soc-2008-mxcurioni/source /blender: Pre-merger changes.
Tamito Kajiyama
rd6t-kjym at asahi-net.or.jp
Sat Apr 6 16:45:50 CEST 2013
Revision: 55843
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=55843
Author: kjym3
Date: 2013-04-06 14:45:50 +0000 (Sat, 06 Apr 2013)
Log Message:
-----------
Pre-merger changes.
Deprecated Freestyle-specific elements were removed from the code base,
in order to address all comments from branch code reviews.
https://codereview.appspot.com/7416049/
Backward compatibility won't be maintained in the following components:
- Freestyle edge/face marks in old .blend files are ignored.
Old .blend files can be converted by loading and saving the files using
a Freestyle branch build between revision 55581 and 55842.
- External style modules are no longer supported.
Instead text datablocks must be used to keep style module files within
.blend files. A branch build between revision 55741 and 55842 is useful
for identifying the style module file names that need reconfiguring.
Revision Links:
--------------
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=55581
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=55741
Modified Paths:
--------------
branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/bpath.c
branches/soc-2008-mxcurioni/source/blender/blenloader/intern/readfile.c
branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_freestyle_types.h
branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_meshdata_types.h
branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_mesh.c
branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_scene.c
branches/soc-2008-mxcurioni/source/blender/modifiers/intern/MOD_mirror.c
branches/soc-2008-mxcurioni/source/blender/modifiers/intern/MOD_solidify.c
Modified: branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/bpath.c
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/bpath.c 2013-04-06 13:50:37 UTC (rev 55842)
+++ branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/bpath.c 2013-04-06 14:45:50 UTC (rev 55843)
@@ -580,19 +580,6 @@
}
SEQ_END
}
- /* TODO, keep this or not? - campbell */
-#if 0
- {
- SceneRenderLayer *srl = scene->r.layers.first;
-
- for(; srl; srl = srl->next) {
- FreestyleModuleConfig *module = srl->freestyleConfig.modules.first;
- for (; module; module = module->next) {
- rewrite_path_fixed(module->module_path, visit_cb, absbase, bpath_user_data);
- }
- }
- }
-#endif
break;
}
case ID_ME:
Modified: branches/soc-2008-mxcurioni/source/blender/blenloader/intern/readfile.c
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/blenloader/intern/readfile.c 2013-04-06 13:50:37 UTC (rev 55842)
+++ branches/soc-2008-mxcurioni/source/blender/blenloader/intern/readfile.c 2013-04-06 14:45:50 UTC (rev 55843)
@@ -9329,82 +9329,7 @@
linestyle->rounds = 3;
}
}
- /* The code segment below will be removed when the trunk merger is done.
- For now it is kept for backward compatibility, giving branch users time
- to migrate to the new CustomData-based edge/face marks. */
- {
- Scene *sce;
- SceneRenderLayer *srl;
- FreestyleModuleConfig *fmc;
- Mesh *me;
- MEdge *medge;
- MPoly *mpoly;
- int i, found;
- for (me = main->mesh.first; me; me = me->id.next) {
- /* Freestyle edge marks */
- found = 0;
- medge = me->medge;
- for (i = 0; i < me->totedge; i++) {
- if (medge->flag & ME_FREESTYLE_EDGE) {
- found = 1;
- break;
- }
- medge++;
- }
- if (found) {
- FreestyleEdge *fed = CustomData_add_layer(&me->edata, CD_FREESTYLE_EDGE, CD_CALLOC, NULL, me->totedge);
- medge = me->medge;
- for (i = 0; i < me->totedge; i++) {
- if (medge->flag & ME_FREESTYLE_EDGE) {
- medge->flag &= ~ME_FREESTYLE_EDGE;
- fed->flag |= FREESTYLE_EDGE_MARK;
- }
- medge++;
- fed++;
- }
- printf("Migrated to CustomData-based Freestyle edge marks\n");
- }
- /* Freestyle face marks */
- found = 0;
- mpoly = me->mpoly;
- for (i = 0; i < me->totpoly; i++) {
- if (mpoly->flag & ME_FREESTYLE_FACE) {
- found = 1;
- break;
- }
- mpoly++;
- }
- if (found) {
- FreestyleFace *ffa = CustomData_add_layer(&me->pdata, CD_FREESTYLE_FACE, CD_CALLOC, NULL, me->totpoly);
- mpoly = me->mpoly;
- for (i = 0; i < me->totpoly; i++) {
- if (mpoly->flag & ME_FREESTYLE_FACE) {
- mpoly->flag &= ~ME_FREESTYLE_FACE;
- ffa->flag |= FREESTYLE_FACE_MARK;
- }
- mpoly++;
- ffa++;
- }
- printf("Migrated to CustomData-based Freestyle face marks\n");
- }
- }
- for (sce = main->scene.first; sce; sce = sce->id.next) {
- for (srl = sce->r.layers.first; srl; srl = srl->next) {
- i = 1;
- for (fmc = srl->freestyleConfig.modules.first; fmc; fmc = fmc->next) {
- if (fmc->module_path[0] != '\0' && !fmc->script) {
- fprintf(stderr, "The external style module below needs to be reconfigured using text datablock:\n");
- fprintf(stderr, " %s\n", fmc->module_path);
- fprintf(stderr, " in scene \"%s\", render layer \"%s\", style module #%d (%s)\n",
- sce->id.name+2, srl->name, i, (fmc->is_displayed) ? "enabled" : "disabled");
- }
- i++;
- }
- }
- }
- }
-
/* WATCH IT!!!: pointers from libdata have not been converted yet here! */
/* WATCH IT 2!: Userdef struct init see do_versions_userdef() above! */
Modified: branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_freestyle_types.h
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_freestyle_types.h 2013-04-06 13:50:37 UTC (rev 55842)
+++ branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_freestyle_types.h 2013-04-06 14:45:50 UTC (rev 55843)
@@ -28,7 +28,6 @@
#ifndef __DNA_FREESTYLE_TYPES_H__
#define __DNA_FREESTYLE_TYPES_H__
-#include "DNA_defs.h"
#include "DNA_listBase.h"
struct FreestyleLineStyle;
@@ -111,7 +110,6 @@
struct FreestyleModuleConfig *next, *prev;
struct Text *script;
- char module_path[1024] DNA_DEPRECATED; /* FILE_MAX */
short is_displayed;
short pad[3];
} FreestyleModuleConfig;
Modified: branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_meshdata_types.h
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_meshdata_types.h 2013-04-06 13:50:37 UTC (rev 55842)
+++ branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_meshdata_types.h 2013-04-06 14:45:50 UTC (rev 55843)
@@ -311,7 +311,6 @@
#define ME_LOOSEEDGE (1<<7)
/* #define ME_SEAM_LAST (1<<8) */ /* UNUSED */
#define ME_SHARP (1<<9) /* only reason this flag remains a 'short' */
-#define ME_FREESTYLE_EDGE (1<<10) /* TO BE REMOVED when the trunk merger is done */
/* puno = vertexnormal (mface) */
#define ME_PROJXY 16
@@ -328,7 +327,6 @@
/* flag (mface) */
#define ME_SMOOTH 1
#define ME_FACE_SEL 2
-#define ME_FREESTYLE_FACE 4 /* TO BE REMOVED when the trunk merger is done */
/* flag ME_HIDE==16 is used here too */
#define ME_POLY_LOOP_PREV(mloop, mp, i) (&(mloop)[(mp)->loopstart + (((i) + (mp)->totloop - 1) % (mp)->totloop)])
Modified: branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_mesh.c
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_mesh.c 2013-04-06 13:50:37 UTC (rev 55842)
+++ branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_mesh.c 2013-04-06 14:45:50 UTC (rev 55843)
@@ -1581,13 +1581,6 @@
RNA_def_property_ui_text(prop, "Sharp", "Sharp edge for the EdgeSplit modifier");
RNA_def_property_update(prop, 0, "rna_Mesh_update_data");
-#ifdef WITH_FREESTYLE /* TO BE REMOVED when the trunk merger is done */
- prop = RNA_def_property(srna, "use_freestyle_edge_mark", PROP_BOOLEAN, PROP_NONE);
- RNA_def_property_boolean_sdna(prop, NULL, "flag", ME_FREESTYLE_EDGE);
- RNA_def_property_ui_text(prop, "Freestyle Edge Mark", "Edge mark for Freestyle feature edge detection");
- RNA_def_property_update(prop, 0, "rna_Mesh_update_data");
-#endif
-
prop = RNA_def_property(srna, "is_loose", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_sdna(prop, NULL, "flag", ME_LOOSEEDGE);
RNA_def_property_ui_text(prop, "Loose", "Loose edge");
@@ -1643,13 +1636,6 @@
RNA_def_property_boolean_sdna(prop, NULL, "flag", ME_SMOOTH);
RNA_def_property_ui_text(prop, "Smooth", "");
RNA_def_property_update(prop, 0, "rna_Mesh_update_data");
-
-#ifdef WITH_FREESTYLE /* TO BE REMOVED when the trunk merger is done */
- prop = RNA_def_property(srna, "use_freestyle_face_mark", PROP_BOOLEAN, PROP_NONE);
- RNA_def_property_boolean_sdna(prop, NULL, "flag", ME_FREESTYLE_FACE);
- RNA_def_property_ui_text(prop, "Freestyle Face Mark", "Face mark for Freestyle feature edge detection");
- RNA_def_property_update(prop, 0, "rna_Mesh_update_data");
-#endif
prop = RNA_def_property(srna, "normal", PROP_FLOAT, PROP_DIRECTION);
RNA_def_property_array(prop, 3);
@@ -1748,11 +1734,6 @@
RNA_def_property_ui_text(prop, "Smooth", "");
RNA_def_property_update(prop, 0, "rna_Mesh_update_data");
- prop = RNA_def_property(srna, "use_freestyle_face_mark", PROP_BOOLEAN, PROP_NONE);
- RNA_def_property_boolean_sdna(prop, NULL, "flag", ME_FREESTYLE_FACE);
- RNA_def_property_ui_text(prop, "Freestyle Face Mark", "Face mark for Freestyle feature edge detection");
- RNA_def_property_update(prop, 0, "rna_Mesh_update_data");
-
prop = RNA_def_property(srna, "normal", PROP_FLOAT, PROP_DIRECTION);
RNA_def_property_array(prop, 3);
RNA_def_property_range(prop, -1.0f, 1.0f);
Modified: branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_scene.c
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_scene.c 2013-04-06 13:50:37 UTC (rev 55842)
+++ branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_scene.c 2013-04-06 14:45:50 UTC (rev 55843)
@@ -2686,13 +2686,6 @@
RNA_def_property_ui_text(prop, "Style Module", "Python script to define a style module");
RNA_def_property_update(prop, NC_SCENE, NULL);
-#if 1 /* TO BE REMOVED when the trunk merger is done */
- prop = RNA_def_property(srna, "module_path", PROP_STRING, PROP_FILEPATH);
- RNA_def_property_string_sdna(prop, NULL, "module_path");
- RNA_def_property_ui_text(prop, "Module Path", "Path to a style module file");
- RNA_def_property_update(prop, NC_SCENE, NULL);
-#endif
-
prop = RNA_def_property(srna, "use", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_sdna(prop, NULL, "is_displayed", 1);
RNA_def_property_ui_text(prop, "Use", "Enable or disable this style module during stroke rendering");
Modified: branches/soc-2008-mxcurioni/source/blender/modifiers/intern/MOD_mirror.c
===================================================================
--- branches/soc-2008-mxcurioni/source/blender/modifiers/intern/MOD_mirror.c 2013-04-06 13:50:37 UTC (rev 55842)
+++ branches/soc-2008-mxcurioni/source/blender/modifiers/intern/MOD_mirror.c 2013-04-06 14:45:50 UTC (rev 55843)
@@ -161,19 +161,6 @@
dm->copyPolyArray(dm, CDDM_get_polys(result));
}
-#if 1 /* WITH_FREESTYLE generic changes */
- /* if the source DM does not have edge/poly CD_ORIGINDEX layer, then
- * the corresponding layer of the result DM is filled with zeros
- * (see CDDM_from_template()) */
- if (!CustomData_has_layer(&dm->edgeData, CD_ORIGINDEX)) {
- range_vn_i(DM_get_edge_data_layer(result, CD_ORIGINDEX), maxEdges, 0);
- }
- if (!CustomData_has_layer(&dm->polyData, CD_ORIGINDEX)) {
- DM_add_poly_layer(result, CD_ORIGINDEX, CD_CALLOC, NULL);
- range_vn_i(DM_get_poly_data_layer(result, CD_ORIGINDEX), maxPolys, 0);
- }
-#endif
-
/* copy customdata to new geometry,
* copy from its self because this data may have been created in the checks above */
DM_copy_vert_data(result, result, 0, maxVerts, maxVerts);
Modified: branches/soc-2008-mxcurioni/source/blender/modifiers/intern/MOD_solidify.c
===================================================================
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list