Blender V5.3
DNA_linestyle_types.h
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2010 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
5#pragma once
6
10
11#include "BLI_math_constants.hh"
12
13#include "DNA_ID.h"
14#include "DNA_listBase.h"
15#include "DNA_texture_types.h"
16
17#include "BLI_enum_flags.hh"
18
19namespace blender {
20
21#ifndef MAX_MTEX
22# define MAX_MTEX 18
23#endif
24
25/* texco (also in DNA_material_types.h) */
26#define TEXCO_STROKE 16 /* actually its UV */
27
28struct AnimData;
29struct ColorBand;
30struct CurveMapping;
31struct MTex;
32struct Object;
33struct bNodeTree;
34
62
69
70
75
76
82
83
88
89
100
101/* mat_attr */
119
126
127
134
135
143
154
156enum eLineStyle_Flag : int {
157 LS_DS_EXPAND = 1 << 0, /* for animation editors */
168 LS_NO_SORTING = 1 << 11,
169 LS_REVERSE_ORDER = 1 << 12, /* for sorting */
170 LS_TEXTURE = 1 << 13,
171 LS_CHAIN_COUNT = 1 << 14,
172};
174
175
180
187
196
204
213
225
226/* Along Stroke modifiers */
227
235
245
256
257/* Distance from Camera modifiers */
258
267
278
290
291/* Distance from Object modifiers */
292
302
314
327
328/* 3D curvature modifiers */
329
339
350
362
363/* Noise modifiers (for color, alpha and thickness) */
364
375
386
396
397/* Crease Angle modifiers */
398
407
418
430
431/* Tangent modifiers */
432
440
450
461
462/* Material modifiers */
463
473
483
494
495/* Geometry modifiers */
496
505
514
523
533
546
559
568
577
586
595
608
617
631
640
641/* Calligraphic thickness modifier */
642
653
655#ifdef __cplusplus
658 static constexpr ID_Type id_type = ID_LS;
659#endif
660
662 struct AnimData *adt = nullptr;
663
664 float r = 0, g = 0, b = 0, alpha = 1.0f;
665 float thickness = 3.0f;
667 float thickness_ratio = 0.5f;
671 unsigned int rounds = 3;
672 float split_length = 100;
674 float min_angle = DEG2RADF(0.0f), max_angle = DEG2RADF(0.0f);
675 float min_length = 0.0f, max_length = 10000.0f;
676 unsigned int chain_count = 10;
677 unsigned short split_dash1 = 0, split_gap1 = 0;
678 unsigned short split_dash2 = 0, split_gap2 = 0;
679 unsigned short split_dash3 = 0, split_gap3 = 0;
682 float texstep = 1.0f;
684 short use_nodes = 0;
685 char _pad[6] = {};
686 unsigned short dash1 = 0, gap1 = 0, dash2 = 0, gap2 = 0, dash3 = 0, gap3 = 0;
689 struct MTex *mtex[/*MAX_MTEX*/ 18] = {};
690 /* nodes */
691 struct bNodeTree *nodetree = nullptr;
692
693 ListBaseT<LineStyleModifier> color_modifiers = {nullptr, nullptr};
694 ListBaseT<LineStyleModifier> alpha_modifiers = {nullptr, nullptr};
695 ListBaseT<LineStyleModifier> thickness_modifiers = {nullptr, nullptr};
696 ListBaseT<LineStyleModifier> geometry_modifiers = {nullptr, nullptr};
697};
698
699} // namespace blender
#define ENUM_OPERATORS(_enum_type)
#define DEG2RADF(_deg)
ID and Library types, which are fundamental for SDNA.
#define DNA_DEFINE_CXX_METHODS(class_name)
Definition DNA_defs.h:104
These structs are the foundation for all linked lists in the library system.
BMesh Iterators.
@ LS_SORT_KEY_DISTANCE_FROM_CAMERA
@ LS_MODIFIER_2D_TRANSFORM_PIVOT_PARAM
@ LS_MODIFIER_2D_TRANSFORM_PIVOT_CENTER
@ LS_MODIFIER_2D_TRANSFORM_PIVOT_ABSOLUTE
@ LS_MODIFIER_2D_TRANSFORM_PIVOT_START
@ LS_MODIFIER_2D_TRANSFORM_PIVOT_END
@ LS_MODIFIER_BLUEPRINT_SQUARES
@ LS_MODIFIER_BLUEPRINT_CIRCLES
@ LS_MODIFIER_BLUEPRINT_ELLIPSES
@ LS_MODIFIER_MATERIAL_SPEC_HARD
@ LS_MODIFIER_SPATIAL_NOISE_SMOOTH
@ LS_MODIFIER_SPATIAL_NOISE_PURERANDOM
@ LS_MODIFIER_PERLIN_NOISE_2D
@ LS_MODIFIER_BACKBONE_STRETCHER
@ LS_MODIFIER_PERLIN_NOISE_1D
@ LS_MODIFIER_DISTANCE_FROM_CAMERA
@ LS_MODIFIER_DISTANCE_FROM_OBJECT
@ LS_MODIFIER_SINUS_DISPLACEMENT
eLineStyleAlphaThicknessModifier_Flag
ListBaseT< LineStyleModifier > color_modifiers
ListBaseT< LineStyleModifier > alpha_modifiers
ListBaseT< LineStyleModifier > thickness_modifiers
eLineStyle_IntegrationType integration_type
eLineStyle_ThicknessPosition thickness_position
ListBaseT< LineStyleModifier > geometry_modifiers
eLineStyleAlphaThicknessModifier_Flag flags
eLineStyleAlphaThicknessModifier_Flag flags
eLineStyleAlphaThicknessModifier_Flag flags
eLineStyleAlphaThicknessModifier_Flag flags
eLineStyleAlphaThicknessModifier_Flag flags
eLineStyleAlphaThicknessModifier_Flag flags
struct LineStyleModifier * next
eLineStyleModifier_Flag flags
struct LineStyleModifier * prev
eLineStyleModifier_Type type
eLineStyleAlphaThicknessModifier_Flag flags
eLineStyleAlphaThicknessModifier_Flag flags
eLineStyleAlphaThicknessModifier_Flag flags
eLineStyleAlphaThicknessModifier_Flag flags
eLineStyleAlphaThicknessModifier_Flag flags