diff options
author | Nicholas Bishop <nicholasbishop@gmail.com> | 2012-03-10 09:15:17 +0400 |
---|---|---|
committer | Nicholas Bishop <nicholasbishop@gmail.com> | 2012-03-10 09:15:17 +0400 |
commit | 24b676e3709ab7af986e493497a95b5ee04754d4 (patch) | |
tree | 77a94a28b41727eae47f9a2badf1eb09487176cd /source/blender | |
parent | d3ffa53f78a7985a316e4f77219f8f5348cbab7a (diff) |
Remove the OBJECT_OT_test_multires operator.
Originated in r35213, appears to have been some test for multires in
BMesh.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/editors/object/object_intern.h | 1 | ||||
-rw-r--r-- | source/blender/editors/object/object_modifier.c | 58 | ||||
-rw-r--r-- | source/blender/editors/object/object_ops.c | 2 |
3 files changed, 0 insertions, 61 deletions
diff --git a/source/blender/editors/object/object_intern.h b/source/blender/editors/object/object_intern.h index 526706b566d..73c5c50f448 100644 --- a/source/blender/editors/object/object_intern.h +++ b/source/blender/editors/object/object_intern.h @@ -159,7 +159,6 @@ void OBJECT_OT_multires_external_pack(struct wmOperatorType *ot); void OBJECT_OT_meshdeform_bind(struct wmOperatorType *ot); void OBJECT_OT_explode_refresh(struct wmOperatorType *ot); void OBJECT_OT_ocean_bake(struct wmOperatorType *ot); -void OBJECT_OT_test_multires(struct wmOperatorType *ot); /* object_constraint.c */ void OBJECT_OT_constraint_add(struct wmOperatorType *ot); diff --git a/source/blender/editors/object/object_modifier.c b/source/blender/editors/object/object_modifier.c index d78b6675eea..de9e3db25b8 100644 --- a/source/blender/editors/object/object_modifier.c +++ b/source/blender/editors/object/object_modifier.c @@ -1176,64 +1176,6 @@ void OBJECT_OT_multires_reshape(wmOperatorType *ot) edit_modifier_properties(ot); } -static int multires_test_exec(bContext *C, wmOperator *op) -{ - Object *ob= ED_object_active_context(C); - Mesh *me = ob->data; - MPoly *mp; - MDisps *mdisps; - int i, x = RNA_int_get(op->ptr, "x"), y = RNA_int_get(op->ptr, "y"); - - if (ob->type != OB_MESH || !me) - return OPERATOR_CANCELLED; - - mdisps = CustomData_get_layer(&me->ldata, CD_MDISPS); - if (!mdisps) - return OPERATOR_CANCELLED; - - mp = me->mpoly; - for (i=0; i<me->totpoly; i++, mp++) { - MLoop *ml; - int j; - - ml = me->mloop + mp->loopstart; - for (j=0; j<mp->totloop; j++, ml++) { - MLoop *ml_prev = ME_POLY_LOOP_PREV(me->mloop, mp, j); - MLoop *ml_next = ME_POLY_LOOP_NEXT(me->mloop, mp, j); - - if ((me->mvert[ml->v].flag&SELECT) && (me->mvert[ml_prev->v].flag&SELECT) && (me->mvert[ml_next->v].flag&SELECT)) { - MDisps *md = mdisps + mp->loopstart + j; - int res = sqrt(md->totdisp); - - if (x >= res) x = res-1; - if (y >= res) y = res-1; - - md->disps[y*res + x][2] += 1.0; - } - } - } - - DAG_id_tag_update(&ob->id, OB_RECALC_DATA); - WM_event_add_notifier(C, NC_OBJECT|ND_MODIFIER, ob); - - return OPERATOR_FINISHED; -} - -void OBJECT_OT_test_multires(wmOperatorType *ot) -{ - ot->name= "Multires Object Mode Test"; - ot->description= ""; - ot->idname= "OBJECT_OT_test_multires"; - - ot->poll= multires_poll; - ot->exec= multires_test_exec; - - /* flags */ - ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "x", 0, 0, 100, "x", "x", 0, 100); - RNA_def_int(ot->srna, "y", 0, 0, 100, "y", "y", 0, 100); -} - /****************** multires save external operator *********************/ diff --git a/source/blender/editors/object/object_ops.c b/source/blender/editors/object/object_ops.c index 542b75e1f19..2b6707de42b 100644 --- a/source/blender/editors/object/object_ops.c +++ b/source/blender/editors/object/object_ops.c @@ -214,8 +214,6 @@ void ED_operatortypes_object(void) WM_operatortype_append(OBJECT_OT_bake_image); WM_operatortype_append(OBJECT_OT_drop_named_material); - - WM_operatortype_append(OBJECT_OT_test_multires); } void ED_operatormacros_object(void) |