Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacques Lucke <mail@jlucke.com>2019-02-06 14:05:34 +0300
committerJacques Lucke <mail@jlucke.com>2019-02-06 14:05:34 +0300
commit45478158479d3aa695de9dfafc2fe433d1ae0f51 (patch)
tree0be810545b6b18d0aa73480c465d72647258cd61 /source/blender/makesrna
parent6202bc82b858d8f6876c6c20ec62dd0a16209087 (diff)
Cleanup: Remove deprecated ghosting code
Most of this code is deprecated for many years already and does not work at all in Blender 2.8. Reviewers: brecht, aligorith Differential Revision: https://developer.blender.org/D4271
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r--source/blender/makesrna/RNA_access.h1
-rw-r--r--source/blender/makesrna/intern/rna_animviz.c104
-rw-r--r--source/blender/makesrna/intern/rna_armature.c88
3 files changed, 0 insertions, 193 deletions
diff --git a/source/blender/makesrna/RNA_access.h b/source/blender/makesrna/RNA_access.h
index e402c68efbf..143e2c475d0 100644
--- a/source/blender/makesrna/RNA_access.h
+++ b/source/blender/makesrna/RNA_access.h
@@ -60,7 +60,6 @@ extern StructRNA RNA_AndController;
extern StructRNA RNA_AnimData;
extern StructRNA RNA_AnimViz;
extern StructRNA RNA_AnimVizMotionPaths;
-extern StructRNA RNA_AnimVizOnionSkinning;
extern StructRNA RNA_AnyType;
extern StructRNA RNA_Area;
extern StructRNA RNA_AreaLight;
diff --git a/source/blender/makesrna/intern/rna_animviz.c b/source/blender/makesrna/intern/rna_animviz.c
index 6e714ed4477..8f064e8d875 100644
--- a/source/blender/makesrna/intern/rna_animviz.c
+++ b/source/blender/makesrna/intern/rna_animviz.c
@@ -45,32 +45,11 @@ const EnumPropertyItem rna_enum_motionpath_bake_location_items[] = {
#ifdef RNA_RUNTIME
-static PointerRNA rna_AnimViz_onion_skinning_get(PointerRNA *ptr)
-{
- return rna_pointer_inherit_refine(ptr, &RNA_AnimVizOnionSkinning, ptr->data);
-}
-
static PointerRNA rna_AnimViz_motion_paths_get(PointerRNA *ptr)
{
return rna_pointer_inherit_refine(ptr, &RNA_AnimVizMotionPaths, ptr->data);
}
-static void rna_AnimViz_ghost_start_frame_set(PointerRNA *ptr, int value)
-{
- bAnimVizSettings *data = (bAnimVizSettings *)ptr->data;
-
- data->ghost_sf = value;
- CLAMP(data->ghost_ef, data->ghost_sf, MAXFRAME / 2);
-}
-
-static void rna_AnimViz_ghost_end_frame_set(PointerRNA *ptr, int value)
-{
- bAnimVizSettings *data = (bAnimVizSettings *)ptr->data;
-
- data->ghost_ef = value;
- CLAMP(data->ghost_sf, 1, data->ghost_ef);
-}
-
static void rna_AnimViz_path_start_frame_set(PointerRNA *ptr, int value)
{
bAnimVizSettings *data = (bAnimVizSettings *)ptr->data;
@@ -188,81 +167,6 @@ static void rna_def_animviz_motion_path(BlenderRNA *brna)
/* --- */
-static void rna_def_animviz_ghosts(BlenderRNA *brna)
-{
- StructRNA *srna;
- PropertyRNA *prop;
-
- static const EnumPropertyItem prop_type_items[] = {
- {GHOST_TYPE_NONE, "NONE", 0, "No Ghosts", "Do not show any ghosts"},
- {GHOST_TYPE_ACFRA, "CURRENT_FRAME", 0, "Around Current Frame", "Show ghosts from around the current frame"},
- {GHOST_TYPE_RANGE, "RANGE", 0, "In Range", "Show ghosts for the specified frame range"},
- {GHOST_TYPE_KEYS, "KEYS", 0, "On Keyframes", "Show ghosts on keyframes"},
- {0, NULL, 0, NULL, NULL},
- };
-
-
- srna = RNA_def_struct(brna, "AnimVizOnionSkinning", NULL);
- RNA_def_struct_sdna(srna, "bAnimVizSettings");
- RNA_def_struct_nested(brna, srna, "AnimViz");
- RNA_def_struct_ui_text(srna, "Onion Skinning Settings", "Onion Skinning settings for animation visualization");
-
- /* Enums */
- prop = RNA_def_property(srna, "type", PROP_ENUM, PROP_NONE);
- RNA_def_property_enum_sdna(prop, NULL, "ghost_type");
- RNA_def_property_enum_items(prop, prop_type_items);
- RNA_def_property_ui_text(prop, "Type", "Method used for determining what ghosts get drawn");
- RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL); /* XXX since this is only for 3d-view drawing */
-
- /* Settings */
- prop = RNA_def_property(srna, "show_only_selected", PROP_BOOLEAN, PROP_NONE);
- RNA_def_property_boolean_sdna(prop, NULL, "ghost_flag", GHOST_FLAG_ONLYSEL);
- RNA_def_property_ui_text(prop, "On Selected Bones Only",
- "For Pose-Mode drawing, only draw ghosts for selected bones");
- RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL); /* XXX since this is only for 3d-view drawing */
-
- prop = RNA_def_property(srna, "frame_step", PROP_INT, PROP_NONE);
- RNA_def_property_int_sdna(prop, NULL, "ghost_step");
- RNA_def_property_range(prop, 1, 20);
- RNA_def_property_ui_text(prop, "Frame Step",
- "Number of frames between ghosts shown (not for 'On Keyframes' Onion-skinning method)");
- RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL); /* XXX since this is only for 3d-view drawing */
-
- /* Playback Ranges */
- prop = RNA_def_property(srna, "frame_start", PROP_INT, PROP_TIME);
- RNA_def_property_int_sdna(prop, NULL, "ghost_sf");
- RNA_def_property_int_funcs(prop, NULL, "rna_AnimViz_ghost_start_frame_set", NULL);
- RNA_def_property_ui_text(prop, "Start Frame",
- "Starting frame of range of Ghosts to display "
- "(not for 'Around Current Frame' Onion-skinning method)");
- RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL); /* XXX since this is only for 3d-view drawing */
-
- prop = RNA_def_property(srna, "frame_end", PROP_INT, PROP_TIME);
- RNA_def_property_int_sdna(prop, NULL, "ghost_ef");
- RNA_def_property_int_funcs(prop, NULL, "rna_AnimViz_ghost_end_frame_set", NULL);
- RNA_def_property_ui_text(prop, "End Frame",
- "End frame of range of Ghosts to display "
- "(not for 'Around Current Frame' Onion-skinning method)");
- RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL); /* XXX since this is only for 3d-view drawing */
-
- /* Around Current Ranges */
- prop = RNA_def_property(srna, "frame_before", PROP_INT, PROP_TIME);
- RNA_def_property_int_sdna(prop, NULL, "ghost_bc");
- RNA_def_property_range(prop, 0, 30);
- RNA_def_property_ui_text(prop, "Before Current",
- "Number of frames to show before the current frame "
- "(only for 'Around Current Frame' Onion-skinning method)");
- RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL); /* XXX since this is only for 3d-view drawing */
-
- prop = RNA_def_property(srna, "frame_after", PROP_INT, PROP_TIME);
- RNA_def_property_int_sdna(prop, NULL, "ghost_ac");
- RNA_def_property_range(prop, 0, 30);
- RNA_def_property_ui_text(prop, "After Current",
- "Number of frames to show after the current frame "
- "(only for 'Around Current Frame' Onion-skinning method)");
- RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL); /* XXX since this is only for 3d-view drawing */
-}
-
static void rna_def_animviz_paths(BlenderRNA *brna)
{
StructRNA *srna;
@@ -387,13 +291,6 @@ static void rna_def_animviz(BlenderRNA *brna)
RNA_def_struct_sdna(srna, "bAnimVizSettings");
RNA_def_struct_ui_text(srna, "Animation Visualization", "Settings for the visualization of motion");
- /* onion-skinning settings (nested struct) */
- prop = RNA_def_property(srna, "onion_skin_frames", PROP_POINTER, PROP_NONE);
- RNA_def_property_flag(prop, PROP_NEVER_NULL);
- RNA_def_property_struct_type(prop, "AnimVizOnionSkinning");
- RNA_def_property_pointer_funcs(prop, "rna_AnimViz_onion_skinning_get", NULL, NULL, NULL);
- RNA_def_property_ui_text(prop, "Onion Skinning", "Onion Skinning (ghosting) settings for visualization");
-
/* motion path settings (nested struct) */
prop = RNA_def_property(srna, "motion_path", PROP_POINTER, PROP_NONE);
RNA_def_property_flag(prop, PROP_NEVER_NULL);
@@ -407,7 +304,6 @@ static void rna_def_animviz(BlenderRNA *brna)
void RNA_def_animviz(BlenderRNA *brna)
{
rna_def_animviz(brna);
- rna_def_animviz_ghosts(brna);
rna_def_animviz_paths(brna);
rna_def_animviz_motion_path(brna);
diff --git a/source/blender/makesrna/intern/rna_armature.c b/source/blender/makesrna/intern/rna_armature.c
index 5f11f1e360b..6b8cfaae028 100644
--- a/source/blender/makesrna/intern/rna_armature.c
+++ b/source/blender/makesrna/intern/rna_armature.c
@@ -311,30 +311,6 @@ static void rna_Armature_layer_set(PointerRNA *ptr, const bool *values)
}
}
-/* XXX deprecated.... old armature only animviz */
-static void rna_Armature_ghost_start_frame_set(PointerRNA *ptr, int value)
-{
- bArmature *data = (bArmature *)ptr->data;
- CLAMP(value, 1, (int)(MAXFRAMEF / 2));
- data->ghostsf = value;
-
- if (data->ghostsf >= data->ghostef) {
- data->ghostef = MIN2(data->ghostsf, (int)(MAXFRAMEF / 2));
- }
-}
-
-static void rna_Armature_ghost_end_frame_set(PointerRNA *ptr, int value)
-{
- bArmature *data = (bArmature *)ptr->data;
- CLAMP(value, 1, (int)(MAXFRAMEF / 2));
- data->ghostef = value;
-
- if (data->ghostsf >= data->ghostef) {
- data->ghostsf = MAX2(data->ghostef, 1);
- }
-}
-/* XXX deprecated... old armature only animviz */
-
static void rna_EditBone_name_set(PointerRNA *ptr, const char *value)
{
bArmature *arm = (bArmature *)ptr->id.data;
@@ -1149,13 +1125,6 @@ static void rna_def_armature(BlenderRNA *brna)
{ARM_WIRE, "WIRE", 0, "Wire", "Display bones as thin wires, showing subdivision and B-Splines"},
{0, NULL, 0, NULL, NULL},
};
- static const EnumPropertyItem prop_ghost_type_items[] = {
- {ARM_GHOST_CUR, "CURRENT_FRAME", 0, "Around Frame",
- "Display Ghosts of poses within a fixed number of frames around the current frame"},
- {ARM_GHOST_RANGE, "RANGE", 0, "In Range", "Display Ghosts of poses within specified range"},
- {ARM_GHOST_KEYS, "KEYS", 0, "On Keyframes", "Display Ghosts of poses on Keyframes"},
- {0, NULL, 0, NULL, NULL},
- };
static const EnumPropertyItem prop_pose_position_items[] = {
{0, "POSE", 0, "Pose Position", "Show armature in posed state"},
{ARM_RESTPOS, "REST", 0, "Rest Position", "Show Armature in binding pose state (no posing possible)"},
@@ -1206,15 +1175,6 @@ static void rna_def_armature(BlenderRNA *brna)
RNA_def_property_update(prop, 0, "rna_Armature_redraw_data");
RNA_def_property_flag(prop, PROP_LIB_EXCEPTION);
-/* XXX deprecated ....... old animviz for armatures only */
- prop = RNA_def_property(srna, "ghost_type", PROP_ENUM, PROP_NONE);
- RNA_def_property_enum_sdna(prop, NULL, "ghosttype");
- RNA_def_property_enum_items(prop, prop_ghost_type_items);
- RNA_def_property_ui_text(prop, "Ghost Type", "Method of Onion-skinning for active Action");
- RNA_def_property_update(prop, 0, "rna_Armature_redraw_data");
- RNA_def_property_flag(prop, PROP_LIB_EXCEPTION);
-/* XXX deprecated ....... old animviz for armatures only */
-
/* Boolean values */
/* layer */
prop = RNA_def_property(srna, "layers", PROP_BOOLEAN, PROP_LAYER_MEMBER);
@@ -1274,54 +1234,6 @@ static void rna_def_armature(BlenderRNA *brna)
RNA_def_property_ui_text(prop, "Display Bone Group Colors", "Display bone group colors");
RNA_def_property_update(prop, 0, "rna_Armature_redraw_data");
-/* XXX deprecated ....... old animviz for armatures only */
- prop = RNA_def_property(srna, "show_only_ghost_selected", PROP_BOOLEAN, PROP_NONE);
- RNA_def_property_boolean_sdna(prop, NULL, "flag", ARM_GHOST_ONLYSEL);
- RNA_def_property_ui_text(prop, "Display Ghosts on Selected Bones Only", "");
- RNA_def_property_update(prop, 0, "rna_Armature_redraw_data");
- RNA_def_property_flag(prop, PROP_LIB_EXCEPTION);
-/* XXX deprecated ....... old animviz for armatures only */
-
- /* Number fields */
-/* XXX deprecated ....... old animviz for armatures only */
- /* ghost/onionskining settings */
- prop = RNA_def_property(srna, "ghost_step", PROP_INT, PROP_NONE);
- RNA_def_property_int_sdna(prop, NULL, "ghostep");
- RNA_def_property_range(prop, 0, 30);
- RNA_def_property_ui_text(prop, "Ghosting Step",
- "Number of frame steps on either side of current frame to show as ghosts "
- "(only for 'Around Current Frame' Onion-skinning method)");
- RNA_def_property_update(prop, 0, "rna_Armature_redraw_data");
- RNA_def_property_flag(prop, PROP_LIB_EXCEPTION);
-
- prop = RNA_def_property(srna, "ghost_size", PROP_INT, PROP_NONE);
- RNA_def_property_int_sdna(prop, NULL, "ghostsize");
- RNA_def_property_range(prop, 1, 20);
- RNA_def_property_ui_text(prop, "Ghosting Frame Step",
- "Frame step for Ghosts (not for 'On Keyframes' Onion-skinning method)");
- RNA_def_property_update(prop, 0, "rna_Armature_redraw_data");
- RNA_def_property_flag(prop, PROP_LIB_EXCEPTION);
-
- prop = RNA_def_property(srna, "ghost_frame_start", PROP_INT, PROP_TIME);
- RNA_def_property_int_sdna(prop, NULL, "ghostsf");
- RNA_def_property_int_funcs(prop, NULL, "rna_Armature_ghost_start_frame_set", NULL);
- RNA_def_property_ui_text(prop, "Ghosting Start Frame",
- "Starting frame of range of Ghosts to display (not for "
- "'Around Current Frame' Onion-skinning method)");
- RNA_def_property_update(prop, 0, "rna_Armature_redraw_data");
- RNA_def_property_flag(prop, PROP_LIB_EXCEPTION);
-
- prop = RNA_def_property(srna, "ghost_frame_end", PROP_INT, PROP_TIME);
- RNA_def_property_int_sdna(prop, NULL, "ghostef");
- RNA_def_property_int_funcs(prop, NULL, "rna_Armature_ghost_end_frame_set", NULL);
- RNA_def_property_ui_text(prop, "Ghosting End Frame",
- "End frame of range of Ghosts to display "
- "(not for 'Around Current Frame' Onion-skinning method)");
- RNA_def_property_update(prop, 0, "rna_Armature_redraw_data");
- RNA_def_property_flag(prop, PROP_LIB_EXCEPTION);
-/* XXX deprecated ....... old animviz for armatures only */
-
-
prop = RNA_def_property(srna, "is_editmode", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_funcs(prop, "rna_Armature_is_editmode_get", NULL);
RNA_def_property_clear_flag(prop, PROP_EDITABLE);