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
path: root/source
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2019-02-27 19:35:43 +0300
committerClément Foucault <foucault.clem@gmail.com>2019-02-27 19:46:17 +0300
commit28ccc0fa2f148bac7d3ed3ebdbe2b2dfa5ee5efc (patch)
treec61b83e610e9ae799a36b589e78a3d7d0ee710dc /source
parentfe5d26807b44e78800ccca0cc43b265801a37a25 (diff)
Armature: Remove the Transparent Bone overlay option
The option is replaced by the Wireframe mode display which (in edit & pose mode) does exactly what transparent bones did.
Diffstat (limited to 'source')
-rw-r--r--source/blender/draw/modes/edit_armature_mode.c3
-rw-r--r--source/blender/draw/modes/pose_mode.c10
-rw-r--r--source/blender/makesdna/DNA_view3d_types.h7
-rw-r--r--source/blender/makesrna/intern/rna_space.c5
4 files changed, 3 insertions, 22 deletions
diff --git a/source/blender/draw/modes/edit_armature_mode.c b/source/blender/draw/modes/edit_armature_mode.c
index 22211730ff6..4eaa9447efe 100644
--- a/source/blender/draw/modes/edit_armature_mode.c
+++ b/source/blender/draw/modes/edit_armature_mode.c
@@ -70,8 +70,7 @@ static void EDIT_ARMATURE_cache_init(void *vedata)
/* Alloc transient pointers */
stl->g_data = MEM_callocN(sizeof(*stl->g_data), __func__);
}
- stl->g_data->transparent_bones = (draw_ctx->v3d->shading.type == OB_WIRE) ||
- (draw_ctx->v3d->overlay.arm_flag & V3D_OVERLAY_ARM_TRANSP_BONES) != 0;
+ stl->g_data->transparent_bones = (draw_ctx->v3d->shading.type == OB_WIRE);
for (int i = 0; i < 2; ++i) {
/* Solid bones */
diff --git a/source/blender/draw/modes/pose_mode.c b/source/blender/draw/modes/pose_mode.c
index 6b646bfa0ea..69c613e7593 100644
--- a/source/blender/draw/modes/pose_mode.c
+++ b/source/blender/draw/modes/pose_mode.c
@@ -111,8 +111,7 @@ static void POSE_cache_init(void *vedata)
stl->g_data = MEM_callocN(sizeof(*stl->g_data), __func__);
}
POSE_PrivateData *ppd = stl->g_data;
- ppd->transparent_bones = (draw_ctx->v3d->shading.type == OB_WIRE) ||
- (draw_ctx->v3d->overlay.arm_flag & V3D_OVERLAY_ARM_TRANSP_BONES) != 0;
+ ppd->transparent_bones = (draw_ctx->v3d->shading.type == OB_WIRE);
for (int i = 0; i < 2; ++i) {
/* Solid bones */
@@ -258,8 +257,6 @@ static void POSE_draw_scene(void *vedata)
POSE_PassList *psl = ((POSE_Data *)vedata)->psl;
DefaultFramebufferList *dfbl = DRW_viewport_framebuffer_list_get();
DefaultTextureList *dtxl = DRW_viewport_texture_list_get();
- const DRWContextState *draw_ctx = DRW_context_state_get();
- const bool transparent_bones = (draw_ctx->v3d->overlay.arm_flag & V3D_OVERLAY_ARM_TRANSP_BONES) != 0;
const bool bone_selection_overlay = POSE_is_bone_selection_overlay_active();
if (DRW_state_is_select()) {
@@ -302,11 +299,6 @@ static void POSE_draw_scene(void *vedata)
GPU_framebuffer_clear_depth(dfbl->default_fb, 1.0f);
}
- if (transparent_bones) {
- DRW_pass_state_add(psl->bone_solid[1], DRW_STATE_BLEND);
- DRW_pass_state_remove(psl->bone_solid[1], DRW_STATE_WRITE_DEPTH);
- }
-
DRW_draw_pass(psl->bone_envelope[1]);
DRW_draw_pass(psl->bone_solid[1]);
DRW_draw_pass(psl->bone_transp[1]);
diff --git a/source/blender/makesdna/DNA_view3d_types.h b/source/blender/makesdna/DNA_view3d_types.h
index 2491e2cb0e0..9f8403670d8 100644
--- a/source/blender/makesdna/DNA_view3d_types.h
+++ b/source/blender/makesdna/DNA_view3d_types.h
@@ -211,7 +211,7 @@ typedef struct View3DOverlay {
float weight_paint_mode_opacity;
/* Armature edit/pose mode settings */
- int arm_flag;
+ int _pad3;
float xray_alpha_bone;
/* Other settings */
@@ -491,11 +491,6 @@ enum {
V3D_OVERLAY_EDIT_CU_NORMALS = (1 << 21),
};
-/* View3DOverlay->arm_flag */
-enum {
- V3D_OVERLAY_ARM_TRANSP_BONES = (1 << 0),
-};
-
/* View3DOverlay->paint_flag */
enum {
V3D_OVERLAY_PAINT_WIRE = (1 << 0),
diff --git a/source/blender/makesrna/intern/rna_space.c b/source/blender/makesrna/intern/rna_space.c
index 8a380514e1b..3dd71527e8e 100644
--- a/source/blender/makesrna/intern/rna_space.c
+++ b/source/blender/makesrna/intern/rna_space.c
@@ -2951,11 +2951,6 @@ static void rna_def_space_view3d_overlay(BlenderRNA *brna)
RNA_def_property_range(prop, 0.0f, 1.0f);
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL);
- prop = RNA_def_property(srna, "show_transparent_bones", PROP_BOOLEAN, PROP_NONE);
- RNA_def_property_boolean_sdna(prop, NULL, "overlay.arm_flag", V3D_OVERLAY_ARM_TRANSP_BONES);
- RNA_def_property_ui_text(prop, "Transparent Bones", "Display bones as transparent");
- RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL);
-
prop = RNA_def_property(srna, "texture_paint_mode_opacity", PROP_FLOAT, PROP_FACTOR);
RNA_def_property_float_sdna(prop, NULL, "overlay.texture_paint_mode_opacity");
RNA_def_property_float_default(prop, 1.0f);