Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/curve/editcurve.c
| Context not available. | |||||
| ot->prop = RNA_def_enum(ot->srna, "type", editcurve_handle_type_items, 1, "Type", "Spline type"); | ot->prop = RNA_def_enum(ot->srna, "type", editcurve_handle_type_items, 1, "Type", "Spline type"); | ||||
| } | } | ||||
| /***************** recalculate handles operator **********************/ | |||||
| static int recalculate_handles_exec(bContext *C, wmOperator *op) | |||||
| { | |||||
| Object *obedit = CTX_data_edit_object(C); | |||||
| ListBase *editnurb = object_editcurve_get(obedit); | |||||
| BKE_nurbList_handles_recalculate(editnurb); | |||||
| WM_event_add_notifier(C, NC_GEOM | ND_DATA, obedit->data); | |||||
| DAG_id_tag_update(obedit->data, 0); | |||||
| return OPERATOR_FINISHED; | |||||
| } | |||||
| void CURVE_OT_recalculate_handles(wmOperatorType *ot) | |||||
| { | |||||
| /* identifiers */ | |||||
| ot->name = "Recalculate handles"; | |||||
| ot->description = "Recalculate handles without changing their"; | |||||
| ot->idname = "CURVE_OT_recalculate_handles"; | |||||
| /* api callbacks */ | |||||
| ot->exec = recalculate_handles_exec; | |||||
| ot->poll = ED_operator_editcurve; | |||||
| /* flags */ | |||||
| ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; | |||||
| } | |||||
| /***************** make segment operator **********************/ | /***************** make segment operator **********************/ | ||||
| /* ******************** SKINNING LOFTING!!! ******************** */ | /* ******************** SKINNING LOFTING!!! ******************** */ | ||||
| Context not available. | |||||