HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
OpenEXRConfig.h
Go to the documentation of this file.
1 // SPDX-License-Identifier: BSD-3-Clause
2 // Copyright (c) Contributors to the OpenEXR Project.
3 
4 // This file is auto-generated by the configure step
5 
6 #ifndef INCLUDED_OPENEXR_CONFIG_H
7 #define INCLUDED_OPENEXR_CONFIG_H 1
8 
9 #pragma once
10 
11 //
12 // Options / configuration based on O.S. / compiler
13 /////////////////////
14 
15 //
16 // Define and set to 1 if the target system has support for large
17 // stack sizes.
18 //
19 /* #undef OPENEXR_HAVE_LARGE_STACK */
20 
21 //////////////////////
22 //
23 // C++ namespace configuration / options
24 
25 //
26 // Current internal library namepace name
27 //
28 #define OPENEXR_IMF_INTERNAL_NAMESPACE_CUSTOM 1
29 #define OPENEXR_IMF_INTERNAL_NAMESPACE Imf_3_1_sidefx
30 
31 //
32 // Current public user namepace name
33 //
34 
35 #define OPENEXR_IMF_NAMESPACE_CUSTOM 1
36 #define OPENEXR_IMF_NAMESPACE Imf
37 
38 //
39 // Version string for runtime access
40 //
41 
42 #define OPENEXR_VERSION_STRING "3.1.5"
43 #define OPENEXR_PACKAGE_STRING "OpenEXR 3.1.5"
44 
45 #define OPENEXR_VERSION_MAJOR 3
46 #define OPENEXR_VERSION_MINOR 1
47 #define OPENEXR_VERSION_PATCH 5
48 #define OPENEXR_VERSION_RELEASE_TYPE ""
49 // Deprecated, for back compatibility:
50 #define OPENEXR_VERSION_EXTRA ""
51 
52 #define OPENEXR_LIB_VERSION_STRING "30.5.1"
53 
54 // Version as a single hex number, e.g. 0x01000300 == 1.0.3
55 #define OPENEXR_VERSION_HEX ((uint32_t(OPENEXR_VERSION_MAJOR) << 24) | \
56  (uint32_t(OPENEXR_VERSION_MINOR) << 16) | \
57  (uint32_t(OPENEXR_VERSION_PATCH) << 8))
58 
59 
60 // On modern versions of gcc & clang, __has_attribute can test support for
61 // __attribute__((attr)). Make sure it's safe for other compilers.
62 #ifndef __has_attribute
63 # define __has_attribute(x) 0
64 #endif
65 
66 
67 // Whether the user configured the library to have symbol visibility
68 // tagged
69 #define OPENEXR_ENABLE_API_VISIBILITY
70 
71 /// \defgroup ExportMacros Macros to manage symbol visibility
72 ///
73 /// See docs/SymbolVisibility.md for more discussion about the
74 /// motivation for these macros
75 ///
76 /// If we are compiling a DLL for Windows, there needs to be custom
77 /// rules for each library such that the macro swaps between doing a
78 /// dllexport and a dllimport, so the defines here are less
79 /// useful. Further, MSVC does not have this concept at all currently,
80 /// so is elided.
81 ///
82 /// The top level macros which start with OPENEXR can act as simple
83 /// ways to combine the logic however for non-DLL or non-windows
84 /// platforms, but until the current patterns change, one should check
85 /// the specific library export.h (i.e. @sa IexExport.h,
86 /// @sa IlmThreadExport.h, @sa ImfExport.h, @sa ImfUtilExport.h )
87 ///
88 /// These per-library exports define a subset which are used by that
89 /// library.
90 ///
91 /// Iex is simple and does not need to do more than expose class types
92 /// and functions, and does not have any private members to hide, so
93 /// only provides a couple of the possible macros.
94 ///
95 /// Similarly, IlmThread is also reasonably simple.
96 ///
97 /// OpenEXR and OpenEXRUtil have much more logic and have to deal with
98 /// templates and template instantiation, and so define more of the
99 /// macros.
100 ///
101 /// @{
102 
103 #if defined(OPENEXR_ENABLE_API_VISIBILITY) && ! ( defined(OPENEXR_DLL) || defined(_MSC_VER) )
104 # define OPENEXR_PUBLIC_SYMBOL_ATTRIBUTE __attribute__ ((__visibility__ ("default")))
105 # define OPENEXR_PRIVATE_SYMBOL_ATTRIBUTE __attribute__ ((__visibility__ ("hidden")))
106  // clang differs from gcc and has type visibility which is needed
107  // for enums and templates, and isn't well documented, but causes
108  // the vtable and typeinfo to be made visible, but not necessarily
109  // all the members
110 # if __has_attribute(__type_visibility__)
111 # define OPENEXR_PUBLIC_TYPE_VISIBILITY_ATTRIBUTE __attribute__ ((__type_visibility__ ("default")))
112 # endif
113 
114  // these are always the same, at least in current compilers
115 # define OPENEXR_EXPORT OPENEXR_PUBLIC_SYMBOL_ATTRIBUTE
116 # define OPENEXR_HIDDEN OPENEXR_PRIVATE_SYMBOL_ATTRIBUTE
117  // currently define this as the same between compilers to export
118  // things like default copy ctors etc, and do not use the type
119  // visibility which only exports the typeinfo / vtable
120 # define OPENEXR_EXPORT_TYPE OPENEXR_EXPORT
121 # define OPENEXR_EXPORT_EXTERN_TEMPLATE OPENEXR_EXPORT
122 
123 # ifdef OPENEXR_PUBLIC_TYPE_VISIBILITY_ATTRIBUTE
124 # define OPENEXR_EXPORT_ENUM OPENEXR_PUBLIC_TYPE_VISIBILITY_ATTRIBUTE
125 # define OPENEXR_EXPORT_TEMPLATE_TYPE OPENEXR_PUBLIC_TYPE_VISIBILITY_ATTRIBUTE
126  // clang (well, type_visibility) seems empirically need the
127  // default/public symbol tag when specifying explicit template
128  // instantiations, where gcc (no type_visibility) complains if
129  // you set that
130 # define OPENEXR_EXPORT_TEMPLATE_INSTANCE OPENEXR_EXPORT
131 # else
132 # define OPENEXR_EXPORT_ENUM
133 # define OPENEXR_EXPORT_TEMPLATE_TYPE OPENEXR_EXPORT
134 # define OPENEXR_EXPORT_TEMPLATE_INSTANCE
135 # endif
136 
137 #else // msvc or api visibility disabled, just clear all this out (DLLs will define a set anyway)
138 
139 # define OPENEXR_EXPORT
140 # define OPENEXR_HIDDEN
141 # define OPENEXR_EXPORT_TYPE
142 # define OPENEXR_EXPORT_EXTERN_TEMPLATE
143 # define OPENEXR_EXPORT_ENUM
144 # define OPENEXR_EXPORT_TEMPLATE_TYPE
145 # define OPENEXR_EXPORT_TYPE
146 # define OPENEXR_EXPORT_TEMPLATE_INSTANCE
147 
148 #endif
149 
150 #if defined(__cplusplus) && (__cplusplus >= 201402L)
151 # define OPENEXR_DEPRECATED(msg) [[deprecated(msg)]]
152 #endif
153 
154 #ifndef OPENEXR_DEPRECATED
155 # ifdef _MSC_VER
156 # define OPENEXR_DEPRECATED(msg) __declspec(deprecated(msg))
157 # else
158 # define OPENEXR_DEPRECATED(msg) __attribute__((deprecated(msg)))
159 # endif
160 #endif
161 
162 #endif // INCLUDED_OPENEXR_CONFIG_H