Blender
V4.3
intern
cycles
kernel
osl
osl/compat.h
Go to the documentation of this file.
1
/* SPDX-FileCopyrightText: 2011-2023 Blender Foundation
2
*
3
* SPDX-License-Identifier: Apache-2.0 */
4
5
#pragma once
6
7
#include <OSL/oslconfig.h>
8
9
CCL_NAMESPACE_BEGIN
10
11
#if OSL_LIBRARY_VERSION_CODE >= 11302
12
typedef
OSL::ustringhash
OSLUStringHash
;
13
typedef
OSL::ustringrep
OSLUStringRep
;
14
15
static
inline
OSL::ustring
to_ustring
(
OSLUStringHash
h)
16
{
17
return
OSL::ustring::from_hash(h.hash());
18
}
19
20
#else
21
typedef
OSL::ustring
OSLUStringHash
;
22
typedef
OSL::ustring
OSLUStringRep
;
23
24
static
inline
OSL::ustring
to_ustring
(
OSLUStringHash
h)
25
{
26
return
h;
27
}
28
#endif
29
30
CCL_NAMESPACE_END
CCL_NAMESPACE_END
#define CCL_NAMESPACE_END
Definition
device/cuda/compat.h:10
CCL_NAMESPACE_BEGIN
Definition
python.cpp:44
to_ustring
static OSL::ustring to_ustring(OSLUStringHash h)
Definition
osl/compat.h:24
OSLUStringHash
CCL_NAMESPACE_BEGIN typedef OSL::ustring OSLUStringHash
Definition
osl/compat.h:21
OSLUStringRep
OSL::ustring OSLUStringRep
Definition
osl/compat.h:22
Generated on Thu Feb 6 2025 07:36:39 for Blender by
doxygen
1.11.0