remove toolsettings (unused for a long time).
authorCampbell Barton <ideasman42@gmail.com>
Tue, 8 Oct 2013 13:07:09 +0000 (13:07 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Tue, 8 Oct 2013 13:07:09 +0000 (13:07 +0000)
source/blender/blenkernel/intern/scene.c
source/blender/blenloader/intern/versioning_legacy.c
source/blender/makesdna/DNA_scene_types.h

index b89cb6b7b82648b7e25dba8dd93d142276deb79f..41e43c0045775da5f570d3e328f1398869281d67 100644 (file)
@@ -493,23 +493,10 @@ Scene *BKE_scene_add(Main *bmain, const char *name)
        sce->r.border.ymax = 1.0f;
        
        sce->toolsettings = MEM_callocN(sizeof(struct ToolSettings), "Tool Settings Struct");
-       sce->toolsettings->cornertype = 1;
-       sce->toolsettings->degr = 90; 
-       sce->toolsettings->step = 9;
-       sce->toolsettings->turn = 1;
-       sce->toolsettings->extr_offs = 1; 
        sce->toolsettings->doublimit = 0.001;
-       sce->toolsettings->segments = 32;
-       sce->toolsettings->rings = 32;
-       sce->toolsettings->vertices = 32;
-       sce->toolsettings->uvcalc_radius = 1.0f;
-       sce->toolsettings->uvcalc_cubesize = 1.0f;
-       sce->toolsettings->uvcalc_mapdir = 1;
-       sce->toolsettings->uvcalc_mapalign = 1;
        sce->toolsettings->uvcalc_margin = 0.001f;
        sce->toolsettings->unwrapper = 1;
        sce->toolsettings->select_thresh = 0.01f;
-       sce->toolsettings->jointrilimit = 0.8f;
 
        sce->toolsettings->selectmode = SCE_SELECT_VERTEX;
        sce->toolsettings->uv_selectmode = UV_SELECT_VERTEX;
index f32215dbf03c8e818d6a28057bbf4a99f65b2d55..067a86299068a7d3611662223e57b4a0c53a5f01 100644 (file)
@@ -1994,15 +1994,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *main)
                while (sce) {
                        if (sce->toolsettings == NULL) {
                                sce->toolsettings = MEM_callocN(sizeof(struct ToolSettings), "Tool Settings Struct");
-                               sce->toolsettings->cornertype =0;
-                               sce->toolsettings->degr = 90;
-                               sce->toolsettings->step = 9;
-                               sce->toolsettings->turn = 1;
-                               sce->toolsettings->extr_offs = 1;
                                sce->toolsettings->doublimit = 0.001f;
-                               sce->toolsettings->segments = 32;
-                               sce->toolsettings->rings = 32;
-                               sce->toolsettings->vertices = 32;
                        }
                        sce = sce->id.next;
                }
@@ -2149,9 +2141,6 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *main)
                }
 
                for (; sce; sce = sce->id.next) {
-                       /* make 'innervert' the default subdivide type, for backwards compat */
-                       sce->toolsettings->cornertype = 1;
-
                        if (sce->r.scemode & R_PASSEPARTOUT) {
                                set_passepartout = 1;
                                sce->r.scemode &= ~R_PASSEPARTOUT;
@@ -2238,11 +2227,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *main)
                                ntree_version_241(sce->nodetree);
 
                        /* uv calculation options moved to toolsettings */
-                       if (sce->toolsettings->uvcalc_radius == 0.0f) {
-                               sce->toolsettings->uvcalc_radius = 1.0f;
-                               sce->toolsettings->uvcalc_cubesize = 1.0f;
-                               sce->toolsettings->uvcalc_mapdir = 1;
-                               sce->toolsettings->uvcalc_mapalign = 1;
+                       if (sce->toolsettings->unwrapper == 0) {
                                sce->toolsettings->uvcalc_flag = UVCALC_FILLHOLES;
                                sce->toolsettings->unwrapper = 1;
                        }
@@ -2343,8 +2328,6 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *main)
                for (sce = main->scene.first; sce; sce = sce->id.next) {
                        if (sce->toolsettings->select_thresh == 0.0f)
                                sce->toolsettings->select_thresh = 0.01f;
-                       if (sce->toolsettings->clean_thresh == 0.0f)
-                               sce->toolsettings->clean_thresh = 0.1f;
 
                        if (sce->r.threads == 0) {
                                if (sce->r.mode & R_THREADS)
@@ -2554,14 +2537,6 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *main)
                                sce->r.bake_flag = R_BAKE_CLEAR;
                        }
                }
-
-               if (main->subversionfile < 5) {
-                       for (sce = main->scene.first; sce; sce = sce->id.next) {
-                               /* improved triangle to quad conversion settings */
-                               if (sce->toolsettings->jointrilimit == 0.0f)
-                                       sce->toolsettings->jointrilimit = 0.8f;
-                       }
-               }
        }
 
        if (main->versionfile <= 243) {
index 002d77fb0e62c01ce95562499899ec43585c1d3f..e8f55ac047ce13a54d5a4986122dc574ebf41003 100644 (file)
@@ -981,17 +981,6 @@ typedef struct ToolSettings {
         * paint */
        float vgroup_weight;
 
-       /* Subdivide Settings */
-       short cornertype;
-       short pad1;
-       /*Triangle to Quad conversion threshold*/
-       float jointrilimit;
-       /* Editmode Tools */
-       float degr; 
-       short step;
-       short turn; 
-       
-       float extr_offs;        /* extrude offset */
        float doublimit;        /* remove doubles limit */
        float normalsize;       /* size of normals */
        short automerge;
@@ -999,30 +988,21 @@ typedef struct ToolSettings {
        /* Selection Mode for Mesh */
        short selectmode;
 
-       /* Primitive Settings */
-       /* UV Sphere */
-       short segments;
-       short rings;
-       
-       /* Cylinder - Tube - Circle */
-       short vertices;
-
        /* UV Calculation */
-       short unwrapper;
-       float uvcalc_radius;
-       float uvcalc_cubesize;
+       char unwrapper;
+       char uvcalc_flag;
+       char uv_flag;
+       char uv_selectmode;
+
        float uvcalc_margin;
-       short uvcalc_mapdir;
-       short uvcalc_mapalign;
-       short uvcalc_flag;
-       short uv_flag, uv_selectmode;
-       short pad2;
-       
-       /* Grease Pencil */
-       short gpencil_flags;
-       
+
        /* Auto-IK */
-       short autoik_chainlen;
+       short autoik_chainlen;  /* runtime only */
+
+       /* Grease Pencil */
+       char gpencil_flags;
+
+       char pad[5];
 
        /* Image Paint (8 byttse aligned please!) */
        struct ImagePaintSettings imapaint;
@@ -1035,16 +1015,13 @@ typedef struct ToolSettings {
 
        /* Select Group Threshold */
        float select_thresh;
-       
-       /* Graph Editor */
-       float clean_thresh;
 
        /* Auto-Keying Mode */
        short autokey_mode, autokey_flag;       /* defines in DNA_userdef_types.h */
 
        /* Multires */
        char multires_subdiv_type;
-       char pad3[5];
+       char pad3[1];
 
        /* Skeleton generation */
        short skgen_resolution;