Blender V4.3
DNA_object_defaults.h
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
9#pragma once
10
11#include "DNA_vec_defaults.h"
12
13/* clang-format off */
14
15/* -------------------------------------------------------------------- */
19#define _DNA_DEFAULT_Object \
20 { \
21 /* Type is not very meaningful as a default, normally changed. */ \
22 .type = OB_EMPTY, \
23 .color = {1, 1, 1, 1}, \
24 \
25 .constinv = _DNA_DEFAULT_UNIT_M4, \
26 .parentinv = _DNA_DEFAULT_UNIT_M4, \
27 \
28 .scale = {1, 1, 1}, \
29 .dscale = {1, 1, 1}, \
30 /* Objects should default to having Euler XYZ rotations, \
31 * but rotations default to quaternions. */ \
32 .rotmode = ROT_MODE_EUL, \
33 \
34 .rotAxis = {0, 1, 0}, \
35 .rotAngle = 0, \
36 .drotAxis = {0, 1, 0}, \
37 .drotAngle = 0, \
38 .quat = _DNA_DEFAULT_UNIT_QT, \
39 .dquat = _DNA_DEFAULT_UNIT_QT, \
40 .flag = OB_FLAG_USE_SIMULATION_CACHE, \
41 .protectflag = OB_LOCK_ROT4D, \
42 \
43 .dt = OB_TEXTURE, \
44 \
45 .empty_drawtype = OB_PLAINAXES, \
46 .empty_drawsize = 1.0, \
47 .empty_image_depth = OB_EMPTY_IMAGE_DEPTH_DEFAULT, \
48 .ima_ofs = {-0.5, -0.5}, \
49 \
50 .instance_faces_scale = 1, \
51 .col_group = 0x01, \
52 .col_mask = 0xffff, \
53 .preview = NULL, \
54 .duplicator_visibility_flag = OB_DUPLI_FLAG_VIEWPORT | OB_DUPLI_FLAG_RENDER, \
55 .pc_ids = {NULL, NULL}, \
56 .lineart = { .crease_threshold = DEG2RAD(140.0f) }, \
57 }
58
61/* clang-format on */