Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/sculpt_paint/sculpt_intern.h
| Show First 20 Lines • Show All 298 Lines • ▼ Show 20 Lines | typedef struct StrokeCache { | ||||
| float true_gravity_direction[3]; | float true_gravity_direction[3]; | ||||
| float gravity_direction[3]; | float gravity_direction[3]; | ||||
| rcti previous_r; /* previous redraw rectangle */ | rcti previous_r; /* previous redraw rectangle */ | ||||
| rcti current_r; /* current redraw rectangle */ | rcti current_r; /* current redraw rectangle */ | ||||
| } StrokeCache; | } StrokeCache; | ||||
| /*Color lock Vpaint*/ | |||||
| typedef struct ColorLock { | |||||
| bool lock_red; | |||||
| bool lock_green; | |||||
| bool lock_blue; | |||||
| bool lock_alpha; | |||||
| }ColorLock; | |||||
mont29: Hrmmm… Am wondering why use a struct for that??? To me looks like a set of (short even) flags… | |||||
| void sculpt_cache_free(StrokeCache *cache); | void sculpt_cache_free(StrokeCache *cache); | ||||
| SculptUndoNode *sculpt_undo_push_node(Object *ob, PBVHNode *node, SculptUndoType type); | SculptUndoNode *sculpt_undo_push_node(Object *ob, PBVHNode *node, SculptUndoType type); | ||||
| SculptUndoNode *sculpt_undo_get_node(PBVHNode *node); | SculptUndoNode *sculpt_undo_get_node(PBVHNode *node); | ||||
| void sculpt_undo_push_begin(const char *name); | void sculpt_undo_push_begin(const char *name); | ||||
| void sculpt_undo_push_end(const struct bContext *C); | void sculpt_undo_push_end(const struct bContext *C); | ||||
| void sculpt_vertcos_to_key(Object *ob, KeyBlock *kb, float (*vertCos)[3]); | void sculpt_vertcos_to_key(Object *ob, KeyBlock *kb, float (*vertCos)[3]); | ||||
| void sculpt_update_object_bounding_box(struct Object *ob); | void sculpt_update_object_bounding_box(struct Object *ob); | ||||
| bool sculpt_get_redraw_rect(struct ARegion *ar, struct RegionView3D *rv3d, Object *ob, rcti *rect); | bool sculpt_get_redraw_rect(struct ARegion *ar, struct RegionView3D *rv3d, Object *ob, rcti *rect); | ||||
| #define SCULPT_THREADED_LIMIT 4 | #define SCULPT_THREADED_LIMIT 4 | ||||
| #endif | #endif | ||||
Hrmmm… Am wondering why use a struct for that??? To me looks like a set of (short even) flags would have been more than enough? I think we rather use bitflags than bools in Blender code in such cases usually…
Also, space on last line