OpenVDB: version.h Source File

OpenVDB 4.0.2

version.h
Go to the documentation of this file.
1 //
3 // Copyright (c) 2012-2017 DreamWorks Animation LLC
4 //
5 // All rights reserved. This software is distributed under the
6 // Mozilla Public License 2.0 ( http://www.mozilla.org/MPL/2.0/ )
7 //
8 // Redistributions of source code must retain the above copyright
9 // and license notice and the following restrictions and disclaimer.
10 //
11 // * Neither the name of DreamWorks Animation nor the names of
12 // its contributors may be used to endorse or promote products derived
13 // from this software without specific prior written permission.
14 //
15 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
16 // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
17 // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
18 // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
19 // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY INDIRECT, INCIDENTAL,
20 // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
21 // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
22 // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
23 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
25 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 // IN NO EVENT SHALL THE COPYRIGHT HOLDERS' AND CONTRIBUTORS' AGGREGATE
27 // LIABILITY FOR ALL CLAIMS REGARDLESS OF THEIR BASIS EXCEED US$250.00.
28 //
30
31 #ifndef OPENVDB_VERSION_HAS_BEEN_INCLUDED
32 #define OPENVDB_VERSION_HAS_BEEN_INCLUDED
33
34 #include "Platform.h"
35
36
43 #define OPENVDB_VERSION_NAME v4_0_2
44
45 // Library major, minor and patch version numbers
46 #define OPENVDB_LIBRARY_MAJOR_VERSION_NUMBER 4
47 #define OPENVDB_LIBRARY_MINOR_VERSION_NUMBER 0
48 #define OPENVDB_LIBRARY_PATCH_VERSION_NUMBER 2
49
54 #define OPENVDB_LIBRARY_VERSION_STRING "4.0.2"
55
57 #define OPENVDB_LIBRARY_VERSION_NUMBER \
58 ((OPENVDB_LIBRARY_MAJOR_VERSION_NUMBER << 24) | \
59 ((OPENVDB_LIBRARY_MINOR_VERSION_NUMBER & 0xFF) << 16) | \
60 (OPENVDB_LIBRARY_PATCH_VERSION_NUMBER & 0xFFFF))
61
66 #ifdef OPENVDB_REQUIRE_VERSION_NAME
67 #define OPENVDB_USE_VERSION_NAMESPACE
68 #else
69 #define OPENVDB_USE_VERSION_NAMESPACE \
72 namespace OPENVDB_VERSION_NAME {} \
73 using namespace OPENVDB_VERSION_NAME;
74 #endif
75
76
77 namespace openvdb {
78 OPENVDB_USE_VERSION_NAMESPACE
79 namespace OPENVDB_VERSION_NAME {
80
83 const int32_t OPENVDB_MAGIC = 0x56444220;
84
85 // Library major, minor and patch version numbers
86 const uint32_t
87 OPENVDB_LIBRARY_MAJOR_VERSION = OPENVDB_LIBRARY_MAJOR_VERSION_NUMBER,
88 OPENVDB_LIBRARY_MINOR_VERSION = OPENVDB_LIBRARY_MINOR_VERSION_NUMBER,
89 OPENVDB_LIBRARY_PATCH_VERSION = OPENVDB_LIBRARY_PATCH_VERSION_NUMBER;
91 const uint32_t OPENVDB_LIBRARY_VERSION = OPENVDB_LIBRARY_VERSION_NUMBER;
92
96 const uint32_t OPENVDB_FILE_VERSION = 224;
97
99 enum {
100 OPENVDB_FILE_VERSION_ROOTNODE_MAP = 213,
101 OPENVDB_FILE_VERSION_INTERNALNODE_COMPRESSION = 214,
102 OPENVDB_FILE_VERSION_SIMPLIFIED_GRID_TYPENAME = 215,
103 OPENVDB_FILE_VERSION_GRID_INSTANCING = 216,
104 OPENVDB_FILE_VERSION_BOOL_LEAF_OPTIMIZATION = 217,
105 OPENVDB_FILE_VERSION_BOOST_UUID = 218,
106 OPENVDB_FILE_VERSION_NO_GRIDMAP = 219,
107 OPENVDB_FILE_VERSION_NEW_TRANSFORM = 219,
108 OPENVDB_FILE_VERSION_SELECTIVE_COMPRESSION = 220,
109 OPENVDB_FILE_VERSION_FLOAT_FRUSTUM_BBOX = 221,
110 OPENVDB_FILE_VERSION_NODE_MASK_COMPRESSION = 222,
111 OPENVDB_FILE_VERSION_BLOSC_COMPRESSION = 223,
112 OPENVDB_FILE_VERSION_POINT_INDEX_GRID = 223,
113 OPENVDB_FILE_VERSION_MULTIPASS_IO = 224
114 };
115
116
118 inline const char* getLibraryVersionString() { return OPENVDB_LIBRARY_VERSION_STRING; }
119
120
121 struct VersionId {
122 uint32_t first, second;
123 VersionId(): first(0), second(0) {}
124 VersionId(uint32_t major, uint32_t minor): first(major), second(minor) {}
125 };
126
127 } // namespace OPENVDB_VERSION_NAME
128 } // namespace openvdb
129
130 #endif // OPENVDB_VERSION_HAS_BEEN_INCLUDED
131
132 // Copyright (c) 2012-2017 DreamWorks Animation LLC
133 // All rights reserved. This software is distributed under the
134 // Mozilla Public License 2.0 ( http://www.mozilla.org/MPL/2.0/ )
openvdb::v4_0_2::OPENVDB_FILE_VERSION_SELECTIVE_COMPRESSION
Definition: version.h:108
openvdb::v4_0_2::OPENVDB_FILE_VERSION
const uint32_t OPENVDB_FILE_VERSION
The current version number of the VDB file format.
Definition: version.h:96
openvdb::v4_0_2::OPENVDB_MAGIC
const int32_t OPENVDB_MAGIC
The magic number is stored in the first four bytes of every VDB file.
Definition: version.h:83
openvdb::v4_0_2::OPENVDB_FILE_VERSION_BLOSC_COMPRESSION
Definition: version.h:111
openvdb::v4_0_2::VersionId::VersionId
VersionId(uint32_t major, uint32_t minor)
Definition: version.h:124
OPENVDB_LIBRARY_VERSION_STRING
#define OPENVDB_LIBRARY_VERSION_STRING
Library version number string of the form "<major>.<minor>.<patch>".
Definition: version.h:54
openvdb::v4_0_2::OPENVDB_LIBRARY_MAJOR_VERSION
const uint32_t OPENVDB_LIBRARY_MAJOR_VERSION
Definition: version.h:87
openvdb::v4_0_2::OPENVDB_FILE_VERSION_NO_GRIDMAP
Definition: version.h:106
openvdb::v4_0_2::VersionId::VersionId
VersionId()
Definition: version.h:123
openvdb::v4_0_2::OPENVDB_FILE_VERSION_POINT_INDEX_GRID
Definition: version.h:112
OPENVDB_VERSION_NAME
#define OPENVDB_VERSION_NAME
Definition: version.h:43
openvdb::v4_0_2::OPENVDB_LIBRARY_PATCH_VERSION
const uint32_t OPENVDB_LIBRARY_PATCH_VERSION
Definition: version.h:89
openvdb::v4_0_2::getLibraryVersionString
const char * getLibraryVersionString()
Return a library version number string of the form "<major>.<minor>.<patch>".
Definition: version.h:118
openvdb::v4_0_2::VersionId
Definition: version.h:121
openvdb
Definition: Exceptions.h:39
openvdb::v4_0_2::OPENVDB_FILE_VERSION_NODE_MASK_COMPRESSION
Definition: version.h:110
OPENVDB_LIBRARY_VERSION_NUMBER
#define OPENVDB_LIBRARY_VERSION_NUMBER
Library version number as a packed integer ("%02x%02x%04x", major, minor, patch)
Definition: version.h:57
openvdb::v4_0_2::OPENVDB_FILE_VERSION_INTERNALNODE_COMPRESSION
Definition: version.h:101
openvdb::v4_0_2::OPENVDB_FILE_VERSION_NEW_TRANSFORM
Definition: version.h:107
openvdb::v4_0_2::OPENVDB_FILE_VERSION_MULTIPASS_IO
Definition: version.h:113
openvdb::v4_0_2::OPENVDB_LIBRARY_MINOR_VERSION
const uint32_t OPENVDB_LIBRARY_MINOR_VERSION
Definition: version.h:88
openvdb::v4_0_2::OPENVDB_LIBRARY_VERSION
const uint32_t OPENVDB_LIBRARY_VERSION
Library version number as a packed integer ("%02x%02x%04x", major, minor, patch)
Definition: version.h:91
OPENVDB_LIBRARY_MAJOR_VERSION_NUMBER
#define OPENVDB_LIBRARY_MAJOR_VERSION_NUMBER
Definition: version.h:46
openvdb::v4_0_2::OPENVDB_FILE_VERSION_ROOTNODE_MAP
Definition: version.h:100
OPENVDB_USE_VERSION_NAMESPACE
#define OPENVDB_USE_VERSION_NAMESPACE
Definition: version.h:71
OPENVDB_LIBRARY_MINOR_VERSION_NUMBER
#define OPENVDB_LIBRARY_MINOR_VERSION_NUMBER
Definition: version.h:47
openvdb::v4_0_2::VersionId::second
uint32_t second
Definition: version.h:122
openvdb::v4_0_2::OPENVDB_FILE_VERSION_SIMPLIFIED_GRID_TYPENAME
Definition: version.h:102
openvdb::v4_0_2::OPENVDB_FILE_VERSION_BOOL_LEAF_OPTIMIZATION
Definition: version.h:104
OPENVDB_LIBRARY_PATCH_VERSION_NUMBER
#define OPENVDB_LIBRARY_PATCH_VERSION_NUMBER
Definition: version.h:48
openvdb::v4_0_2::OPENVDB_FILE_VERSION_FLOAT_FRUSTUM_BBOX
Definition: version.h:109
Platform.h
openvdb::v4_0_2::OPENVDB_FILE_VERSION_BOOST_UUID
Definition: version.h:105
openvdb::v4_0_2::OPENVDB_FILE_VERSION_GRID_INSTANCING
Definition: version.h:103