Blender
V4.3
source
blender
editors
space_outliner
tree
tree_element_id_linestyle.cc
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
#include "
DNA_ID.h
"
10
#include "
DNA_linestyle_types.h
"
11
#include "
DNA_listBase.h
"
12
#include "
DNA_outliner_types.h
"
13
#include "
DNA_texture_types.h
"
14
15
#include "
../outliner_intern.hh
"
16
17
#include "
tree_element_id_linestyle.hh
"
18
19
namespace
blender::ed::outliner
{
20
21
TreeElementIDLineStyle::TreeElementIDLineStyle
(
TreeElement
&legacy_te,
22
FreestyleLineStyle
&
linestyle
)
23
:
TreeElementID
(legacy_te,
linestyle
.id), linestyle_(
linestyle
)
24
{
25
}
26
27
void
TreeElementIDLineStyle::expand
(
SpaceOutliner
&
/*space_outliner*/
)
const
28
{
29
expand_animation_data
(linestyle_.
adt
);
30
31
expand_textures();
32
}
33
34
void
TreeElementIDLineStyle::expand_textures()
const
35
{
36
for
(
int
a = 0; a <
MAX_MTEX
; a++) {
37
if
(linestyle_.
mtex
[a]) {
38
add_element
(&
legacy_te_
.
subtree
,
39
reinterpret_cast<
ID
*
>
((linestyle_.
mtex
[a])->tex),
40
nullptr
,
41
&
legacy_te_
,
42
TSE_SOME_ID
,
43
a);
44
}
45
}
46
}
47
48
}
// namespace blender::ed::outliner
DNA_ID.h
ID and Library types, which are fundamental for SDNA.
DNA_linestyle_types.h
DNA_listBase.h
These structs are the foundation for all linked lists in the library system.
DNA_outliner_types.h
TSE_SOME_ID
@ TSE_SOME_ID
Definition
DNA_outliner_types.h:65
DNA_texture_types.h
MAX_MTEX
#define MAX_MTEX
Definition
Stroke.h:33
blender::ed::outliner::AbstractTreeElement::add_element
TreeElement * add_element(ListBase *lb, ID *owner_id, void *create_data, TreeElement *parent, short type, short index, const bool expand=true) const
Definition
tree_element.cc:240
blender::ed::outliner::AbstractTreeElement::legacy_te_
TreeElement & legacy_te_
Definition
tree_element.hh:36
blender::ed::outliner::TreeElementIDLineStyle::TreeElementIDLineStyle
TreeElementIDLineStyle(TreeElement &legacy_te, FreestyleLineStyle &linestyle)
Definition
tree_element_id_linestyle.cc:21
blender::ed::outliner::TreeElementIDLineStyle::expand
void expand(SpaceOutliner &) const override
Definition
tree_element_id_linestyle.cc:27
blender::ed::outliner::TreeElementID
Definition
tree_element_id.hh:20
blender::ed::outliner::TreeElementID::expand_animation_data
void expand_animation_data(AnimData *) const
Definition
tree_element_id.cc:132
linestyle
FreestyleLineStyle linestyle
Definition
deg_eval_copy_on_write.cc:103
blender::ed::outliner
Definition
outliner_collections.cc:42
outliner_intern.hh
FreestyleLineStyle
Definition
DNA_linestyle_types.h:641
FreestyleLineStyle::adt
struct AnimData * adt
Definition
DNA_linestyle_types.h:645
FreestyleLineStyle::mtex
struct MTex * mtex[18]
Definition
DNA_linestyle_types.h:671
ID
Definition
DNA_ID.h:413
SpaceOutliner
Definition
DNA_space_types.h:289
blender::ed::outliner::TreeElement
Definition
outliner_intern.hh:84
blender::ed::outliner::TreeElement::subtree
ListBase subtree
Definition
outliner_intern.hh:95
tree_element_id_linestyle.hh
Generated on Thu Feb 6 2025 07:36:39 for Blender by
doxygen
1.11.0