Blender
V5.3
source
blender
animrig
ANIM_armature_iter.hh
Go to the documentation of this file.
1
/* SPDX-FileCopyrightText: 2023 Blender Authors
2
*
3
* SPDX-License-Identifier: GPL-2.0-or-later */
4
10
11
#pragma once
12
13
#include "
DNA_armature_types.h
"
14
15
#include "
BLI_listbase_wrapper.hh
"
16
17
namespace
blender::animrig
{
26
template
<
typename
CB>
static
void
ANIM_armature_foreach_bone
(ListBaseT<Bone> *bones,
CB
callback)
27
{
28
for
(
Bone
*bone :
ListBaseWrapper<Bone>
(bones)) {
29
callback(bone);
30
ANIM_armature_foreach_bone
(&bone->childbase, callback);
31
}
32
}
33
42
template
<
typename
CB>
43
static
void
ANIM_armature_foreach_bone
(
const
ListBaseT<Bone> *bones,
CB
callback)
44
{
45
for
(
const
Bone
*bone :
ConstListBaseWrapper<Bone>
(bones)) {
46
callback(bone);
47
ANIM_armature_foreach_bone
(&bone->childbase, callback);
48
}
49
}
50
51
};
// namespace blender::animrig
BLI_listbase_wrapper.hh
DNA_armature_types.h
CB
#define CB(a)
blender::animrig
Definition
ANIM_action.hh:39
blender::animrig::ANIM_armature_foreach_bone
static void ANIM_armature_foreach_bone(ListBaseT< Bone > *bones, CB callback)
Definition
ANIM_armature_iter.hh:26
blender::ConstListBaseWrapper
ListBaseWrapperTemplate< const ListBase, const T > ConstListBaseWrapper
Definition
BLI_listbase_wrapper.hh:100
blender::ListBaseWrapper
ListBaseWrapperTemplate< ListBase, T > ListBaseWrapper
Definition
BLI_listbase_wrapper.hh:99
blender::Bone
Definition
DNA_armature_types.h:302
Generated on
for Blender by
doxygen
1.18.0