Blender
V5.0
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
8
9
#pragma once
10
11
#include "
BLI_math_vector_types.hh
"
12
#include "
BLI_vector.hh
"
13
14
struct
GPUMaterial
;
15
struct
Object
;
16
namespace
blender::gpu
{
17
class
Batch;
18
}
19
20
namespace
blender::draw
{
21
22
#define SCULPT_DEBUG_DRAW (G.debug_value == 889)
23
24
struct
SculptBatch
{
25
gpu::Batch *
batch
;
26
int
material_slot
;
27
int
debug_index
;
28
float3
debug_color
();
29
};
30
31
enum
SculptBatchFeature
{
32
SCULPT_BATCH_DEFAULT
= 0,
33
SCULPT_BATCH_WIREFRAME
= 1 << 0,
34
SCULPT_BATCH_MASK
= 1 << 1,
35
SCULPT_BATCH_FACE_SET
= 1 << 2,
36
SCULPT_BATCH_VERTEX_COLOR
= 1 << 3,
37
SCULPT_BATCH_UV
= 1 << 4
38
};
39
ENUM_OPERATORS
(
SculptBatchFeature
,
SCULPT_BATCH_UV
);
40
42
Vector<SculptBatch>
sculpt_batches_get
(
const
Object
*ob,
SculptBatchFeature
features);
43
45
Vector<SculptBatch>
sculpt_batches_per_material_get
(
const
Object
*ob,
46
Span<const GPUMaterial *>
materials);
47
48
}
// namespace blender::draw
BLI_math_vector_types.hh
ENUM_OPERATORS
#define ENUM_OPERATORS(_type, _max)
Definition
BLI_utildefines.h:588
BLI_vector.hh
blender::Span
Definition
BLI_span.hh:74
blender::Vector
Definition
BLI_vector.hh:76
blender::draw
Definition
DRW_engine.hh:179
blender::draw::sculpt_batches_get
Vector< SculptBatch > sculpt_batches_get(const Object *ob, SculptBatchFeature features)
Definition
draw_sculpt.cc:156
blender::draw::SculptBatchFeature
SculptBatchFeature
Definition
draw_sculpt.hh:31
blender::draw::SCULPT_BATCH_DEFAULT
@ SCULPT_BATCH_DEFAULT
Definition
draw_sculpt.hh:32
blender::draw::SCULPT_BATCH_VERTEX_COLOR
@ SCULPT_BATCH_VERTEX_COLOR
Definition
draw_sculpt.hh:36
blender::draw::SCULPT_BATCH_FACE_SET
@ SCULPT_BATCH_FACE_SET
Definition
draw_sculpt.hh:35
blender::draw::SCULPT_BATCH_UV
@ SCULPT_BATCH_UV
Definition
draw_sculpt.hh:37
blender::draw::SCULPT_BATCH_WIREFRAME
@ SCULPT_BATCH_WIREFRAME
Definition
draw_sculpt.hh:33
blender::draw::SCULPT_BATCH_MASK
@ SCULPT_BATCH_MASK
Definition
draw_sculpt.hh:34
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:202
blender::gpu
Definition
blf_internal_types.hh:32
blender::float3
VecBase< float, 3 > float3
Definition
BLI_math_vector_types.hh:619
GPUMaterial
Definition
gpu/intern/gpu_material.cc:63
Object
Definition
DNA_object_types.h:191
blender::draw::SculptBatch
Definition
draw_sculpt.hh:24
blender::draw::SculptBatch::material_slot
int material_slot
Definition
draw_sculpt.hh:26
blender::draw::SculptBatch::batch
gpu::Batch * batch
Definition
draw_sculpt.hh:25
blender::draw::SculptBatch::debug_index
int debug_index
Definition
draw_sculpt.hh:27
blender::draw::SculptBatch::debug_color
float3 debug_color()
Definition
draw_sculpt.cc:33
Generated on
for Blender by
doxygen
1.16.1