Blender
V4.3
source
blender
draw
intern
draw_sculpt.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
9
#pragma once
10
11
#include "
draw_manager.hh
"
12
13
namespace
blender::draw
{
14
15
#define SCULPT_DEBUG_DRAW (G.debug_value == 889)
16
17
struct
SculptBatch
{
18
gpu::Batch *
batch
;
19
int
material_slot
;
20
int
debug_index
;
21
float3
debug_color
();
22
};
23
24
enum
SculptBatchFeature
{
25
SCULPT_BATCH_DEFAULT
= 0,
26
SCULPT_BATCH_WIREFRAME
= 1 << 0,
27
SCULPT_BATCH_MASK
= 1 << 1,
28
SCULPT_BATCH_FACE_SET
= 1 << 2,
29
SCULPT_BATCH_VERTEX_COLOR
= 1 << 3,
30
SCULPT_BATCH_UV
= 1 << 4
31
};
32
ENUM_OPERATORS
(
SculptBatchFeature
,
SCULPT_BATCH_UV
);
33
35
Vector<SculptBatch>
sculpt_batches_get
(
const
Object
*ob,
SculptBatchFeature
features);
36
38
Vector<SculptBatch>
sculpt_batches_per_material_get
(
const
Object
*ob,
39
Span<const GPUMaterial *>
materials);
40
41
}
// namespace blender::draw
ENUM_OPERATORS
#define ENUM_OPERATORS(_type, _max)
Definition
BLI_utildefines.h:616
blender::Span
Definition
BLI_span.hh:75
blender::Vector
Definition
BLI_vector.hh:65
draw_manager.hh
blender::draw
Definition
DRW_engine.hh:178
blender::draw::sculpt_batches_get
Vector< SculptBatch > sculpt_batches_get(const Object *ob, SculptBatchFeature features)
Definition
draw_sculpt.cc:133
blender::draw::SculptBatchFeature
SculptBatchFeature
Definition
draw_sculpt.hh:24
blender::draw::SCULPT_BATCH_DEFAULT
@ SCULPT_BATCH_DEFAULT
Definition
draw_sculpt.hh:25
blender::draw::SCULPT_BATCH_VERTEX_COLOR
@ SCULPT_BATCH_VERTEX_COLOR
Definition
draw_sculpt.hh:29
blender::draw::SCULPT_BATCH_FACE_SET
@ SCULPT_BATCH_FACE_SET
Definition
draw_sculpt.hh:28
blender::draw::SCULPT_BATCH_UV
@ SCULPT_BATCH_UV
Definition
draw_sculpt.hh:30
blender::draw::SCULPT_BATCH_WIREFRAME
@ SCULPT_BATCH_WIREFRAME
Definition
draw_sculpt.hh:26
blender::draw::SCULPT_BATCH_MASK
@ SCULPT_BATCH_MASK
Definition
draw_sculpt.hh:27
blender::draw::sculpt_batches_per_material_get
Vector< SculptBatch > sculpt_batches_per_material_get(const Object *ob, Span< const GPUMaterial * > materials)
Definition
draw_sculpt.cc:168
Object
Definition
DNA_object_types.h:193
blender::VecBase< float, 3 >
blender::draw::SculptBatch
Definition
draw_sculpt.hh:17
blender::draw::SculptBatch::material_slot
int material_slot
Definition
draw_sculpt.hh:19
blender::draw::SculptBatch::batch
gpu::Batch * batch
Definition
draw_sculpt.hh:18
blender::draw::SculptBatch::debug_index
int debug_index
Definition
draw_sculpt.hh:20
blender::draw::SculptBatch::debug_color
float3 debug_color()
Definition
draw_sculpt.cc:21
Generated on Thu Feb 6 2025 07:36:39 for Blender by
doxygen
1.11.0