Blender
V5.3
source
blender
draw
intern
shaders
draw_view.bsl.hh
Go to the documentation of this file.
1
/* SPDX-FileCopyrightText: 2018-2023 Blender Authors
2
*
3
* SPDX-License-Identifier: GPL-2.0-or-later */
4
8
9
#pragma once
10
11
#include "
draw_shader_shared.hh
"
12
13
namespace
draw
{
14
15
struct
View
{
16
[[
uniform
(
DRW_VIEW_UBO_SLOT
)]]
const
ViewMatrices
(&
view_buf
)[64];
17
18
/* `view_id` should be the result of `draw::ID::view_id()` or manually indexed view. */
19
ViewMatrices
get
(uint view_id)
const
20
{
21
return
view_buf
[view_id];
22
}
23
};
24
25
}
// namespace draw
DRW_VIEW_UBO_SLOT
#define DRW_VIEW_UBO_SLOT
Definition
draw_defines.hh:15
draw_shader_shared.hh
uniform
#define uniform(slot)
Definition
gpu_shader_cxx_attribute.hh:117
draw
Definition
select_lib.bsl.hh:10
ViewMatrices
Definition
draw_shader_shared.hh:133
draw::View
Definition
draw_view.bsl.hh:15
draw::View::view_buf
const ViewMatrices(& view_buf)[64]
Definition
draw_view.bsl.hh:16
draw::View::get
ViewMatrices get(uint view_id) const
Definition
draw_view.bsl.hh:19
Generated on
for Blender by
doxygen
1.18.0