Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/transform/transform.h
| Show First 20 Lines • Show All 868 Lines • ▼ Show 20 Lines | enum { | ||||
| POINT_INIT = 1 << 2, | POINT_INIT = 1 << 2, | ||||
| MULTI_POINTS = 1 << 3, | MULTI_POINTS = 1 << 3, | ||||
| }; | }; | ||||
| /* Hard min/max for proportional size. */ | /* Hard min/max for proportional size. */ | ||||
| #define T_PROP_SIZE_MIN 1e-6f | #define T_PROP_SIZE_MIN 1e-6f | ||||
| #define T_PROP_SIZE_MAX 1e12f | #define T_PROP_SIZE_MAX 1e12f | ||||
| bool initTransform(struct bContext *C, | /* transform.c */ | ||||
| struct TransInfo *t, | bool transdata_check_local_center(TransInfo *t, short around); | ||||
| struct wmOperator *op, | bool transdata_check_local_islands(TransInfo *t, short around); | ||||
| const struct wmEvent *event, | |||||
| int mode); | |||||
| void saveTransform(struct bContext *C, struct TransInfo *t, struct wmOperator *op); | |||||
| int transformEvent(TransInfo *t, const struct wmEvent *event); | |||||
| void transformApply(struct bContext *C, TransInfo *t); | |||||
| int transformEnd(struct bContext *C, TransInfo *t); | |||||
| void setTransformViewMatrices(TransInfo *t); | void setTransformViewMatrices(TransInfo *t); | ||||
| void setTransformViewAspect(TransInfo *t, float r_aspect[3]); | void setTransformViewAspect(TransInfo *t, float r_aspect[3]); | ||||
| void convertViewVec(TransInfo *t, float r_vec[3], double dx, double dy); | void convertViewVec(TransInfo *t, float r_vec[3], double dx, double dy); | ||||
| void projectIntViewEx(TransInfo *t, const float vec[3], int adr[2], const eV3DProjTest flag); | void projectIntViewEx(TransInfo *t, const float vec[3], int adr[2], const eV3DProjTest flag); | ||||
| void projectIntView(TransInfo *t, const float vec[3], int adr[2]); | void projectIntView(TransInfo *t, const float vec[3], int adr[2]); | ||||
| void projectFloatViewEx(TransInfo *t, const float vec[3], float adr[2], const eV3DProjTest flag); | void projectFloatViewEx(TransInfo *t, const float vec[3], float adr[2], const eV3DProjTest flag); | ||||
| void projectFloatView(TransInfo *t, const float vec[3], float adr[2]); | void projectFloatView(TransInfo *t, const float vec[3], float adr[2]); | ||||
| void applyAspectRatio(TransInfo *t, float vec[2]); | |||||
| void removeAspectRatio(TransInfo *t, float vec[2]); | void removeAspectRatio(TransInfo *t, float vec[2]); | ||||
| bool checkUseAxisMatrix(TransInfo *t); | |||||
| void drawPropCircle(const struct bContext *C, TransInfo *t); | |||||
| struct wmKeyMap *transform_modal_keymap(struct wmKeyConfig *keyconf); | |||||
| /*********************** transform_gizmo.c ********** */ | /*********************** transform_gizmo.c ********** */ | ||||
| #define GIZMO_AXIS_LINE_WIDTH 2.0f | #define GIZMO_AXIS_LINE_WIDTH 2.0f | ||||
| /* return 0 when no gimbal for selection */ | /* return 0 when no gimbal for selection */ | ||||
| bool gimbal_axis(struct Object *ob, float gmat[3][3]); | bool gimbal_axis(struct Object *ob, float gmat[3][3]); | ||||
| void drawDial3d(const TransInfo *t); | void drawDial3d(const TransInfo *t); | ||||
| /*********************** TransData Creation and General Handling *********** */ | |||||
| bool transdata_check_local_islands(TransInfo *t, short around); | |||||
| /*********************** Constraints *****************************/ | /*********************** Constraints *****************************/ | ||||
| void drawPropCircle(const bContext *C, TransInfo *t); | |||||
| void drawConstraint(TransInfo *t); | void drawConstraint(TransInfo *t); | ||||
| void getConstraintMatrix(TransInfo *t); | void getConstraintMatrix(TransInfo *t); | ||||
| void setConstraint(TransInfo *t, float space[3][3], int mode, const char text[]); | void setConstraint(TransInfo *t, float space[3][3], int mode, const char text[]); | ||||
| void setAxisMatrixConstraint(TransInfo *t, int mode, const char text[]); | void setAxisMatrixConstraint(TransInfo *t, int mode, const char text[]); | ||||
| void setLocalConstraint(TransInfo *t, int mode, const char text[]); | void setLocalConstraint(TransInfo *t, int mode, const char text[]); | ||||
| void setUserConstraint(TransInfo *t, short orientation, int mode, const char text[]); | void setUserConstraint(TransInfo *t, short orientation, int mode, const char text[]); | ||||
| ▲ Show 20 Lines • Show All 159 Lines • ▼ Show 20 Lines | |||||
| void freeCustomNormalArray(TransInfo *t, TransDataContainer *tc, TransCustomData *custom_data); | void freeCustomNormalArray(TransInfo *t, TransDataContainer *tc, TransCustomData *custom_data); | ||||
| void freeEdgeSlideVerts(TransInfo *t, TransDataContainer *tc, TransCustomData *custom_data); | void freeEdgeSlideVerts(TransInfo *t, TransDataContainer *tc, TransCustomData *custom_data); | ||||
| void projectEdgeSlideData(TransInfo *t, bool is_final); | void projectEdgeSlideData(TransInfo *t, bool is_final); | ||||
| void freeVertSlideVerts(TransInfo *t, TransDataContainer *tc, TransCustomData *custom_data); | void freeVertSlideVerts(TransInfo *t, TransDataContainer *tc, TransCustomData *custom_data); | ||||
| void projectVertSlideData(TransInfo *t, bool is_final); | void projectVertSlideData(TransInfo *t, bool is_final); | ||||
| /* TODO. transform_query.c */ | |||||
| bool checkUseAxisMatrix(TransInfo *t); | |||||
| #define TRANSFORM_SNAP_MAX_PX 100.0f | #define TRANSFORM_SNAP_MAX_PX 100.0f | ||||
| #define TRANSFORM_DIST_INVALID -FLT_MAX | #define TRANSFORM_DIST_INVALID -FLT_MAX | ||||
| /* Temp macros. */ | /* Temp macros. */ | ||||
| #define TRANS_DATA_CONTAINER_FIRST_OK(t) (&(t)->data_container[0]) | #define TRANS_DATA_CONTAINER_FIRST_OK(t) (&(t)->data_container[0]) | ||||
| /* For cases we _know_ there is only one handle. */ | /* For cases we _know_ there is only one handle. */ | ||||
| #define TRANS_DATA_CONTAINER_FIRST_SINGLE(t) \ | #define TRANS_DATA_CONTAINER_FIRST_SINGLE(t) \ | ||||
| Show All 15 Lines | |||||