Welcome to mirror list, hosted at ThFree Co, Russian Federation.

RNA_enum_types.h « makesrna « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: d544083a749b48b041be489087fe67537c8f577b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
/*
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 */

#pragma once

/** \file
 * \ingroup RNA
 */

#include "RNA_types.h"

#ifdef __cplusplus
extern "C" {
#endif

struct ID;
struct bNodeSocketType;
struct bNodeTreeType;
struct bNodeType;

/* Types */

/* use in cases where only dynamic types are used */
extern const EnumPropertyItem DummyRNA_NULL_items[];
extern const EnumPropertyItem DummyRNA_DEFAULT_items[];

/* all others should follow 'rna_enum_*_items' naming */
extern const EnumPropertyItem rna_enum_id_type_items[];

extern const EnumPropertyItem rna_enum_object_mode_items[];
extern const EnumPropertyItem rna_enum_workspace_object_mode_items[];
extern const EnumPropertyItem rna_enum_object_empty_drawtype_items[];
extern const EnumPropertyItem rna_enum_object_gpencil_type_items[];
extern const EnumPropertyItem rna_enum_metaelem_type_items[];

extern const EnumPropertyItem rna_enum_proportional_falloff_items[];
extern const EnumPropertyItem rna_enum_proportional_falloff_curve_only_items[];
extern const EnumPropertyItem rna_enum_snap_target_items[];
extern const EnumPropertyItem rna_enum_snap_element_items[];
extern const EnumPropertyItem rna_enum_snap_node_element_items[];
extern const EnumPropertyItem rna_enum_curve_fit_method_items[];
extern const EnumPropertyItem rna_enum_mesh_select_mode_items[];
extern const EnumPropertyItem rna_enum_mesh_select_mode_uv_items[];
extern const EnumPropertyItem rna_enum_mesh_delimit_mode_items[];
extern const EnumPropertyItem rna_enum_space_graph_mode_items[];
extern const EnumPropertyItem rna_enum_space_file_browse_mode_items[];
extern const EnumPropertyItem rna_enum_space_sequencer_view_type_items[];
extern const EnumPropertyItem rna_enum_space_type_items[];
extern const EnumPropertyItem rna_enum_space_image_mode_items[];
extern const EnumPropertyItem rna_enum_space_image_mode_all_items[];
extern const EnumPropertyItem rna_enum_space_action_mode_items[];
extern const EnumPropertyItem rna_enum_fileselect_params_sort_items[];
extern const EnumPropertyItem rna_enum_region_type_items[];
extern const EnumPropertyItem rna_enum_object_modifier_type_items[];
extern const EnumPropertyItem rna_enum_constraint_type_items[];
extern const EnumPropertyItem rna_enum_boidrule_type_items[];
extern const EnumPropertyItem rna_enum_sequence_modifier_type_items[];
extern const EnumPropertyItem rna_enum_object_greasepencil_modifier_type_items[];
extern const EnumPropertyItem rna_enum_object_shaderfx_type_items[];

extern const EnumPropertyItem rna_enum_modifier_triangulate_quad_method_items[];
extern const EnumPropertyItem rna_enum_modifier_triangulate_ngon_method_items[];
extern const EnumPropertyItem rna_enum_modifier_shrinkwrap_mode_items[];

extern const EnumPropertyItem rna_enum_image_type_items[];
extern const EnumPropertyItem rna_enum_image_color_mode_items[];
extern const EnumPropertyItem rna_enum_image_color_depth_items[];
extern const EnumPropertyItem rna_enum_image_generated_type_items[];

extern const EnumPropertyItem rna_enum_normal_space_items[];
extern const EnumPropertyItem rna_enum_normal_swizzle_items[];
extern const EnumPropertyItem rna_enum_bake_save_mode_items[];
extern const EnumPropertyItem rna_enum_bake_target_items[];

extern const EnumPropertyItem rna_enum_views_format_items[];
extern const EnumPropertyItem rna_enum_views_format_multilayer_items[];
extern const EnumPropertyItem rna_enum_views_format_multiview_items[];
extern const EnumPropertyItem rna_enum_stereo3d_display_items[];
extern const EnumPropertyItem rna_enum_stereo3d_anaglyph_type_items[];
extern const EnumPropertyItem rna_enum_stereo3d_interlace_type_items[];

extern const EnumPropertyItem rna_enum_exr_codec_items[];
extern const EnumPropertyItem rna_enum_color_sets_items[];

extern const EnumPropertyItem rna_enum_beztriple_keyframe_type_items[];
extern const EnumPropertyItem rna_enum_beztriple_interpolation_mode_items[];
extern const EnumPropertyItem rna_enum_beztriple_interpolation_easing_items[];
extern const EnumPropertyItem rna_enum_fcurve_auto_smoothing_items[];
extern const EnumPropertyItem rna_enum_keyframe_handle_type_items[];
extern const EnumPropertyItem rna_enum_driver_target_rotation_mode_items[];

extern const EnumPropertyItem rna_enum_keyblock_type_items[];

extern const EnumPropertyItem rna_enum_keyingset_path_grouping_items[];
extern const EnumPropertyItem rna_enum_keying_flag_items[];
extern const EnumPropertyItem rna_enum_keying_flag_items_api[];

extern const EnumPropertyItem rna_enum_keyframe_paste_offset_items[];
extern const EnumPropertyItem rna_enum_keyframe_paste_merge_items[];

extern const EnumPropertyItem rna_enum_fmodifier_type_items[];

extern const EnumPropertyItem rna_enum_nla_mode_extend_items[];
extern const EnumPropertyItem rna_enum_nla_mode_blend_items[];

extern const EnumPropertyItem rna_enum_motionpath_bake_location_items[];

extern const EnumPropertyItem rna_enum_event_value_all_items[];
extern const EnumPropertyItem rna_enum_event_value_keymouse_items[];
extern const EnumPropertyItem rna_enum_event_value_tweak_items[];

extern const EnumPropertyItem rna_enum_event_type_items[];
extern const EnumPropertyItem rna_enum_event_type_mask_items[];

extern const EnumPropertyItem rna_enum_operator_type_flag_items[];
extern const EnumPropertyItem rna_enum_operator_return_items[];
extern const EnumPropertyItem rna_enum_operator_property_tags[];

extern const EnumPropertyItem rna_enum_brush_sculpt_tool_items[];
extern const EnumPropertyItem rna_enum_brush_uv_sculpt_tool_items[];
extern const EnumPropertyItem rna_enum_brush_vertex_tool_items[];
extern const EnumPropertyItem rna_enum_brush_weight_tool_items[];
extern const EnumPropertyItem rna_enum_brush_gpencil_types_items[];
extern const EnumPropertyItem rna_enum_brush_gpencil_vertex_types_items[];
extern const EnumPropertyItem rna_enum_brush_gpencil_sculpt_types_items[];
extern const EnumPropertyItem rna_enum_brush_gpencil_weight_types_items[];
extern const EnumPropertyItem rna_enum_brush_image_tool_items[];

extern const EnumPropertyItem rna_enum_particle_edit_hair_brush_items[];
extern const EnumPropertyItem rna_enum_particle_edit_disconnected_hair_brush_items[];

extern const EnumPropertyItem rna_enum_uv_sculpt_tool_items[];

extern const EnumPropertyItem rna_enum_axis_xy_items[];
extern const EnumPropertyItem rna_enum_axis_xyz_items[];

extern const EnumPropertyItem rna_enum_axis_flag_xyz_items[];

extern const EnumPropertyItem rna_enum_symmetrize_direction_items[];

extern const EnumPropertyItem rna_enum_texture_type_items[];

extern const EnumPropertyItem rna_enum_light_type_items[];

extern const EnumPropertyItem rna_enum_lightprobes_type_items[];

extern const EnumPropertyItem rna_enum_unpack_method_items[];

extern const EnumPropertyItem rna_enum_object_type_items[];
extern const EnumPropertyItem rna_enum_object_rotation_mode_items[];

extern const EnumPropertyItem rna_enum_object_type_curve_items[];

extern const EnumPropertyItem rna_enum_rigidbody_object_type_items[];
extern const EnumPropertyItem rna_enum_rigidbody_object_shape_items[];
extern const EnumPropertyItem rna_enum_rigidbody_constraint_type_items[];

extern const EnumPropertyItem rna_enum_object_axis_items[];

extern const EnumPropertyItem rna_enum_controller_type_items[];

extern const EnumPropertyItem rna_enum_render_pass_type_items[];
extern const EnumPropertyItem rna_enum_render_pass_debug_type_items[];

extern const EnumPropertyItem rna_enum_bake_pass_type_items[];
extern const EnumPropertyItem rna_enum_bake_pass_filter_type_items[];

extern const EnumPropertyItem rna_enum_keymap_propvalue_items[];

extern const EnumPropertyItem rna_enum_operator_context_items[];

extern const EnumPropertyItem rna_enum_wm_report_items[];

extern const EnumPropertyItem rna_enum_transform_pivot_items_full[];
extern const EnumPropertyItem rna_enum_transform_orientation_items[];
extern const EnumPropertyItem rna_enum_transform_mode_types[];

extern const EnumPropertyItem rna_enum_property_type_items[];
extern const EnumPropertyItem rna_enum_property_subtype_items[];
extern const EnumPropertyItem rna_enum_property_unit_items[];

extern const EnumPropertyItem rna_enum_shading_type_items[];

extern const EnumPropertyItem rna_enum_navigation_mode_items[];

extern const EnumPropertyItem rna_enum_node_socket_in_out_items[];

extern const EnumPropertyItem rna_enum_node_math_items[];
extern const EnumPropertyItem rna_enum_mapping_type_items[];
extern const EnumPropertyItem rna_enum_node_vec_math_items[];
extern const EnumPropertyItem rna_enum_node_boolean_math_items[];
extern const EnumPropertyItem rna_enum_node_float_compare_items[];
extern const EnumPropertyItem rna_enum_node_filter_items[];
extern const EnumPropertyItem rna_enum_node_float_to_int_items[];
extern const EnumPropertyItem rna_enum_node_map_range_items[];
extern const EnumPropertyItem rna_enum_node_clamp_items[];

extern const EnumPropertyItem rna_enum_ramp_blend_items[];

extern const EnumPropertyItem rna_enum_prop_dynamicpaint_type_items[];

extern const EnumPropertyItem rna_enum_clip_editor_mode_items[];

extern const EnumPropertyItem rna_enum_icon_items[];
extern const EnumPropertyItem rna_enum_uilist_layout_type_items[];

extern const EnumPropertyItem rna_enum_linestyle_color_modifier_type_items[];
extern const EnumPropertyItem rna_enum_linestyle_alpha_modifier_type_items[];
extern const EnumPropertyItem rna_enum_linestyle_thickness_modifier_type_items[];
extern const EnumPropertyItem rna_enum_linestyle_geometry_modifier_type_items[];

extern const EnumPropertyItem rna_enum_window_cursor_items[];

extern const EnumPropertyItem rna_enum_dt_method_vertex_items[];
extern const EnumPropertyItem rna_enum_dt_method_edge_items[];
extern const EnumPropertyItem rna_enum_dt_method_loop_items[];
extern const EnumPropertyItem rna_enum_dt_method_poly_items[];
extern const EnumPropertyItem rna_enum_dt_mix_mode_items[];
extern const EnumPropertyItem rna_enum_dt_layers_select_src_items[];
extern const EnumPropertyItem rna_enum_dt_layers_select_dst_items[];

extern const EnumPropertyItem rna_enum_context_mode_items[];

extern const EnumPropertyItem rna_enum_curveprofile_preset_items[];
extern const EnumPropertyItem rna_enum_preference_section_items[];

extern const EnumPropertyItem rna_enum_attribute_type_items[];
extern const EnumPropertyItem rna_enum_attribute_type_with_auto_items[];
extern const EnumPropertyItem rna_enum_attribute_domain_items[];
extern const EnumPropertyItem rna_enum_attribute_domain_with_auto_items[];
extern const EnumPropertyItem *rna_enum_attribute_domain_itemf(struct ID *id, bool *r_free);

extern const EnumPropertyItem rna_enum_collection_color_items[];

/**
 * For ID filters (#FILTER_ID_AC, #FILTER_ID_AR, ...) an int isn't enough. This version allows 64
 * bit integers. So can't use the regular #EnumPropertyItem. Would be nice if RNA supported this
 * itself.
 *
 * Meant to be used with #RNA_def_property_boolean_sdna() which supports 64 bit flags as well.
 */
struct IDFilterEnumPropertyItem {
  const uint64_t flag;
  const char *identifier;
  const int icon;
  const char *name;
  const char *description;
};
extern const struct IDFilterEnumPropertyItem rna_enum_id_type_filter_items[];

/* API calls */
int rna_node_tree_type_to_enum(struct bNodeTreeType *typeinfo);
int rna_node_tree_idname_to_enum(const char *idname);
struct bNodeTreeType *rna_node_tree_type_from_enum(int value);
const EnumPropertyItem *rna_node_tree_type_itemf(void *data,
                                                 bool (*poll)(void *data, struct bNodeTreeType *),
                                                 bool *r_free);

int rna_node_type_to_enum(struct bNodeType *typeinfo);
int rna_node_idname_to_enum(const char *idname);
struct bNodeType *rna_node_type_from_enum(int value);
const EnumPropertyItem *rna_node_type_itemf(void *data,
                                            bool (*poll)(void *data, struct bNodeType *),
                                            bool *r_free);

int rna_node_socket_type_to_enum(struct bNodeSocketType *typeinfo);
int rna_node_socket_idname_to_enum(const char *idname);
struct bNodeSocketType *rna_node_socket_type_from_enum(int value);
const EnumPropertyItem *rna_node_socket_type_itemf(
    void *data, bool (*poll)(void *data, struct bNodeSocketType *), bool *r_free);

struct PointerRNA;
struct PropertyRNA;
struct bContext;

const EnumPropertyItem *rna_TransformOrientation_itemf(struct bContext *C,
                                                       struct PointerRNA *ptr,
                                                       struct PropertyRNA *prop,
                                                       bool *r_free);

/* Generic functions, return an enum from library data, index is the position
 * in the linked list can add more for different types as needed */
const EnumPropertyItem *RNA_action_itemf(struct bContext *C,
                                         struct PointerRNA *ptr,
                                         struct PropertyRNA *prop,
                                         bool *r_free);
#if 0
EnumPropertyItem *RNA_action_local_itemf(struct bContext *C,
                                         struct PointerRNA *ptr,
                                         struct PropertyRNA *prop,
                                         bool *r_free);
#endif
const EnumPropertyItem *RNA_collection_itemf(struct bContext *C,
                                             struct PointerRNA *ptr,
                                             struct PropertyRNA *prop,
                                             bool *r_free);
const EnumPropertyItem *RNA_collection_local_itemf(struct bContext *C,
                                                   struct PointerRNA *ptr,
                                                   struct PropertyRNA *prop,
                                                   bool *r_free);
const EnumPropertyItem *RNA_image_itemf(struct bContext *C,
                                        struct PointerRNA *ptr,
                                        struct PropertyRNA *prop,
                                        bool *r_free);
const EnumPropertyItem *RNA_image_local_itemf(struct bContext *C,
                                              struct PointerRNA *ptr,
                                              struct PropertyRNA *prop,
                                              bool *r_free);
const EnumPropertyItem *RNA_scene_itemf(struct bContext *C,
                                        struct PointerRNA *ptr,
                                        struct PropertyRNA *prop,
                                        bool *r_free);
const EnumPropertyItem *RNA_scene_without_active_itemf(struct bContext *C,
                                                       struct PointerRNA *ptr,
                                                       struct PropertyRNA *prop,
                                                       bool *r_free);
const EnumPropertyItem *RNA_scene_local_itemf(struct bContext *C,
                                              struct PointerRNA *ptr,
                                              struct PropertyRNA *prop,
                                              bool *r_free);
const EnumPropertyItem *RNA_movieclip_itemf(struct bContext *C,
                                            struct PointerRNA *ptr,
                                            struct PropertyRNA *prop,
                                            bool *r_free);
const EnumPropertyItem *RNA_movieclip_local_itemf(struct bContext *C,
                                                  struct PointerRNA *ptr,
                                                  struct PropertyRNA *prop,
                                                  bool *r_free);
const EnumPropertyItem *RNA_mask_itemf(struct bContext *C,
                                       struct PointerRNA *ptr,
                                       struct PropertyRNA *prop,
                                       bool *r_free);
const EnumPropertyItem *RNA_mask_local_itemf(struct bContext *C,
                                             struct PointerRNA *ptr,
                                             struct PropertyRNA *prop,
                                             bool *r_free);

/* Non confirming, utility function. */
const EnumPropertyItem *RNA_enum_node_tree_types_itemf_impl(struct bContext *C, bool *r_free);

#ifdef __cplusplus
}
#endif