Blender
V5.0
intern
cycles
util
util/nanovdb.h
Go to the documentation of this file.
1
/* SPDX-FileCopyrightText: Contributors to the OpenVDB Project
2
* SPDX-FileCopyrightText: 2025 Blender Foundation
3
*
4
* SPDX-License-Identifier: Apache-2.0 */
5
6
#pragma once
7
8
#ifdef WITH_NANOVDB
9
10
# include <openvdb/openvdb.h>
11
12
# define NANOVDB_USE_OPENVDB
13
# define NANOVDB_USE_TBB
14
15
# include <nanovdb/NanoVDB.h>
// manages and streams the raw memory buffer of a NanoVDB grid.
16
17
# if NANOVDB_MAJOR_VERSION_NUMBER > 32 || \
18
(NANOVDB_MAJOR_VERSION_NUMBER == 32 && NANOVDB_MINOR_VERSION_NUMBER >= 7)
19
# include <nanovdb/GridHandle.h>
20
# else
21
# include <nanovdb/util/GridHandle.h>
22
# endif
23
24
CCL_NAMESPACE_BEGIN
25
26
/* Convert NanoVDB to OpenVDB mask grid that represents just the topology. */
27
openvdb::MaskGrid::Ptr nanovdb_to_openvdb_mask(
const
nanovdb::GridHandle<> &handle);
28
29
/* Convert OpenVDB to NanoVDB grid. */
30
nanovdb::GridHandle<> openvdb_to_nanovdb(
const
openvdb::GridBase::ConstPtr &grid,
31
const
int
precision,
32
const
float
clipping);
33
34
CCL_NAMESPACE_END
35
36
#endif
CCL_NAMESPACE_END
#define CCL_NAMESPACE_END
Definition
device/cuda/compat.h:10
CCL_NAMESPACE_BEGIN
Definition
python.cpp:37
Generated on
for Blender by
doxygen
1.16.1