96 if (cd_fmap_offset != -1) {
122 for (
int i = 0; i < me->
totpoly; i++) {
191 ot->
name =
"Add Face Map";
192 ot->
idname =
"OBJECT_OT_face_map_add";
220 ot->
name =
"Remove Face Map";
221 ot->
idname =
"OBJECT_OT_face_map_remove";
222 ot->
description =
"Remove a face map from the active object";
269 ot->
name =
"Assign Face Map";
270 ot->
idname =
"OBJECT_OT_face_map_assign";
293 int mapindex = ob->
actfmap - 1;
319 ot->
name =
"Remove from Face Map";
320 ot->
idname =
"OBJECT_OT_face_map_remove_from";
339 int mapindex = ob->
actfmap - 1;
350 if (*
map == mapindex) {
374 ot->
name =
"Select Face Map Faces";
375 ot->
idname =
"OBJECT_OT_face_map_select";
404 ot->
name =
"Deselect Face Map Faces";
405 ot->
idname =
"OBJECT_OT_face_map_deselect";
432 int pos2 = pos1 - dir;
438 for (
int i = 0; i <
len; i++) {
473 {1,
"UP", 0,
"Up",
""},
474 {-1,
"DOWN", 0,
"Down",
""},
479 ot->
name =
"Move Face Map";
480 ot->
idname =
"OBJECT_OT_face_map_move";
481 ot->
description =
"Move the active face map up/down in the list";
491 ot->
srna,
"direction", fmap_slot_move, 0,
"Direction",
"Direction to move, up or down");
CustomData interface, see also DNA_customdata_types.h.
bool CustomData_has_layer(const struct CustomData *data, int type)
void * CustomData_get_layer(const struct CustomData *data, int type)
void * CustomData_add_layer(struct CustomData *data, int type, eCDAllocType alloctype, void *layer, int totelem)
int CustomData_get_offset(const struct CustomData *data, int type)
General operations, lookup, etc. for blender objects.
bool BKE_object_is_in_editmode(const struct Object *ob)
Functions for dealing with object face-maps.
void BKE_object_facemap_remove(struct Object *ob, struct bFaceMap *fmap)
struct bFaceMap * BKE_object_facemap_add(struct Object *ob)
void BLI_insertlinkafter(struct ListBase *listbase, void *vprevlink, void *vnewlink) ATTR_NONNULL(1)
void BLI_remlink(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
int BLI_findindex(const struct ListBase *listbase, const void *vlink) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void BLI_insertlinkbefore(struct ListBase *listbase, void *vnextlink, void *vnewlink) ATTR_NONNULL(1)
void * BLI_findlink(const struct ListBase *listbase, int number) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
int BLI_listbase_count(const struct ListBase *listbase) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void range_vn_i(int *array_tar, int size, int start)
#define IN_RANGE(a, b, c)
void DEG_id_tag_update(struct ID *id, int flag)
#define ID_IS_LINKED(_id)
#define ID_IS_OVERRIDE_LIBRARY(_id)
Object is a sort of wrapper for general info.
struct Object * ED_object_context(const struct bContext *C)
Read Guarded memory(de)allocation.
__forceinline const avxb select(const avxb &m, const avxb &t, const avxb &f)
#define BM_ELEM_CD_GET_VOID_P(ele, offset)
#define BM_elem_flag_test(ele, hflag)
void BM_data_layer_add(BMesh *bm, CustomData *data, int type)
#define BM_ITER_MESH(ele, iter, bm, itype)
void BM_face_select_set(BMesh *bm, BMFace *f, const bool select)
Select Face.
return(oflags[bm->toolflag_index].f &oflag) !=0
ccl_gpu_kernel_postfix ccl_global float int int int int float bool int offset
void(* MEM_freeN)(void *vmemh)
void *(* MEM_mallocN)(size_t len, const char *str)
SymEdge< T > * prev(const SymEdge< T > *se)
SocketIndexByIdentifierMap * map
void OBJECT_OT_face_map_remove_from(struct wmOperatorType *ot)
void ED_object_facemap_face_remove(Object *ob, bFaceMap *fmap, int facenum)
static int face_map_remove_from_exec(bContext *C, wmOperator *UNUSED(op))
void OBJECT_OT_face_map_remove(struct wmOperatorType *ot)
static bool face_map_supported_remove_poll(bContext *C)
void ED_object_facemap_face_add(Object *ob, bFaceMap *fmap, int facenum)
void OBJECT_OT_face_map_move(wmOperatorType *ot)
static void fmap_select(Object *ob, bool select)
static void object_fmap_remap_edit_mode(Object *ob, const int *remap)
static bool face_map_supported_poll(bContext *C)
static int face_map_select_exec(bContext *C, wmOperator *UNUSED(op))
void OBJECT_OT_face_map_select(struct wmOperatorType *ot)
static int face_map_remove_exec(bContext *C, wmOperator *UNUSED(op))
static int face_map_deselect_exec(bContext *C, wmOperator *UNUSED(op))
static int face_map_assign_exec(bContext *C, wmOperator *UNUSED(op))
static void object_fmap_remap_object_mode(Object *ob, const int *remap)
static int face_map_move_exec(bContext *C, wmOperator *op)
void OBJECT_OT_face_map_add(struct wmOperatorType *ot)
static void object_facemap_remap(Object *ob, const int *remap)
static int face_map_add_exec(bContext *C, wmOperator *UNUSED(op))
static bool face_map_supported_edit_mode_poll(bContext *C)
void OBJECT_OT_face_map_assign(struct wmOperatorType *ot)
void OBJECT_OT_face_map_deselect(struct wmOperatorType *ot)
int RNA_enum_get(PointerRNA *ptr, const char *name)
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, int default_value, const char *ui_name, const char *ui_description)
struct BMEditMesh * edit_mesh
bool(* poll)(struct bContext *) ATTR_WARN_UNUSED_RESULT
int(* exec)(struct bContext *, struct wmOperator *) ATTR_WARN_UNUSED_RESULT
void WM_event_add_notifier(const bContext *C, uint type, void *reference)