├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.md │ ├── build---installation.md │ └── feature_request.md └── workflows │ ├── ax.yml │ ├── build.yml │ ├── docs.yml │ ├── houdini.yml │ ├── nanovdb.yml │ ├── weekly.yml │ └── whitespace.yml ├── .gitignore ├── CHANGES ├── CMakeLists.txt ├── CODEOWNERS ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── MAINTAINERS.md ├── RE-LICENSE_NOTE.txt ├── README.md ├── ci ├── build.sh ├── build_sonar.sh ├── download_houdini.py ├── download_houdini.sh ├── download_vdb_caches.py ├── extract_test_examples.sh ├── install_blosc.sh ├── install_cppunit.sh ├── install_doxygen.sh ├── install_glfw.sh ├── install_gtest.sh ├── install_llvm_windows.sh ├── install_macos.sh ├── install_nanobind.sh ├── install_tbb_macos.sh ├── install_windows.ps1 ├── install_windows_cuda.ps1 ├── test_install.sh └── test_sonar.sh ├── cmake ├── CPM.cmake ├── FindBlosc.cmake ├── FindCppUnit.cmake ├── FindJemalloc.cmake ├── FindLog4cplus.cmake ├── FindNCCL.cmake ├── FindOpenEXR.cmake ├── FindOpenVDB.cmake ├── FindTBB.cmake ├── OpenVDBGLFW3Setup.cmake ├── OpenVDBHoudiniSetup.cmake ├── OpenVDBMayaSetup.cmake ├── OpenVDBUtils.cmake ├── Uninstall.cmake ├── config │ ├── OpenVDBCXX.cmake │ └── OpenVDBVersions.cmake └── scripts │ ├── lsan.supp │ └── ubsan.supp ├── doc ├── CMakeLists.txt ├── ax │ ├── ax.txt │ ├── axcplusplus.txt │ ├── axexamples.txt │ ├── axfunctionlist.txt │ ├── doc.txt │ ├── gen_function_docs │ └── gen_function_houdini_docs ├── build.txt ├── changes.txt ├── codingstyle.txt ├── dependencies.txt ├── doc.txt ├── examplecode.txt ├── faq.txt ├── houdini.txt ├── img │ ├── banner.png │ ├── multiparm.png │ └── tabmenu.png ├── math.txt ├── nanovdb │ ├── FAQ.md │ ├── HelloWorld.md │ ├── HowToBuild.md │ ├── SourceTree.md │ └── doc.md ├── points.txt └── python.txt ├── nanovdb └── nanovdb │ ├── CMakeLists.txt │ ├── CNanoVDB.h │ ├── GridHandle.h │ ├── HostBuffer.h │ ├── NanoVDB.h │ ├── NodeManager.h │ ├── PNanoVDB.h │ ├── Readme.md │ ├── cmd │ ├── CMakeLists.txt │ ├── convert │ │ └── nanovdb_convert.cc │ ├── print │ │ └── nanovdb_print.cc │ ├── updateFiles.py │ ├── updateFiles.sh │ └── validate │ │ └── nanovdb_validate.cc │ ├── cuda │ ├── DeviceBuffer.h │ ├── DeviceMesh.h │ ├── DeviceStreamMap.h │ ├── GridHandle.cuh │ ├── NodeManager.cuh │ ├── TempDevicePool.h │ └── UnifiedBuffer.h │ ├── docs │ ├── CMakeLists.txt │ ├── codingstyle.txt │ └── doxygen-config │ ├── examples │ ├── CMakeLists.txt │ ├── ex_bump_pool_buffer │ │ └── bump_pool_buffer.cc │ ├── ex_collide_level_set │ │ ├── common.h │ │ ├── main.cc │ │ ├── nanovdb.cu │ │ └── openvdb.cc │ ├── ex_index_grid_cuda │ │ ├── index_grid_cuda.cc │ │ └── index_grid_cuda_kernel.cu │ ├── ex_make_custom_nanovdb │ │ └── make_custom_nanovdb.cc │ ├── ex_make_custom_nanovdb_cuda │ │ ├── make_custom_nanovdb_cuda.cc │ │ └── make_custom_nanovdb_cuda_kernel.cu │ ├── ex_make_funny_nanovdb │ │ └── make_funny_nanovdb.cc │ ├── ex_make_mgpu_nanovdb │ │ └── main.cu │ ├── ex_make_nanovdb_sphere │ │ └── make_nanovdb_sphere.cc │ ├── ex_make_typed_grids │ │ └── make_typed_grids.cc │ ├── ex_map_pool_buffer │ │ └── map_pool_buffer.cc │ ├── ex_modify_nanovdb_thrust │ │ ├── modify_nanovdb_thrust.cc │ │ └── modify_nanovdb_thrust.cu │ ├── ex_nodemanager_cuda │ │ ├── nodemanager_cuda.cc │ │ └── nodemanager_cuda_kernel.cu │ ├── ex_openvdb_to_nanovdb │ │ └── openvdb_to_nanovdb.cc │ ├── ex_openvdb_to_nanovdb_accessor │ │ └── openvdb_to_nanovdb_accessor.cc │ ├── ex_openvdb_to_nanovdb_cuda │ │ ├── openvdb_to_nanovdb_cuda.cc │ │ └── openvdb_to_nanovdb_cuda_kernel.cu │ ├── ex_raytrace_fog_volume │ │ ├── common.h │ │ ├── main.cc │ │ ├── nanovdb.cu │ │ └── openvdb.cc │ ├── ex_raytrace_level_set │ │ ├── common.h │ │ ├── main.cc │ │ ├── nanovdb.cu │ │ └── openvdb.cc │ ├── ex_read_nanovdb_sphere │ │ └── read_nanovdb_sphere.cc │ ├── ex_read_nanovdb_sphere_accessor │ │ └── read_nanovdb_sphere_accessor.cc │ ├── ex_read_nanovdb_sphere_accessor_cuda │ │ ├── read_nanovdb_sphere_accessor_cuda.cu │ │ └── read_nanovdb_sphere_accessor_cuda_kernel.cu │ ├── ex_util │ │ └── ComputePrimitives.h │ ├── ex_vox_to_nanovdb │ │ ├── VoxToNanoVDB.h │ │ └── vox_to_nanovdb.cc │ ├── ex_voxels_to_grid_cuda │ │ └── ex_voxels_to_grid_cuda.cu │ ├── ex_voxels_to_grid_mgpu │ │ └── ex_voxels_to_grid_mgpu.cu │ └── ex_write_nanovdb_grids │ │ └── write_nanovdb_grids.cc │ ├── io │ └── IO.h │ ├── math │ ├── CSampleFromVoxels.h │ ├── DitherLUT.h │ ├── HDDA.h │ ├── Math.h │ ├── Ray.h │ ├── SampleFromVoxels.h │ └── Stencils.h │ ├── python │ ├── CMakeLists.txt │ ├── NanoVDBModule.cc │ ├── PyCreateNanoGrid.cc │ ├── PyCreateNanoGrid.h │ ├── PyGridChecksum.cc │ ├── PyGridChecksum.h │ ├── PyGridHandle.cc │ ├── PyGridHandle.h │ ├── PyGridStats.cc │ ├── PyGridStats.h │ ├── PyGridValidator.cc │ ├── PyGridValidator.h │ ├── PyHostBuffer.cc │ ├── PyHostBuffer.h │ ├── PyIO.cc │ ├── PyIO.h │ ├── PyMath.cc │ ├── PyMath.h │ ├── PyNanoToOpenVDB.cc │ ├── PyNanoToOpenVDB.h │ ├── PyPrimitives.cc │ ├── PyPrimitives.h │ ├── PySampleFromVoxels.cc │ ├── PySampleFromVoxels.h │ ├── PyTools.cc │ ├── PyTools.h │ ├── __init__.py │ ├── cuda │ │ ├── PyDeviceBuffer.cc │ │ ├── PyDeviceBuffer.h │ │ ├── PyDeviceGridHandle.cu │ │ ├── PyPointsToGrid.cu │ │ ├── PyPointsToGrid.h │ │ ├── PySampleFromVoxels.cu │ │ ├── PySampleFromVoxels.h │ │ ├── PySignedFloodFill.cu │ │ └── PySignedFloodFill.h │ └── test │ │ └── TestNanoVDB.py │ ├── tools │ ├── CreateNanoGrid.h │ ├── CreatePrimitives.h │ ├── GridBuilder.h │ ├── GridChecksum.h │ ├── GridStats.h │ ├── GridValidator.h │ ├── NanoToOpenVDB.h │ └── cuda │ │ ├── AddBlindData.cuh │ │ ├── DistributedPointsToGrid.cuh │ │ ├── GridChecksum.cuh │ │ ├── GridStats.cuh │ │ ├── GridValidator.cuh │ │ ├── IndexToGrid.cuh │ │ ├── PointsToGrid.cuh │ │ └── SignedFloodFill.cuh │ ├── unittest │ ├── CMakeLists.txt │ ├── TestNanoVDB.cc │ ├── TestNanoVDB.cu │ ├── TestOpenVDB.cc │ └── pnanovdb_validate_strides.h │ └── util │ ├── CpuTimer.h │ ├── CreateNanoGrid.h │ ├── DitherLUT.h │ ├── ForEach.h │ ├── GridBuilder.h │ ├── GridChecksum.h │ ├── GridStats.h │ ├── GridValidator.h │ ├── HDDA.h │ ├── HostBuffer.h │ ├── IO.h │ ├── Invoke.h │ ├── NanoToOpenVDB.h │ ├── NodeManager.h │ ├── OpenToNanoVDB.h │ ├── PrefixSum.h │ ├── Primitives.h │ ├── Range.h │ ├── Ray.h │ ├── Reduce.h │ ├── SampleFromVoxels.h │ ├── Stencils.h │ ├── Timer.h │ ├── Util.h │ └── cuda │ ├── CudaAddBlindData.cuh │ ├── CudaDeviceBuffer.h │ ├── CudaGridChecksum.cuh │ ├── CudaGridHandle.cuh │ ├── CudaGridStats.cuh │ ├── CudaGridValidator.cuh │ ├── CudaIndexToGrid.cuh │ ├── CudaNodeManager.cuh │ ├── CudaPointsToGrid.cuh │ ├── CudaSignedFloodFill.cuh │ ├── CudaUtils.h │ ├── GpuTimer.h │ ├── Timer.h │ └── Util.h ├── openvdb └── openvdb │ ├── CMakeLists.txt │ ├── COPYRIGHT │ ├── Exceptions.h │ ├── Grid.cc │ ├── Grid.h │ ├── LICENSE │ ├── MetaMap.cc │ ├── MetaMap.h │ ├── Metadata.cc │ ├── Metadata.h │ ├── Platform.cc │ ├── Platform.h │ ├── PlatformConfig.h │ ├── README │ ├── TypeList.h │ ├── Types.h │ ├── io │ ├── Archive.cc │ ├── Archive.h │ ├── Compression.cc │ ├── Compression.h │ ├── DelayedLoadMetadata.cc │ ├── DelayedLoadMetadata.h │ ├── File.cc │ ├── File.h │ ├── GridDescriptor.cc │ ├── GridDescriptor.h │ ├── Queue.cc │ ├── Queue.h │ ├── Stream.cc │ ├── Stream.h │ ├── TempFile.cc │ ├── TempFile.h │ └── io.h │ ├── math │ ├── BBox.h │ ├── ConjGradient.h │ ├── Coord.h │ ├── DDA.h │ ├── FiniteDifference.h │ ├── Half.cc │ ├── Half.h │ ├── LegacyFrustum.h │ ├── Maps.cc │ ├── Maps.h │ ├── Mat.h │ ├── Mat3.h │ ├── Mat4.h │ ├── Math.h │ ├── Operators.h │ ├── Proximity.cc │ ├── Proximity.h │ ├── QuantizedUnitVec.cc │ ├── QuantizedUnitVec.h │ ├── Quat.h │ ├── Ray.h │ ├── Stats.h │ ├── Stencils.h │ ├── Transform.cc │ ├── Transform.h │ ├── Tuple.h │ ├── Vec2.h │ ├── Vec3.h │ └── Vec4.h │ ├── openvdb.cc │ ├── openvdb.h │ ├── points │ ├── AttributeArray.cc │ ├── AttributeArray.h │ ├── AttributeArrayString.cc │ ├── AttributeArrayString.h │ ├── AttributeGroup.cc │ ├── AttributeGroup.h │ ├── AttributeSet.cc │ ├── AttributeSet.h │ ├── IndexFilter.h │ ├── IndexIterator.h │ ├── PointAdvect.h │ ├── PointAttribute.h │ ├── PointConversion.h │ ├── PointCount.h │ ├── PointDataGrid.h │ ├── PointDelete.h │ ├── PointGroup.h │ ├── PointMask.h │ ├── PointMove.h │ ├── PointRasterizeFrustum.h │ ├── PointRasterizeSDF.h │ ├── PointRasterizeTrilinear.h │ ├── PointReplicate.h │ ├── PointSample.h │ ├── PointScatter.h │ ├── PointStatistics.h │ ├── PointTransfer.h │ ├── StreamCompression.cc │ ├── StreamCompression.h │ ├── impl │ │ ├── PointAttributeImpl.h │ │ ├── PointConversionImpl.h │ │ ├── PointCountImpl.h │ │ ├── PointDeleteImpl.h │ │ ├── PointGroupImpl.h │ │ ├── PointMaskImpl.h │ │ ├── PointMoveImpl.h │ │ ├── PointRasterizeFrustumImpl.h │ │ ├── PointRasterizeSDFImpl.h │ │ ├── PointRasterizeTrilinearImpl.h │ │ ├── PointReplicateImpl.h │ │ ├── PointSampleImpl.h │ │ ├── PointScatterImpl.h │ │ └── PointStatisticsImpl.h │ └── points.cc │ ├── python │ ├── CMakeLists.txt │ ├── __init__.py │ ├── pyAccessor.h │ ├── pyFloatGrid.cc │ ├── pyGrid.h │ ├── pyGridBase.cc │ ├── pyIntGrid.cc │ ├── pyMetadata.cc │ ├── pyOpenVDBModule.cc │ ├── pyPointGrid.cc │ ├── pyTransform.cc │ ├── pyTypeCasters.h │ ├── pyVec3Grid.cc │ ├── pyutil.h │ └── test │ │ └── TestOpenVDB.py │ ├── thread │ └── Threading.h │ ├── tools │ ├── Activate.h │ ├── ChangeBackground.h │ ├── Clip.h │ ├── Composite.h │ ├── Count.h │ ├── Dense.h │ ├── DenseSparseTools.h │ ├── Diagnostics.h │ ├── FastSweeping.h │ ├── Filter.h │ ├── FindActiveValues.h │ ├── GridOperators.h │ ├── GridTransformer.h │ ├── Interpolation.h │ ├── LevelSetAdvect.h │ ├── LevelSetDilatedMesh.h │ ├── LevelSetFilter.h │ ├── LevelSetFracture.h │ ├── LevelSetMeasure.h │ ├── LevelSetMorph.h │ ├── LevelSetPlatonic.h │ ├── LevelSetRebuild.h │ ├── LevelSetSphere.h │ ├── LevelSetTracker.h │ ├── LevelSetTubes.h │ ├── LevelSetUtil.h │ ├── Mask.h │ ├── Merge.h │ ├── MeshToVolume.h │ ├── Morphology.h │ ├── MultiResGrid.h │ ├── NodeVisitor.h │ ├── ParticleAtlas.h │ ├── ParticlesToLevelSet.h │ ├── PointAdvect.h │ ├── PointIndexGrid.h │ ├── PointPartitioner.h │ ├── PointScatter.h │ ├── PointsToMask.h │ ├── PoissonSolver.h │ ├── PotentialFlow.h │ ├── Prune.h │ ├── RayIntersector.h │ ├── RayTracer.h │ ├── SignedFloodFill.h │ ├── Statistics.h │ ├── TopologyToLevelSet.h │ ├── ValueTransformer.h │ ├── VectorTransformer.h │ ├── VelocityFields.h │ ├── VolumeAdvect.h │ ├── VolumeToMesh.h │ ├── VolumeToSpheres.h │ └── impl │ │ ├── ConvexVoxelizer.h │ │ ├── LevelSetDilatedMeshImpl.h │ │ └── LevelSetTubesImpl.h │ ├── tree │ ├── InternalNode.h │ ├── Iterator.h │ ├── LeafBuffer.h │ ├── LeafManager.h │ ├── LeafNode.h │ ├── LeafNodeBool.h │ ├── LeafNodeMask.h │ ├── NodeManager.h │ ├── NodeUnion.h │ ├── RootNode.h │ ├── Tree.h │ ├── TreeIterator.h │ └── ValueAccessor.h │ ├── unittest │ ├── CMakeLists.txt │ ├── PointBuilder.h │ ├── TestActivate.cc │ ├── TestAttributeArray.cc │ ├── TestAttributeArrayString.cc │ ├── TestAttributeGroup.cc │ ├── TestAttributeSet.cc │ ├── TestBBox.cc │ ├── TestClip.cc │ ├── TestConjGradient.cc │ ├── TestCoord.cc │ ├── TestCount.cc │ ├── TestCpt.cc │ ├── TestCurl.cc │ ├── TestDelayedLoadMetadata.cc │ ├── TestDense.cc │ ├── TestDenseSparseTools.cc │ ├── TestDiagnostics.cc │ ├── TestDivergence.cc │ ├── TestDoubleMetadata.cc │ ├── TestExceptions.cc │ ├── TestFastSweeping.cc │ ├── TestFile.cc │ ├── TestFilter.cc │ ├── TestFindActiveValues.cc │ ├── TestFloatMetadata.cc │ ├── TestGradient.cc │ ├── TestGrid.cc │ ├── TestGridBbox.cc │ ├── TestGridDescriptor.cc │ ├── TestGridIO.cc │ ├── TestGridTransformer.cc │ ├── TestIndexFilter.cc │ ├── TestIndexIterator.cc │ ├── TestInit.cc │ ├── TestInt32Metadata.cc │ ├── TestInt64Metadata.cc │ ├── TestInternalNode.cc │ ├── TestInternalOrigin.cc │ ├── TestLaplacian.cc │ ├── TestLeaf.cc │ ├── TestLeafBool.cc │ ├── TestLeafIO.cc │ ├── TestLeafManager.cc │ ├── TestLeafMask.cc │ ├── TestLeafOrigin.cc │ ├── TestLevelSetDilatedMesh.cc │ ├── TestLevelSetFilter.cc │ ├── TestLevelSetRayIntersector.cc │ ├── TestLevelSetTubes.cc │ ├── TestLevelSetUtil.cc │ ├── TestLinearInterp.cc │ ├── TestMaps.cc │ ├── TestMat4Metadata.cc │ ├── TestMath.cc │ ├── TestMeanCurvature.cc │ ├── TestMerge.cc │ ├── TestMeshToVolume.cc │ ├── TestMetaMap.cc │ ├── TestMetadata.cc │ ├── TestMetadataIO.cc │ ├── TestMorphology.cc │ ├── TestMultiResGrid.cc │ ├── TestName.cc │ ├── TestNodeIterator.cc │ ├── TestNodeManager.cc │ ├── TestNodeMask.cc │ ├── TestNodeVisitor.cc │ ├── TestParticleAtlas.cc │ ├── TestParticlesToLevelSet.cc │ ├── TestPointAdvect.cc │ ├── TestPointAttribute.cc │ ├── TestPointConversion.cc │ ├── TestPointCount.cc │ ├── TestPointDataLeaf.cc │ ├── TestPointDelete.cc │ ├── TestPointGroup.cc │ ├── TestPointIndexGrid.cc │ ├── TestPointInstantiate.cc │ ├── TestPointMask.cc │ ├── TestPointMove.cc │ ├── TestPointPartitioner.cc │ ├── TestPointRasterizeFrustum.cc │ ├── TestPointRasterizeSDF.cc │ ├── TestPointRasterizeTrilinear.cc │ ├── TestPointReplicate.cc │ ├── TestPointSample.cc │ ├── TestPointScatter.cc │ ├── TestPointStatistics.cc │ ├── TestPointsToMask.cc │ ├── TestPoissonSolver.cc │ ├── TestPotentialFlow.cc │ ├── TestPrePostAPI.cc │ ├── TestQuadraticInterp.cc │ ├── TestQuantizedUnitVec.cc │ ├── TestQuat.cc │ ├── TestRay.cc │ ├── TestRootNode.cc │ ├── TestStats.cc │ ├── TestStencils.cc │ ├── TestStream.cc │ ├── TestStreamCompression.cc │ ├── TestStringMetadata.cc │ ├── TestTools.cc │ ├── TestTopologyToLevelSet.cc │ ├── TestTransform.cc │ ├── TestTree.cc │ ├── TestTreeCombine.cc │ ├── TestTreeGetSetValues.cc │ ├── TestTreeIterators.cc │ ├── TestTypeList.cc │ ├── TestTypes.cc │ ├── TestUtil.cc │ ├── TestValueAccessor.cc │ ├── TestVec2Metadata.cc │ ├── TestVec3Metadata.cc │ ├── TestVolumeRayIntersector.cc │ ├── TestVolumeToMesh.cc │ ├── TestVolumeToSpheres.cc │ ├── main.cc │ └── util.h │ ├── util │ ├── Assert.cc │ ├── Assert.h │ ├── CpuTimer.h │ ├── ExplicitInstantiation.h │ ├── Formats.cc │ ├── Formats.h │ ├── MapsUtil.h │ ├── Name.h │ ├── NodeMasks.h │ ├── NullInterrupter.h │ ├── PagedArray.h │ ├── Util.h │ └── logging.h │ └── version.h.in ├── openvdb_ax └── openvdb_ax │ ├── CMakeLists.txt │ ├── Exceptions.h │ ├── ast │ ├── AST.h │ ├── Parse.cc │ ├── Parse.h │ ├── PrintTree.cc │ ├── PrintTree.h │ ├── Scanners.cc │ ├── Scanners.h │ ├── Tokens.h │ └── Visitor.h │ ├── ax.cc │ ├── ax.h │ ├── codegen │ ├── Codecs.cc │ ├── Codecs.h │ ├── ComputeGenerator.cc │ ├── ComputeGenerator.h │ ├── ConstantFolding.h │ ├── FunctionRegistry.cc │ ├── FunctionRegistry.h │ ├── FunctionTypes.cc │ ├── FunctionTypes.h │ ├── Functions.h │ ├── PointComputeGenerator.cc │ ├── PointComputeGenerator.h │ ├── PointFunctions.cc │ ├── PointLeafLocalData.h │ ├── StandardFunctions.cc │ ├── String.h │ ├── StringFunctions.cc │ ├── SymbolTable.h │ ├── Types.cc │ ├── Types.h │ ├── Utils.h │ ├── VolumeComputeGenerator.cc │ ├── VolumeComputeGenerator.h │ └── VolumeFunctions.cc │ ├── compiler │ ├── AttributeBindings.h │ ├── AttributeRegistry.h │ ├── Compiler.cc │ ├── Compiler.h │ ├── CompilerOptions.h │ ├── CustomData.h │ ├── Logger.cc │ ├── Logger.h │ ├── PointExecutable.cc │ ├── PointExecutable.h │ ├── VolumeExecutable.cc │ └── VolumeExecutable.h │ ├── grammar │ ├── axlexer.l │ ├── axparser.y │ └── generated │ │ ├── README │ │ ├── axlexer.cc │ │ ├── axparser.cc │ │ └── axparser.h │ ├── math │ ├── OpenSimplexNoise.cc │ └── OpenSimplexNoise.h │ ├── test │ ├── CMakeLists.txt │ ├── TestAXCmd.cmake │ ├── ast │ │ ├── TestPrinters.cc │ │ └── TestScanners.cc │ ├── backend │ │ ├── TestAttributeBindings.cc │ │ ├── TestCodecs.cc │ │ ├── TestComputeGeneratorFailures.cc │ │ ├── TestFunctionGroup.cc │ │ ├── TestFunctionRegistry.cc │ │ ├── TestFunctionTypes.cc │ │ ├── TestLogger.cc │ │ ├── TestStringIR.cc │ │ ├── TestSymbolTable.cc │ │ ├── TestTypes.cc │ │ └── util.h │ ├── cmd │ │ ├── vdb_ax_test_attr_create │ │ ├── vdb_ax_test_fail_1 │ │ ├── vdb_ax_test_fail_10 │ │ ├── vdb_ax_test_fail_11 │ │ ├── vdb_ax_test_fail_12 │ │ ├── vdb_ax_test_fail_13 │ │ ├── vdb_ax_test_fail_14 │ │ ├── vdb_ax_test_fail_15 │ │ ├── vdb_ax_test_fail_16 │ │ ├── vdb_ax_test_fail_17 │ │ ├── vdb_ax_test_fail_18 │ │ ├── vdb_ax_test_fail_19 │ │ ├── vdb_ax_test_fail_2 │ │ ├── vdb_ax_test_fail_20 │ │ ├── vdb_ax_test_fail_3 │ │ ├── vdb_ax_test_fail_4 │ │ ├── vdb_ax_test_fail_5 │ │ ├── vdb_ax_test_fail_6 │ │ ├── vdb_ax_test_fail_7 │ │ ├── vdb_ax_test_fail_8 │ │ ├── vdb_ax_test_fail_9 │ │ ├── vdb_ax_test_ls_sphere_1 │ │ ├── vdb_ax_test_ls_sphere_2 │ │ ├── vdb_ax_test_ls_sphere_3 │ │ ├── vdb_ax_test_pass_1 │ │ ├── vdb_ax_test_pass_10 │ │ ├── vdb_ax_test_pass_11 │ │ ├── vdb_ax_test_pass_12 │ │ ├── vdb_ax_test_pass_13 │ │ ├── vdb_ax_test_pass_14 │ │ ├── vdb_ax_test_pass_15 │ │ ├── vdb_ax_test_pass_2 │ │ ├── vdb_ax_test_pass_3 │ │ ├── vdb_ax_test_pass_4 │ │ ├── vdb_ax_test_pass_5 │ │ ├── vdb_ax_test_pass_6 │ │ ├── vdb_ax_test_pass_7 │ │ ├── vdb_ax_test_pass_8 │ │ ├── vdb_ax_test_pass_9 │ │ ├── vdb_ax_test_uuid │ │ └── vdb_ax_test_vol_bind │ ├── compiler │ │ ├── TestAXRun.cc │ │ ├── TestPointExecutable.cc │ │ └── TestVolumeExecutable.cc │ ├── frontend │ │ ├── TestArrayPack.cc │ │ ├── TestArrayUnpackNode.cc │ │ ├── TestAssignExpressionNode.cc │ │ ├── TestAttributeNode.cc │ │ ├── TestBinaryOperatorNode.cc │ │ ├── TestCastNode.cc │ │ ├── TestCommaOperator.cc │ │ ├── TestConditionalStatementNode.cc │ │ ├── TestCrementNode.cc │ │ ├── TestDeclareLocalNode.cc │ │ ├── TestExternalVariableNode.cc │ │ ├── TestFunctionCallNode.cc │ │ ├── TestKeywordNode.cc │ │ ├── TestLocalNode.cc │ │ ├── TestLoopNode.cc │ │ ├── TestStatementListNode.cc │ │ ├── TestSyntaxFailures.cc │ │ ├── TestTernaryOperatorNode.cc │ │ ├── TestUnaryOperatorNode.cc │ │ └── TestValueNode.cc │ ├── integration │ │ ├── CompareGrids.cc │ │ ├── CompareGrids.h │ │ ├── TestArrayUnpack.cc │ │ ├── TestArrayUnpack │ │ │ ├── array_unpack.mat.double.ax │ │ │ ├── array_unpack.mat.float.ax │ │ │ ├── array_unpack.vec.double.ax │ │ │ ├── array_unpack.vec.double.rgb.ax │ │ │ ├── array_unpack.vec.double.xyz.ax │ │ │ ├── array_unpack.vec.float.ax │ │ │ ├── array_unpack.vec.float.rgb.ax │ │ │ ├── array_unpack.vec.float.xyz.ax │ │ │ ├── array_unpack.vec.int.ax │ │ │ ├── array_unpack.vec.int.rgb.ax │ │ │ └── array_unpack.vec.int.xyz.ax │ │ ├── TestAssign.cc │ │ ├── TestAssign │ │ │ ├── assign.bool.ax │ │ │ ├── assign.double.ax │ │ │ ├── assign.float.ax │ │ │ ├── assign.int32.ax │ │ │ ├── assign.int64.ax │ │ │ ├── assign.mat3d.ax │ │ │ ├── assign.mat3f.ax │ │ │ ├── assign.mat4d.ax │ │ │ ├── assign.mat4f.ax │ │ │ ├── assign.string.ax │ │ │ ├── assign.vec2d.ax │ │ │ ├── assign.vec2f.ax │ │ │ ├── assign.vec2i.ax │ │ │ ├── assign.vec3d.ax │ │ │ ├── assign.vec3f.ax │ │ │ ├── assign.vec3i.ax │ │ │ ├── assign.vec4d.ax │ │ │ ├── assign.vec4f.ax │ │ │ ├── assign.vec4i.ax │ │ │ ├── assign_compound.bool.ax │ │ │ ├── assign_compound.double.ax │ │ │ ├── assign_compound.float.ax │ │ │ ├── assign_compound.int32.ax │ │ │ ├── assign_compound.int64.ax │ │ │ ├── assign_compound.mat3d.ax │ │ │ ├── assign_compound.mat3f.ax │ │ │ ├── assign_compound.mat4d.ax │ │ │ ├── assign_compound.mat4f.ax │ │ │ ├── assign_compound.string.ax │ │ │ ├── assign_compound.vec2d.ax │ │ │ ├── assign_compound.vec2f.ax │ │ │ ├── assign_compound.vec2i.ax │ │ │ ├── assign_compound.vec3d.ax │ │ │ ├── assign_compound.vec3f.ax │ │ │ ├── assign_compound.vec3i.ax │ │ │ ├── assign_compound.vec4d.ax │ │ │ ├── assign_compound.vec4f.ax │ │ │ ├── assign_compound.vec4i.ax │ │ │ ├── assign_implicit_container.mat3d.ax │ │ │ ├── assign_implicit_container.mat3f.ax │ │ │ ├── assign_implicit_container.mat4d.ax │ │ │ ├── assign_implicit_container.mat4f.ax │ │ │ ├── assign_implicit_container.vec2d.ax │ │ │ ├── assign_implicit_container.vec2f.ax │ │ │ ├── assign_implicit_container.vec2i.ax │ │ │ ├── assign_implicit_container.vec3d.ax │ │ │ ├── assign_implicit_container.vec3f.ax │ │ │ ├── assign_implicit_container.vec3i.ax │ │ │ ├── assign_implicit_container.vec4d.ax │ │ │ ├── assign_implicit_container.vec4f.ax │ │ │ ├── assign_implicit_container.vec4i.ax │ │ │ ├── assign_implicit_container_scalar.bool.ax │ │ │ ├── assign_implicit_container_scalar.double.ax │ │ │ ├── assign_implicit_container_scalar.float.ax │ │ │ ├── assign_implicit_container_scalar.int32.ax │ │ │ ├── assign_implicit_container_scalar.int64.ax │ │ │ ├── assign_implicit_scalar.bool.ax │ │ │ ├── assign_implicit_scalar.double.ax │ │ │ ├── assign_implicit_scalar.float.ax │ │ │ ├── assign_implicit_scalar.int32.ax │ │ │ ├── assign_implicit_scalar.int64.ax │ │ │ └── assign_scoped.float.ax │ │ ├── TestBinary.cc │ │ ├── TestBinary │ │ │ ├── binary_bitand.ax │ │ │ ├── binary_bitor.ax │ │ │ ├── binary_bitxor.ax │ │ │ ├── binary_div.ax │ │ │ ├── binary_logicaland.ax │ │ │ ├── binary_logicaland_scircuit.ax │ │ │ ├── binary_logicalor.ax │ │ │ ├── binary_logicalor_scircuit.ax │ │ │ ├── binary_minus.ax │ │ │ ├── binary_mod.ax │ │ │ ├── binary_mult.ax │ │ │ ├── binary_plus.ax │ │ │ ├── binary_relational_equalsequals.ax │ │ │ ├── binary_relational_greaterthan.ax │ │ │ ├── binary_relational_greaterthanequals.ax │ │ │ ├── binary_relational_lessthan.ax │ │ │ ├── binary_relational_lessthanequals.ax │ │ │ ├── binary_relational_notequals.ax │ │ │ ├── binary_shiftleft.ax │ │ │ └── binary_shiftright.ax │ │ ├── TestCast.cc │ │ ├── TestCast │ │ │ ├── cast_explicit.bool.ax │ │ │ ├── cast_explicit.double.ax │ │ │ ├── cast_explicit.float.ax │ │ │ ├── cast_explicit.int32.ax │ │ │ └── cast_explicit.int64.ax │ │ ├── TestConditional.cc │ │ ├── TestCrement.cc │ │ ├── TestCrement │ │ │ ├── crement_dec.component.ax │ │ │ ├── crement_dec.double.ax │ │ │ ├── crement_dec.float.ax │ │ │ ├── crement_dec.int16.ax │ │ │ ├── crement_dec.int32.ax │ │ │ ├── crement_dec.int64.ax │ │ │ ├── crement_inc.component.ax │ │ │ ├── crement_inc.double.ax │ │ │ ├── crement_inc.float.ax │ │ │ ├── crement_inc.int16.ax │ │ │ ├── crement_inc.int32.ax │ │ │ └── crement_inc.int64.ax │ │ ├── TestDeclare.cc │ │ ├── TestEmpty.cc │ │ ├── TestExternals.cc │ │ ├── TestExternals │ │ │ ├── external_assign_from.bool.ax │ │ │ ├── external_assign_from.double.ax │ │ │ ├── external_assign_from.float.ax │ │ │ ├── external_assign_from.int32.ax │ │ │ ├── external_assign_from.int64.ax │ │ │ ├── external_assign_from.mat3d.ax │ │ │ ├── external_assign_from.mat3f.ax │ │ │ ├── external_assign_from.mat4d.ax │ │ │ ├── external_assign_from.mat4f.ax │ │ │ ├── external_assign_from.string.ax │ │ │ ├── external_assign_from.vec2d.ax │ │ │ ├── external_assign_from.vec2f.ax │ │ │ ├── external_assign_from.vec2i.ax │ │ │ ├── external_assign_from.vec3d.ax │ │ │ ├── external_assign_from.vec3f.ax │ │ │ ├── external_assign_from.vec3i.ax │ │ │ ├── external_assign_from.vec4d.ax │ │ │ ├── external_assign_from.vec4f.ax │ │ │ └── external_assign_from.vec4i.ax │ │ ├── TestHarness.cc │ │ ├── TestHarness.h │ │ ├── TestKeyword.cc │ │ ├── TestLoop.cc │ │ ├── TestStandardFunctions.cc │ │ ├── TestString.cc │ │ ├── TestTernary.cc │ │ ├── TestUnary.cc │ │ ├── TestVDBFunctions.cc │ │ └── TestWorldSpaceAccessors.cc │ ├── main.cc │ ├── snippets │ │ ├── conditional │ │ │ ├── conditionalErrors │ │ │ ├── conditionalIfWithinElse │ │ │ ├── conditionalScopingStatement │ │ │ ├── conditionalSimpleElseIf │ │ │ └── conditionalSimpleStatement │ │ ├── declare │ │ │ ├── declareAmbiguousScalarAttributes │ │ │ ├── declareAmbiguousScalarExternals │ │ │ ├── declareAmbiguousVectorAttributes │ │ │ ├── declareAmbiguousVectorExternals │ │ │ ├── declareAttributes │ │ │ ├── declareAttributesVolume │ │ │ ├── declareLocalVariables │ │ │ ├── declareLocalVectorVariables │ │ │ ├── declareNewVectorAttributes │ │ │ ├── declareVectorAttributeImplicit │ │ │ └── declareVectorAttributes │ │ ├── empty │ │ │ └── empty │ │ ├── function │ │ │ ├── abs │ │ │ ├── acos │ │ │ ├── adjoint │ │ │ ├── argsort │ │ │ ├── asin │ │ │ ├── atan │ │ │ ├── atan2 │ │ │ ├── atof │ │ │ ├── atoi │ │ │ ├── cbrt │ │ │ ├── clamp │ │ │ ├── cofactor │ │ │ ├── cosh │ │ │ ├── cross │ │ │ ├── curlnoise │ │ │ ├── curlsimplexnoise │ │ │ ├── degrees │ │ │ ├── determinant │ │ │ ├── diag │ │ │ ├── dot │ │ │ ├── euclideanmod │ │ │ ├── external │ │ │ ├── fit │ │ │ ├── floormod │ │ │ ├── hash │ │ │ ├── hsvtorgb │ │ │ ├── identity3 │ │ │ ├── identity4 │ │ │ ├── intrinsic │ │ │ ├── inverse │ │ │ ├── isfinite │ │ │ ├── isinf │ │ │ ├── isnan │ │ │ ├── length │ │ │ ├── lengthsq │ │ │ ├── lerp │ │ │ ├── max │ │ │ ├── min │ │ │ ├── noise │ │ │ ├── normalize │ │ │ ├── polardecompose │ │ │ ├── postscale │ │ │ ├── pow │ │ │ ├── prescale │ │ │ ├── pretransform │ │ │ ├── print │ │ │ ├── radians │ │ │ ├── rand │ │ │ ├── rand32 │ │ │ ├── rgbtohsv │ │ │ ├── sign │ │ │ ├── signbit │ │ │ ├── simplexnoise │ │ │ ├── sinh │ │ │ ├── sort │ │ │ ├── svd │ │ │ ├── tan │ │ │ ├── tanh │ │ │ ├── trace │ │ │ ├── transform │ │ │ ├── transpose │ │ │ └── truncatemod │ │ ├── keyword │ │ │ ├── conditionalReturn │ │ │ ├── doWhileLoopKeywords │ │ │ ├── forLoopKeywords │ │ │ ├── returnBranchIf │ │ │ ├── returnBranchLoop │ │ │ ├── simpleReturn │ │ │ └── whileLoopKeywords │ │ ├── loop │ │ │ ├── doWhileLoop │ │ │ ├── forLoop │ │ │ ├── loopErrors │ │ │ ├── loopOverflow │ │ │ └── whileLoop │ │ ├── string │ │ │ ├── assignCompound │ │ │ ├── assignFromAttributes │ │ │ ├── assignFromLocals │ │ │ ├── assignNewOverwrite │ │ │ ├── binaryConcat │ │ │ └── declare │ │ ├── ternary │ │ │ ├── ternary │ │ │ ├── ternaryErrors │ │ │ └── ternaryVoid │ │ ├── unary │ │ │ ├── unaryBitwiseNot │ │ │ ├── unaryNegate │ │ │ ├── unaryNot │ │ │ └── unaryVector │ │ ├── vdb_functions │ │ │ ├── addremovefromgroup │ │ │ ├── deletepoint │ │ │ ├── getcoord │ │ │ ├── getvoxelpws │ │ │ └── ingroup │ │ └── worldspace │ │ │ ├── worldSpaceAssign │ │ │ ├── worldSpaceAssignBound │ │ │ ├── worldSpaceAssignComponent │ │ │ ├── worldSpaceAssignFromP │ │ │ ├── worldSpaceDecrementComponentByZero │ │ │ ├── worldSpaceDivideComponentByOne │ │ │ ├── worldSpaceIncrement │ │ │ ├── worldSpaceIncrementComponent │ │ │ ├── worldSpaceIncrementComponentByZero │ │ │ └── worldSpaceMultiplyComponentByOne │ └── util.h │ └── util │ ├── x86.cc │ └── x86.h ├── openvdb_cmd ├── CMakeLists.txt ├── vdb_ax │ ├── CMakeLists.txt │ ├── cli.h │ └── main.cc ├── vdb_lod │ ├── CMakeLists.txt │ └── main.cc ├── vdb_print │ ├── CMakeLists.txt │ └── main.cc ├── vdb_render │ ├── CMakeLists.txt │ └── main.cc ├── vdb_tool │ ├── CHANGES.md │ ├── CMakeLists.txt │ ├── README.md │ ├── examples │ │ ├── EXAMPLES.md │ │ ├── demos.md │ │ ├── dilate_level_set.txt │ │ ├── dilate_mesh.txt │ │ ├── erode_level_set.txt │ │ ├── erode_mesh.txt │ │ ├── hello_world.txt │ │ ├── level_set_to_mesh.txt │ │ ├── mesh_to_level_set.txt │ │ ├── obj_to_ply.txt │ │ ├── ply_to_obj.txt │ │ ├── points_to_mesh.txt │ │ ├── process_multiple_files.txt │ │ ├── simplify_mesh.txt │ │ ├── smooth_level_set.txt │ │ ├── smooth_mesh.txt │ │ └── vdb_points_to_ply.txt │ ├── include │ │ ├── Geometry.h │ │ ├── Parser.h │ │ ├── Tool.h │ │ └── Util.h │ └── src │ │ ├── main.cpp │ │ └── unittest.cpp └── vdb_view │ ├── CMakeLists.txt │ ├── Camera.cc │ ├── Camera.h │ ├── ClipBox.cc │ ├── ClipBox.h │ ├── Font.cc │ ├── Font.h │ ├── RenderModules.cc │ ├── RenderModules.h │ ├── Viewer.cc │ ├── Viewer.h │ └── main.cc ├── openvdb_houdini └── openvdb_houdini │ ├── AXUtils.h │ ├── AttributeTransferUtil.h │ ├── CMakeLists.txt │ ├── COPYRIGHT │ ├── DW_OpenVDBRasterizePoints.cmd │ ├── GEO_VDBTranslator.cc │ ├── GR_PrimVDBPoints.cc │ ├── GT_GEOPrimCollectVDB.cc │ ├── GT_GEOPrimCollectVDB.h │ ├── GU_VDBPointTools.cc │ ├── GU_VDBPointTools.h │ ├── GeometryUtil.cc │ ├── GeometryUtil.h │ ├── LICENSE │ ├── ParmFactory.cc │ ├── ParmFactory.h │ ├── PointUtils.cc │ ├── PointUtils.h │ ├── SHOP_OpenVDB_Points.cc │ ├── SOP_NodeVDB.cc │ ├── SOP_NodeVDB.h │ ├── SOP_OpenVDB.svg │ ├── SOP_OpenVDB_AX.cc │ ├── SOP_OpenVDB_Activate.cc │ ├── SOP_OpenVDB_Advect.cc │ ├── SOP_OpenVDB_Advect_Points.cc │ ├── SOP_OpenVDB_Analysis.cc │ ├── SOP_OpenVDB_Clip.cc │ ├── SOP_OpenVDB_Combine.cc │ ├── SOP_OpenVDB_Convert.cc │ ├── SOP_OpenVDB_Create.cc │ ├── SOP_OpenVDB_Densify.cc │ ├── SOP_OpenVDB_Diagnostics.cc │ ├── SOP_OpenVDB_Extrapolate.cc │ ├── SOP_OpenVDB_Fill.cc │ ├── SOP_OpenVDB_Filter.cc │ ├── SOP_OpenVDB_Filter_Level_Set.cc │ ├── SOP_OpenVDB_Fracture.cc │ ├── SOP_OpenVDB_From_Particles.cc │ ├── SOP_OpenVDB_From_Polygons.cc │ ├── SOP_OpenVDB_LOD.cc │ ├── SOP_OpenVDB_Merge.cc │ ├── SOP_OpenVDB_Metadata.cc │ ├── SOP_OpenVDB_Morph_Level_Set.cc │ ├── SOP_OpenVDB_Noise.cc │ ├── SOP_OpenVDB_Occlusion_Mask.cc │ ├── SOP_OpenVDB_Platonic.cc │ ├── SOP_OpenVDB_Points_Convert.cc │ ├── SOP_OpenVDB_Points_Delete.cc │ ├── SOP_OpenVDB_Points_Group.cc │ ├── SOP_OpenVDB_Potential_Flow.cc │ ├── SOP_OpenVDB_Prune.cc │ ├── SOP_OpenVDB_Rasterize_Frustum.cc │ ├── SOP_OpenVDB_Rasterize_Points.cc │ ├── SOP_OpenVDB_Ray.cc │ ├── SOP_OpenVDB_Read.cc │ ├── SOP_OpenVDB_Rebuild_Level_Set.cc │ ├── SOP_OpenVDB_Remap.cc │ ├── SOP_OpenVDB_Remove_Divergence.cc │ ├── SOP_OpenVDB_Resample.cc │ ├── SOP_OpenVDB_Sample_Points.cc │ ├── SOP_OpenVDB_Scatter.cc │ ├── SOP_OpenVDB_Segment.cc │ ├── SOP_OpenVDB_Sort_Points.cc │ ├── SOP_OpenVDB_To_Polygons.cc │ ├── SOP_OpenVDB_To_Spheres.cc │ ├── SOP_OpenVDB_Topology_To_Level_Set.cc │ ├── SOP_OpenVDB_Transform.cc │ ├── SOP_OpenVDB_Vector_Merge.cc │ ├── SOP_OpenVDB_Vector_Split.cc │ ├── SOP_OpenVDB_Visualize.cc │ ├── SOP_OpenVDB_Write.cc │ ├── SOP_VDBVerbUtils.h │ ├── UT_VDBTools.h │ ├── UT_VDBUtils.cc │ ├── UT_VDBUtils.h │ ├── Utils.cc │ ├── Utils.h │ ├── VRAY_OpenVDB_Points.cc │ ├── abitest │ ├── CMakeLists.txt │ ├── TestABI.cc │ ├── TestABI.h │ └── main.cc │ ├── geometry.cc │ ├── geometry.h │ ├── help │ └── ax │ │ └── functions.txt │ ├── pythonrc.py │ └── reference │ ├── GEO_PrimVDB.cc │ ├── GEO_PrimVDB.h │ ├── GU_PrimVDB.cc │ └── GU_PrimVDB.h ├── openvdb_maya └── openvdb_maya │ ├── AEOpenVDBCopyTemplate.mel │ ├── AEOpenVDBFilterTemplate.mel │ ├── AEOpenVDBFromMayaFluidTemplate.mel │ ├── AEOpenVDBFromPolygonsTemplate.mel │ ├── AEOpenVDBReadTemplate.mel │ ├── AEOpenVDBToPolygonsTemplate.mel │ ├── AEOpenVDBTransformTemplate.mel │ ├── AEOpenVDBVisualizeTemplate.mel │ ├── AEOpenVDBWriteTemplate.mel │ ├── CMakeLists.txt │ ├── COPYRIGHT │ ├── LICENSE │ ├── OpenVDBCopyNode.cc │ ├── OpenVDBData.cc │ ├── OpenVDBData.h │ ├── OpenVDBFilterNode.cc │ ├── OpenVDBFromMayaFluidNode.cc │ ├── OpenVDBFromPolygonsNode.cc │ ├── OpenVDBPlugin.cc │ ├── OpenVDBPlugin.h │ ├── OpenVDBReadNode.cc │ ├── OpenVDBToPolygonsNode.cc │ ├── OpenVDBTransformNode.cc │ ├── OpenVDBUtil.cc │ ├── OpenVDBUtil.h │ ├── OpenVDBVisualizeNode.cc │ └── OpenVDBWriteNode.cc ├── openvdb_wolfram └── OpenVDBLink │ ├── AggregateData.m │ ├── BuildSettings.m │ ├── CSG.m │ ├── DistanceMeasure.m │ ├── Filter.m │ ├── FogVolume.m │ ├── Getters.m │ ├── Grids.m │ ├── IO.m │ ├── Image.m │ ├── Kernel │ └── init.m │ ├── LTemplate.m │ ├── LTemplate │ ├── IncludeFiles │ │ ├── Doxyfile │ │ ├── LTemplate.h │ │ ├── LTemplate.inc │ │ ├── LTemplateCompilerSetup.h │ │ ├── LTemplateHelpers.h │ │ └── mlstream.h │ ├── Kernel │ │ └── init.m │ ├── LICENSE.txt │ ├── LTemplate.m │ ├── LTemplate.qbs │ ├── LTemplateInner.m │ ├── LTemplatePrivate.m │ └── LTemplatePrivateNoCompile.m │ ├── LevelSet.m │ ├── Measure.m │ ├── Mesh.m │ ├── Messages.m │ ├── Morphology.m │ ├── OpenVDBLink.m │ ├── Readme.md │ ├── Render.m │ ├── Setters.m │ ├── Source │ ├── ExplicitGrids │ │ ├── LTemplate-OpenVDBLink.cpp │ │ ├── OpenVDBBoolGrid.h │ │ ├── OpenVDBByteGrid.h │ │ ├── OpenVDBDoubleGrid.h │ │ ├── OpenVDBFloatGrid.h │ │ ├── OpenVDBInt32Grid.h │ │ ├── OpenVDBInt64Grid.h │ │ ├── OpenVDBMaskGrid.h │ │ ├── OpenVDBUInt32Grid.h │ │ ├── OpenVDBVec2DGrid.h │ │ ├── OpenVDBVec2IGrid.h │ │ ├── OpenVDBVec2SGrid.h │ │ ├── OpenVDBVec3DGrid.h │ │ ├── OpenVDBVec3IGrid.h │ │ └── OpenVDBVec3SGrid.h │ ├── GlueTensors.h │ ├── OpenVDBCommon.h │ ├── OpenVDBGrid.h │ ├── OpenVDBGrid │ │ ├── AggregateData.h │ │ ├── CSG.h │ │ ├── DistanceMeasure.h │ │ ├── Filter.h │ │ ├── FogVolume.h │ │ ├── Getters.h │ │ ├── IO.h │ │ ├── Image.h │ │ ├── LevelSetCreation.h │ │ ├── Measure.h │ │ ├── Mesh.h │ │ ├── Metadata.h │ │ ├── Morphology.h │ │ ├── Render.h │ │ ├── Setters.h │ │ └── Transform.h │ └── Utilities │ │ ├── Aggregate.h │ │ ├── Distance.h │ │ ├── Image.h │ │ ├── LevelSet.h │ │ ├── Mesh.h │ │ ├── Metadata.h │ │ ├── Render.h │ │ └── Transform.h │ ├── Transform.m │ ├── UnitTests │ └── wlt │ │ ├── Aggregate.wlt │ │ ├── CSG.wlt │ │ ├── DistanceMeasure.wlt │ │ ├── Filter.wlt │ │ ├── FogVolume.wlt │ │ ├── Getters.wlt │ │ ├── Grids.wlt │ │ ├── IO.wlt │ │ ├── Image.wlt │ │ ├── LevelSet.wlt │ │ ├── Measure.wlt │ │ ├── Mesh.wlt │ │ ├── Morphology.wlt │ │ ├── Render.wlt │ │ ├── Setters.wlt │ │ ├── Transform.wlt │ │ └── Values.wlt │ └── Values.m ├── pendingchanges ├── README ├── level_set_constructors.txt ├── math_nodiscard.txt ├── nanovdb.txt ├── nanovdb_offset_bug.txt └── vdb_tool.txt ├── pyproject.toml └── tsc ├── ccla.md ├── charter.md ├── icla.md ├── meetings ├── 2018-11-17.md ├── 2018-11-30.md ├── 2018-12-06.md ├── 2018-12-13.md ├── 2019-01-17.md ├── 2019-01-24.md ├── 2019-01-31.md ├── 2019-02-14.md ├── 2019-02-28.md ├── 2019-03-07.md ├── 2019-03-21.md ├── 2019-03-28.md ├── 2019-04-18.md ├── 2019-04-25.md ├── 2019-05-02.md ├── 2019-05-09.md ├── 2019-05-23.md ├── 2019-05-30.md ├── 2019-06-06.md ├── 2019-06-13.md ├── 2019-06-20.md ├── 2019-06-27.md ├── 2019-07-11.md ├── 2019-07-25.md ├── 2019-08-22.md ├── 2019-08-29.md ├── 2019-09-12.md ├── 2019-09-26.md ├── 2019-10-10.md ├── 2019-10-24.md ├── 2019-10-31.md ├── 2019-11-14.md ├── 2019-11-21.md ├── 2019-11-28.md ├── 2019-12-05.md ├── 2019-12-19.md ├── 2020-01-09.md ├── 2020-01-16.md ├── 2020-01-23.md ├── 2020-02-13.md ├── 2020-02-20.md ├── 2020-03-05.md ├── 2020-03-19.md ├── 2020-04-02.md ├── 2020-04-09.md ├── 2020-04-16.md ├── 2020-04-30.md ├── 2020-05-07.md ├── 2020-05-14.md ├── 2020-05-21.md ├── 2020-05-28.md ├── 2020-06-04.md ├── 2020-06-18.md ├── 2020-06-25.md ├── 2020-06-30.md ├── 2020-07-07.md ├── 2020-07-14.md ├── 2020-07-21.md ├── 2020-07-28.md ├── 2020-08-04.md ├── 2020-08-11.md ├── 2020-08-18.md ├── 2020-08-25.md ├── 2020-09-01.md ├── 2020-09-22.md ├── 2020-09-29.md ├── 2020-10-13.md ├── 2020-10-20.md ├── 2020-10-27.md ├── 2020-11-03.md ├── 2020-11-10.md ├── 2020-11-17.md ├── 2020-12-01.md ├── 2020-12-15.md ├── 2021-01-05.md ├── 2021-01-12.md ├── 2021-01-19.md ├── 2021-01-26.md ├── 2021-02-02.md ├── 2021-02-09.md ├── 2021-02-16.md ├── 2021-02-23.md ├── 2021-03-02.md ├── 2021-03-16.md ├── 2021-03-23.md ├── 2021-04-06.md ├── 2021-04-13.md ├── 2021-04-20.md ├── 2021-04-27.md ├── 2021-05-04.md ├── 2021-05-11.md ├── 2021-05-18.md ├── 2021-05-25.md ├── 2021-06-01.md ├── 2021-06-08.md ├── 2021-06-15.md ├── 2021-06-22.md ├── 2021-06-29.md ├── 2021-07-13.md ├── 2021-07-20.md ├── 2021-08-03.md ├── 2021-08-17.md ├── 2021-08-31.md ├── 2021-09-07.md ├── 2021-09-14.md ├── 2021-09-28.md ├── 2021-10-05.md ├── 2021-10-12.md ├── 2021-10-19.md ├── 2021-10-26.md ├── 2021-11-02.md ├── 2021-11-09.md ├── 2021-11-16.md ├── 2021-11-23.md ├── 2021-12-07.md ├── 2022-01-11.md ├── 2022-01-18.md ├── 2022-01-25.md ├── 2022-02-02.md ├── 2022-02-08.md ├── 2022-02-22.md ├── 2022-03-01.md ├── 2022-03-15.md ├── 2022-03-22.md ├── 2022-03-29.md ├── 2022-04-05.md ├── 2022-04-12.md ├── 2022-04-26.md ├── 2022-05-03.md ├── 2022-05-10.md ├── 2022-05-17.md ├── 2022-05-24.md ├── 2022-05-31.md ├── 2022-06-14.md ├── 2022-06-21.md ├── 2022-06-28.md ├── 2022-07-12.md ├── 2022-07-19.md ├── 2022-07-26.md ├── 2022-08-16.md ├── 2022-08-30.md ├── 2022-09-06.md ├── 2022-09-13.md ├── 2022-09-20.md ├── 2022-09-27.md ├── 2022-10-04.md ├── 2022-10-11.md ├── 2022-10-18.md ├── 2022-11-01.md ├── 2022-11-29.md ├── 2023-01-10.md ├── 2023-01-17.md ├── 2023-01-24.md ├── 2023-02-07.md ├── 2023-04-18.md ├── 2023-04-25.md ├── 2023-05-02.md ├── 2023-06-27.md ├── 2023-07-25.md ├── 2023-09-05.md ├── 2023-09-19.md ├── 2023-10-17.md ├── 2023-11-07.md ├── 2023-12-19.md ├── 2024-01-16.md ├── 2024-01-23.md ├── 2024-02-06.md ├── 2024-02-13.md ├── 2024-03-12.md ├── 2024-03-19.md ├── 2024-04-06.md ├── 2024-04-23.md ├── 2024-04-30.md ├── 2024-05-14.md ├── 2024-05-21.md ├── 2024-06-25.md ├── 2024-07-02.md ├── 2024-08-27.md ├── 2024-09-10.md ├── 2024-09-24.md ├── 2024-10-08.md ├── 2024-10-22.md ├── 2024-10-29.md ├── 2024-11-05.md ├── 2024-12-03.md ├── 2025-01-09.md ├── 2025-01-22.md ├── 2025-02-05.md ├── 2025-03-26.md └── 2025-05-07.md └── process ├── codereview.md ├── deprecation.md ├── release.md └── security.md /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Create a report to help us improve 4 | title: "[BUG]" 5 | labels: bug 6 | assignees: '' 7 | 8 | --- 9 | 10 | ### Environment 11 | **Operating System:** (e.g. Windows 2019, macOS-10.15, Linux CentOS 7.4) 12 | **Version / Commit SHA:** (e.g VDB 7.2, SHA: 1a2b3c4d5e...) 13 | **Other:** (e.g compiler, C++ standard etc.) 14 | 15 | ### Describe the bug 16 | (A clear and concise description of what the bug is.) 17 | 18 | ### To Reproduce 19 | Steps to reproduce the behavior: 20 | 1. Build with '...' 21 | 2. Run function '....' 22 | 3. See error 23 | 24 | ### Expected behavior 25 | (A clear and concise description of what you expected to happen.) 26 | 27 | ### Additional context 28 | (Add any other context about the problem here.) 29 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/build---installation.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Build / Installation 3 | about: Describe a problem with installation 4 | title: "[BUILD]" 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | ### Environment 11 | **Operating System:** (e.g. Windows 2019, macOS-10.15, Linux CentOS 7.4) 12 | **Version / Commit SHA:** (e.g VDB 7.2, SHA: 1a2b3c4d5e...) 13 | **CMake Version:** (e.g. 3.18) 14 | **Compiler:** (e.g. gcc 10, msvc 2019) 15 | 16 | ### Describe the problem 17 | (A clear and concise description of the encountered issue.) 18 | 19 | ### To Reproduce 20 | Steps to reproduce the behavior: 21 | 1. Checkout repo '...' 22 | 2. Run CMake '....' 23 | 3. Build with '....' 24 | 4. See error 25 | 26 | ### Additional context 27 | (Add any other context about the problem here.) 28 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Feature request 3 | about: Suggest an idea for this project 4 | title: "[REQUEST]" 5 | labels: enhancement 6 | assignees: '' 7 | 8 | --- 9 | 10 | ### Is your feature request related to a problem? Please describe. 11 | (A clear and concise description of what the problem is) 12 | 13 | ### Describe the solution you'd like 14 | (A clear and concise description of what you want to happen.) 15 | 16 | ### Describe alternatives you've considered 17 | (A clear and concise description of any alternative solutions or features you've considered.) 18 | 19 | ### Additional context 20 | (Add any other context or screenshots about the feature request here.) 21 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /build/* 2 | .DS_Store 3 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | All participants agree to abide by LF Projects Code of Conduct (as defined in the [charter](tsc/charter.md)) available at https://lfprojects.org/policies/code-of-conduct/ 2 | -------------------------------------------------------------------------------- /MAINTAINERS.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | # OpenVDB Committers 5 | 6 | The current OpenVDB maintainers are: 7 | 8 | 9 | | Name | Email | 10 | | ---------------- | ----------------- 11 | | Jeff Lait | jlait@sidefx.com 12 | | Dan Bailey | danbailey@ilm.com 13 | | Nick Avramoussis | navramoussis@wetafx.co.nz 14 | | Ken Museth | ken.museth@gmail.com 15 | | Andre Pradhana | andre.pradhana@gmail.com 16 | | Richard Jones | richardj@ilm.com 17 | | Gregory Hurst | tbd 18 | | Jonathan Swartz | tbd 19 | -------------------------------------------------------------------------------- /RE-LICENSE_NOTE.txt: -------------------------------------------------------------------------------- 1 | The following copyright holders agree that all of their contributions 2 | originally submitted to this project under the Mozilla Public License 3 | Version 2.0, are hereby relicensed to the Apache License, Version 2.0, 4 | and are submitted pursuant to the Developer Certificate of Origin, version 1.1: 5 | 6 | Ken Museth 7 | Mehdi Chinoune 8 | DreamWorks Animation 9 | Side Effects Software Inc. 10 | Blender Foundation 11 | NVIDIA Corporation 12 | United Therapeutics Corporation 13 | Digital Domain 3.0, Inc. 14 | Double Negative 15 | Ubisoft Entertainment SA 16 | Adobe Inc. 17 | Mathieu Malaterre 18 | Brecht Sanders 19 | Ignacio Vizzo 20 | Ben FrantzDale 21 | Sebastian Gaida 22 | Alessio Quaglino 23 | Benedikt Mersch 24 | David Aguilar 25 | Brian Sharpe 26 | Kartik Shrivastava 27 | Michael Lackner 28 | Lucas Baraya 29 | Kuba Roth 30 | Tom Cnops 31 | Walt Disney Pictures (Walt Disney Animation Studios) 32 | The Linux Foundation 33 | Industrial Light & Magic (ILM) 34 | -------------------------------------------------------------------------------- /ci/build_sonar.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -ex 6 | 7 | wget -q https://sonarcloud.io/static/cpp/build-wrapper-linux-x86.zip 8 | unzip build-wrapper-linux-x86.zip 9 | 10 | mkdir build 11 | cd build 12 | cmake \ 13 | -DCMAKE_CXX_COMPILER=g++ \ 14 | -DOPENVDB_ABI_VERSION_NUMBER=6 \ 15 | -DUSE_BLOSC=ON \ 16 | -DOPENVDB_CXX_STRICT=ON \ 17 | -DOPENVDB_BUILD_UNITTESTS=ON \ 18 | -DOPENVDB_BUILD_BINARIES=OFF \ 19 | -DOPENVDB_CORE_STATIC=OFF \ 20 | -DOPENVDB_BUILD_PYTHON_MODULE=OFF \ 21 | -DOPENVDB_CODE_COVERAGE=ON \ 22 | .. 23 | 24 | ../build-wrapper-linux-x86/build-wrapper-linux-x86-64 --out-dir bw_output make -j2 25 | -------------------------------------------------------------------------------- /ci/install_blosc.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -ex 6 | 7 | BLOSC_VERSION="$1" 8 | INSTALL_ROOT="$2" 9 | CMAKE_EXTRA=() 10 | if [ ! -z "${INSTALL_ROOT}" ]; then 11 | CMAKE_EXTRA+=("-DCMAKE_INSTALL_PREFIX=${INSTALL_ROOT}") 12 | fi 13 | 14 | git clone https://github.com/Blosc/c-blosc.git 15 | cd c-blosc 16 | 17 | if [ "$BLOSC_VERSION" != "latest" ]; then 18 | git checkout tags/v${BLOSC_VERSION} -b v${BLOSC_VERSION} 19 | fi 20 | 21 | mkdir build 22 | cd build 23 | 24 | # On MacOS there's a bug between blosc 1.14-1.20 where unistd isn't included 25 | # in zlib-1.2.8/gzlib.c. Provide -DPREFER_EXTERNAL_ZLIB to use the installed 26 | # version of zlib. 27 | # https://github.com/Blosc/python-blosc/issues/229 28 | cmake \ 29 | -DPREFER_EXTERNAL_ZLIB=ON \ 30 | -DBUILD_STATIC=OFF \ 31 | -DBUILD_TESTS=OFF \ 32 | -DBUILD_FUZZERS=OFF \ 33 | -DBUILD_BENCHMARKS=OFF \ 34 | "${CMAKE_EXTRA[@]}" \ 35 | .. 36 | 37 | make -j8 38 | make install 39 | -------------------------------------------------------------------------------- /ci/install_cppunit.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -ex 6 | CURL_VERSION="$1" 7 | 8 | wget -O cppunit.tar.gz https://dev-www.libreoffice.org/src/cppunit-${CURL_VERSION}.tar.gz 9 | 10 | tar -xzf cppunit.tar.gz 11 | 12 | cd cppunit-${CURL_VERSION} 13 | 14 | ./configure 15 | 16 | make -j8 17 | make install 18 | -------------------------------------------------------------------------------- /ci/install_doxygen.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -ex 6 | 7 | DOXYGEN_VERSION="$1" 8 | 9 | git clone https://github.com/doxygen/doxygen.git 10 | cd doxygen 11 | 12 | if [ "$DOXYGEN_VERSION" != "latest" ]; then 13 | git checkout Release_${DOXYGEN_VERSION} -b v${DOXYGEN_VERSION} 14 | fi 15 | 16 | mkdir build 17 | cd build 18 | cmake ../. 19 | make -j8 20 | make install 21 | -------------------------------------------------------------------------------- /ci/install_glfw.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -ex 6 | GLFW_VERSION="$1" 7 | 8 | git clone https://github.com/glfw/glfw.git 9 | cd glfw 10 | 11 | if [ "$GLFW_VERSION" != "latest" ]; then 12 | git checkout tags/${GLFW_VERSION} -b ${GLFW_VERSION} 13 | fi 14 | 15 | mkdir build 16 | cd build 17 | 18 | cmake .. 19 | 20 | make -j8 21 | make install 22 | -------------------------------------------------------------------------------- /ci/install_gtest.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -ex 6 | 7 | GTEST_VERSION="$1" 8 | 9 | 10 | git clone https://github.com/google/googletest.git -b v${GTEST_VERSION} 11 | cd googletest 12 | mkdir build 13 | cd build 14 | cmake .. 15 | 16 | make -j$(nproc) 17 | 18 | sudo make install 19 | -------------------------------------------------------------------------------- /ci/install_llvm_windows.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -ex 6 | 7 | LLVM_CRT="$1" 8 | 9 | git clone -b llvmorg-14.0.0 --depth 1 https://github.com/llvm/llvm-project.git llvm 10 | cd llvm 11 | 12 | mkdir .build 13 | cd .build 14 | 15 | # @note currently only test static builds with MT 16 | cmake -B . -S ../llvm -A x64 -G "Visual Studio 17 2022" -Thost=x64 \ 17 | -DCMAKE_INSTALL_PREFIX="${HOME}/llvm_install" \ 18 | -DLLVM_TARGETS_TO_BUILD="host" \ 19 | -DLLVM_BUILD_TOOLS=OFF \ 20 | -DLLVM_INCLUDE_BENCHMARKS=OFF \ 21 | -DLLVM_INCLUDE_EXAMPLES=OFF \ 22 | -DLLVM_INCLUDE_TESTS=OFF \ 23 | -DLLVM_INCLUDE_TOOLS=OFF \ 24 | -DLLVM_USE_CRT_RELEASE=${LLVM_CRT} 25 | 26 | cmake --build . --config Release --target install 27 | 28 | cd .. 29 | 30 | du -h .build -d0 31 | du -h ${HOME}/llvm_install -d0 32 | 33 | rm -rf .build 34 | -------------------------------------------------------------------------------- /ci/install_nanobind.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -ex 6 | 7 | PYBIND11_VERSION="$1" 8 | INSTALL_ROOT="$2" 9 | CMAKE_EXTRA=() 10 | if [ ! -z "${INSTALL_ROOT}" ]; then 11 | CMAKE_EXTRA+=("-DCMAKE_INSTALL_PREFIX=${INSTALL_ROOT}") 12 | fi 13 | 14 | git clone --recurse-submodules https://github.com/wjakob/nanobind.git 15 | cd nanobind 16 | 17 | if [ "$PYBIND11_VERSION" != "latest" ]; then 18 | git checkout tags/v${PYBIND11_VERSION} -b v${PYBIND11_VERSION} 19 | fi 20 | 21 | mkdir build 22 | cd build 23 | 24 | cmake \ 25 | -DNB_TEST=OFF \ 26 | "${CMAKE_EXTRA[@]}" \ 27 | .. 28 | 29 | make -j8 30 | sudo make install 31 | -------------------------------------------------------------------------------- /ci/install_tbb_macos.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | 5 | set -x 6 | 7 | brew update 8 | brew install tbb 9 | -------------------------------------------------------------------------------- /ci/install_windows.ps1: -------------------------------------------------------------------------------- 1 | # Enable verbose and stop on error 2 | $ErrorActionPreference = "Stop" 3 | $VerbosePreference = "Continue" 4 | 5 | # Required dependencies 6 | $vcpkgPackages = @( 7 | "zlib", 8 | "libpng", 9 | "openexr", 10 | "tbb", 11 | "gtest", 12 | "cppunit", 13 | "blosc", 14 | "glfw3", 15 | "glew", 16 | "python3", 17 | "jemalloc", 18 | "boost-iostreams", 19 | "boost-interprocess", 20 | "boost-algorithm", 21 | "nanobind" 22 | ) 23 | 24 | # Update vcpkg 25 | vcpkg update 26 | 27 | # Allow the vcpkg command to fail once so we can retry with the latest 28 | try { 29 | vcpkg install $vcpkgPackages 30 | } catch { 31 | Write-Host "vcpkg install failed, retrying with latest ports..." 32 | # Retry the installation with updated ports 33 | Push-Location $env:VCPKG_INSTALLATION_ROOT 34 | git pull 35 | Pop-Location 36 | vcpkg update 37 | vcpkg install $vcpkgPackages 38 | } 39 | 40 | Write-Host "vcpkg install completed successfully" 41 | -------------------------------------------------------------------------------- /ci/test_install.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright Contributors to the OpenVDB Project 3 | # SPDX-License-Identifier: Apache-2.0 4 | set -e 5 | 6 | # Various tests to test the FindOpenVDB CMake modules and 7 | # general VDB installation 8 | 9 | # 1) Test basic CMakeLists is able to build vdb_print with 10 | # the expected VDB installation 11 | 12 | cmakelists=" 13 | cmake_minimum_required(VERSION 3.20) 14 | project(TestInstall LANGUAGES CXX) 15 | find_package(OpenVDB REQUIRED COMPONENTS openvdb) 16 | add_executable(test_vdb_print \"../openvdb_cmd/vdb_print/main.cc\") 17 | target_link_libraries(test_vdb_print OpenVDB::openvdb) 18 | " 19 | mkdir tmp 20 | cd tmp 21 | echo -e "$cmakelists" > CMakeLists.txt 22 | cmake -DCMAKE_MODULE_PATH=/usr/local/lib64/cmake/OpenVDB/ . 23 | cmake --build . --config Release --target test_vdb_print 24 | -------------------------------------------------------------------------------- /cmake/CPM.cmake: -------------------------------------------------------------------------------- 1 | # SPDX-License-Identifier: MIT 2 | # 3 | # SPDX-FileCopyrightText: Copyright (c) 2019-2023 Lars Melchior and contributors 4 | 5 | set(CPM_DOWNLOAD_VERSION 0.40.2) 6 | set(CPM_HASH_SUM "c8cdc32c03816538ce22781ed72964dc864b2a34a310d3b7104812a5ca2d835d") 7 | 8 | if(CPM_SOURCE_CACHE) 9 | set(CPM_DOWNLOAD_LOCATION "${CPM_SOURCE_CACHE}/cpm/CPM_${CPM_DOWNLOAD_VERSION}.cmake") 10 | elseif(DEFINED ENV{CPM_SOURCE_CACHE}) 11 | set(CPM_DOWNLOAD_LOCATION "$ENV{CPM_SOURCE_CACHE}/cpm/CPM_${CPM_DOWNLOAD_VERSION}.cmake") 12 | else() 13 | set(CPM_DOWNLOAD_LOCATION "${CMAKE_BINARY_DIR}/cmake/CPM_${CPM_DOWNLOAD_VERSION}.cmake") 14 | endif() 15 | 16 | # Expand relative path. This is important if the provided path contains a tilde (~) 17 | get_filename_component(CPM_DOWNLOAD_LOCATION ${CPM_DOWNLOAD_LOCATION} ABSOLUTE) 18 | 19 | file(DOWNLOAD 20 | https://github.com/cpm-cmake/CPM.cmake/releases/download/v${CPM_DOWNLOAD_VERSION}/CPM.cmake 21 | ${CPM_DOWNLOAD_LOCATION} EXPECTED_HASH SHA256=${CPM_HASH_SUM} 22 | ) 23 | 24 | include(${CPM_DOWNLOAD_LOCATION}) 25 | -------------------------------------------------------------------------------- /cmake/scripts/lsan.supp: -------------------------------------------------------------------------------- 1 | ################################################################################# 2 | ## This file is loaded by the Leak/Address Sanitizer build for the unit tests. ## 3 | ## It can be used to ignore various errors reported by the sanitizer. This is ## 4 | ## especially useful with upstream issues (e.g. boost/tbb). For help defining ## 5 | ## suppression rules, see: ## 6 | ## https://clang.llvm.org/docs/AddressSanitizer.html ## 7 | ## The build is configured with CMAKE_BUILD_TYPE=asan or lsan ## 8 | ################################################################################# 9 | 10 | ##### Upstream ##### 11 | 12 | # Leaks from TBB init which occur due to tbb teardown issues 13 | # https://github.com/oneapi-src/oneTBB/issues/206 14 | # Should be fixed in oneTBB. Ignore them for now 15 | leak:tbb::internal::task_stream<3>::initialize* 16 | -------------------------------------------------------------------------------- /doc/img/banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AcademySoftwareFoundation/openvdb/67964d1e15f5aaeaffe56751f54d8fc5a5d4bed1/doc/img/banner.png -------------------------------------------------------------------------------- /doc/img/multiparm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AcademySoftwareFoundation/openvdb/67964d1e15f5aaeaffe56751f54d8fc5a5d4bed1/doc/img/multiparm.png -------------------------------------------------------------------------------- /doc/img/tabmenu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AcademySoftwareFoundation/openvdb/67964d1e15f5aaeaffe56751f54d8fc5a5d4bed1/doc/img/tabmenu.png -------------------------------------------------------------------------------- /doc/nanovdb/doc.md: -------------------------------------------------------------------------------- 1 | # NanoVDB {#NanoVDB_MainPage} 2 | 3 | Welcome to the NanoVDB documentation page. 4 | 5 | * @subpage NanoVDB_HowToBuild 6 | * @subpage NanoVDB_FAQ 7 | * @subpage NanoVDB_SourceTree 8 | * @subpage NanoVDB_HelloWorld 9 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/Readme.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | # NanoVDB: 4 | A lightweight GPU friendly version of VDB initially targeting rendering applications. 5 | 6 | * [Build instructions for make and cmake](../../doc/nanovdb/HowToBuild.md) 7 | * [Frequently asked questions](../../doc/nanovdb/FAQ.md) 8 | * [Source tree](../../doc/nanovdb/SourceTree.md) 9 | * [Examples](../../doc/nanovdb/HelloWorld.md) 10 | 11 | ### Copyright Contributors to the OpenVDB Project 12 | ### SPDX-License-Identifier: Apache-2.0 13 | 14 | [![CircleCI](https://circleci.com/gh/NVIDIA-Omniverse/NanoVDB.svg?style=svg&circle-token=6c3b9bb166841033a0e0c1a9ee5ac49f73d89152)](https://circleci.com/gh/NVIDIA-Omniverse/NanoVDB) 15 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/examples/ex_collide_level_set/common.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #pragma once 5 | 6 | #define _USE_MATH_DEFINES 7 | #include 8 | #include 9 | #include 10 | #include 11 | #include "ComputePrimitives.h" 12 | 13 | // http://www.burtleburtle.net/bob/hash/doobs.html 14 | inline __hostdev__ uint32_t hash(uint32_t x) 15 | { 16 | x += (x << 10u); 17 | x ^= (x >> 6u); 18 | x += (x << 3u); 19 | x ^= (x >> 11u); 20 | x += (x << 15u); 21 | return x; 22 | } 23 | 24 | inline __hostdev__ float randomf(uint32_t s) 25 | { 26 | return hash(s) / float(0xffffffffu); 27 | } 28 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/examples/ex_make_nanovdb_sphere/make_nanovdb_sphere.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include 5 | 6 | #include 7 | 8 | /// @brief Creates a NanoVDB grid of a level set sphere and access a value. 9 | /// 10 | /// @note This example only depends on NanoVDB. 11 | int main() 12 | { 13 | try { 14 | auto handle = nanovdb::tools::createLevelSetSphere(100.0f); 15 | 16 | auto* dstGrid = handle.grid(); // Get a (raw) pointer to the NanoVDB grid form the GridManager. 17 | if (!dstGrid) 18 | throw std::runtime_error("GridHandle does not contain a grid with value type float"); 19 | 20 | // Access and print out a single value (inside the level set) from both grids 21 | printf("NanoVDB cpu: %4.2f\n", dstGrid->tree().getValue(nanovdb::Coord(99, 0, 0))); 22 | } 23 | catch (const std::exception& e) { 24 | std::cerr << "An exception occurred: \"" << e.what() << "\"" << std::endl; 25 | } 26 | return 0; 27 | } -------------------------------------------------------------------------------- /nanovdb/nanovdb/examples/ex_read_nanovdb_sphere/read_nanovdb_sphere.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include 5 | 6 | /// @brief Read a NanoVDB grid form file, check pointer and access a single value 7 | /// 8 | /// @note This example does NOT dpend on OpenVDB (or CUDA), only NanoVDB. 9 | int main() 10 | { 11 | try { 12 | auto handle = nanovdb::io::readGrid("data/sphere.nvdb"); // read first grid in file 13 | 14 | auto* grid = handle.grid(); // get a (raw) pointer to the first NanoVDB grid of value type float 15 | 16 | if (grid == nullptr) 17 | throw std::runtime_error("File did not contain a grid with value type float"); 18 | 19 | // Access and print out a single value in the NanoVDB grid 20 | printf("NanoVDB cpu: %4.2f\n", grid->tree().getValue(nanovdb::Coord(99, 0, 0))); 21 | } 22 | catch (const std::exception& e) { 23 | std::cerr << "An exception occurred: \"" << e.what() << "\"" << std::endl; 24 | } 25 | 26 | return 0; 27 | } -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyCreateNanoGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYCREATENANOGRID_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYCREATENANOGRID_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | template void defineCreateNanoGrid(nb::module_& m, const char* name); 13 | 14 | #ifdef NANOVDB_USE_OPENVDB 15 | template void defineOpenToNanoVDB(nb::module_& m); 16 | #endif 17 | 18 | } // namespace pynanovdb 19 | 20 | #endif 21 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyGridChecksum.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYGRIDCHECKSUM_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYGRIDCHECKSUM_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | void defineCheckMode(nb::module_& m); 13 | void defineChecksum(nb::module_& m); 14 | void defineUpdateChecksum(nb::module_& m); 15 | 16 | } // namespace pynanovdb 17 | 18 | #endif 19 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyGridHandle.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #include "PyGridHandle.h" 4 | #include 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | using namespace nb::literals; 10 | using namespace nanovdb; 11 | 12 | namespace pynanovdb { 13 | 14 | void defineHostGridHandle(nb::module_& m) 15 | { 16 | using BufferT = HostBuffer; 17 | defineGridHandle(m, "GridHandle") 18 | .def( 19 | "__init__", 20 | [](GridHandle& handle, nb::ndarray, nb::device::cpu> t) { 21 | auto buffer = BufferT::createFull(t.size() * sizeof(uint32_t), t.data()); 22 | new (&handle) GridHandle(std::move(buffer)); 23 | }, 24 | "t"_a.noconvert()); 25 | } 26 | 27 | } // namespace pynanovdb 28 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyGridStats.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #include "PyGridStats.h" 4 | 5 | #include 6 | 7 | namespace nb = nanobind; 8 | using namespace nanovdb; 9 | 10 | namespace pynanovdb { 11 | 12 | void defineStatsMode(nb::module_& m) 13 | { 14 | nb::enum_(m, "StatsMode") 15 | .value("Disable", tools::StatsMode::Disable) 16 | .value("BBox", tools::StatsMode::BBox) 17 | .value("MinMax", tools::StatsMode::MinMax) 18 | .value("All", tools::StatsMode::All) 19 | .value("Default", tools::StatsMode::Default) 20 | .value("End", tools::StatsMode::End); 21 | } 22 | 23 | } // namespace pynanovdb 24 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyGridStats.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYGRIDSTATS_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYGRIDSTATS_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | void defineStatsMode(nb::module_& m); 13 | 14 | } 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyGridValidator.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #include "PyGridValidator.h" 4 | 5 | #include 6 | #include 7 | #ifdef NANOVDB_USE_CUDA 8 | #include 9 | #endif 10 | 11 | #include 12 | 13 | namespace nb = nanobind; 14 | using namespace nb::literals; 15 | using namespace nanovdb; 16 | 17 | namespace pynanovdb { 18 | 19 | template void defineValidateGrids(nb::module_& m) 20 | { 21 | m.def("validateGrids", &tools::validateGrids>, "handle"_a, "mode"_a, "verbose"_a); 22 | } 23 | 24 | template void defineValidateGrids(nb::module_&); 25 | #ifdef NANOVDB_USE_CUDA 26 | template void defineValidateGrids(nb::module_&); 27 | #endif 28 | 29 | } // namespace pynanovdb 30 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyGridValidator.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYGRIDVALIDATOR_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYGRIDVALIDATOR_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | template void defineValidateGrids(nb::module_& m); 13 | 14 | } // namespace pynanovdb 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyHostBuffer.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #include "PyHostBuffer.h" 4 | 5 | #include 6 | 7 | namespace nb = nanobind; 8 | using namespace nanovdb; 9 | 10 | namespace pynanovdb { 11 | 12 | void defineHostBuffer(nb::module_& m) 13 | { 14 | nb::class_(m, "HostBuffer"); 15 | } 16 | 17 | } // namespace pynanovdb 18 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyHostBuffer.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYHOSTBUFFER_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYHOSTBUFFER_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | void defineHostBuffer(nb::module_& m); 13 | 14 | } 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyIO.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYIO_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYIO_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | void defineIOModule(nb::module_& m); 13 | 14 | } // namespace pynanovdb 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyMath.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYMATH_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYMATH_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | void defineMathModule(nb::module_& m); 13 | 14 | } // namespace pynanovdb 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyNanoToOpenVDB.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #include "PyNanoToOpenVDB.h" 4 | 5 | #include 6 | #include 7 | #ifdef NANOVDB_USE_OPENVDB 8 | #include 9 | #include 10 | #endif 11 | 12 | namespace nb = nanobind; 13 | using namespace nb::literals; 14 | using namespace nanovdb; 15 | 16 | namespace pynanovdb { 17 | 18 | template void defineNanoToOpenVDB(nb::module_& m) 19 | { 20 | #ifdef NANOVDB_USE_OPENVDB 21 | // Wrap nanoToOpenVDB into a lambda to workaround an MSVC compiler bug 22 | m.def( 23 | "nanoToOpenVDB", [](GridHandle& handle, int verbose, uint32_t n){ 24 | return tools::nanoToOpenVDB(handle, verbose, n); 25 | }, "handle"_a, "verbose"_a = 0, "n"_a = 0); 26 | #endif 27 | } 28 | 29 | template void defineNanoToOpenVDB(nb::module_&); 30 | 31 | } // namespace pynanovdb 32 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyNanoToOpenVDB.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYNANOTOOPENVDB_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYNANOTOOPENVDB_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | template void defineNanoToOpenVDB(nb::module_& m); 13 | 14 | } // namespace pynanovdb 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyPrimitives.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYPRIMITIVES_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYPRIMITIVES_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | template void definePrimitives(nb::module_& m); 13 | 14 | } // namespace pynanovdb 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PySampleFromVoxels.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYSAMPLEFROMVOXELS_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYSAMPLEFROMVOXELS_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | template void defineNearestNeighborSampler(nb::module_& m, const char* name); 13 | template void defineTrilinearSampler(nb::module_& m, const char* name); 14 | template void defineTriquadraticSampler(nb::module_& m, const char* name); 15 | template void defineTricubicSampler(nb::module_& m, const char* name); 16 | 17 | } // namespace pynanovdb 18 | 19 | #endif 20 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/PyTools.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_PYTOOLS_HAS_BEEN_INCLUDED 4 | #define NANOVDB_PYTOOLS_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | void defineToolsModule(nb::module_& m); 13 | 14 | } // namespace pynanovdb 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright Contributors to the OpenVDB Project 2 | # SPDX-License-Identifier: Apache-2.0 3 | import sys 4 | if sys.platform == "win32": 5 | import os 6 | openvdb_dll_directory = os.path.join(os.path.dirname(os.path.abspath(__file__)), os.pardir, 'openvdb', 'lib') 7 | os.add_dll_directory(directory) 8 | 9 | from .lib.nanovdb import * 10 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/cuda/PyDeviceBuffer.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifdef NANOVDB_USE_CUDA 4 | 5 | #include "PyDeviceBuffer.h" 6 | 7 | #include 8 | 9 | namespace nb = nanobind; 10 | using namespace nanovdb; 11 | 12 | namespace pynanovdb { 13 | 14 | void defineDeviceBuffer(nb::module_& m) 15 | { 16 | nb::class_(m, "DeviceBuffer"); 17 | } 18 | 19 | } // namespace pynanovdb 20 | 21 | #endif 22 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/cuda/PyDeviceBuffer.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_CUDA_PYDEVICEBUFFER_HAS_BEEN_INCLUDED 4 | #define NANOVDB_CUDA_PYDEVICEBUFFER_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | #ifdef NANOVDB_USE_CUDA 13 | void defineDeviceBuffer(nb::module_& m); 14 | #endif 15 | 16 | } // namespace pynanovdb 17 | 18 | #endif 19 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/cuda/PyPointsToGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_CUDA_PYPOINTSTOGRID_HAS_BEEN_INCLUDED 4 | #define NANOVDB_CUDA_PYPOINTSTOGRID_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | template void definePointsToGrid(nb::module_& m, const char* name); 13 | 14 | } // namespace pynanovdb 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/cuda/PySampleFromVoxels.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_CUDA_PYSAMPLEFROMVOXELS_HAS_BEEN_INCLUDED 4 | #define NANOVDB_CUDA_PYSAMPLEFROMVOXELS_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | template void defineSampleFromVoxels(nb::module_& m, const char* name); 13 | 14 | } // namespace pynanovdb 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/cuda/PySignedFloodFill.cu: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #include "PySignedFloodFill.h" 4 | 5 | #include 6 | 7 | namespace nb = nanobind; 8 | using namespace nb::literals; 9 | using namespace nanovdb; 10 | 11 | namespace pynanovdb { 12 | 13 | template void defineSignedFloodFill(nb::module_& m, const char* name) 14 | { 15 | m.def( 16 | name, [](NanoGrid* d_grid, bool verbose) { return tools::cuda::signedFloodFill(d_grid, verbose); }, "d_grid"_a, "verbose"_a = false); 17 | } 18 | 19 | template void defineSignedFloodFill(nb::module_&, const char*); 20 | template void defineSignedFloodFill(nb::module_&, const char*); 21 | 22 | } // namespace pynanovdb 23 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/python/cuda/PySignedFloodFill.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | #ifndef NANOVDB_CUDA_PYSIGNEDFLOODFILL_HAS_BEEN_INCLUDED 4 | #define NANOVDB_CUDA_PYSIGNEDFLOODFILL_HAS_BEEN_INCLUDED 5 | 6 | #include 7 | 8 | namespace nb = nanobind; 9 | 10 | namespace pynanovdb { 11 | 12 | template void defineSignedFloodFill(nb::module_& m, const char* name); 13 | 14 | } // namespace pynanovdb 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/CpuTimer.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/util/Timer.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/CreateNanoGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/CreateNanoGrid.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/DitherLUT.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/math/DitherLUT.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/GridBuilder.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/GridBuilder.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/GridChecksum.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/GridChecksum.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/GridStats.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/GridStats.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/GridValidator.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/GridValidator.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/HDDA.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/math/HDDA.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/HostBuffer.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/HostBuffer.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/IO.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/io/IO.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/NanoToOpenVDB.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/NanoToOpenVDB.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/NodeManager.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/NodeManager.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/OpenToNanoVDB.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Use nanovdb/tools/CreateNanoGrid.h instead.") -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/Primitives.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/CreatePrimitives.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/Ray.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/math/Ray.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/SampleFromVoxels.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/math/SampleFromVoxels.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/Stencils.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/math/Stencils.h instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaAddBlindData.cuh: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/cuda/AddBlindData.cuh instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaDeviceBuffer.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/cuda/DeviceBuffer.h instead.") -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaGridChecksum.cuh: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/cuda/GridChecksum.cuh instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaGridHandle.cuh: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/cuda/GridHandle.cuh instead.") -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaGridStats.cuh: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/cuda/GridStats.cuh instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaGridValidator.cuh: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/cuda/GridValidator.cuh instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaIndexToGrid.cuh: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/cuda/IndexToGrid.cuh instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaNodeManager.cuh: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/cuda/NodeManager.cuh instead.") -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaPointsToGrid.cuh: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/cuda/PointsToGrid.cuh instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaSignedFloodFill.cuh: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/tools/cuda/SignedFloodFill.cuh instead.") 7 | -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/CudaUtils.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/util/cuda/Util.h instead.") -------------------------------------------------------------------------------- /nanovdb/nanovdb/util/cuda/GpuTimer.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for NANOVDB_DEPRECATED_HEADER 5 | #include 6 | NANOVDB_DEPRECATED_HEADER("Include nanovdb/util/cuda/Timer.h instead.") -------------------------------------------------------------------------------- /openvdb/openvdb/COPYRIGHT: -------------------------------------------------------------------------------- 1 | Copyright Contributors to the OpenVDB Project 2 | SPDX-License-Identifier: Apache-2.0 -------------------------------------------------------------------------------- /openvdb/openvdb/Platform.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | // For Windows, we need these includes to ensure all OPENVDB_API 5 | // functions/classes are compiled into the shared library. 6 | #include "openvdb.h" 7 | #include "Exceptions.h" 8 | -------------------------------------------------------------------------------- /openvdb/openvdb/PlatformConfig.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | /// 4 | /// @file PlatformConfig.h 5 | /// @note PlatformConfig.h will be marked as deprecated in the future 6 | 7 | #include "Platform.h" 8 | 9 | -------------------------------------------------------------------------------- /openvdb/openvdb/README: -------------------------------------------------------------------------------- 1 | ======================================================================== 2 | OpenVDB 3 | ======================================================================== 4 | 5 | The OpenVDB library comprises a hierarchical data structure and a suite 6 | of tools for the efficient manipulation of sparse, possibly time-varying, 7 | volumetric data discretized on a three-dimensional grid. 8 | 9 | For instructions on library installation and dependencies see INSTALL 10 | 11 | For documentation of the library and code examples see: 12 | https://www.openvdb.org/documentation/doxygen 13 | 14 | For more details visit the project's home page: 15 | www.openvdb.org 16 | 17 | -------------------------------------------------------------------------------- /openvdb/openvdb/python/__init__.py: -------------------------------------------------------------------------------- 1 | # Copyright Contributors to the OpenVDB Project 2 | # SPDX-License-Identifier: Apache-2.0 3 | from .lib.openvdb import * 4 | -------------------------------------------------------------------------------- /openvdb/openvdb/python/pyFloatGrid.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | // 4 | /// @file pyFloatGrid.cc 5 | /// @author Peter Cucka 6 | /// @brief nanobind wrappers for scalar, floating-point openvdb::Grid types 7 | 8 | #include "pyGrid.h" 9 | 10 | /// Create a Python wrapper for each supported Grid type. 11 | void 12 | exportFloatGrid(nb::module_ m) 13 | { 14 | pyGrid::exportScalarGrid(m); 15 | #ifdef PY_OPENVDB_WRAP_ALL_GRID_TYPES 16 | pyGrid::exportScalarGrid(m); 17 | #endif 18 | 19 | m.def("createLevelSetSphere", 20 | &pyGrid::createLevelSetSphere, 21 | nb::arg("radius"), nb::arg("center")=openvdb::Coord(), nb::arg("voxelSize")=1.0, 22 | nb::arg("halfWidth")=openvdb::LEVEL_SET_HALF_WIDTH, 23 | "Return a grid containing a narrow-band level set representation\n" 24 | "of a sphere."); 25 | } 26 | -------------------------------------------------------------------------------- /openvdb/openvdb/python/pyIntGrid.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | // 4 | /// @file pyIntGrid.cc 5 | /// @brief nanobind wrappers for scalar, integer-valued openvdb::Grid types 6 | 7 | #include "pyGrid.h" 8 | 9 | void 10 | exportIntGrid(nb::module_ m) 11 | { 12 | pyGrid::exportScalarGrid(m); 13 | #ifdef PY_OPENVDB_WRAP_ALL_GRID_TYPES 14 | pyGrid::exportScalarGrid(m); 15 | pyGrid::exportScalarGrid(m); 16 | #endif 17 | } 18 | -------------------------------------------------------------------------------- /openvdb/openvdb/python/pyPointGrid.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | // 4 | /// @file pyPointGrid.cc 5 | /// @brief nanobind wrappers for point openvdb::Grid types 6 | 7 | #include 8 | 9 | #include "pyGrid.h" 10 | 11 | namespace nb = nanobind; 12 | 13 | 14 | #ifdef PY_OPENVDB_WRAP_ALL_GRID_TYPES 15 | void 16 | exportPointGrid(nb::module_ m) 17 | { 18 | pyGrid::exportGrid(m); 19 | } 20 | #else 21 | void 22 | exportPointGrid(nb::module_) 23 | { 24 | } 25 | #endif 26 | -------------------------------------------------------------------------------- /openvdb/openvdb/python/pyVec3Grid.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | // 4 | /// @file pyVec3Grid.cc 5 | /// @brief nanobind wrappers for vector-valued openvdb::Grid types 6 | 7 | #include "pyGrid.h" 8 | 9 | void 10 | exportVec3Grid(nb::module_ m) 11 | { 12 | pyGrid::exportVectorGrid(m); 13 | #ifdef PY_OPENVDB_WRAP_ALL_GRID_TYPES 14 | pyGrid::exportVectorGrid(m); 15 | pyGrid::exportVectorGrid(m); 16 | #endif 17 | } 18 | -------------------------------------------------------------------------------- /openvdb/openvdb/unittest/TestInt32Metadata.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include 5 | #include 6 | 7 | #include 8 | 9 | class TestInt32Metadata : public ::testing::Test 10 | { 11 | }; 12 | 13 | 14 | TEST_F(TestInt32Metadata, test) 15 | { 16 | using namespace openvdb; 17 | 18 | Metadata::Ptr m(new Int32Metadata(123)); 19 | Metadata::Ptr m2 = m->copy(); 20 | 21 | EXPECT_TRUE(dynamic_cast(m.get()) != 0); 22 | EXPECT_TRUE(dynamic_cast(m2.get()) != 0); 23 | 24 | EXPECT_TRUE(m->typeName().compare("int32") == 0); 25 | EXPECT_TRUE(m2->typeName().compare("int32") == 0); 26 | 27 | Int32Metadata *s = dynamic_cast(m.get()); 28 | EXPECT_TRUE(s->value() == 123); 29 | s->value() = 456; 30 | EXPECT_TRUE(s->value() == 456); 31 | 32 | m2->copy(*s); 33 | 34 | s = dynamic_cast(m2.get()); 35 | EXPECT_TRUE(s->value() == 456); 36 | } 37 | -------------------------------------------------------------------------------- /openvdb/openvdb/unittest/TestInt64Metadata.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include 5 | #include 6 | 7 | #include 8 | 9 | 10 | class TestInt64Metadata : public ::testing::Test 11 | { 12 | }; 13 | 14 | 15 | TEST_F(TestInt64Metadata, test) 16 | { 17 | using namespace openvdb; 18 | 19 | Metadata::Ptr m(new Int64Metadata(123)); 20 | Metadata::Ptr m2 = m->copy(); 21 | 22 | EXPECT_TRUE(dynamic_cast(m.get()) != 0); 23 | EXPECT_TRUE(dynamic_cast(m2.get()) != 0); 24 | 25 | EXPECT_TRUE(m->typeName().compare("int64") == 0); 26 | EXPECT_TRUE(m2->typeName().compare("int64") == 0); 27 | 28 | Int64Metadata *s = dynamic_cast(m.get()); 29 | EXPECT_TRUE(s->value() == 123); 30 | s->value() = 456; 31 | EXPECT_TRUE(s->value() == 456); 32 | 33 | m2->copy(*s); 34 | 35 | s = dynamic_cast(m2.get()); 36 | EXPECT_TRUE(s->value() == 456); 37 | } 38 | -------------------------------------------------------------------------------- /openvdb/openvdb/unittest/main.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include // for std::shuffle() 5 | #include // for std::round() 6 | #include // for EXIT_SUCCESS 7 | #include // for strrchr() 8 | #include 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | 15 | #include 16 | 17 | int 18 | main(int argc, char *argv[]) 19 | { 20 | ::testing::InitGoogleTest(&argc, argv); 21 | return RUN_ALL_TESTS(); 22 | } 23 | -------------------------------------------------------------------------------- /openvdb/openvdb/util/Assert.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | /// 4 | /// @file Platform.h 5 | 6 | #include "Assert.h" 7 | 8 | #include 9 | #include 10 | 11 | namespace openvdb { 12 | OPENVDB_USE_VERSION_NAMESPACE 13 | namespace OPENVDB_VERSION_NAME { 14 | 15 | [[noreturn]] void assertAbort( 16 | const char *assertion, 17 | const char *file, 18 | const unsigned line, 19 | const char *function, 20 | const char* msg) 21 | { 22 | std::fprintf(stderr, "%s:%u:", file, line); 23 | std::fprintf(stderr, " Assertion failed: "); 24 | std::fprintf(stderr, "'%s'", assertion); 25 | std::fprintf(stderr, " in function: "); 26 | std::fprintf(stderr, "'%s'", function); 27 | if (msg) std::fprintf(stderr, "\n%s", msg); 28 | std::fprintf(stderr, "\n"); 29 | // @todo could make this optional with another compile define 30 | std::abort(); 31 | } 32 | 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /openvdb/openvdb/util/ExplicitInstantiation.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDB_UTIL_EXPLICIT_INSTANTIATION_HAS_BEEN_INCLUDED 5 | #define OPENVDB_UTIL_EXPLICIT_INSTANTIATION_HAS_BEEN_INCLUDED 6 | 7 | #undef OPENVDB_INSTANTIATE 8 | #undef OPENVDB_INSTANTIATE_CLASS 9 | #undef OPENVDB_INSTANTIATE_STRUCT 10 | 11 | #define OPENVDB_INSTANTIATE template OPENVDB_TEMPLATE_EXPORT 12 | #define OPENVDB_INSTANTIATE_CLASS template class OPENVDB_TEMPLATE_EXPORT 13 | #define OPENVDB_INSTANTIATE_STRUCT template struct OPENVDB_TEMPLATE_EXPORT 14 | 15 | #endif // OPENVDB_UTIL_EXPLICIT_INSTANTIATION_HAS_BEEN_INCLUDED 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/grammar/generated/README: -------------------------------------------------------------------------------- 1 | This folder contains pre-generated grammar source and header files for 2 | OpenVDB AX. The grammar can be re-generated by using the OpenVDB AX 3 | CMake variable OPENVDB_BUILD_AX_GRAMMAR during the first run of CMake, 4 | in which case these files are ignored in favour of the new files from 5 | CMakes temporary build folder. 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_attr_create: -------------------------------------------------------------------------------- 1 | WARNING: position arguments [input.vdb ] are deprecated. use -i and -o 2 | WARNING: no output VDB File specified - nothing will be written to disk 3 | FATAL: Execution error! 4 | Errors: 5 | AXExecutionError: [1] error: Attribute "nonexist" does not exist on grid "points". 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_10: -------------------------------------------------------------------------------- 1 | ERROR: AXCompilerError: Function "ax.compute.voxel.k1" cannot be called for the current target:"ax.volume.module". This function only runs on OpenVDB Point Grids. 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_11: -------------------------------------------------------------------------------- 1 | WARNING: position arguments [input.vdb ] are deprecated. use -i and -o 2 | FATAL: analyze does not take input vdb files. See 'vdb_ax --help' 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_12: -------------------------------------------------------------------------------- 1 | FATAL: CLIError: positional argument 'execute' used after optional argument. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_13: -------------------------------------------------------------------------------- 1 | FATAL: CLIError: positional argument 'execute' used after optional argument. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_14: -------------------------------------------------------------------------------- 1 | FATAL: analyze does not take input vdb files. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_15: -------------------------------------------------------------------------------- 1 | FATAL: vdb_ax functions requires a valid option. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_16: -------------------------------------------------------------------------------- 1 | FATAL: functions does not take input vdb files. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_17: -------------------------------------------------------------------------------- 1 | FATAL: position arguments [input.vdb ] are deprecated and cannot be used with -i and -o. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_18: -------------------------------------------------------------------------------- 1 | FATAL: position arguments [input.vdb ] are deprecated and cannot be used with -i and -o. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_19: -------------------------------------------------------------------------------- 1 | FATAL: CLIError: Unable to convert argument: 'nan' to a valid interger. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_2: -------------------------------------------------------------------------------- 1 | FATAL: no vdb files have been provided. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_20: -------------------------------------------------------------------------------- 1 | FATAL: CLIError: Unable to convert argument: 'nan' to a valid interger. See 'vdb_ax --help' 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_4: -------------------------------------------------------------------------------- 1 | FATAL: File Load Error: invalid_file 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_5: -------------------------------------------------------------------------------- 1 | [1] error: implicit conversion in assignment (possible truncation) [warning-as-error] 1:1 2 | int a = 1.0; 3 | ^ 4 | [2] error: implicit conversion in assignment (possible truncation) [warning-as-error] 1:1 5 | int a = 1.0; 6 | ^ 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_6: -------------------------------------------------------------------------------- 1 | [1] error: implicit conversion in assignment (possible truncation) [warning-as-error] 1:1 2 | int a = 1.0; int a = 1.0; 3 | ^ 4 | [2] error: local variable "a" has already been declared 1:14 5 | int a = 1.0; int a = 1.0; 6 | -------------^ 7 | [3] error: implicit conversion in assignment (possible truncation) [warning-as-error] 1:1 8 | int a = 1.0; int a = 1.0; 9 | ^ 10 | [4] error: local variable "a" has already been declared 1:14 11 | int a = 1.0; int a = 1.0; 12 | -------------^ 13 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_7: -------------------------------------------------------------------------------- 1 | [1] error: implicit conversion in assignment (possible truncation) [warning-as-error] 1:1 2 | int a = 1.0; int a = 1.0; 3 | ^ 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_8: -------------------------------------------------------------------------------- 1 | [1] error: implicit conversion in assignment (possible truncation) [warning-as-error] 1:1 2 | int a = 1.0; int a = 1.0; 3 | ^ 4 | [2] error: local variable "a" has already been declared 1:14 5 | int a = 1.0; int a = 1.0; 6 | -------------^ 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_fail_9: -------------------------------------------------------------------------------- 1 | [1] error: unexpected IDENTIFIER, expecting SEMICOLON 1:9 2 | invalid code; 3 | --------^ 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_ls_sphere_1: -------------------------------------------------------------------------------- 1 | WARNING: position arguments [input.vdb ] are deprecated. use -i and -o 2 | WARNING: no output VDB File specified - nothing will be written to disk 3 | 0.0508118 4 | 0.10083 5 | 0.050415 6 | 0.0508118 7 | 0.100403 8 | 0.10083 9 | 0.050415 10 | 0.100403 11 | 0.0508118 12 | 0.10083 13 | 0.0499878 14 | 0.050415 15 | 0.0999756 16 | 0.100403 17 | 0.050415 18 | 0.0508118 19 | 0.100403 20 | 0.10083 21 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_ls_sphere_2: -------------------------------------------------------------------------------- 1 | WARNING: position arguments [input.vdb ] are deprecated. use -i and -o 2 | WARNING: no output VDB File specified - nothing will be written to disk 3 | 0.0508118 4 | 0.10083 5 | 0.050415 6 | 0.0508118 7 | 0.100403 8 | 0.10083 9 | 0.050415 10 | 0.100403 11 | 0.0508118 12 | 0.10083 13 | 0.0499878 14 | 0.050415 15 | 0.0999756 16 | 0.100403 17 | 0.050415 18 | 0.0508118 19 | 0.100403 20 | 0.10083 21 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_10: -------------------------------------------------------------------------------- 1 | [1] warning: declaration of variable "i" shadows a previous declaration 24:9 2 | for(int32 i = 0; i < 3;) { 3 | --------^ 4 | [2] warning: implicit conversion in function call 61:33 5 | for (int32 i = 5; int32 k = floor(i - 1); --i) j++; 6 | --------------------------------^ 7 | [3] warning: implicit conversion in assignment (possible truncation) 61:23 8 | for (int32 i = 5; int32 k = floor(i - 1); --i) j++; 9 | ----------------------^ 10 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_11: -------------------------------------------------------------------------------- 1 | [1] warning: declaration of variable "i" shadows a previous declaration 24:9 2 | for(int32 i = 0; i < 3;) { 3 | --------^ 4 | [2] warning: implicit conversion in function call 61:33 5 | for (int32 i = 5; int32 k = floor(i - 1); --i) j++; 6 | --------------------------------^ 7 | [3] warning: implicit conversion in assignment (possible truncation) 61:23 8 | for (int32 i = 5; int32 k = floor(i - 1); --i) j++; 9 | ----------------------^ 10 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_12: -------------------------------------------------------------------------------- 1 | usage: vdb_ax [functions] [] 2 | [functions] query available function information: 3 | 4 | Examples: 5 | vdb_ax functions --list log // print functions with 'log' in the name 6 | 7 | --list list functions, their documentation and their signatures. optionally 8 | only list those whose name includes a provided string. 9 | --list-names list all available functions names only. 10 | 11 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_13: -------------------------------------------------------------------------------- 1 | log 2 | | 3 | | - Computes the natural (base e) logarithm of arg. 4 | | 5 | | - double(double n) 6 | | - float(float n) 7 | 8 | log10 9 | | 10 | | - Computes the common (base-10) logarithm of arg. 11 | | 12 | | - double(double n) 13 | | - float(float n) 14 | 15 | log2 16 | | 17 | | - Computes the binary (base-2) logarithm of arg. 18 | | 19 | | - double(double n) 20 | | - float(float n) 21 | 22 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_14: -------------------------------------------------------------------------------- 1 | abs, acos, acosh, addtogroup, adjoint, argsort, asin, asinh, atan, atan2, atanh, atof, atoi, cbrt, ceil, 2 | clamp, cofactor, cos, cosh, cross, curlsimplexnoise, degrees, deletepoint, determinant, diag, dot, euclideanmod, 3 | exp, exp2, external, externalv, fabs, fit, floor, floormod, getcoord, getcoordx, getcoordy, getcoordz, 4 | getvoxelpws, hash, hsvtorgb, identity3, identity4, ingroup, inverse, isfinite, isinf, isnan, length, lengthsq, 5 | lerp, log, log10, log2, max, min, normalize, polardecompose, postscale, pow, prescale, pretransform, print, 6 | radians, rand, rand32, removefromgroup, rgbtohsv, round, sign, signbit, simplexnoise, sin, sinh, sort, 7 | sqrt, tan, tanh, trace, transform, transpose,truncatemod 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_2: -------------------------------------------------------------------------------- 1 | usage: vdb_ax [analyze] [] 2 | [analyze] parse code and run analysis: 3 | 4 | Examples: 5 | vdb_ax analyze -s "@density += 1;" --try-compile points // compile code for points 6 | 7 | --ast-print print the generated abstract syntax tree. 8 | --re-print re-interpret print of the code post ast traversal. 9 | --reg-print print the attribute registry (name, types, access, dependencies). 10 | --try-compile 11 | attempt compilation for points, volumes or both if no option is 12 | provided. 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_3: -------------------------------------------------------------------------------- 1 | scoped block: 1 statement(s) 2 | [0] assignment expression: += 3 | attribute: @(float - inferred) a 4 | attribute: @(float - inferred) b 5 | 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_4: -------------------------------------------------------------------------------- 1 | { 2 | float@a += float@b; 3 | } 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_5: -------------------------------------------------------------------------------- 1 | Attribute: b, type: float 2 | Index : 0 3 | Reads From : true 4 | Writes To : false 5 | Dependencies : 0 6 | Usage : 1 7 | Attribute: a type: float 8 | 9 | Attribute: a, type: float 10 | Index : 1 11 | Reads From : true 12 | Writes To : true 13 | Dependencies : 2 14 | Attribute: a type: float 15 | Attribute: b type: float 16 | Usage : 1 17 | Attribute: a type: float 18 | 19 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_pass_9: -------------------------------------------------------------------------------- 1 | [1] warning: declaration of variable "i" shadows a previous declaration 24:9 2 | for(int32 i = 0; i < 3;) { 3 | --------^ 4 | [2] warning: implicit conversion in function call 61:33 5 | for (int32 i = 5; int32 k = floor(i - 1); --i) j++; 6 | --------------------------------^ 7 | [3] warning: implicit conversion in assignment (possible truncation) 61:23 8 | for (int32 i = 5; int32 k = floor(i - 1); --i) j++; 9 | ----------------------^ 10 | [4] warning: declaration of variable "i" shadows a previous declaration 24:9 11 | for(int32 i = 0; i < 3;) { 12 | --------^ 13 | [5] warning: implicit conversion in function call 61:33 14 | for (int32 i = 5; int32 k = floor(i - 1); --i) j++; 15 | --------------------------------^ 16 | [6] warning: implicit conversion in assignment (possible truncation) 61:23 17 | for (int32 i = 5; int32 k = floor(i - 1); --i) j++; 18 | ----------------------^ 19 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_uuid: -------------------------------------------------------------------------------- 1 | WARNING: position arguments [input.vdb ] are deprecated. use -i and -o 2 | WARNING: no output VDB File specified - nothing will be written to disk 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/cmd/vdb_ax_test_vol_bind: -------------------------------------------------------------------------------- 1 | WARNING: position arguments [input.vdb ] are deprecated. use -i and -o 2 | WARNING: no output VDB File specified - nothing will be written to disk 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestArrayUnpack/array_unpack.vec.double.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2d@test1[0] = vec2d@test2[1]; 3 | vec2d@test2[1] = vec2d@test1[0]; 4 | 5 | vec3d@test3[1] = vec3d@test3[2]; 6 | vec3d@test4[2] = vec3d@test4[0]; 7 | vec3d@test3[0] = vec3d@test4[1]; 8 | 9 | vec4d@test5[0] = vec4d@test6[2]; 10 | vec4d@test5[3] = vec4d@test5[1]; 11 | vec4d@test5[2] = vec4d@test6[3]; 12 | vec4d@test6[1] = vec4d@test6[0]; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestArrayUnpack/array_unpack.vec.double.rgb.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2d@test1.r = vec2d@test2.g; 3 | vec2d@test2.g = vec2d@test1.r; 4 | 5 | vec3d@test3.g = vec3d@test3.b; 6 | vec3d@test4.b = vec3d@test4.r; 7 | vec3d@test3.r = vec3d@test4.g; 8 | 9 | vec4d@test5.r = vec4d@test6.b; 10 | vec4d@test5[3] = vec4d@test5.g; 11 | vec4d@test5.b = vec4d@test6[3]; 12 | vec4d@test6.g = vec4d@test6.r; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestArrayUnpack/array_unpack.vec.double.xyz.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2d@test1.x = vec2d@test2.y; 3 | vec2d@test2.y = vec2d@test1.x; 4 | 5 | vec3d@test3.y = vec3d@test3.z; 6 | vec3d@test4.z = vec3d@test4.x; 7 | vec3d@test3.x = vec3d@test4.y; 8 | 9 | vec4d@test5.x = vec4d@test6.z; 10 | vec4d@test5[3] = vec4d@test5.y; 11 | vec4d@test5.z = vec4d@test6[3]; 12 | vec4d@test6.y = vec4d@test6.x; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestArrayUnpack/array_unpack.vec.float.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2f@test1[0] = vec2f@test2[1]; 3 | vec2f@test2[1] = vec2f@test1[0]; 4 | 5 | vec3f@test3[1] = vec3f@test3[2]; 6 | vec3f@test4[2] = vec3f@test4[0]; 7 | vec3f@test3[0] = vec3f@test4[1]; 8 | 9 | vec4f@test5[0] = vec4f@test6[2]; 10 | vec4f@test5[3] = vec4f@test5[1]; 11 | vec4f@test5[2] = vec4f@test6[3]; 12 | vec4f@test6[1] = vec4f@test6[0]; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestArrayUnpack/array_unpack.vec.float.rgb.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2f@test1.r = vec2f@test2.g; 3 | vec2f@test2.g = vec2f@test1.r; 4 | 5 | vec3f@test3.g = vec3f@test3.b; 6 | vec3f@test4.b = vec3f@test4.r; 7 | vec3f@test3.r = vec3f@test4.g; 8 | 9 | vec4f@test5.r = vec4f@test6.b; 10 | vec4f@test5[3] = vec4f@test5.g; 11 | vec4f@test5.b = vec4f@test6[3]; 12 | vec4f@test6.g = vec4f@test6.r; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestArrayUnpack/array_unpack.vec.float.xyz.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2f@test1.x = vec2f@test2.y; 3 | vec2f@test2.y = vec2f@test1.x; 4 | 5 | vec3f@test3.y = vec3f@test3.z; 6 | vec3f@test4.z = vec3f@test4.x; 7 | vec3f@test3.x = vec3f@test4.y; 8 | 9 | vec4f@test5.x = vec4f@test6.z; 10 | vec4f@test5[3] = vec4f@test5.y; 11 | vec4f@test5.z = vec4f@test6[3]; 12 | vec4f@test6.y = vec4f@test6.x; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestArrayUnpack/array_unpack.vec.int.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2i@test1[0] = vec2i@test2[1]; 3 | vec2i@test2[1] = vec2i@test1[0]; 4 | 5 | vec3i@test3[1] = vec3i@test3[2]; 6 | vec3i@test4[2] = vec3i@test4[0]; 7 | vec3i@test3[0] = vec3i@test4[1]; 8 | 9 | vec4i@test5[0] = vec4i@test6[2]; 10 | vec4i@test5[3] = vec4i@test5[1]; 11 | vec4i@test5[2] = vec4i@test6[3]; 12 | vec4i@test6[1] = vec4i@test6[0]; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestArrayUnpack/array_unpack.vec.int.rgb.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2i@test1.r = vec2i@test2.g; 3 | vec2i@test2.g = vec2i@test1.r; 4 | 5 | vec3i@test3.g = vec3i@test3.b; 6 | vec3i@test4.b = vec3i@test4.r; 7 | vec3i@test3.r = vec3i@test4.g; 8 | 9 | vec4i@test5.r = vec4i@test6.b; 10 | vec4i@test5[3] = vec4i@test5.g; 11 | vec4i@test5.b = vec4i@test6[3]; 12 | vec4i@test6.g = vec4i@test6.r; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestArrayUnpack/array_unpack.vec.int.xyz.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2i@test1.x = vec2i@test2.y; 3 | vec2i@test2.y = vec2i@test1.x; 4 | 5 | vec3i@test3.y = vec3i@test3.z; 6 | vec3i@test4.z = vec3i@test4.x; 7 | vec3i@test3.x = vec3i@test4.y; 8 | 9 | vec4i@test5.x = vec4i@test6.z; 10 | vec4i@test5[3] = vec4i@test5.y; 11 | vec4i@test5.z = vec4i@test6[3]; 12 | vec4i@test6.y = vec4i@test6.x; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.bool.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@test1 = true; 3 | bool local1 = true; 4 | bool@test2 = local1; 5 | bool@test3 = 6 | bool@test4 = 7 | bool@test2; 8 | bool local3, 9 | local2 = false; 10 | bool@test5 = 11 | local3 = 12 | local2; 13 | bool@test6 = false, 14 | bool@test7 = true; 15 | bool@test8 = false; 16 | bool@test8 = true; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.double.ax: -------------------------------------------------------------------------------- 1 | 2 | double@test1 = 1.1; 3 | double local1 = 1.1; 4 | double@test2 = local1; 5 | double@test3 = 6 | double@test4 = 7 | double@test2; 8 | double local3, 9 | local2 = 2.3; 10 | double@test5 = 11 | local3 = 12 | local2; 13 | double@test6 = 2.3, 14 | double@test7 = 1.1; 15 | double@test8 = 2.3; 16 | double@test8 = 1.1; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.float.ax: -------------------------------------------------------------------------------- 1 | 2 | float@test1 = 1.1f; 3 | float local1 = 1.1f; 4 | float@test2 = local1; 5 | float@test3 = 6 | float@test4 = 7 | float@test2; 8 | float local3, 9 | local2 = 2.3f; 10 | float@test5 = 11 | local3 = 12 | local2; 13 | float@test6 = 2.3f, 14 | float@test7 = 1.1f; 15 | float@test8 = 2.3f; 16 | float@test8 = 1.1f; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.int32.ax: -------------------------------------------------------------------------------- 1 | 2 | int32@test1 = 2; 3 | int32 local1 = 2; 4 | int32@test2 = local1; 5 | int32@test3 = 6 | int32@test4 = 7 | int32@test2; 8 | int32 local3, 9 | local2 = 3; 10 | int32@test5 = 11 | local3 = 12 | local2; 13 | int32@test6 = 3, 14 | int32@test7 = 2; 15 | int32@test8 = 3; 16 | int32@test8 = 2; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.int64.ax: -------------------------------------------------------------------------------- 1 | 2 | int64@test1 = 2l; 3 | int64 local1 = 2l; 4 | int64@test2 = local1; 5 | int64@test3 = 6 | int64@test4 = 7 | int64@test2; 8 | int64 local3, 9 | local2 = 3l; 10 | int64@test5 = 11 | local3 = 12 | local2; 13 | int64@test6 = 3l, 14 | int64@test7 = 2l; 15 | int64@test8 = 3l; 16 | int64@test8 = 2l; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.mat3d.ax: -------------------------------------------------------------------------------- 1 | 2 | mat3d@test1 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2 }; 3 | mat3d local1 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2 }; 4 | mat3d@test2 = local1; 5 | mat3d@test3 = 6 | mat3d@test4 = 7 | mat3d@test2; 8 | mat3d local3, 9 | local2 = {9.1, 7.3, -1.3, 4.4, -6.7, 0.8, 9.1,-0.5, 8.2 }; 10 | mat3d@test5 = 11 | local3 = 12 | local2; 13 | mat3d@test6 = {9.1, 7.3, -1.3, 4.4, -6.7, 0.8, 9.1,-0.5, 8.2 }, 14 | mat3d@test7 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2 }; 15 | mat3d@test8 = {9.1, 7.3, -1.3, 4.4, -6.7, 0.8, 9.1,-0.5, 8.2 }; 16 | mat3d@test8 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2 }; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.mat3f.ax: -------------------------------------------------------------------------------- 1 | 2 | mat3f@test1 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f }; 3 | mat3f local1 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f }; 4 | mat3f@test2 = local1; 5 | mat3f@test3 = 6 | mat3f@test4 = 7 | mat3f@test2; 8 | mat3f local3, 9 | local2 = {9.1f, 7.3f, -1.3f, 4.4f, -6.7f, 0.8f, 9.1f,-0.5f, 8.2f }; 10 | mat3f@test5 = 11 | local3 = 12 | local2; 13 | mat3f@test6 = {9.1f, 7.3f, -1.3f, 4.4f, -6.7f, 0.8f, 9.1f,-0.5f, 8.2f }, 14 | mat3f@test7 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f }; 15 | mat3f@test8 = {9.1f, 7.3f, -1.3f, 4.4f, -6.7f, 0.8f, 9.1f,-0.5f, 8.2f }; 16 | mat3f@test8 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f }; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.mat4d.ax: -------------------------------------------------------------------------------- 1 | 2 | mat4d@test1 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2, 3.3, 2.9, 5.9, 0.1, 0.3, 5.1, 1.9}; 3 | mat4d local1 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2, 3.3, 2.9, 5.9, 0.1, 0.3, 5.1, 1.9}; 4 | mat4d@test2 = local1; 5 | mat4d@test3 = 6 | mat4d@test4 = 7 | mat4d@test2; 8 | mat4d local3, 9 | local2 = {0.1, 2.3,-9.3, 4.5, -1.7, 7.8, 2.1, 3.3, 3.3,-3.3,-0.3, 2.5, 5.1, 0.5, 8.1,-1.7}; 10 | mat4d@test5 = 11 | local3 = 12 | local2; 13 | mat4d@test6 = {0.1, 2.3,-9.3, 4.5, -1.7, 7.8, 2.1, 3.3, 3.3,-3.3,-0.3, 2.5, 5.1, 0.5, 8.1,-1.7}, 14 | mat4d@test7 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2, 3.3, 2.9, 5.9, 0.1, 0.3, 5.1, 1.9}; 15 | mat4d@test8 = {0.1, 2.3,-9.3, 4.5, -1.7, 7.8, 2.1, 3.3, 3.3,-3.3,-0.3, 2.5, 5.1, 0.5, 8.1,-1.7}; 16 | mat4d@test8 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2, 3.3, 2.9, 5.9, 0.1, 0.3, 5.1, 1.9}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.mat4f.ax: -------------------------------------------------------------------------------- 1 | 2 | mat4f@test1 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f, 3.3f, 2.9f, 5.9f, 0.1f, 0.3f, 5.1f, 1.9f}; 3 | mat4f local1 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f, 3.3f, 2.9f, 5.9f, 0.1f, 0.3f, 5.1f, 1.9f}; 4 | mat4f@test2 = local1; 5 | mat4f@test3 = 6 | mat4f@test4 = 7 | mat4f@test2; 8 | mat4f local3, 9 | local2 = {0.1f, 2.3f,-9.3f, 4.5f, -1.7f, 7.8f, 2.1f, 3.3f, 3.3f,-3.3f,-0.3f, 2.5f, 5.1f, 0.5f, 8.1f,-1.7f}; 10 | mat4f@test5 = 11 | local3 = 12 | local2; 13 | mat4f@test6 = {0.1f, 2.3f,-9.3f, 4.5f, -1.7f, 7.8f, 2.1f, 3.3f, 3.3f,-3.3f,-0.3f, 2.5f, 5.1f, 0.5f, 8.1f,-1.7f}, 14 | mat4f@test7 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f, 3.3f, 2.9f, 5.9f, 0.1f, 0.3f, 5.1f, 1.9f}; 15 | mat4f@test8 = {0.1f, 2.3f,-9.3f, 4.5f, -1.7f, 7.8f, 2.1f, 3.3f, 3.3f,-3.3f,-0.3f, 2.5f, 5.1f, 0.5f, 8.1f,-1.7f}; 16 | mat4f@test8 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f, 3.3f, 2.9f, 5.9f, 0.1f, 0.3f, 5.1f, 1.9f}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.string.ax: -------------------------------------------------------------------------------- 1 | 2 | string@test1 = "foo"; 3 | string local1 = "foo"; 4 | string@test2 = local1; 5 | string@test3 = 6 | string@test4 = 7 | string@test2; 8 | string local3, 9 | local2 = "bar"; 10 | string@test5 = 11 | local3 = 12 | local2; 13 | string@test6 = "bar", 14 | string@test7 = "foo"; 15 | string@test8 = "bar"; 16 | string@test8 = "foo"; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.vec2d.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2d@test1 = {1.1, 2.3}; 3 | vec2d local1 = {1.1, 2.3}; 4 | vec2d@test2 = local1; 5 | vec2d@test3 = 6 | vec2d@test4 = 7 | vec2d@test2; 8 | vec2d local3, 9 | local2 = {4.1, 5.3}; 10 | vec2d@test5 = 11 | local3 = 12 | local2; 13 | vec2d@test6 = {4.1, 5.3}, 14 | vec2d@test7 = {1.1, 2.3}; 15 | vec2d@test8 = {4.1, 5.3}; 16 | vec2d@test8 = {1.1, 2.3}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.vec2f.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2f@test1 = {1.1f, 2.3f}; 3 | vec2f local1 = {1.1f, 2.3f}; 4 | vec2f@test2 = local1; 5 | vec2f@test3 = 6 | vec2f@test4 = 7 | vec2f@test2; 8 | vec2f local3, 9 | local2 = {4.1f, 5.3f}; 10 | vec2f@test5 = 11 | local3 = 12 | local2; 13 | vec2f@test6 = {4.1f, 5.3f}, 14 | vec2f@test7 = {1.1f, 2.3f}; 15 | vec2f@test8 = {4.1f, 5.3f}; 16 | vec2f@test8 = {1.1f, 2.3f}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.vec2i.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2i@test1 = {1, 2}; 3 | vec2i local1 = {1, 2}; 4 | vec2i@test2 = local1; 5 | vec2i@test3 = 6 | vec2i@test4 = 7 | vec2i@test2; 8 | vec2i local3, 9 | local2 = {3, 4}; 10 | vec2i@test5 = 11 | local3 = 12 | local2; 13 | vec2i@test6 = {3, 4}, 14 | vec2i@test7 = {1, 2}; 15 | vec2i@test8 = {3, 4}; 16 | vec2i@test8 = {1, 2}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.vec3d.ax: -------------------------------------------------------------------------------- 1 | 2 | vec3d@test1 = {1.1, 2.3 , 4.3}; 3 | vec3d local1 = {1.1, 2.3 , 4.3}; 4 | vec3d@test2 = local1; 5 | vec3d@test3 = 6 | vec3d@test4 = 7 | vec3d@test2; 8 | vec3d local3, 9 | local2 = {4.1, 5.3, 6.3}; 10 | vec3d@test5 = 11 | local3 = 12 | local2; 13 | vec3d@test6 = {4.1, 5.3, 6.3}, 14 | vec3d@test7 = {1.1, 2.3 , 4.3}; 15 | vec3d@test8 = {4.1, 5.3, 6.3}; 16 | vec3d@test8 = {1.1, 2.3 , 4.3}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.vec3f.ax: -------------------------------------------------------------------------------- 1 | 2 | vec3f@test1 = {1.1f, 2.3f, 4.3f}; 3 | vec3f local1 = {1.1f, 2.3f, 4.3f}; 4 | vec3f@test2 = local1; 5 | vec3f@test3 = 6 | vec3f@test4 = 7 | vec3f@test2; 8 | vec3f local3, 9 | local2 = {4.1f, 5.3f, 6.3f}; 10 | vec3f@test5 = 11 | local3 = 12 | local2; 13 | vec3f@test6 = {4.1f, 5.3f, 6.3f}, 14 | vec3f@test7 = {1.1f, 2.3f, 4.3f}; 15 | vec3f@test8 = {4.1f, 5.3f, 6.3f}; 16 | vec3f@test8 = {1.1f, 2.3f, 4.3f}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.vec3i.ax: -------------------------------------------------------------------------------- 1 | 2 | vec3i@test1 = {1, 2, 3}; 3 | vec3i local1 = {1, 2, 3}; 4 | vec3i@test2 = local1; 5 | vec3i@test3 = 6 | vec3i@test4 = 7 | vec3i@test2; 8 | vec3i local3, 9 | local2 = {4, 5, 6}; 10 | vec3i@test5 = 11 | local3 = 12 | local2; 13 | vec3i@test6 = {4, 5, 6}, 14 | vec3i@test7 = {1, 2, 3}; 15 | vec3i@test8 = {4, 5, 6}; 16 | vec3i@test8 = {1, 2, 3}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.vec4d.ax: -------------------------------------------------------------------------------- 1 | 2 | vec4d@test1 = {1.1, 2.3, 4.3, 5.4}; 3 | vec4d local1 = {1.1, 2.3, 4.3, 5.4}; 4 | vec4d@test2 = local1; 5 | vec4d@test3 = 6 | vec4d@test4 = 7 | vec4d@test2; 8 | vec4d local3, 9 | local2 = {5.1, 6.3, 7.3, 8.4}; 10 | vec4d@test5 = 11 | local3 = 12 | local2; 13 | vec4d@test6 = {5.1, 6.3, 7.3, 8.4}, 14 | vec4d@test7 = {1.1, 2.3, 4.3, 5.4}; 15 | vec4d@test8 = {5.1, 6.3, 7.3, 8.4}; 16 | vec4d@test8 = {1.1, 2.3, 4.3, 5.4}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.vec4f.ax: -------------------------------------------------------------------------------- 1 | 2 | vec4f@test1 = {1.1f, 2.3f, 4.3f, 5.4f}; 3 | vec4f local1 = {1.1f, 2.3f, 4.3f, 5.4f}; 4 | vec4f@test2 = local1; 5 | vec4f@test3 = 6 | vec4f@test4 = 7 | vec4f@test2; 8 | vec4f local3, 9 | local2 = {5.1f, 6.3f, 7.3f, 8.4f}; 10 | vec4f@test5 = 11 | local3 = 12 | local2; 13 | vec4f@test6 = {5.1f, 6.3f, 7.3f, 8.4f}, 14 | vec4f@test7 = {1.1f, 2.3f, 4.3f, 5.4f}; 15 | vec4f@test8 = {5.1f, 6.3f, 7.3f, 8.4f}; 16 | vec4f@test8 = {1.1f, 2.3f, 4.3f, 5.4f}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign.vec4i.ax: -------------------------------------------------------------------------------- 1 | 2 | vec4i@test1 = {1, 2, 3, 4}; 3 | vec4i local1 = {1, 2, 3, 4}; 4 | vec4i@test2 = local1; 5 | vec4i@test3 = 6 | vec4i@test4 = 7 | vec4i@test2; 8 | vec4i local3, 9 | local2 = {5, 6, 7, 8}; 10 | vec4i@test5 = 11 | local3 = 12 | local2; 13 | vec4i@test6 = {5, 6, 7, 8}, 14 | vec4i@test7 = {1, 2, 3, 4}; 15 | vec4i@test8 = {5, 6, 7, 8}; 16 | vec4i@test8 = {1, 2, 3, 4}; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.bool.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@test1 += true; 3 | bool@test2 -= true; 4 | bool@test3 *= true; 5 | bool@test4 /= true; 6 | bool@test5 %= true; 7 | bool@test6 <<= true; 8 | bool@test7 >>= true; 9 | bool@test8 &= true; 10 | bool@test9 ^= true; 11 | bool@test10 |= true; 12 | 13 | bool local1 = true, 14 | local2 = false; 15 | 16 | local1 += local2; 17 | bool@test11 = local1; 18 | bool@test12 += bool@test13; 19 | bool@test14 += local2; 20 | 21 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.double.ax: -------------------------------------------------------------------------------- 1 | 2 | double@test1 += 1.1; 3 | double@test2 -= 1.1; 4 | double@test3 *= 1.1; 5 | double@test4 /= 1.1; 6 | double@test5 %= 1.1; 7 | 8 | double local1 = 1.1, 9 | local2 = 2.3; 10 | 11 | local1 += local2; 12 | double@test6 = local1; 13 | double@test7 += double@test8; 14 | double@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.float.ax: -------------------------------------------------------------------------------- 1 | 2 | float@test1 += 1.1f; 3 | float@test2 -= 1.1f; 4 | float@test3 *= 1.1f; 5 | float@test4 /= 1.1f; 6 | float@test5 %= 1.1f; 7 | 8 | float local1 = 1.1f, 9 | local2 = 2.3f; 10 | 11 | local1 += local2; 12 | float@test6 = local1; 13 | float@test7 += float@test8; 14 | float@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.int32.ax: -------------------------------------------------------------------------------- 1 | 2 | int32@test1 += 2; 3 | int32@test2 -= 2; 4 | int32@test3 *= 2; 5 | int32@test4 /= 2; 6 | int32@test5 %= 2; 7 | int32@test6 <<= 2; 8 | int32@test7 >>= 2; 9 | int32@test8 &= 2; 10 | int32@test9 ^= 2; 11 | int32@test10 |= 2; 12 | 13 | int32 local1 = 2, 14 | local2 = 3; 15 | 16 | local1 += local2; 17 | int32@test11 = local1; 18 | int32@test12 += int32@test13; 19 | int32@test14 += local2; 20 | 21 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.int64.ax: -------------------------------------------------------------------------------- 1 | 2 | int64@test1 += 2l; 3 | int64@test2 -= 2l; 4 | int64@test3 *= 2l; 5 | int64@test4 /= 2l; 6 | int64@test5 %= 2l; 7 | int64@test6 <<= 2l; 8 | int64@test7 >>= 2l; 9 | int64@test8 &= 2l; 10 | int64@test9 ^= 2l; 11 | int64@test10 |= 2l; 12 | 13 | int64 local1 = 2l, 14 | local2 = 3l; 15 | 16 | local1 += local2; 17 | int64@test11 = local1; 18 | int64@test12 += int64@test13; 19 | int64@test14 += local2; 20 | 21 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.mat3d.ax: -------------------------------------------------------------------------------- 1 | 2 | mat3d@test1 += {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2 }; 3 | mat3d@test2 -= {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2 }; 4 | mat3d@test3 *= {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2 }; 5 | 6 | mat3d local1 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2 }, 7 | local2 = {9.1, 7.3, -1.3, 4.4, -6.7, 0.8, 9.1,-0.5, 8.2 }; 8 | 9 | local1 += local2; 10 | mat3d@test4 = local1; 11 | mat3d@test5 += mat3d@test6; 12 | mat3d@test7 += local2; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.mat3f.ax: -------------------------------------------------------------------------------- 1 | 2 | mat3f@test1 += {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f }; 3 | mat3f@test2 -= {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f }; 4 | mat3f@test3 *= {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f }; 5 | 6 | mat3f local1 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f }, 7 | local2 = {9.1f, 7.3f, -1.3f, 4.4f, -6.7f, 0.8f, 9.1f,-0.5f, 8.2f }; 8 | 9 | local1 += local2; 10 | mat3f@test4 = local1; 11 | mat3f@test5 += mat3f@test6; 12 | mat3f@test7 += local2; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.mat4d.ax: -------------------------------------------------------------------------------- 1 | 2 | mat4d@test1 += {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2, 3.3, 2.9, 5.9, 0.1, 0.3, 5.1, 1.9}; 3 | mat4d@test2 -= {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2, 3.3, 2.9, 5.9, 0.1, 0.3, 5.1, 1.9}; 4 | mat4d@test3 *= {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2, 3.3, 2.9, 5.9, 0.1, 0.3, 5.1, 1.9}; 5 | 6 | mat4d local1 = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2, 3.3, 2.9, 5.9, 0.1, 0.3, 5.1, 1.9}, 7 | local2 = {0.1, 2.3,-9.3, 4.5, -1.7, 7.8, 2.1, 3.3, 3.3,-3.3,-0.3, 2.5, 5.1, 0.5, 8.1,-1.7}; 8 | 9 | local1 += local2; 10 | mat4d@test4 = local1; 11 | mat4d@test5 += mat4d@test6; 12 | mat4d@test7 += local2; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.mat4f.ax: -------------------------------------------------------------------------------- 1 | 2 | mat4f@test1 += {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f, 3.3f, 2.9f, 5.9f, 0.1f, 0.3f, 5.1f, 1.9f}; 3 | mat4f@test2 -= {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f, 3.3f, 2.9f, 5.9f, 0.1f, 0.3f, 5.1f, 1.9f}; 4 | mat4f@test3 *= {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f, 3.3f, 2.9f, 5.9f, 0.1f, 0.3f, 5.1f, 1.9f}; 5 | 6 | mat4f local1 = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f, 3.3f, 2.9f, 5.9f, 0.1f, 0.3f, 5.1f, 1.9f}, 7 | local2 = {0.1f, 2.3f,-9.3f, 4.5f, -1.7f, 7.8f, 2.1f, 3.3f, 3.3f,-3.3f,-0.3f, 2.5f, 5.1f, 0.5f, 8.1f,-1.7f}; 8 | 9 | local1 += local2; 10 | mat4f@test4 = local1; 11 | mat4f@test5 += mat4f@test6; 12 | mat4f@test7 += local2; 13 | 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.string.ax: -------------------------------------------------------------------------------- 1 | 2 | string@test1 += "foo"; 3 | 4 | string local1 = "foo", 5 | local2 = "bar"; 6 | 7 | // test default init and empty string 8 | string empty = ""; 9 | string defaultstr; 10 | local1 += local2; 11 | defaultstr += local1; 12 | defaultstr += empty; 13 | 14 | string@test2 = defaultstr; 15 | string@test3 += string@test4; 16 | string@test5 += local2; 17 | 18 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.vec2d.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2d@test1 += {1.1, 2.3}; 3 | vec2d@test2 -= {1.1, 2.3}; 4 | vec2d@test3 *= {1.1, 2.3}; 5 | vec2d@test4 /= {1.1, 2.3}; 6 | vec2d@test5 %= {1.1, 2.3}; 7 | 8 | vec2d local1 = {1.1, 2.3}, 9 | local2 = {4.1, 5.3}; 10 | 11 | local1 += local2; 12 | vec2d@test6 = local1; 13 | vec2d@test7 += vec2d@test8; 14 | vec2d@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.vec2f.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2f@test1 += {1.1f, 2.3f}; 3 | vec2f@test2 -= {1.1f, 2.3f}; 4 | vec2f@test3 *= {1.1f, 2.3f}; 5 | vec2f@test4 /= {1.1f, 2.3f}; 6 | vec2f@test5 %= {1.1f, 2.3f}; 7 | 8 | vec2f local1 = {1.1f, 2.3f}, 9 | local2 = {4.1f, 5.3f}; 10 | 11 | local1 += local2; 12 | vec2f@test6 = local1; 13 | vec2f@test7 += vec2f@test8; 14 | vec2f@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.vec2i.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2i@test1 += {1, 2}; 3 | vec2i@test2 -= {1, 2}; 4 | vec2i@test3 *= {1, 2}; 5 | vec2i@test4 /= {1, 2}; 6 | vec2i@test5 %= {1, 2}; 7 | 8 | vec2i local1 = {1, 2}, 9 | local2 = {3, 4}; 10 | 11 | local1 += local2; 12 | vec2i@test6 = local1; 13 | vec2i@test7 += vec2i@test8; 14 | vec2i@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.vec3d.ax: -------------------------------------------------------------------------------- 1 | 2 | vec3d@test1 += {1.1, 2.3 , 4.3}; 3 | vec3d@test2 -= {1.1, 2.3 , 4.3}; 4 | vec3d@test3 *= {1.1, 2.3 , 4.3}; 5 | vec3d@test4 /= {1.1, 2.3 , 4.3}; 6 | vec3d@test5 %= {1.1, 2.3 , 4.3}; 7 | 8 | vec3d local1 = {1.1, 2.3 , 4.3}, 9 | local2 = {4.1, 5.3, 6.3}; 10 | 11 | local1 += local2; 12 | vec3d@test6 = local1; 13 | vec3d@test7 += vec3d@test8; 14 | vec3d@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.vec3f.ax: -------------------------------------------------------------------------------- 1 | 2 | vec3f@test1 += {1.1f, 2.3f, 4.3f}; 3 | vec3f@test2 -= {1.1f, 2.3f, 4.3f}; 4 | vec3f@test3 *= {1.1f, 2.3f, 4.3f}; 5 | vec3f@test4 /= {1.1f, 2.3f, 4.3f}; 6 | vec3f@test5 %= {1.1f, 2.3f, 4.3f}; 7 | 8 | vec3f local1 = {1.1f, 2.3f, 4.3f}, 9 | local2 = {4.1f, 5.3f, 6.3f}; 10 | 11 | local1 += local2; 12 | vec3f@test6 = local1; 13 | vec3f@test7 += vec3f@test8; 14 | vec3f@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.vec3i.ax: -------------------------------------------------------------------------------- 1 | 2 | vec3i@test1 += {1, 2, 3}; 3 | vec3i@test2 -= {1, 2, 3}; 4 | vec3i@test3 *= {1, 2, 3}; 5 | vec3i@test4 /= {1, 2, 3}; 6 | vec3i@test5 %= {1, 2, 3}; 7 | 8 | vec3i local1 = {1, 2, 3}, 9 | local2 = {4, 5, 6}; 10 | 11 | local1 += local2; 12 | vec3i@test6 = local1; 13 | vec3i@test7 += vec3i@test8; 14 | vec3i@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.vec4d.ax: -------------------------------------------------------------------------------- 1 | 2 | vec4d@test1 += {1.1, 2.3, 4.3, 5.4}; 3 | vec4d@test2 -= {1.1, 2.3, 4.3, 5.4}; 4 | vec4d@test3 *= {1.1, 2.3, 4.3, 5.4}; 5 | vec4d@test4 /= {1.1, 2.3, 4.3, 5.4}; 6 | vec4d@test5 %= {1.1, 2.3, 4.3, 5.4}; 7 | 8 | vec4d local1 = {1.1, 2.3, 4.3, 5.4}, 9 | local2 = {5.1, 6.3, 7.3, 8.4}; 10 | 11 | local1 += local2; 12 | vec4d@test6 = local1; 13 | vec4d@test7 += vec4d@test8; 14 | vec4d@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.vec4f.ax: -------------------------------------------------------------------------------- 1 | 2 | vec4f@test1 += {1.1f, 2.3f, 4.3f, 5.4f}; 3 | vec4f@test2 -= {1.1f, 2.3f, 4.3f, 5.4f}; 4 | vec4f@test3 *= {1.1f, 2.3f, 4.3f, 5.4f}; 5 | vec4f@test4 /= {1.1f, 2.3f, 4.3f, 5.4f}; 6 | vec4f@test5 %= {1.1f, 2.3f, 4.3f, 5.4f}; 7 | 8 | vec4f local1 = {1.1f, 2.3f, 4.3f, 5.4f}, 9 | local2 = {5.1f, 6.3f, 7.3f, 8.4f}; 10 | 11 | local1 += local2; 12 | vec4f@test6 = local1; 13 | vec4f@test7 += vec4f@test8; 14 | vec4f@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_compound.vec4i.ax: -------------------------------------------------------------------------------- 1 | 2 | vec4i@test1 += {1, 2, 3, 4}; 3 | vec4i@test2 -= {1, 2, 3, 4}; 4 | vec4i@test3 *= {1, 2, 3, 4}; 5 | vec4i@test4 /= {1, 2, 3, 4}; 6 | vec4i@test5 %= {1, 2, 3, 4}; 7 | 8 | vec4i local1 = {1, 2, 3, 4}, 9 | local2 = {5, 6, 7, 8}; 10 | 11 | local1 += local2; 12 | vec4i@test6 = local1; 13 | vec4i@test7 += vec4i@test8; 14 | vec4i@test9 += local2; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.mat3d.ax: -------------------------------------------------------------------------------- 1 | mat3d local = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2 }; 2 | mat3f@testmat3f = local; 3 | 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.mat3f.ax: -------------------------------------------------------------------------------- 1 | mat3f local = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f }; 2 | mat3d@testmat3d = local; 3 | 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.mat4d.ax: -------------------------------------------------------------------------------- 1 | mat4d local = {1.1, 2.3, 4.3, 5.4, 6.7, 7.8, 9.1, 4.5, 8.2, 3.3, 2.9, 5.9, 0.1, 0.3, 5.1, 1.9}; 2 | mat4f@testmat4f = local; 3 | 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.mat4f.ax: -------------------------------------------------------------------------------- 1 | mat4f local = {1.1f, 2.3f, 4.3f, 5.4f, 6.7f, 7.8f, 9.1f, 4.5f, 8.2f, 3.3f, 2.9f, 5.9f, 0.1f, 0.3f, 5.1f, 1.9f}; 2 | mat4d@testmat4d = local; 3 | 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.vec2d.ax: -------------------------------------------------------------------------------- 1 | vec2d local = {1.1, 2.3}; 2 | vec2f@testvec2f = local; 3 | vec2i@testvec2i = local; 4 | 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.vec2f.ax: -------------------------------------------------------------------------------- 1 | vec2f local = {1.1f, 2.3f}; 2 | vec2d@testvec2d = local; 3 | vec2i@testvec2i = local; 4 | 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.vec2i.ax: -------------------------------------------------------------------------------- 1 | vec2i local = {1, 2}; 2 | vec2d@testvec2d = local; 3 | vec2f@testvec2f = local; 4 | 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.vec3d.ax: -------------------------------------------------------------------------------- 1 | vec3d local = {1.1, 2.3 , 4.3}; 2 | vec3f@testvec3f = local; 3 | vec3i@testvec3i = local; 4 | 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.vec3f.ax: -------------------------------------------------------------------------------- 1 | vec3f local = {1.1f, 2.3f, 4.3f}; 2 | vec3d@testvec3d = local; 3 | vec3i@testvec3i = local; 4 | 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.vec3i.ax: -------------------------------------------------------------------------------- 1 | vec3i local = {1, 2, 3}; 2 | vec3d@testvec3d = local; 3 | vec3f@testvec3f = local; 4 | 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.vec4d.ax: -------------------------------------------------------------------------------- 1 | vec4d local = {1.1, 2.3, 4.3, 5.4}; 2 | vec4f@testvec4f = local; 3 | vec4i@testvec4i = local; 4 | 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.vec4f.ax: -------------------------------------------------------------------------------- 1 | vec4f local = {1.1f, 2.3f, 4.3f, 5.4f}; 2 | vec4d@testvec4d = local; 3 | vec4i@testvec4i = local; 4 | 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container.vec4i.ax: -------------------------------------------------------------------------------- 1 | vec4i local = {1, 2, 3, 4}; 2 | vec4d@testvec4d = local; 3 | vec4f@testvec4f = local; 4 | 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container_scalar.bool.ax: -------------------------------------------------------------------------------- 1 | bool local = true; 2 | vec2d@testvec2d = local; 3 | vec2f@testvec2f = local; 4 | vec2i@testvec2i = local; 5 | vec3d@testvec3d = local; 6 | vec3f@testvec3f = local; 7 | vec3i@testvec3i = local; 8 | vec4d@testvec4d = local; 9 | vec4f@testvec4f = local; 10 | vec4i@testvec4i = local; 11 | mat3d@testmat3d = local; 12 | mat3f@testmat3f = local; 13 | mat4d@testmat4d = local; 14 | mat4f@testmat4f = local; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container_scalar.double.ax: -------------------------------------------------------------------------------- 1 | double local = 1.1; 2 | vec2d@testvec2d = local; 3 | vec2f@testvec2f = local; 4 | vec2i@testvec2i = local; 5 | vec3d@testvec3d = local; 6 | vec3f@testvec3f = local; 7 | vec3i@testvec3i = local; 8 | vec4d@testvec4d = local; 9 | vec4f@testvec4f = local; 10 | vec4i@testvec4i = local; 11 | mat3d@testmat3d = local; 12 | mat3f@testmat3f = local; 13 | mat4d@testmat4d = local; 14 | mat4f@testmat4f = local; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container_scalar.float.ax: -------------------------------------------------------------------------------- 1 | float local = 1.1f; 2 | vec2d@testvec2d = local; 3 | vec2f@testvec2f = local; 4 | vec2i@testvec2i = local; 5 | vec3d@testvec3d = local; 6 | vec3f@testvec3f = local; 7 | vec3i@testvec3i = local; 8 | vec4d@testvec4d = local; 9 | vec4f@testvec4f = local; 10 | vec4i@testvec4i = local; 11 | mat3d@testmat3d = local; 12 | mat3f@testmat3f = local; 13 | mat4d@testmat4d = local; 14 | mat4f@testmat4f = local; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container_scalar.int32.ax: -------------------------------------------------------------------------------- 1 | int32 local = 2; 2 | vec2d@testvec2d = local; 3 | vec2f@testvec2f = local; 4 | vec2i@testvec2i = local; 5 | vec3d@testvec3d = local; 6 | vec3f@testvec3f = local; 7 | vec3i@testvec3i = local; 8 | vec4d@testvec4d = local; 9 | vec4f@testvec4f = local; 10 | vec4i@testvec4i = local; 11 | mat3d@testmat3d = local; 12 | mat3f@testmat3f = local; 13 | mat4d@testmat4d = local; 14 | mat4f@testmat4f = local; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_container_scalar.int64.ax: -------------------------------------------------------------------------------- 1 | int64 local = 2l; 2 | vec2d@testvec2d = local; 3 | vec2f@testvec2f = local; 4 | vec2i@testvec2i = local; 5 | vec3d@testvec3d = local; 6 | vec3f@testvec3f = local; 7 | vec3i@testvec3i = local; 8 | vec4d@testvec4d = local; 9 | vec4f@testvec4f = local; 10 | vec4i@testvec4i = local; 11 | mat3d@testmat3d = local; 12 | mat3f@testmat3f = local; 13 | mat4d@testmat4d = local; 14 | mat4f@testmat4f = local; 15 | 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_scalar.bool.ax: -------------------------------------------------------------------------------- 1 | bool local = true; 2 | int32@testint32 = local; 3 | int64@testint64 = local; 4 | double@testdouble = local; 5 | float@testfloat = local; 6 | 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_scalar.double.ax: -------------------------------------------------------------------------------- 1 | double local = 1.1; 2 | bool@testbool = local; 3 | int32@testint32 = local; 4 | int64@testint64 = local; 5 | float@testfloat = local; 6 | 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_scalar.float.ax: -------------------------------------------------------------------------------- 1 | float local = 1.1f; 2 | bool@testbool = local; 3 | int32@testint32 = local; 4 | int64@testint64 = local; 5 | double@testdouble = local; 6 | 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_scalar.int32.ax: -------------------------------------------------------------------------------- 1 | int32 local = 2; 2 | bool@testbool = local; 3 | int64@testint64 = local; 4 | double@testdouble = local; 5 | float@testfloat = local; 6 | 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_implicit_scalar.int64.ax: -------------------------------------------------------------------------------- 1 | int64 local = 2l; 2 | bool@testbool = local; 3 | int32@testint32 = local; 4 | double@testdouble = local; 5 | float@testfloat = local; 6 | 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestAssign/assign_scoped.float.ax: -------------------------------------------------------------------------------- 1 | 2 | float var = 30.0f; 3 | 4 | { 5 | float var = 3.0f; 6 | } 7 | { 8 | float var = 1.0f; 9 | float@test2 = var; 10 | { 11 | float var = -10.0f; 12 | float@test3 = var; 13 | } 14 | { 15 | float@test7 = var; 16 | } 17 | } 18 | { 19 | float var = -100.0f; 20 | } 21 | { 22 | float var = 50.0f; 23 | { 24 | float var = -15.0f; 25 | float@test4 = var; 26 | } 27 | { 28 | float var = -10.0f; 29 | } 30 | { 31 | float@test5 = var; 32 | } 33 | 34 | float@test6 = var; 35 | } 36 | 37 | float@test1 = var; 38 | 39 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_bitand.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@testbool = true & false; 3 | int16@testint16 = 2 & 3; 4 | int32@testint32 = 2 & 3; 5 | int64@testint64 = 2l & 3l; 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_bitor.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@testbool = true | false; 3 | int16@testint16 = 2 | 3; 4 | int32@testint32 = 2 | 3; 5 | int64@testint64 = 2l | 3l; 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_bitxor.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@testbool = true ^ false; 3 | int16@testint16 = 2 ^ 3; 4 | int32@testint32 = 2 ^ 3; 5 | int64@testint64 = 2l ^ 3l; 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_div.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@testbool = false / true; 3 | int16@testint16 = 3 / 2; 4 | int32@testint32 = 3 / 2; 5 | int64@testint64 = 3l / 2l; 6 | double@testdouble = 2.3 / 1.1; 7 | float@testfloat = 2.3f / 1.1f; 8 | vec2d@testvec2d = {4.1, 5.3} / {1.1, 2.3}; 9 | vec2f@testvec2f = {4.1f, 5.3f} / {1.1f, 2.3f}; 10 | vec2i@testvec2i = {3, 4} / {1, 2}; 11 | vec3d@testvec3d = {4.1, 5.3, 6.3} / {1.1, 2.3 , 4.3}; 12 | vec3f@testvec3f = {4.1f, 5.3f, 6.3f} / {1.1f, 2.3f, 4.3f}; 13 | vec3i@testvec3i = {4, 5, 6} / {1, 2, 3}; 14 | vec4d@testvec4d = {5.1, 6.3, 7.3, 8.4} / {1.1, 2.3, 4.3, 5.4}; 15 | vec4f@testvec4f = {5.1f, 6.3f, 7.3f, 8.4f} / {1.1f, 2.3f, 4.3f, 5.4f}; 16 | vec4i@testvec4i = {5, 6, 7, 8} / {1, 2, 3, 4}; 17 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_logicaland.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@testbool = true && false; 3 | int16@testint16 = 2 && 3; 4 | int32@testint32 = 2 && 3; 5 | int64@testint64 = 2l && 3l; 6 | double@testdouble = 1.1 && 2.3; 7 | float@testfloat = 1.1f && 2.3f; 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_logicaland_scircuit.ax: -------------------------------------------------------------------------------- 1 | 2 | int@scircuit1 = 0; 3 | int@scircuit2 = 1; 4 | int@scircuit3 = 2; 5 | int@scircuit1++ && ++int@scircuit2; 6 | ++int@scircuit1 && ++int@scircuit3; 7 | int@scircuit4 = 1; 8 | int@scircuit5 = 1; 9 | true && int@scircuit4 = 2; 10 | false && int@scircuit5 = 2; 11 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_logicalor.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@testbool = true || false; 3 | int16@testint16 = 2 || 3; 4 | int32@testint32 = 2 || 3; 5 | int64@testint64 = 2l || 3l; 6 | double@testdouble = 1.1 || 2.3; 7 | float@testfloat = 1.1f || 2.3f; 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_logicalor_scircuit.ax: -------------------------------------------------------------------------------- 1 | 2 | int@scircuit1 = 0; 3 | int@scircuit2 = 1; 4 | int@scircuit3 = 2; 5 | int@scircuit1++ || ++int@scircuit2; 6 | ++int@scircuit1 || ++int@scircuit3; 7 | int@scircuit4 = 1; 8 | int@scircuit5 = 1; 9 | true || int@scircuit4 = 2; 10 | false || int@scircuit5 = 2; 11 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_mod.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@testbool = false % true; 3 | int16@testint16 = 3 % 2; 4 | int32@testint32 = 3 % 2; 5 | int64@testint64 = 3l % 2l; 6 | double@testdouble = 2.3 % 1.1; 7 | float@testfloat = 2.3f % 1.1f; 8 | vec2d@testvec2d = {4.1, 5.3} % {1.1, 2.3}; 9 | vec2f@testvec2f = {4.1f, 5.3f} % {1.1f, 2.3f}; 10 | vec2i@testvec2i = {3, 4} % {1, 2}; 11 | vec3d@testvec3d = {4.1, 5.3, 6.3} % {1.1, 2.3 , 4.3}; 12 | vec3f@testvec3f = {4.1f, 5.3f, 6.3f} % {1.1f, 2.3f, 4.3f}; 13 | vec3i@testvec3i = {4, 5, 6} % {1, 2, 3}; 14 | vec4d@testvec4d = {5.1, 6.3, 7.3, 8.4} % {1.1, 2.3, 4.3, 5.4}; 15 | vec4f@testvec4f = {5.1f, 6.3f, 7.3f, 8.4f} % {1.1f, 2.3f, 4.3f, 5.4f}; 16 | vec4i@testvec4i = {5, 6, 7, 8} % {1, 2, 3, 4}; 17 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_relational_greaterthan.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@test1 = true > false; 3 | bool@test2 = false > true; 4 | bool@test3 = false > false; 5 | bool@test4 = 2 > 3; 6 | bool@test5 = 3 > 2; 7 | bool@test6 = 3 > 3; 8 | bool@test7 = 2 > 3; 9 | bool@test8 = 3 > 2; 10 | bool@test9 = 3 > 3; 11 | bool@test10 = 2l > 3l; 12 | bool@test11 = 3l > 2l; 13 | bool@test12 = 3l > 3l; 14 | bool@test13 = 1.1 > 2.3; 15 | bool@test14 = 2.3 > 1.1; 16 | bool@test15 = 2.3 > 2.3; 17 | bool@test16 = 1.1f > 2.3f; 18 | bool@test17 = 2.3f > 1.1f; 19 | bool@test18 = 2.3f > 2.3f; 20 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_relational_greaterthanequals.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@test1 = true >= false; 3 | bool@test2 = false >= true; 4 | bool@test3 = false >= false; 5 | bool@test4 = 2 >= 3; 6 | bool@test5 = 3 >= 2; 7 | bool@test6 = 3 >= 3; 8 | bool@test7 = 2 >= 3; 9 | bool@test8 = 3 >= 2; 10 | bool@test9 = 3 >= 3; 11 | bool@test10 = 2l >= 3l; 12 | bool@test11 = 3l >= 2l; 13 | bool@test12 = 3l >= 3l; 14 | bool@test13 = 1.1 >= 2.3; 15 | bool@test14 = 2.3 >= 1.1; 16 | bool@test15 = 2.3 >= 2.3; 17 | bool@test16 = 1.1f >= 2.3f; 18 | bool@test17 = 2.3f >= 1.1f; 19 | bool@test18 = 2.3f >= 2.3f; 20 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_relational_lessthan.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@test1 = true < false; 3 | bool@test2 = false < true; 4 | bool@test3 = false < false; 5 | bool@test4 = 2 < 3; 6 | bool@test5 = 3 < 2; 7 | bool@test6 = 3 < 3; 8 | bool@test7 = 2 < 3; 9 | bool@test8 = 3 < 2; 10 | bool@test9 = 3 < 3; 11 | bool@test10 = 2l < 3l; 12 | bool@test11 = 3l < 2l; 13 | bool@test12 = 3l < 3l; 14 | bool@test13 = 1.1 < 2.3; 15 | bool@test14 = 2.3 < 1.1; 16 | bool@test15 = 2.3 < 2.3; 17 | bool@test16 = 1.1f < 2.3f; 18 | bool@test17 = 2.3f < 1.1f; 19 | bool@test18 = 2.3f < 2.3f; 20 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_relational_lessthanequals.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@test1 = true <= false; 3 | bool@test2 = false <= true; 4 | bool@test3 = false <= false; 5 | bool@test4 = 2 <= 3; 6 | bool@test5 = 3 <= 2; 7 | bool@test6 = 3 <= 3; 8 | bool@test7 = 2 <= 3; 9 | bool@test8 = 3 <= 2; 10 | bool@test9 = 3 <= 3; 11 | bool@test10 = 2l <= 3l; 12 | bool@test11 = 3l <= 2l; 13 | bool@test12 = 3l <= 3l; 14 | bool@test13 = 1.1 <= 2.3; 15 | bool@test14 = 2.3 <= 1.1; 16 | bool@test15 = 2.3 <= 2.3; 17 | bool@test16 = 1.1f <= 2.3f; 18 | bool@test17 = 2.3f <= 1.1f; 19 | bool@test18 = 2.3f <= 2.3f; 20 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_shiftleft.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@testbool1 = true << false; 3 | bool@testbool2 = false << true; 4 | int16@testint161 = 2 << 3; 5 | int16@testint162 = 3 << 2; 6 | int32@testint321 = 2 << 3; 7 | int32@testint322 = 3 << 2; 8 | int64@testint641 = 2l << 3l; 9 | int64@testint642 = 3l << 2l; 10 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestBinary/binary_shiftright.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@testbool1 = true >> false; 3 | bool@testbool2 = false >> true; 4 | int16@testint161 = 2 >> 3; 5 | int16@testint162 = 3 >> 2; 6 | int32@testint321 = 2 >> 3; 7 | int32@testint322 = 3 >> 2; 8 | int64@testint641 = 2l >> 3l; 9 | int64@testint642 = 3l >> 2l; 10 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCast/cast_explicit.bool.ax: -------------------------------------------------------------------------------- 1 | bool@test1 = bool(int32@testint32); 2 | bool@test2 = bool(int64@testint64); 3 | bool@test3 = bool(float@testfloat); 4 | bool@test4 = bool(double@testdouble); 5 | 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCast/cast_explicit.double.ax: -------------------------------------------------------------------------------- 1 | double@test1 = double(bool@testbool); 2 | double@test2 = double(int32@testint32); 3 | double@test3 = double(int64@testint64); 4 | double@test4 = double(float@testfloat); 5 | 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCast/cast_explicit.float.ax: -------------------------------------------------------------------------------- 1 | float@test1 = float(bool@testbool); 2 | float@test2 = float(int32@testint32); 3 | float@test3 = float(int64@testint64); 4 | float@test4 = float(double@testdouble); 5 | 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCast/cast_explicit.int32.ax: -------------------------------------------------------------------------------- 1 | int32@test1 = int32(bool@testbool); 2 | int32@test2 = int32(int64@testint64); 3 | int32@test3 = int32(float@testfloat); 4 | int32@test4 = int32(double@testdouble); 5 | 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCast/cast_explicit.int64.ax: -------------------------------------------------------------------------------- 1 | int64@test1 = int64(bool@testbool); 2 | int64@test2 = int64(int32@testint32); 3 | int64@test3 = int64(float@testfloat); 4 | int64@test4 = int64(double@testdouble); 5 | 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_dec.double.ax: -------------------------------------------------------------------------------- 1 | 2 | double@test1 = --double@test2; 3 | double@test3 = double@test4--; 4 | double@test5 = (double@test6--, double@test7--, --double@test6); 5 | double@test8 = (--double@test6, --double@test7, double@test6--); 6 | --double@test9 = double@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_dec.float.ax: -------------------------------------------------------------------------------- 1 | 2 | float@test1 = --float@test2; 3 | float@test3 = float@test4--; 4 | float@test5 = (float@test6--, float@test7--, --float@test6); 5 | float@test8 = (--float@test6, --float@test7, float@test6--); 6 | --float@test9 = float@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_dec.int16.ax: -------------------------------------------------------------------------------- 1 | 2 | int16@test1 = --int16@test2; 3 | int16@test3 = int16@test4--; 4 | int16@test5 = (int16@test6--, int16@test7--, --int16@test6); 5 | int16@test8 = (--int16@test6, --int16@test7, int16@test6--); 6 | --int16@test9 = int16@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_dec.int32.ax: -------------------------------------------------------------------------------- 1 | 2 | int32@test1 = --int32@test2; 3 | int32@test3 = int32@test4--; 4 | int32@test5 = (int32@test6--, int32@test7--, --int32@test6); 5 | int32@test8 = (--int32@test6, --int32@test7, int32@test6--); 6 | --int32@test9 = int32@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_dec.int64.ax: -------------------------------------------------------------------------------- 1 | 2 | int64@test1 = --int64@test2; 3 | int64@test3 = int64@test4--; 4 | int64@test5 = (int64@test6--, int64@test7--, --int64@test6); 5 | int64@test8 = (--int64@test6, --int64@test7, int64@test6--); 6 | --int64@test9 = int64@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_inc.double.ax: -------------------------------------------------------------------------------- 1 | 2 | double@test1 = ++double@test2; 3 | double@test3 = double@test4++; 4 | double@test5 = (double@test6++, double@test7++, ++double@test6); 5 | double@test8 = (++double@test6, ++double@test7, double@test6++); 6 | ++double@test9 = double@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_inc.float.ax: -------------------------------------------------------------------------------- 1 | 2 | float@test1 = ++float@test2; 3 | float@test3 = float@test4++; 4 | float@test5 = (float@test6++, float@test7++, ++float@test6); 5 | float@test8 = (++float@test6, ++float@test7, float@test6++); 6 | ++float@test9 = float@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_inc.int16.ax: -------------------------------------------------------------------------------- 1 | 2 | int16@test1 = ++int16@test2; 3 | int16@test3 = int16@test4++; 4 | int16@test5 = (int16@test6++, int16@test7++, ++int16@test6); 5 | int16@test8 = (++int16@test6, ++int16@test7, int16@test6++); 6 | ++int16@test9 = int16@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_inc.int32.ax: -------------------------------------------------------------------------------- 1 | 2 | int32@test1 = ++int32@test2; 3 | int32@test3 = int32@test4++; 4 | int32@test5 = (int32@test6++, int32@test7++, ++int32@test6); 5 | int32@test8 = (++int32@test6, ++int32@test7, int32@test6++); 6 | ++int32@test9 = int32@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestCrement/crement_inc.int64.ax: -------------------------------------------------------------------------------- 1 | 2 | int64@test1 = ++int64@test2; 3 | int64@test3 = int64@test4++; 4 | int64@test5 = (int64@test6++, int64@test7++, ++int64@test6); 5 | int64@test8 = (++int64@test6, ++int64@test7, int64@test6++); 6 | ++int64@test9 = int64@test9; 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestEmpty.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include "TestHarness.h" 5 | 6 | #include 7 | 8 | #include 9 | 10 | using namespace openvdb::points; 11 | 12 | class TestEmpty : public unittest_util::AXTestCase 13 | { 14 | 15 | public: 16 | CPPUNIT_TEST_SUITE(TestEmpty); 17 | CPPUNIT_TEST(testEmpty); 18 | CPPUNIT_TEST_SUITE_END(); 19 | void testEmpty(); 20 | }; 21 | 22 | CPPUNIT_TEST_SUITE_REGISTRATION(TestEmpty); 23 | 24 | void 25 | TestEmpty::testEmpty() 26 | { 27 | unittest_util::AXTestHarness harness; 28 | harness.executeCode("test/snippets/empty/empty"); 29 | AXTESTS_STANDARD_ASSERT_HARNESS(harness); 30 | } 31 | 32 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.bool.ax: -------------------------------------------------------------------------------- 1 | 2 | bool@test1 = bool$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.double.ax: -------------------------------------------------------------------------------- 1 | 2 | double@test1 = double$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.float.ax: -------------------------------------------------------------------------------- 1 | 2 | float@test1 = float$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.int32.ax: -------------------------------------------------------------------------------- 1 | 2 | int32@test1 = int32$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.int64.ax: -------------------------------------------------------------------------------- 1 | 2 | int64@test1 = int64$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.mat3d.ax: -------------------------------------------------------------------------------- 1 | 2 | mat3d@test1 = mat3d$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.mat3f.ax: -------------------------------------------------------------------------------- 1 | 2 | mat3f@test1 = mat3f$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.mat4d.ax: -------------------------------------------------------------------------------- 1 | 2 | mat4d@test1 = mat4d$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.mat4f.ax: -------------------------------------------------------------------------------- 1 | 2 | mat4f@test1 = mat4f$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.string.ax: -------------------------------------------------------------------------------- 1 | 2 | string@test1 = string$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.vec2d.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2d@test1 = vec2d$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.vec2f.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2f@test1 = vec2f$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.vec2i.ax: -------------------------------------------------------------------------------- 1 | 2 | vec2i@test1 = vec2i$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.vec3d.ax: -------------------------------------------------------------------------------- 1 | 2 | vec3d@test1 = vec3d$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.vec3f.ax: -------------------------------------------------------------------------------- 1 | 2 | vec3f@test1 = vec3f$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.vec3i.ax: -------------------------------------------------------------------------------- 1 | 2 | vec3i@test1 = vec3i$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.vec4d.ax: -------------------------------------------------------------------------------- 1 | 2 | vec4d@test1 = vec4d$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.vec4f.ax: -------------------------------------------------------------------------------- 1 | 2 | vec4f@test1 = vec4f$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/integration/TestExternals/external_assign_from.vec4i.ax: -------------------------------------------------------------------------------- 1 | 2 | vec4i@test1 = vec4i$ext1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/conditional/conditionalErrors: -------------------------------------------------------------------------------- 1 | if ({1,1,1}) { 2 | true; 3 | } 4 | 5 | if (false) { 6 | true; 7 | } else if ("foo") { 8 | true; 9 | } 10 | 11 | if ({1,1,1} < 1) { 12 | true; 13 | } -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/conditional/conditionalIfWithinElse: -------------------------------------------------------------------------------- 1 | bool@bool_test = false; 2 | 3 | if (false) {} 4 | else 5 | { 6 | if (false) ; 7 | else if (true) { 8 | if (true) 9 | { 10 | bool@bool_test = true; 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/conditional/conditionalScopingStatement: -------------------------------------------------------------------------------- 1 | int32@int_test = 0; 2 | 3 | if(true) { 4 | if (true) { 5 | int@int_test = 1; 6 | } 7 | else if(true) { 8 | int@int_test = 2; 9 | } 10 | else { 11 | int@int_test = 3; 12 | } 13 | } 14 | else { 15 | int@int_test = 4; 16 | } 17 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/conditional/conditionalSimpleElseIf: -------------------------------------------------------------------------------- 1 | int32@int_test = 2; 2 | bool@bool_test = false; 3 | 4 | if(int32@int_test == 0) ; 5 | else if (int32@int_test == 1) ; 6 | else if (int32@int_test == 2) bool@bool_test = true; 7 | else 8 | 9 | int32@int_test = 0; 10 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/conditional/conditionalSimpleStatement: -------------------------------------------------------------------------------- 1 | @float_test = 5.f; 2 | bool@bool_test = false; 3 | 4 | if (!bool@bool_test) @float_test = 1.f; 5 | 6 | if(!bool@bool_test) if(true) bool@bool_test = true; 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareAmbiguousScalarAttributes: -------------------------------------------------------------------------------- 1 | @float_test; 2 | i@float_test; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareAmbiguousScalarExternals: -------------------------------------------------------------------------------- 1 | $float_test; 2 | i$float_test; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareAmbiguousVectorAttributes: -------------------------------------------------------------------------------- 1 | v@vector_float; 2 | vec3i@vector_float; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareAmbiguousVectorExternals: -------------------------------------------------------------------------------- 1 | v$vector_float; 2 | vec3i$vector_float; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareAttributes: -------------------------------------------------------------------------------- 1 | @float_test1; 2 | int32@int_test1; 3 | 4 | int16@short_test = 1s; 5 | int32@int_test2 = 5; 6 | int64@long_test = 3l; 7 | 8 | float@float_test2 = 0.2f; 9 | double@double_test = 0.3; 10 | 11 | f@float_test3 = 10.0f; 12 | @float_test4 = 10.0f; 13 | 14 | i@int_test3 = 10; 15 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareAttributesVolume: -------------------------------------------------------------------------------- 1 | // Same as declareAttributes without short data. Used for volume tests since "short" volumes 2 | // are not supported at the moment. Can be deprecated if this ever changes 3 | 4 | @float_test1; 5 | int32@int_test1; 6 | 7 | int32@int_test2 = 5; 8 | int64@long_test = 3l; 9 | 10 | float@float_test2 = 0.2f; 11 | double@double_test = 0.3; 12 | 13 | f@float_test3 = 10.0f; 14 | @float_test4 = 10.0f; 15 | 16 | i@int_test3 = 10; 17 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareLocalVariables: -------------------------------------------------------------------------------- 1 | float a_float; 2 | int32 a_int; 3 | 4 | int16 a_short = 1s; 5 | int32 b_int = 5; 6 | int64 a_long = 3l; 7 | 8 | float b_float = 0.2f; 9 | double a_double = 0.3; 10 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareLocalVectorVariables: -------------------------------------------------------------------------------- 1 | vec3f a_float; 2 | vec3i a_int; 3 | 4 | vec3i b_int = {5, 6, 7}; 5 | 6 | vec3f b_float = {0.2f, 0.3f, 0.4f}; 7 | vec3d a_double = {0.3, 0.4, 0.5}; 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareNewVectorAttributes: -------------------------------------------------------------------------------- 1 | v@vec_float_test; 2 | vec3i@vec_int_test; 3 | 4 | vec3i@vec_int_test2 = {5, 6, 7}; 5 | 6 | vec3f@vec_float_test2 = {0.2f, 0.3f, 0.4f}; 7 | vec3d@vec_double_test = {0.3, 0.4, 0.5}; 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareVectorAttributeImplicit: -------------------------------------------------------------------------------- 1 | 2 | vec3d@vec_double_test = {1.f, 0.3, 0.4}; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/declare/declareVectorAttributes: -------------------------------------------------------------------------------- 1 | v@vec_float_test; 2 | vec3i@vec_int_test; 3 | 4 | vec3i@vec_int_test2 = {5, 6, 7}; 5 | 6 | vec3f@vec_float_test2 = {0.2f, 0.3f, 0.4f}; 7 | vec3d@vec_double_test = {0.3, 0.4, 0.5}; 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/empty/empty: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AcademySoftwareFoundation/openvdb/67964d1e15f5aaeaffe56751f54d8fc5a5d4bed1/openvdb_ax/openvdb_ax/test/snippets/empty/empty -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/abs: -------------------------------------------------------------------------------- 1 | int32@test1 = abs(-3); 2 | int32@test2 = abs(3); 3 | int32@test3 = abs(0); 4 | int64@test4 = abs(-2147483649l); 5 | float@test5 = abs(0.3f); 6 | float@test6 = abs(-0.3f); 7 | double@test7 = abs(1.79769e+308); 8 | double@test8 = abs(-1.79769e+308); 9 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/acos: -------------------------------------------------------------------------------- 1 | double@test1 = acos(0.5); 2 | float@test2 = acos(0.5f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/adjoint: -------------------------------------------------------------------------------- 1 | 2 | mat3d inputd = { 3 | 1.0, -1.0, 0.0, 4 | 2.0, 2.0, 0.0, 5 | 0.0, 0.0, -1.0 6 | }; 7 | 8 | mat3d add; 9 | add = adjoint(inputd); 10 | 11 | mat3f inputf = { 12 | 1.0f, -1.0f, 0.0f, 13 | 2.0f, 2.0f, 0.0f, 14 | 0.0f, 0.0f, -1.0f 15 | }; 16 | 17 | mat3f adf; 18 | adf = adjoint(inputf); 19 | 20 | mat3d@test1 = add; 21 | mat3f@test2 = adf; 22 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/argsort: -------------------------------------------------------------------------------- 1 | 2 | vec3d input3d = {1.0, -1.0, 0.0}; 3 | vec3f input3f = {1.0f, -1.0f, 0.0f}; 4 | vec3i input3i = {1, -1, 0}; 5 | 6 | vec4d input4d = {1.0, -1.0, 0.0, 5.0}; 7 | vec4f input4f = {1.0f, -1.0f, 0.0f, 5.0f}; 8 | vec4i input4i = {1, -1, 0, 5}; 9 | 10 | vec3i sorted3d; 11 | sorted3d = argsort(input3d); 12 | 13 | vec3i sorted3f; 14 | sorted3f = argsort(input3f); 15 | 16 | vec3i sorted3i; 17 | sorted3i = argsort(input3i); 18 | 19 | vec4i sorted4d; 20 | sorted4d = argsort(input4d); 21 | 22 | vec4i sorted4f; 23 | sorted4f = argsort(input4f); 24 | 25 | vec4i sorted4i; 26 | sorted4i = argsort(input4i); 27 | 28 | vec3i@test1 = sorted3d; 29 | vec3i@test2 = sorted3f; 30 | vec3i@test3 = sorted3i; 31 | vec4i@test4 = sorted4d; 32 | vec4i@test5 = sorted4f; 33 | vec4i@test6 = sorted4i; 34 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/asin: -------------------------------------------------------------------------------- 1 | double@test1 = asin(-0.5); 2 | float@test2 = asin(-0.5f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/atan: -------------------------------------------------------------------------------- 1 | double@test1 = atan(1.0); 2 | float@test2 = atan(1.0f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/atan2: -------------------------------------------------------------------------------- 1 | double@test1 = atan2(1.0, 1.0); 2 | float@test2 = atan2(1.0f, 1.0f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/atof: -------------------------------------------------------------------------------- 1 | double@test1 = atof(""); 2 | double@test2 = atof("-0.0"); 3 | double@test3 = atof("+0.0"); 4 | double@test4 = atof("-1.1"); 5 | double@test5 = atof("1.5"); 6 | double@test6 = atof("1.s9"); 7 | double@test7 = atof("1s.9"); 8 | double@test8 = atof(" 1.6"); 9 | double@test9 = atof("1.5s1"); 10 | double@test10 = atof("1. 1.3"); 11 | double@test11 = atof("11.11"); 12 | double@test12 = atof("1.79769e+308"); 13 | double@test13 = atof("2.22507e-308"); 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/atoi: -------------------------------------------------------------------------------- 1 | i@test1 = atoi(""); 2 | i@test2 = atoi("-0"); 3 | i@test3 = atoi("+0"); 4 | i@test4 = atoi("-1"); 5 | i@test5 = atoi("1"); 6 | i@test6 = atoi("1s"); 7 | i@test7 = atoi("1s"); 8 | i@test8 = atoi(" 1"); 9 | i@test9 = atoi("1s1"); 10 | i@test10 = atoi("1 1"); 11 | i@test11 = atoi("11"); 12 | i@test12 = atoi("2147483647"); // int max 13 | i@test13 = atoi("-2147483648"); 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/cbrt: -------------------------------------------------------------------------------- 1 | double@test1 = cbrt(729.0); 2 | float@test2 = cbrt(729.0f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/clamp: -------------------------------------------------------------------------------- 1 | 2 | double@double_test1 = clamp(-2.5, -1.5, 1.5); 3 | double@double_test2 = clamp(0.0, -1.5, 1.5); 4 | double@double_test3 = clamp(2.5, -1.5, 1.5); 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/cofactor: -------------------------------------------------------------------------------- 1 | 2 | mat3d inputd = { 3 | 1.0, -1.0, 0.0, 4 | 2.0, 2.0, 0.0, 5 | 0.0, 0.0, -1.0 6 | }; 7 | 8 | mat3d cd; 9 | cd = cofactor(inputd); 10 | 11 | mat3f inputf = { 12 | 1.0f, -1.0f, 0.0f, 13 | 2.0f, 2.0f, 0.0f, 14 | 0.0f, 0.0f, -1.0f 15 | }; 16 | 17 | mat3f cf; 18 | cf = cofactor(inputf); 19 | 20 | mat3d@test1 = cd; 21 | mat3f@test2 = cf; 22 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/cosh: -------------------------------------------------------------------------------- 1 | double@test1 = cosh(1.0); 2 | float@test2 = cosh(1.0f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/cross: -------------------------------------------------------------------------------- 1 | vec3d ad = {1.0,2.2,3.4}; 2 | vec3d bd = {4.1,5.3,6.2}; 3 | vec3d@test1 = cross(ad, bd); 4 | vec3f af = {1.0f,2.2f,3.4f}; 5 | vec3f bf = {4.1f,5.3f,6.2f}; 6 | vec3f@test2 = cross(af, bf); 7 | vec3f ai = {1,2,3}; 8 | vec3f bi = {4,5,6}; 9 | vec3i@test3 = cross(ai, bi); 10 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/curlsimplexnoise: -------------------------------------------------------------------------------- 1 | vec3d p = {4.3,5.7,-6.2}; 2 | vec3d@test1 = curlsimplexnoise(p); 3 | vec3d@test2 = curlsimplexnoise(4.3,5.7,-6.2); 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/degrees: -------------------------------------------------------------------------------- 1 | double@test1 = degrees(1.5708); 2 | float@test2 = degrees(-1.1344f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/determinant: -------------------------------------------------------------------------------- 1 | 2 | mat3f m3f = { 1.0f, 0.0f, 0.0f, 3 | 0.0f, 200.0f, 0.0f, 4 | 0.0f, 0.0f, 3.0f }; 5 | 6 | mat3d m3d = { 100.0, 0.0, 0.0, 7 | 0.0, 2.0, 0.0, 8 | 0.0, 0.0, 3.0 }; 9 | 10 | mat4f m4f = { 1.0f, 0.0f, 0.0f, 0.0f, 11 | 0.0f, 2.0f, 0.0f, 0.0f, 12 | 0.0f, 0.0f, 3.0f, 0.0f, 13 | 0.0f, 0.0f, 0.0f, 4.0f }; 14 | 15 | mat4d m4d = { 1.0, 0.0, 0.0, 0.0, 16 | 0.0, 2.0, 0.0, 0.0, 17 | 0.0, 0.0, 3.0, 0.0, 18 | 0.0, 0.0, 0.0, 400.0 }; 19 | 20 | float@det3_float = determinant(m3f); 21 | double@det3_double = determinant(m3d); 22 | float@det4_float = determinant(m4f); 23 | double@det4_double = determinant(m4d); 24 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/diag: -------------------------------------------------------------------------------- 1 | vec3d diag1 = {-1.0,-2.0,-3.0}; 2 | vec3f diag2 = {-1.0f,-2.0f,-3.0f}; 3 | mat3d@test1 = diag(diag1); 4 | mat3f@test2 = diag(diag2); 5 | 6 | vec4d diag3 = {-1.0,-2.0,-3.0,-4.0}; 7 | vec4f diag4 = {-1.0f,-2.0f,-3.0f,-4.0f}; 8 | mat4d@test3 = diag(diag3); 9 | mat4f@test4 = diag(diag4); 10 | 11 | mat3d diag5 = {-1.0,2.0,3.0, 4.0,-5.0,6.0, 7.0,8.0,-9.0}; 12 | mat3f diag6 = {-1.0f,2.0f,3.0f, 4.0f,-5.0f,6.0f, 7.0f,8.0f,-9.0f}; 13 | vec3d@test5 = diag(diag5); 14 | vec3f@test6 = diag(diag6); 15 | 16 | mat4d diag7 = {-1.0,2.0,3.0,4.0, 5.0,-6.0,7.0,8.0, 9.0,10.0,-11.0,12.0, 13.0,14.0,15.0,-16.0}; 17 | mat4f diag8 = {-1.0f,2.0f,3.0f,4.0f, 5.0f,-6.0f,7.0f,8.0f, 9.0f,10.0f,-11.0f,12.0f, 13.0f,14.0f,15.0f,-16.0f}; 18 | 19 | vec4d@test7 = diag(diag7); 20 | vec4f@test8 = diag(diag8); 21 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/dot: -------------------------------------------------------------------------------- 1 | vec3d ad = {1.0,2.2,3.4}; 2 | vec3d bd = {4.1,5.3,6.2}; 3 | double@test1 = dot(ad, bd); 4 | vec3f af = {1.0f,2.2f,3.4f}; 5 | vec3f bf = {4.1f,5.3f,6.2f}; 6 | float@test2 = dot(af, bf); 7 | vec3f ai = {1,2,3}; 8 | vec3f bi = {4,5,6}; 9 | int@test3 = dot(ai, bi); 10 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/euclideanmod: -------------------------------------------------------------------------------- 1 | 2 | int@itest1 = euclideanmod(7,5); 3 | int@itest2 = euclideanmod(-7,5); 4 | int@itest3 = euclideanmod(7,-5); 5 | int@itest4 = euclideanmod(-7,-5); 6 | 7 | float@ftest1 = euclideanmod(7.2f,5.7f); 8 | float@ftest2 = euclideanmod(-7.2f,5.7f); 9 | float@ftest3 = euclideanmod(7.2f,-5.7f); 10 | float@ftest4 = euclideanmod(-7.2f,-5.7f); 11 | 12 | double@dtest1 = euclideanmod(7.2,5.7); 13 | double@dtest2 = euclideanmod(-7.2,5.7); 14 | double@dtest3 = euclideanmod(7.2,-5.7); 15 | double@dtest4 = euclideanmod(-7.2,-5.7); 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/external: -------------------------------------------------------------------------------- 1 | @foo = external("float1"); 2 | v@v = externalv("vector1"); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/floormod: -------------------------------------------------------------------------------- 1 | 2 | int@itest1 = floormod(7,5); 3 | int@itest2 = 7%5; 4 | int@itest3 = floormod(-7,5); 5 | int@itest4 = -7%5; 6 | int@itest5 = floormod(7,-5); 7 | int@itest6 = 7%-5; 8 | int@itest7 = floormod(-7,-5); 9 | int@itest8 = -7%-5; 10 | 11 | float@ftest1 = floormod(7.2f,5.7f); 12 | float@ftest2 = 7.2f%5.7f; 13 | float@ftest3 = floormod(-7.2f,5.7f); 14 | float@ftest4 = -7.2f%5.7f; 15 | float@ftest5 = floormod(7.2f,-5.7f); 16 | float@ftest6 = 7.2f%-5.7f; 17 | float@ftest7 = floormod(-7.2f,-5.7f); 18 | float@ftest8 = -7.2f%-5.7f; 19 | 20 | double@dtest1 = floormod(7.2,5.7); 21 | double@dtest2 = 7.2%5.7; 22 | double@dtest3 = floormod(-7.2,5.7); 23 | double@dtest4 = -7.2%5.7; 24 | double@dtest5 = floormod(7.2,-5.7); 25 | double@dtest6 = 7.2%-5.7; 26 | double@dtest7 = floormod(-7.2,-5.7); 27 | double@dtest8 = -7.2%-5.7; 28 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/hash: -------------------------------------------------------------------------------- 1 | 2 | int64@test1 = hash(""); 3 | int64@test2 = hash("0"); 4 | int64@test3 = hash("abc"); 5 | int64@test4 = hash("123"); 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/hsvtorgb: -------------------------------------------------------------------------------- 1 | vec3d@test1 = hsvtorgb({0,0,0}); 2 | vec3d@test2 = hsvtorgb({1,1,1}); 3 | vec3d@test3 = hsvtorgb({5.8,1,1}); 4 | vec3d@test4 = hsvtorgb({-0.1,-0.5,10}); 5 | vec3d@test5 = hsvtorgb({-5.1,10.5,-5}); 6 | vec3d@test6 = hsvtorgb({-7,-11.5,5}); 7 | vec3d@test7 = hsvtorgb({0.5,0.5,0.5}); 8 | vec3d@test8 = hsvtorgb({0.3,1.0,10.0}); 9 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/identity3: -------------------------------------------------------------------------------- 1 | mat3d@test = identity3(); 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/identity4: -------------------------------------------------------------------------------- 1 | mat4d@test = identity4(); 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/intrinsic: -------------------------------------------------------------------------------- 1 | double@dtest1 = sqrt(9.0); 2 | double@dtest2 = cos(0.0); 3 | double@dtest3 = sin(0.0); 4 | double@dtest4 = log(1.0); 5 | double@dtest5 = log10(1.0); 6 | double@dtest6 = log2(2.0); 7 | double@dtest7 = exp(0.0); 8 | double@dtest8 = exp2(4.0); 9 | double@dtest9 = fabs(-10.321); 10 | double@dtest10 = floor(2194.213); 11 | double@dtest11 = ceil(2194.213); 12 | double@dtest12 = round(0.5); 13 | 14 | float@ftest1 = sqrt(9.0f); 15 | float@ftest2 = cos(0.0f); 16 | float@ftest3 = sin(0.0f); 17 | float@ftest4 = log(1.0f); 18 | float@ftest5 = log10(1.0f); 19 | float@ftest6 = log2(2.0f); 20 | float@ftest7 = exp(0.0f); 21 | float@ftest8 = exp2(4.0f); 22 | float@ftest9 = fabs(-10.321f); 23 | float@ftest10 = floor(2194.213f); 24 | float@ftest11 = ceil(2194.213f); 25 | float@ftest12 = round(0.5f); 26 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/inverse: -------------------------------------------------------------------------------- 1 | 2 | mat3d inputd = { 3 | 1.0, -1.0, 0.0, 4 | 2.0, 2.0, 0.0, 5 | 0.0, 0.0, -1.0 6 | }; 7 | 8 | mat3d singulard = { 9 | 1.0, 2.0, 3.0, 10 | 4.0, 5.0, 6.0, 11 | 7.0, 8.0, 9.0 12 | }; 13 | 14 | mat3d invd; 15 | invd = inverse(inputd); 16 | mat3d sind; 17 | sind = inverse(singulard); 18 | 19 | mat3f inputf = { 20 | 1.0f, -1.0f, 0.0f, 21 | 2.0f, 2.0f, 0.0f, 22 | 0.0f, 0.0f, -1.0f 23 | }; 24 | 25 | mat3f singularf = { 26 | 1.0f, 2.0f, 3.0f, 27 | 4.0f, 5.0f, 6.0f, 28 | 7.0f, 8.0f, 9.0f 29 | }; 30 | 31 | mat3f invf; 32 | invf = inverse(inputf); 33 | mat3f sinf; 34 | sinf = inverse(singularf); 35 | 36 | mat3d@test1 = invd; 37 | mat3f@test2 = invf; 38 | mat3d@test3 = sind; 39 | mat3f@test4 = sinf; 40 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/length: -------------------------------------------------------------------------------- 1 | vec2d test1 = {2.2, 3.3}; 2 | double@test1 = length(test1); 3 | vec2f test2 = {2.2f, 3.3f}; 4 | float@test2 = length(test2); 5 | vec2i test3 = {2, 3}; 6 | double@test3 = length(test3); 7 | 8 | vec3d test4 = {2.2, 3.3, 6.6}; 9 | double@test4 = length(test4); 10 | vec3f test5 = {2.2f, 3.3f, 6.6f}; 11 | float@test5 = length(test5); 12 | vec3i test6 = {2, 3, 6}; 13 | double@test6 = length(test6); 14 | 15 | vec4d test7 = {2.2, 3.3, 6.6, 7.7}; 16 | double@test7 = length(test7); 17 | vec4f test8 = {2.2f, 3.3f, 6.6f, 7.7f}; 18 | float@test8 = length(test8); 19 | vec4i test9 = {2, 3, 6, 7}; 20 | double@test9 = length(test9); 21 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/lengthsq: -------------------------------------------------------------------------------- 1 | vec2d test1 = {2.2, 3.3}; 2 | double@test1 = lengthsq(test1); 3 | vec2f test2 = {2.2f, 3.3f}; 4 | float@test2 = lengthsq(test2); 5 | vec2i test3 = {2, 3}; 6 | int@test3 = lengthsq(test3); 7 | 8 | vec3d test4 = {2.2, 3.3, 6.6}; 9 | double@test4 = lengthsq(test4); 10 | vec3f test5 = {2.2f, 3.3f, 6.6f}; 11 | float@test5 = lengthsq(test5); 12 | vec3i test6 = {2, 3, 6}; 13 | int@test6 = lengthsq(test6); 14 | 15 | vec4d test7 = {2.2, 3.3, 6.6, 7.7}; 16 | double@test7 = lengthsq(test7); 17 | vec4f test8 = {2.2f, 3.3f, 6.6f, 7.7f}; 18 | float@test8 = lengthsq(test8); 19 | vec4i test9 = {2, 3, 6, 7}; 20 | int@test9 = lengthsq(test9); 21 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/lerp: -------------------------------------------------------------------------------- 1 | double@test1 = lerp(-1.1, 1.0000001, 0.0); 2 | // test formulation returns b when t = 1.0 3 | double@test2 = lerp(-1.1, 1.0000001, 1.0); 4 | double@test3 = lerp(1.1, 1.0000001, 1.0); 5 | double@test4 = lerp(-1.1, -1.0000001, 1.0); 6 | // test formulation returns exact input when a==b 7 | double@test5 = lerp(1.1, 1.1, 100.0); 8 | double@test6 = lerp(-1.1, -1.1, 100.0); 9 | // 10 | double@test7 = lerp(1.0, 11.0, 0.5); 11 | double@test8 = lerp(1.0, 11.0, 2.0); 12 | double@test9 = lerp(1.0, 11.0,-2.0); 13 | float@test10 = lerp(1.0f, 11.0f, 0.5f); 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/max: -------------------------------------------------------------------------------- 1 | double@test1 = max(-1.5, 1.5); 2 | float@test2 = max(-1.5f, 1.5f); 3 | int@test3 = max(-1, 1); 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/min: -------------------------------------------------------------------------------- 1 | double@test1 = min(-1.5, 1.5); 2 | float@test2 = min(-1.5f, 1.5f); 3 | int@test3 = min(-1, 1); 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/normalize: -------------------------------------------------------------------------------- 1 | 2 | vec3f test3f = {1.f, 2.f, 3.f}; 3 | vec3d test3d = {1., 2., 3.}; 4 | vec3i test3i = {1, 2, 3}; 5 | 6 | vec4f test4f = {1.f, 2.f, 3.f, 4.f}; 7 | vec4d test4d = {1., 2., 3., 4.}; 8 | vec4i test4i = {1, 2, 3, 4}; 9 | 10 | vec3f@test1 = normalize(test3f); 11 | vec3d@test2 = normalize(test3d); 12 | vec3d@test3 = normalize(test3i); 13 | 14 | vec4f@test4 = normalize(test4f); 15 | vec4d@test5 = normalize(test4d); 16 | vec4d@test6 = normalize(test4i); 17 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/polardecompose: -------------------------------------------------------------------------------- 1 | // inputs to create combination matrix: 2 | // 3 | // mat3d scale = { 4 | // 2, 0, 0, 5 | // 0, 3.3, 0, 6 | // 0, 0, -7.2 7 | // }; 8 | // 9 | // 45 deg around 0,1,0 10 | // mat3d rotation = { 11 | // 0.7071067811847432, 0.0000000, 0.7071067811883519, 12 | // 0.0000000, 1.0000000, 0.0000000, 13 | // -0.7071067811883519, 0.0000000, 0.7071067811847432 14 | // }; 15 | 16 | // r*s 17 | mat3d transform = { 18 | 1.41421456236949, 0, -5.09116882455613, 19 | 0, 3.3, 0.0, 20 | -1.41421356237670, 0, -5.09116882453015 21 | }; 22 | polardecompose(transform, mat3d@rotation, mat3d@symm); 23 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/pow: -------------------------------------------------------------------------------- 1 | 2 | float temp1 = 4.7f; 3 | float temp2 = -4.3f; 4 | int temp3 = 3; 5 | 6 | @float_test1 = pow(1.0, 1.0); 7 | @float_test2 = pow(3.0, -2.1); 8 | i@int_test1 = pow(temp3, 5); 9 | @float_test3 = pow(temp1, temp2); 10 | @float_test4 = pow(temp1, temp3); 11 | @float_test5 = pow(5, -5); 12 | 13 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/pretransform: -------------------------------------------------------------------------------- 1 | 2 | mat3d m3d1 = { 3 | 1.0, 2.0, 3.0, 4 | 4.0, 5.0, 6.0, 5 | 7.0, 8.0, 9.0 6 | }; 7 | 8 | mat4d m4d1 = { 9 | 1.0, 2.0, 3.0, 4.0, 10 | 5.0, 6.0, 7.0, 8.0, 11 | 9.0, 10.0,11.0,12.0, 12 | 13.0,14.0,15.0,16.0 13 | }; 14 | 15 | mat3d m3f1 = { 16 | 1.0f, 2.0f, 3.0f, 17 | 4.0f, 5.0f, 6.0f, 18 | 7.0f, 8.0f, 9.0f 19 | }; 20 | 21 | mat4d m4f1 = { 22 | 1.0f, 2.0f, 3.0f, 4.0f, 23 | 5.0f, 6.0f, 7.0f, 8.0f, 24 | 9.0f, 10.0f,11.0f,12.0f, 25 | 13.0f,14.0f,15.0f,16.0f 26 | }; 27 | 28 | vec3d@test1 = pretransform(m3d1, {1.0,2.0,3.0}); 29 | vec3f@test2 = pretransform(m3f1, {1.0f,2.0f,3.0f}); 30 | vec3d@test3 = pretransform(m4d1, {1.0,2.0,3.0}); 31 | vec3f@test4 = pretransform(m4f1, {1.0f,2.0f,3.0f}); 32 | 33 | vec4d@test5 = pretransform(m4d1, {1.0,2.0,3.0,4.0}); 34 | vec4f@test6 = pretransform(m4f1, {1.0f,2.0f,3.0f,4.0f}); 35 | 36 | vec3i v3i = {1,2,3}; 37 | vec3d@test7 = pretransform(m4d1, v3i); 38 | vec3f@test8 = pretransform(m4f1, v3i); 39 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/print: -------------------------------------------------------------------------------- 1 | 2 | print("a"); 3 | print(1); 4 | print(2e-10); 5 | print({3,4,5,6}); 6 | print("bcd"); 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/radians: -------------------------------------------------------------------------------- 1 | double@test1 = radians(90.0); 2 | float@test2 = radians(-65.0f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/rand: -------------------------------------------------------------------------------- 1 | 2 | double seed = 2.0; 3 | double@test0 = rand(seed); 4 | double@test1 = rand(seed); // should be the same as test0 5 | double@test2 = rand(seed + 1.0); // should be different to test0 and test1 6 | double@test3 = rand(); // should advance the generator from seed+1 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/rand32: -------------------------------------------------------------------------------- 1 | 2 | double seed = 2.0; 3 | double@test0 = rand32(seed); 4 | double@test1 = rand32(seed); // should be the same as test0 5 | double@test2 = rand32(seed + 1.0); // should be different to test0 and test1 6 | double@test3 = rand32(); // should advance the generator from seed+1 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/rgbtohsv: -------------------------------------------------------------------------------- 1 | vec3d@test1 = rgbtohsv({0,0,0}); 2 | vec3d@test2 = rgbtohsv({1,1,1}); 3 | vec3d@test3 = rgbtohsv({20.5,40.3,100.1}); 4 | vec3d@test4 = rgbtohsv({-10,1.3,0.25}); 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/sign: -------------------------------------------------------------------------------- 1 | i@test1 = sign(-0.0); 2 | i@test2 = sign(+0.0); 3 | i@test3 = sign(-0.0f); 4 | i@test4 = sign(+0.0f); 5 | i@test5 = sign(0.0); 6 | i@test6 = sign(0.0f); 7 | i@test7 = sign(0); 8 | i@test8 = sign(-0.1); 9 | i@test9 = sign(-0.1f); 10 | i@test10 = sign(-1); 11 | i@test11 = sign(0.1); 12 | i@test12 = sign(0.1f); 13 | i@test13 = sign(1); 14 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/signbit: -------------------------------------------------------------------------------- 1 | bool@test1 = signbit(-0.0); 2 | bool@test2 = signbit(+0.0); 3 | bool@test3 = signbit(-0.0f); 4 | bool@test4 = signbit(+0.0f); 5 | bool@test5 = signbit(0); 6 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/simplexnoise: -------------------------------------------------------------------------------- 1 | double@noise1 = simplexnoise(1.0, 2.0, 3.0); 2 | double@noise2 = simplexnoise(1.0, 2.0); 3 | double@noise3 = simplexnoise(1.0); 4 | 5 | vec3d x = {4.0, 14.0, 114.0}; 6 | double@noise4 = simplexnoise(x); 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/sinh: -------------------------------------------------------------------------------- 1 | double@test1 = sinh(1.0); 2 | float@test2 = sinh(1.0f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/sort: -------------------------------------------------------------------------------- 1 | 2 | vec3d input3d = {1.0, -1.0, 0.0}; 3 | vec3f input3f = {1.0f, -1.0f, 0.0f}; 4 | vec3i input3i = {1, -1, 0}; 5 | 6 | vec4d input4d = {1.0, -1.0, 0.0, 5.0}; 7 | vec4f input4f = {1.0f, -1.0f, 0.0f, 5.0f}; 8 | vec4i input4i = {1, -1, 0, 5}; 9 | 10 | vec3d sorted3d; 11 | sorted3d = sort(input3d); 12 | 13 | vec3f sorted3f; 14 | sorted3f = sort(input3f); 15 | 16 | vec3i sorted3i; 17 | sorted3i = sort(input3i); 18 | 19 | vec4d sorted4d; 20 | sorted4d = sort(input4d); 21 | 22 | vec4f sorted4f; 23 | sorted4f = sort(input4f); 24 | 25 | vec4i sorted4i; 26 | sorted4i = sort(input4i); 27 | 28 | vec3d@test1 = sorted3d; 29 | vec3f@test2 = sorted3f; 30 | vec3i@test3 = sorted3i; 31 | vec4d@test4 = sorted4d; 32 | vec4f@test5 = sorted4f; 33 | vec4i@test6 = sorted4i; 34 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/svd: -------------------------------------------------------------------------------- 1 | 2 | mat3d inputd = { 3 | 1.0, -1.0, 0.0, 4 | 2.0, 2.0, 0.0, 5 | 0.0, 0.0, -1.0 6 | }; 7 | 8 | mat3d ud,vd; 9 | vec3d sigmad; 10 | svd(inputd, ud, sigmad, vd); 11 | 12 | mat3f inputf = { 13 | 1.0f, -1.0f, 0.0f, 14 | 2.0f, 2.0f, 0.0f, 15 | 0.0f, 0.0f, -1.0f 16 | }; 17 | 18 | mat3f uf,vf; 19 | vec3f sigmaf; 20 | svd(inputf, uf, sigmaf, vf); 21 | 22 | mat3d@test1 = ud; 23 | mat3d@test2 = vd; 24 | 25 | mat3f@test3 = uf; 26 | mat3f@test4 = vf; 27 | 28 | vec3d@test5 = sigmad; 29 | vec3f@test6 = sigmaf; 30 | 31 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/tan: -------------------------------------------------------------------------------- 1 | double@test1 = tan(1.0); 2 | float@test2 = tan(1.0f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/tanh: -------------------------------------------------------------------------------- 1 | double@test1 = tanh(1.0); 2 | float@test2 = tanh(1.0f); 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/trace: -------------------------------------------------------------------------------- 1 | mat3d testm3d = { 2 | 1.0,-100.0,-100.0, 3 | -100.0, 2.0,-100.0, 4 | -100.0,-100.0, 3.0 5 | }; 6 | 7 | double@test1 = trace(testm3d); 8 | 9 | mat3f testm3f = { 10 | 1.0f,-100.0f,-100.0f, 11 | -100.0f, 2.0f,-100.0f, 12 | -100.0f,-100.0f, 3.0f 13 | }; 14 | 15 | float@test2 = trace(testm3f); 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/transform: -------------------------------------------------------------------------------- 1 | 2 | mat3d m3d1 = { 3 | 1.0, 2.0, 3.0, 4 | 4.0, 5.0, 6.0, 5 | 7.0, 8.0, 9.0 6 | }; 7 | 8 | mat4d m4d1 = { 9 | 1.0, 2.0, 3.0, 4.0, 10 | 5.0, 6.0, 7.0, 8.0, 11 | 9.0, 10.0,11.0,12.0, 12 | 13.0,14.0,15.0,16.0 13 | }; 14 | 15 | mat3d m3f1 = { 16 | 1.0f, 2.0f, 3.0f, 17 | 4.0f, 5.0f, 6.0f, 18 | 7.0f, 8.0f, 9.0f 19 | }; 20 | 21 | mat4d m4f1 = { 22 | 1.0f, 2.0f, 3.0f, 4.0f, 23 | 5.0f, 6.0f, 7.0f, 8.0f, 24 | 9.0f, 10.0f,11.0f,12.0f, 25 | 13.0f,14.0f,15.0f,16.0f 26 | }; 27 | 28 | vec3d@test1 = transform({1.0,2.0,3.0}, m3d1); 29 | vec3f@test2 = transform({1.0f,2.0f,3.0f}, m3f1); 30 | vec3d@test3 = transform({1.0,2.0,3.0}, m4d1); 31 | vec3f@test4 = transform({1.0f,2.0f,3.0f}, m4f1); 32 | 33 | vec4d@test5 = transform({1.0,2.0,3.0,4.0}, m4d1); 34 | vec4f@test6 = transform({1.0f,2.0f,3.0f,4.0f}, m4f1); 35 | 36 | vec3i v3i = {1,2,3}; 37 | vec3d@test7 = transform(v3i, m4d1); 38 | vec3f@test8 = transform(v3i, m4f1); 39 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/transpose: -------------------------------------------------------------------------------- 1 | 2 | mat3d m3d1 = { 3 | 1.0, 2.0, 3.0, 4 | 4.0, 5.0, 6.0, 5 | 7.0, 8.0, 9.0 6 | }; 7 | 8 | mat3d@test1 = transpose(m3d1); 9 | 10 | mat3f m3f1 = { 11 | 1.0f, 2.0f, 3.0f, 12 | 4.0f, 5.0f, 6.0f, 13 | 7.0f, 8.0f, 9.0f 14 | }; 15 | 16 | mat3f@test2 = transpose(m3f1); 17 | 18 | mat4d m4d1 = { 19 | 1.0, 2.0, 3.0, 4.0, 20 | 5.0, 6.0, 7.0, 8.0, 21 | 9.0, 10.0,11.0,12.0, 22 | 13.0,14.0,15.0,16.0 23 | }; 24 | 25 | mat4d@test3 = transpose(m4d1); 26 | 27 | mat4f m4f1 = { 28 | 1.0f, 2.0f, 3.0f, 4.0f, 29 | 5.0f, 6.0f, 7.0f, 8.0f, 30 | 9.0f, 10.0f,11.0f,12.0f, 31 | 13.0f,14.0f,15.0f,16.0f 32 | }; 33 | 34 | mat4f@test4 = transpose(m4f1); 35 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/function/truncatemod: -------------------------------------------------------------------------------- 1 | 2 | int@itest1 = truncatemod(7,5); 3 | int@itest2 = truncatemod(-7,5); 4 | int@itest3 = truncatemod(7,-5); 5 | int@itest4 = truncatemod(-7,-5); 6 | 7 | float@ftest1 = truncatemod(7.2f,5.7f); 8 | float@ftest2 = truncatemod(-7.2f,5.7f); 9 | float@ftest3 = truncatemod(7.2f,-5.7f); 10 | float@ftest4 = truncatemod(-7.2f,-5.7f); 11 | 12 | double@dtest1 = truncatemod(7.2,5.7); 13 | double@dtest2 = truncatemod(-7.2,5.7); 14 | double@dtest3 = truncatemod(7.2,-5.7); 15 | double@dtest4 = truncatemod(-7.2,-5.7); 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/keyword/conditionalReturn: -------------------------------------------------------------------------------- 1 | if (false) 2 | { 3 | int@return_test3 = 1; 4 | return; 5 | int@return_test3 = 2; 6 | } 7 | else 8 | { 9 | int@return_test3 = 3; 10 | return; 11 | int@return_test3 = 4; 12 | } 13 | 14 | int@return_test3 = 5; 15 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/keyword/doWhileLoopKeywords: -------------------------------------------------------------------------------- 1 | // do loop with break 2 | { 3 | vec3f v = 0.0f; 4 | int i = 0; 5 | do { 6 | if (i == 1) break; 7 | v[i] = i+1; 8 | i++; 9 | } 10 | while(i < 3) 11 | 12 | vec3f@loop_test13 = v; 13 | } 14 | 15 | // do loop with continue 16 | { 17 | vec3f v = 0.0f; 18 | int i = 0; 19 | 20 | do { 21 | i++; 22 | if (i == 1) continue; 23 | v[i] = i; 24 | } 25 | while(i < 2) 26 | 27 | vec3f@loop_test14 = v; 28 | } 29 | 30 | // do loop with return 31 | { 32 | vec3f v = 0.0f; 33 | int i = 0; 34 | vec3f@return_test7 = 100; 35 | 36 | do { 37 | if (i == 1) return; 38 | v[i] = i+1; 39 | i++; 40 | } 41 | while(i < 3) 42 | 43 | vec3f@return_test7 = v; 44 | } 45 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/keyword/returnBranchIf: -------------------------------------------------------------------------------- 1 | int@return_test1 = 1; 2 | return; 3 | 4 | int@return_test1 = 1000; 5 | if (1 != 0) int@return_test1 = 3; 6 | else int@return_test1 = 5; 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/keyword/returnBranchLoop: -------------------------------------------------------------------------------- 1 | int@return_test2 = 1; 2 | return; 3 | 4 | for(int i = 0; i < 10; ++i) { 5 | int@return_test2 = i; 6 | } 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/keyword/simpleReturn: -------------------------------------------------------------------------------- 1 | return; 2 | int@return_test0 = 1; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/keyword/whileLoopKeywords: -------------------------------------------------------------------------------- 1 | 2 | // while loop with break 3 | { 4 | vec3f v = 0.0f; 5 | int i = 0; 6 | while(i < 3) { 7 | if (i == 1) break; 8 | v[i] = i+1; 9 | i++; 10 | } 11 | vec3f@loop_test10 = v; 12 | } 13 | 14 | // while loop with continue 15 | { 16 | vec3f v = 0.0f; 17 | int i = 0; 18 | while(i < 2) { 19 | i++; 20 | if (i == 1) continue; 21 | v[i] = i; 22 | } 23 | vec3f@loop_test11 = v; 24 | } 25 | 26 | // while loop with return 27 | { 28 | vec3f v = 0.0f; 29 | int i = 0; 30 | vec3f@return_test6 = 100; 31 | 32 | while(i < 3) { 33 | if (i == 1) return; 34 | v[i] = i+1; 35 | i++; 36 | } 37 | vec3f@return_test6 = v; 38 | } 39 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/loop/doWhileLoop: -------------------------------------------------------------------------------- 1 | // do loop 2 | { 3 | vec3f v = 0.0f; 4 | int32 i = 0; 5 | do { 6 | v[i] = i+1; 7 | i++; 8 | } 9 | while(i < 3); 10 | 11 | vec3f@loop_test12 = v; 12 | } 13 | 14 | // do loop false condition 15 | { 16 | vec3f v = 0.0f; 17 | int32 i = 0; 18 | do { 19 | v[i] = i + 1; 20 | } 21 | while(false) 22 | 23 | vec3f@loop_test17 = v; 24 | } 25 | 26 | // do loop multi expression false condition 27 | { 28 | vec3f v = 0.0f; 29 | int32 i = 0; 30 | do { 31 | v[i] = i + 1; 32 | } 33 | while(true, true, true, false) 34 | 35 | vec3f@loop_test29 = v; 36 | } 37 | 38 | // do while loop declaration condition 39 | { 40 | int32 k = 1; 41 | float j = 1.1f; 42 | do { 43 | k++; 44 | j--; 45 | } 46 | while(int32 i = floor(j)) 47 | 48 | int32@loop_test32 = k; 49 | } 50 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/loop/loopErrors: -------------------------------------------------------------------------------- 1 | for (int i; {1,1,1}; ++i) { 2 | true; 3 | } 4 | 5 | for (int i; {1,1,1} < 1; ++i) { 6 | true; 7 | } 8 | 9 | do { 10 | true; 11 | } while ("foo") 12 | 13 | mat3f mat = identity3(); 14 | while (mat) { 15 | true; 16 | } -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/loop/loopOverflow: -------------------------------------------------------------------------------- 1 | mat4d m1=0; 2 | vec3f v1=1; 3 | for (int32 i = 0; i < 10000000; ++i) { 4 | // 10000000 x alloca inside of loop 5 | mat4d m2 = m1; 6 | // sret function, 10000000 x alloca of result 7 | vec3f v2 = normalize(v1); 8 | // strings 9 | string a = "foo" + "bar"; 10 | } 11 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/loop/whileLoop: -------------------------------------------------------------------------------- 1 | // while loop 2 | { 3 | vec3f v = 0.0f; 4 | int32 i = 0; 5 | while(i < 3) { 6 | v[i] = i+1; 7 | i++; 8 | } 9 | vec3f@loop_test9 = v; 10 | } 11 | 12 | // while loop false condition 13 | { 14 | vec3f v = 0.0f; 15 | int32 i = 0; 16 | while(false) { 17 | v[i] = i + 1; 18 | } 19 | vec3f@loop_test16 = v; 20 | } 21 | 22 | // while loop multi expression false condition 23 | { 24 | vec3f v = 0.0f; 25 | int32 i = 0; 26 | while(true, true, true, false) { 27 | v[i] = i + 1; 28 | } 29 | vec3f@loop_test28 = v; 30 | } 31 | 32 | // while loop declaration condition 33 | { 34 | int32 k = 1; 35 | float j = 1.1f; 36 | while(int32 i = floor(j)) { 37 | k++; 38 | j--; 39 | 40 | } 41 | int32@loop_test31 = k; 42 | } 43 | 44 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/string/assignCompound: -------------------------------------------------------------------------------- 1 | // uninitialized string should be set to "" 2 | 3 | string test1; 4 | test1 += "foo"; 5 | string test2 = "foo"; 6 | test2 += "bar"; 7 | 8 | s@test1 = test1; 9 | s@test2 = test2; 10 | 11 | for (int i = 0; i < 10; i++) { 12 | s@test3 += "a"; 13 | } 14 | 15 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/string/assignFromAttributes: -------------------------------------------------------------------------------- 1 | 2 | string@string_test2 = string@string_test1; // set to test - string_test only existing string attribute 3 | 4 | string@string_test1 = "new value"; 5 | 6 | string@string_test3 = string@string_test1; // "new value", string_test3 created 7 | string@string_test4 = string@string_test3; // "new value" 8 | 9 | string@string_test6 = string@string_test5; // empty strings, both created 10 | 11 | 12 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/string/assignFromLocals: -------------------------------------------------------------------------------- 1 | string test = "test"; 2 | string test2 = test; 3 | string@string_test1 = test2; // test 4 | 5 | test2 = "new string size"; 6 | string@string_test2 = test; // test 7 | string@string_test3 = test2; // new string size 8 | 9 | test = ""; 10 | string@string_test4 = test; // empty string 11 | 12 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/string/assignNewOverwrite: -------------------------------------------------------------------------------- 1 | 2 | string value = "new_value"; // A value which shouldn't exist on the string attribute 3 | string@string_test1 = value; 4 | string@string_test2 = value; 5 | 6 | string@string_test1 = "next_value"; // re-assign the value to one of the strings 7 | 8 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/string/binaryConcat: -------------------------------------------------------------------------------- 1 | 2 | string test = "test"; 3 | string space = " "; 4 | string test2 = "new value"; 5 | string result = test + space + test2; 6 | 7 | string@string_test1 = result; // "test new value" 8 | string@string_test2 = test + space + test2; // "test new value" 9 | 10 | result = test + " " + test2; 11 | 12 | string@string_test3 = result; // "test new value" 13 | string@string_test4 = test + " " + test2; // "test new value" 14 | string@string_test5 = "" + ""; // "" 15 | string@string_test6 = "" + result; // "test new value" 16 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/string/declare: -------------------------------------------------------------------------------- 1 | string test = "test"; 2 | string@string_test = test; 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/ternary/ternaryErrors: -------------------------------------------------------------------------------- 1 | {1,1,1} ? 0 : 1; 2 | 3 | {1,0,0,0,1,0,0,0,1} & 1 ? 0 : 1; 4 | 5 | "foo" ? : "bar"; 6 | 7 | "foo" ? : 1; 8 | 9 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/ternary/ternaryVoid: -------------------------------------------------------------------------------- 1 | 2 | bool b = false; 3 | b ? removefromgroup("notdead") : addtogroup("notdead"); 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/unary/unaryBitwiseNot: -------------------------------------------------------------------------------- 1 | 2 | int int_value = 8; 3 | int int_value2 = 7; 4 | 5 | int@int_test = ~int_value; 6 | int@int_test2 = ~int_value2; 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/unary/unaryNegate: -------------------------------------------------------------------------------- 1 | 2 | int int_value = 3; 3 | 4 | int_value = - int_value; 5 | int_value = - int_value; 6 | int_value = - int_value; 7 | int_value = + int_value; 8 | 9 | int@int_test = int_value; 10 | 11 | float float_value = 5.5f; 12 | 13 | float_value = - float_value; 14 | float_value = - float_value; 15 | float_value = - float_value; 16 | float_value = + float_value; 17 | 18 | float@float_test = float_value; 19 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/unary/unaryNot: -------------------------------------------------------------------------------- 1 | 2 | bool t = true; 3 | bool f = false; 4 | 5 | bool@bool_test = !t; 6 | bool@bool_test2 = !f; 7 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/unary/unaryVector: -------------------------------------------------------------------------------- 1 | 2 | vec3i v3i = {0, 1, -1}; 3 | vec3f v3f = {0.0f, 1.1f, -1.1f}; 4 | vec3d v3d = {0.0, 1.1, -1.1}; 5 | 6 | vec4i v4i = {0, 1, -1, 2}; 7 | vec4f v4f = {0.0f, 1.1f, -1.1f, 2.1f}; 8 | vec4d v4d = {0.0, 1.1, -1.1, 2.1}; 9 | 10 | // vec3 11 | 12 | vec3i@v3i1 = +v3i; 13 | vec3i@v3i2 = -v3i; 14 | vec3i@v3i3 = ~v3i; 15 | vec3i@v3i4 = !v3i; 16 | 17 | vec3f@v3f1 = +v3f; 18 | vec3f@v3f2 = -v3f; 19 | 20 | vec3d@v3d1 = +v3d; 21 | vec3d@v3d2 = -v3d; 22 | 23 | // vec4 24 | 25 | vec4i@v4i1 = +v4i; 26 | vec4i@v4i2 = -v4i; 27 | vec4i@v4i3 = ~v4i; 28 | vec4i@v4i4 = !v4i; 29 | 30 | vec4f@v4f1 = +v4f; 31 | vec4f@v4f2 = -v4f; 32 | 33 | vec4d@v4d1 = +v4d; 34 | vec4d@v4d2 = -v4d; 35 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/vdb_functions/addremovefromgroup: -------------------------------------------------------------------------------- 1 | // both adds and removes from groups 2 | // we use 9 groups as a stress test since 8 groups can be stored 3 | // using a single attribute 4 | 5 | addtogroup("newTestGroup1"); 6 | int@newTestAttribute1 = ingroup("newTestGroup1"); 7 | addtogroup("newTestGroup2"); 8 | addtogroup("newTestGroup3"); 9 | addtogroup("newTestGroup4"); 10 | addtogroup("newTestGroup5"); 11 | addtogroup("newTestGroup6"); 12 | addtogroup("newTestGroup7"); 13 | addtogroup("newTestGroup8"); 14 | addtogroup("newTestGroup9"); 15 | 16 | // should already exist 17 | 18 | if(ingroup("existingTestGroup")) 19 | { 20 | removefromgroup("newTestGroup9"); 21 | addtogroup("existingTestGroup2"); 22 | int@newTestAttribute2 = 1; 23 | } 24 | 25 | // remove from a group that neither exists nor will be added 26 | // nothing should be done in this case 27 | removefromgroup("nonExistentGroup"); 28 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/vdb_functions/deletepoint: -------------------------------------------------------------------------------- 1 | if (i@delete) deletepoint(); 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/vdb_functions/getcoord: -------------------------------------------------------------------------------- 1 | int@a0 = getcoordx(); 2 | int@a1 = getcoordy(); 3 | int@a2 = getcoordz(); 4 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/vdb_functions/getvoxelpws: -------------------------------------------------------------------------------- 1 | vector@a = getvoxelpws(); 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/vdb_functions/ingroup: -------------------------------------------------------------------------------- 1 | 2 | // create an attribute from groups so that we can check their values in 3 | // the C++ test code. We add "1" since data is often initialized to 0 and 4 | // this can cause misleading test results. 5 | 6 | if (ingroup("a")) i@test = 1; 7 | 8 | int@groupTest = ingroup("testGroup") + 1; 9 | int@groupTest2 = ingroup("testGroup2") + 1; 10 | 11 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceAssign: -------------------------------------------------------------------------------- 1 | 2 | v@P_original = @P; // access @P - should return original world-space position 3 | @P = {2.22f, 3.33f, 4.44f}; // store @P - value given in world-space should be turned into voxel-space 4 | v@P_new = @P; // access @P - should return @P in world-space and store in P_new 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceAssignBound: -------------------------------------------------------------------------------- 1 | 2 | v@P_original = v@pos; // access @P through binding to v@pos - should return original world-space position 3 | v@pos = {2.22f, 3.33f, 4.44f}; // store @P through binding to v@pos - value given in world-space should be turned into voxel-space 4 | v@P_new = v@pos; // access @P through binding to v@pos- should return @P in world-space and store in P_new 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceAssignComponent: -------------------------------------------------------------------------------- 1 | 2 | @Px_original = @P.x; // access @P.x - should return original world-space position x component 3 | @P.x = 5.22f; // store @P.x - value given in world-space should be turned into voxel-space 4 | @Px_new = @P.x; // access @P.x - should return world-space value and store in Px_new 5 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceAssignFromP: -------------------------------------------------------------------------------- 1 | v@test = v@P; // the point of this test is that we are using a world-space accessor but not writing to P 2 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceDecrementComponentByZero: -------------------------------------------------------------------------------- 1 | 2 | v@P.y -= 0.0f; // decrement @P.y in world-space by zero. 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceDivideComponentByOne: -------------------------------------------------------------------------------- 1 | 2 | v@P.y /= 1.0f; // divide @P.y in world-space by one. 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceIncrement: -------------------------------------------------------------------------------- 1 | 2 | v@P += {5.0f, 6.0f, 7.0f}; // increment @P in world-space 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceIncrementComponent: -------------------------------------------------------------------------------- 1 | 2 | v@P.x += 7.0f; // increment @P.x in world-space 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceIncrementComponentByZero: -------------------------------------------------------------------------------- 1 | 2 | v@P.y += 0.0f; // increment @P.y in world-space by zero. 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/test/snippets/worldspace/worldSpaceMultiplyComponentByOne: -------------------------------------------------------------------------------- 1 | 2 | v@P.y *= 1.0f; // multiply @P.y in world-space by one. 3 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/util/x86.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /// @file util/x86.cc 5 | 6 | #include "x86.h" 7 | 8 | #include 9 | #include 10 | 11 | namespace openvdb { 12 | OPENVDB_USE_VERSION_NAMESPACE 13 | namespace OPENVDB_VERSION_NAME { 14 | namespace ax { 15 | namespace x86 { 16 | 17 | CpuFlagStatus CheckX86Feature(const std::string& flag) 18 | { 19 | llvm::StringMap HostFeatures; 20 | if (!llvm::sys::getHostCPUFeatures(HostFeatures)) { 21 | return CpuFlagStatus::Unknown; 22 | } 23 | if (!HostFeatures.empty()) { 24 | for (auto& feature : HostFeatures) { 25 | if (feature.first() == flag) { 26 | return feature.second ? 27 | CpuFlagStatus::Supported : 28 | CpuFlagStatus::Unsupported; 29 | } 30 | } 31 | } 32 | return CpuFlagStatus::Unknown; 33 | } 34 | 35 | } 36 | } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /openvdb_ax/openvdb_ax/util/x86.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /// @file util/x86.h 5 | 6 | #ifndef OPENVDB_AX_UTIL_X86_HAS_BEEN_INCLUDED 7 | #define OPENVDB_AX_UTIL_X86_HAS_BEEN_INCLUDED 8 | 9 | #include 10 | #include 11 | 12 | namespace openvdb { 13 | OPENVDB_USE_VERSION_NAMESPACE 14 | namespace OPENVDB_VERSION_NAME { 15 | namespace ax { 16 | namespace x86 { 17 | 18 | enum class CpuFlagStatus { 19 | Unknown, Unsupported, Supported 20 | }; 21 | 22 | /// @brief On X86, get the status if a particular CPU instruction 23 | /// @param flag The flag to check. e.g. avx, bmi, f16c, etc 24 | /// @note Returns Unknown if the flag was not found. This could either be 25 | /// because the platform is not X86, because the flag is not a valid X86 26 | /// feature or because the feature is too new for this version of AX/LLVM. 27 | OPENVDB_AX_API CpuFlagStatus CheckX86Feature(const std::string& flag); 28 | 29 | } 30 | } 31 | } 32 | } 33 | 34 | #endif // OPENVDB_AX_UTIL_X86_HAS_BEEN_INCLUDED 35 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_lod/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Copyright Contributors to the OpenVDB Project 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | #[=======================================================================[ 5 | 6 | CMake Configuration for VDB LOD 7 | 8 | #]=======================================================================] 9 | 10 | cmake_minimum_required(VERSION 3.20) 11 | project(VDBLOD LANGUAGES CXX) 12 | 13 | include(GNUInstallDirs) 14 | 15 | set(SOURCE_FILES main.cc) 16 | add_executable(vdb_lod ${SOURCE_FILES}) 17 | target_link_libraries(vdb_lod ${OPENVDB_BINARIES_DEPENDENT_LIBS}) 18 | 19 | install(TARGETS vdb_lod RUNTIME DESTINATION ${OPENVDB_INSTALL_BINDIR}) 20 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_print/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Copyright Contributors to the OpenVDB Project 2 | # SPDX-License-Identifier: Apache-2.0 3 | # 4 | #[=======================================================================[ 5 | 6 | CMake Configuration for VDB Print 7 | 8 | #]=======================================================================] 9 | 10 | cmake_minimum_required(VERSION 3.20) 11 | project(VDBPrint LANGUAGES CXX) 12 | 13 | include(GNUInstallDirs) 14 | 15 | set(SOURCE_FILES main.cc) 16 | add_executable(vdb_print ${SOURCE_FILES}) 17 | target_link_libraries(vdb_print ${OPENVDB_BINARIES_DEPENDENT_LIBS}) 18 | 19 | install(TARGETS vdb_print RUNTIME DESTINATION ${OPENVDB_INSTALL_BINDIR}) 20 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/dilate_level_set.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to read a narrow-band level set 4 | # from an OpenVDB file, dilating it, and writing out the level set 5 | # to a different OpenVDB file. 6 | 7 | # read level set from openvdb file 8 | read bunny.vdb 9 | 10 | # Dilate level set 11 | # radius of dilation is 5.0 voxels 12 | # spatial discretization is 5'th order WENO 13 | # temporal discretization is 1'th order TVD-RK 14 | dilate radius=5 space=5 time=1 15 | 16 | # write level set to file 17 | write bunny_dilated.vdb 18 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/dilate_mesh.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to read a polygon mesh from a ply file, 4 | # converting it into a narrow-band level set, dilating the level set, 5 | # converting the level set into an adaptive polygon mesh and writing out 6 | # the mesh to a binary ply file. 7 | 8 | # read mesh 9 | read bunny.ply 10 | 11 | # Mesh to level set conversion 12 | # dimension is 256 voxels 13 | # narrow-band level set width is 3 voxel units 14 | mesh2ls dim=256 width=3 15 | 16 | # Dilate level set 17 | # radius of dilation is 5.0 voxels 18 | # spatial discretization is 5'th order WENO 19 | # temporal discretization is 1'th order TVD-RK 20 | dilate radius=5 space=5 time=1 21 | 22 | # Level set to polygon mesh conversion 23 | # Mesh adaptivity is 0.1 % 24 | ls2mesh adapt=0.1 25 | 26 | # write polygon mesh to binary ply file 27 | write bunny_dilated.ply 28 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/erode_level_set.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to read a narrow-band level set 4 | # from an OpenVDB file, erode it, and the level set writing 5 | # out to a different OpenVDB file. 6 | 7 | # read level set from openvdb file 8 | read bunny.vdb 9 | 10 | # Erode level set 11 | # radius of erosion is 5.0 voxels 12 | # spatial discretization is 5'th order WENO 13 | # temporal discretization is 1'th order TVD-RK 14 | erode radius=5 space=5 time=1 15 | 16 | # write level set to file 17 | write bunny_erode.vdb 18 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/erode_mesh.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to read a polygon mesh from a ply file, 4 | # converting it into a narrow-band level set, erode the level set, 5 | # converting the level set into an adaptive polygon mesh and writing out 6 | # the mesh to a binary ply file. 7 | 8 | # read mesh 9 | read bunny.ply 10 | 11 | # Mesh to level set conversion 12 | # dimension is 256 voxels 13 | # narrow-band level set width is 3 voxel units 14 | mesh2ls dim=256 width=3 15 | 16 | # Erode level set 17 | # radius of erosion is 5.0 voxels 18 | # spatial discretization is 5'th order WENO 19 | # temporal discretization is 1'th order TVD-RK 20 | erode radius=5 space=5 time=1 21 | 22 | # Level set to polygon mesh conversion 23 | # Mesh adaptivity is 0.1 % 24 | ls2mesh adapt=0.1 25 | 26 | # write polygon mesh to binary ply file 27 | write bunny_erode.ply 28 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/hello_world.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to create a narrow-band 4 | # level set of a sphere and save it to an OpenVDB file. 5 | 6 | # create a narrow-band level set of a sphere 7 | # the dimension is 256 voxels (default value) 8 | # the radius is 100 world units (default value) 9 | # the half width of the narrow band is 3 voxels (default value) 10 | # the sphere is centered at (0,0,0) in world (and voxel) space (default value) 11 | sphere dim=256 radius=100 width=3 center=(0,0,0) 12 | 13 | # write level set to file 14 | write sphere.vdb 15 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/level_set_to_mesh.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to read a narrow-band level set 4 | # from an OpenVDB file and converting the level set into an adaptive 5 | # polygon mesh and writing out the mesh to a binary ply file. 6 | 7 | # read OpenVDB file with level set 8 | read bunny.vdb 9 | 10 | # Level set to polygon mesh conversion 11 | # Mesh adaptivity is 0.1 % 12 | ls2mesh adapt=0.1 13 | 14 | # write polygon mesh to binary ply file 15 | write bunny.ply 16 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/mesh_to_level_set.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to read a polygon mesh from a ply file, 4 | # converting it into a narrow-band level set, and writing out the level set 5 | # to an OpenVDB file. 6 | 7 | # read OpenVDB file with points 8 | read bunny.ply 9 | 10 | # Mesh to level set conversion 11 | # dimension is 256 voxel 12 | # narrow-band level set width is 3 voxel units 13 | mesh2ls dim=256 width=3 14 | 15 | # write level set to an openvdb fie 16 | write bunny.vdb 17 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/obj_to_ply.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This example demonstrated how to convert an ascii 4 | # obj mesh file to a binary ply mesh file. 5 | 6 | # read obj ascii file with polygons 7 | read bunny.obj 8 | 9 | # write polygon mesh to binary ply file 10 | write bunny.ply 11 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/ply_to_obj.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This example demonstrated how to convert a 4 | # binary ply mesh file into an ascii obj mesh file. 5 | 6 | # read polygon mesh from binary ply file 7 | read bunny.ply 8 | 9 | # write polygon mesh to ascii obj file 10 | write bunny.obj 11 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/simplify_mesh.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to read a polygon mesh from a ply file, 4 | # converting it into a narrow-band level set, converting the level set 5 | # into an adaptive polygon mesh and writing out the mesh to a binary ply file. 6 | 7 | # read OpenVDB file with points 8 | read bunny.ply 9 | 10 | # Mesh to level set conversion 11 | # dimension is 256 voxels 12 | # narrow-band level set width is 3 voxel units 13 | mesh2ls dim=256 width=3 14 | 15 | # Level set to polygon mesh conversion 16 | # Mesh adaptivity is 0.25 % 17 | ls2mesh adapt=0.25 18 | 19 | # write polygon mesh to binary ply file 20 | write bunny_smooth.ply 21 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/smooth_level_set.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to read a polygon mesh from a ply file, 4 | # converting it into a narrow-band level set, smooth the level set, 5 | # converting the level set into an adaptive polygon mesh and writing out 6 | # the mesh to a binary ply file. 7 | 8 | # read level set from openvdb file 9 | read bunny.vdb 10 | 11 | # Gaussian filtering of level set 12 | # number of iterations is 5 13 | # spatial discretization is 5'th order WENO 14 | # temporal discretization is 1'th order TVD-RK 15 | # size of the filter kernel is 1.0 voxels 16 | gauss iter=5 space=5 time=1 size=1 17 | 18 | # write level set to file 19 | write bunny_smooth.vdb 20 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/smooth_mesh.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This examples demonstrates how to read a polygon mesh from a ply file, 4 | # converting it into a narrow-band level set, smoothing the level set, 5 | # converting the level set into an adaptive polygon mesh and writing out 6 | # the mesh to a binary ply file. 7 | 8 | # read mesh 9 | read bunny.ply 10 | 11 | # Mesh to level set conversion 12 | # dimension is 256 voxels 13 | # narrow-band level set width is 3 voxel units 14 | mesh2ls dim=256 width=3 15 | 16 | # Gaussian filtering of level set 17 | # number of iterations is 5 18 | # spatial discretization is 5'th order WENO 19 | # temporal discretization is 1'th order TVD-RK 20 | # size of the filter kernel is 1.0 voxels 21 | gauss iter=5 space=5 time=1 size=1 22 | 23 | # Level set to polygon mesh conversion 24 | # Mesh adaptivity is 0.1 % 25 | ls2mesh adapt=0.1 26 | 27 | # write polygon mesh to binary ply file 28 | write bunny_smooth.ply 29 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_tool/examples/vdb_points_to_ply.txt: -------------------------------------------------------------------------------- 1 | vdb_tool 10.6.1 2 | 3 | # This example demonstrates how to convert points 4 | # in an OpenVDB PointDataGrid to a binary ply file. 5 | 6 | # read OpenVDB file with points 7 | read points.vdb 8 | 9 | # extract point from VDB grid 10 | vdb2points 11 | 12 | # write points to binary ply file 13 | write points.ply 14 | -------------------------------------------------------------------------------- /openvdb_cmd/vdb_view/Font.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDB_VIEWER_FONT_HAS_BEEN_INCLUDED 5 | #define OPENVDB_VIEWER_FONT_HAS_BEEN_INCLUDED 6 | 7 | #include 8 | 9 | #if defined(__APPLE__) || defined(MACOSX) 10 | #include 11 | #include 12 | #elif defined(_WIN32) 13 | #include 14 | #else 15 | #include 16 | #include 17 | #endif 18 | 19 | 20 | namespace openvdb_viewer { 21 | 22 | class BitmapFont13 23 | { 24 | public: 25 | BitmapFont13() {} 26 | 27 | static void initialize(); 28 | 29 | static void enableFontRendering(); 30 | static void disableFontRendering(); 31 | 32 | static void print(GLint px, GLint py, const std::string&); 33 | 34 | private: 35 | static GLuint sOffset; 36 | static GLubyte sCharacters[95][13]; 37 | }; 38 | 39 | } // namespace openvdb_viewer 40 | 41 | #endif // OPENVDB_VIEWER_FONT_HAS_BEEN_INCLUDED 42 | -------------------------------------------------------------------------------- /openvdb_houdini/openvdb_houdini/COPYRIGHT: -------------------------------------------------------------------------------- 1 | Copyright Contributors to the OpenVDB Project 2 | SPDX-License-Identifier: Apache-2.0 -------------------------------------------------------------------------------- /openvdb_houdini/openvdb_houdini/GU_VDBPointTools.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #include "GU_VDBPointTools.h" 5 | 6 | 7 | -------------------------------------------------------------------------------- /openvdb_houdini/openvdb_houdini/UT_VDBUtils.cc: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | /* 5 | * Copyright (c) Side Effects Software Inc. 6 | * 7 | * Produced by: 8 | * Side Effects Software Inc 9 | * 477 Richmond Street West 10 | * Toronto, Ontario 11 | * Canada M5V 3E7 12 | * 416-504-9876 13 | * 14 | * NAME: UT_VDBUtils.h (UT Library, C++) 15 | * 16 | * COMMENTS: 17 | */ 18 | 19 | #include "UT_VDBUtils.h" 20 | 21 | namespace openvdb_houdini { 22 | // empty 23 | } 24 | -------------------------------------------------------------------------------- /openvdb_houdini/openvdb_houdini/abitest/TestABI.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | const char* getABI(); 5 | const char* getNamespace(); 6 | void* createFloatGrid(); 7 | void* createPointsGrid(); 8 | void cleanupFloatGrid(void*); 9 | void cleanupPointsGrid(void*); 10 | int validateFloatGrid(void*); 11 | int validatePointsGrid(void*); 12 | -------------------------------------------------------------------------------- /openvdb_maya/openvdb_maya/AEOpenVDBCopyTemplate.mel: -------------------------------------------------------------------------------- 1 | global proc AEOpenVDBCopyTemplate( string $nodeAttr ) 2 | { 3 | editorTemplate -beginScrollLayout; 4 | { 5 | editorTemplate -beginLayout "OpenVDB Copy" -collapse 0; 6 | editorTemplate 7 | -annotation "Shallow copy selected grids form the A input." 8 | -addControl "GridsFromA"; 9 | editorTemplate 10 | -annotation "Shallow copy selected grids form the B input." 11 | -addControl "GridsFromB"; 12 | editorTemplate -endLayout; 13 | editorTemplate -addExtraControls; 14 | } 15 | editorTemplate -endScrollLayout; 16 | } 17 | -------------------------------------------------------------------------------- /openvdb_maya/openvdb_maya/AEOpenVDBTransformTemplate.mel: -------------------------------------------------------------------------------- 1 | global proc AEOpenVDBTransformTemplate( string $nodeAttr ) 2 | { 3 | editorTemplate -beginScrollLayout; 4 | { 5 | editorTemplate -beginLayout "OpenVDB Transform" -collapse 0; 6 | editorTemplate -addControl "Translate"; 7 | editorTemplate -addControl "Rotate"; 8 | editorTemplate -addControl "Scale"; 9 | editorTemplate -addControl "Pivot"; 10 | editorTemplate -addControl "UniformScale"; 11 | editorTemplate -addControl "InvertTransformation"; 12 | editorTemplate -endLayout; 13 | editorTemplate -addExtraControls; 14 | } 15 | editorTemplate -endScrollLayout; 16 | } 17 | -------------------------------------------------------------------------------- /openvdb_maya/openvdb_maya/COPYRIGHT: -------------------------------------------------------------------------------- 1 | Copyright Contributors to the OpenVDB Project 2 | SPDX-License-Identifier: Apache-2.0 -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Kernel/init.m: -------------------------------------------------------------------------------- 1 | (* ::Package:: *) 2 | 3 | If[$CloudEvaluation, 4 | Print["OpenVDBLink cannot run in the Wolfram Cloud because the cloud does not support LibraryLink. Aborting."]; 5 | Abort[] 6 | ]; 7 | 8 | 9 | If[$VersionNumber < 11.0, 10 | Print["OpenVDBLink requires Mathematica 11.0 or later. Aborting."]; 11 | Abort[] 12 | ] 13 | 14 | 15 | Unprotect["OpenVDBLink`*"]; 16 | 17 | 18 | Get["OpenVDBLink`OpenVDBLink`"]; 19 | 20 | 21 | With[{$userSyms = {"$OpenVDBCreator", "$OpenVDBHalfWidth", "$OpenVDBSpacing"}}, 22 | Scan[SetAttributes[#, {Protected, ReadProtected}]&, Complement[Names["OpenVDBLink`*"], $userSyms]]; 23 | ] 24 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/LTemplate.m: -------------------------------------------------------------------------------- 1 | (* ::Package:: *) 2 | 3 | (* ::Text:: *) 4 | (*Copyright Contributors to the OpenVDB Project*) 5 | (*SPDX-License-Identifier: Apache-2.0*) 6 | 7 | 8 | (* ::Text:: *) 9 | (*This is a traditional package that uses BeginPackage instead of Package.*) 10 | (*It loads LTemplate into the correct context.*) 11 | 12 | 13 | BeginPackage["OpenVDBLink`"] 14 | 15 | 16 | Get["OpenVDBLink`LTemplate`LTemplatePrivate`"]; 17 | ConfigureLTemplate["MessageSymbol" -> OpenVDBLink, "LazyLoading" -> False] 18 | 19 | 20 | EndPackage[] 21 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/LTemplate/IncludeFiles/LTemplateCompilerSetup.h: -------------------------------------------------------------------------------- 1 | #ifndef LTEMPLATE_COMPILER_SETUP_H 2 | #define LTEMPLATE_COMPILER_SETUP_H 3 | 4 | #if __cplusplus >= 201103L || _MSC_VER >= 1900 5 | #define LTEMPLATE_USE_CXX11 6 | #endif 7 | 8 | #if LTEMPLATE_MMA_VERSION >= 1040 && defined (LTEMPLATE_USE_CXX11) 9 | #define LTEMPLATE_RAWARRAY 10 | #endif 11 | 12 | #if LTEMPLATE_MMA_VERSION >= 1200 && defined (LTEMPLATE_USE_CXX11) 13 | #define LTEMPLATE_NUMERICARRAY 14 | #endif 15 | 16 | #ifdef _WIN32 17 | #ifndef NOMINMAX 18 | #define NOMINMAX 19 | #endif 20 | #endif 21 | 22 | #endif // LTEMPLATE_COMPILER_SETUP_H 23 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/LTemplate/Kernel/init.m: -------------------------------------------------------------------------------- 1 | (* ::Package:: *) 2 | 3 | (* Mathematica Init File *) 4 | 5 | Get["LTemplate`LTemplate`"] 6 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/LTemplate/LTemplatePrivate.m: -------------------------------------------------------------------------------- 1 | (* Mathematica Package *) 2 | 3 | (* :Package Version: 0.5.4 *) 4 | (* :Copyright: (c) 2019 Szabolcs Horvat *) 5 | (* :License: MIT license, see LICENSE.txt *) 6 | 7 | (* 8 | * To include LTemplate privately in another package, load LTemplatePrivate.m using Get[], 9 | * then immediately call ConfigureLTemplate[]. 10 | *) 11 | 12 | BeginPackage["`LTemplate`", {"SymbolicC`", "CCompilerDriver`"}] 13 | 14 | (* Note: Do not Protect symbols when LTemplate is loaded privately. *) 15 | 16 | `Private`$private = True; 17 | Quiet[ 18 | Get@FileNameJoin[{DirectoryName[$InputFileName], "LTemplateInner.m"}], 19 | General::shdw (* suppress false shadowing warnings if public LTemplate was loaded first *) 20 | ] 21 | 22 | EndPackage[] 23 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/LTemplate/LTemplatePrivateNoCompile.m: -------------------------------------------------------------------------------- 1 | (* Mathematica Package *) 2 | 3 | (* :Package Version: 0.5.4 *) 4 | (* :Copyright: (c) 2019 Szabolcs Horvat *) 5 | (* :License: MIT license, see LICENSE.txt *) 6 | 7 | (* 8 | * To include LTemplate privately in another package, and disable compilation support, 9 | * load LTemplatePrivateNoCompile.m using Get[], then immediately call ConfigureLTemplate[]. 10 | * Disabling compilation support will avoid loading CCompilerDriver` and therefore improve 11 | * loading performance on Windows. Packages that ship with pre-compiled binaries do not need 12 | * compilation support in the LTemplate they embed. 13 | *) 14 | 15 | BeginPackage["`LTemplate`", {"SymbolicC`"}] 16 | 17 | (* Note: Do not Protect symbols when LTemplate is loaded privately. *) 18 | 19 | `Private`$private = True; 20 | `Private`$noCompile = True; 21 | Quiet[ 22 | Get@FileNameJoin[{DirectoryName[$InputFileName], "LTemplateInner.m"}], 23 | General::shdw (* suppress false shadowing warnings if public LTemplate was loaded first *) 24 | ] 25 | 26 | EndPackage[] 27 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBBoolGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBBOOLGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBBOOLGRID_HAS_BEEN_INCLUDED 6 | 7 | #include "../OpenVDBGrid.h" 8 | 9 | using OpenVDBBoolGrid = openvdbmma::OpenVDBGrid; 10 | 11 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBBOOLGRID_HAS_BEEN_INCLUDED 12 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBByteGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBBYTEGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBBYTEGRID_HAS_BEEN_INCLUDED 6 | 7 | #include "../OpenVDBGrid.h" 8 | 9 | using OpenVDBByteGrid = openvdbmma::OpenVDBGrid; 10 | 11 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBBYTEGRID_HAS_BEEN_INCLUDED 12 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBDoubleGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBDOUBLEGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBDOUBLEGRID_HAS_BEEN_INCLUDED 6 | 7 | #include "../OpenVDBGrid.h" 8 | 9 | using OpenVDBDoubleGrid = openvdbmma::OpenVDBGrid; 10 | 11 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBDOUBLEGRID_HAS_BEEN_INCLUDED 12 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBFloatGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBFLOATGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBFLOATGRID_HAS_BEEN_INCLUDED 6 | 7 | #include "../OpenVDBGrid.h" 8 | 9 | using OpenVDBFloatGrid = openvdbmma::OpenVDBGrid; 10 | 11 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBFLOATGRID_HAS_BEEN_INCLUDED 12 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBInt32Grid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBINT32GRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBINT32GRID_HAS_BEEN_INCLUDED 6 | 7 | #include "../OpenVDBGrid.h" 8 | 9 | using OpenVDBInt32Grid = openvdbmma::OpenVDBGrid; 10 | 11 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBINT32GRID_HAS_BEEN_INCLUDED 12 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBInt64Grid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBINT64GRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBINT64GRID_HAS_BEEN_INCLUDED 6 | 7 | #include "../OpenVDBGrid.h" 8 | 9 | using OpenVDBInt64Grid = openvdbmma::OpenVDBGrid; 10 | 11 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBINT64GRID_HAS_BEEN_INCLUDED 12 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBMaskGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBMASKGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBMASKGRID_HAS_BEEN_INCLUDED 6 | 7 | #include 8 | #include 9 | 10 | #include "../OpenVDBGrid.h" 11 | 12 | using OpenVDBMaskGrid = openvdbmma::OpenVDBGrid; 13 | 14 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBMASKGRID_HAS_BEEN_INCLUDED 15 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBUInt32Grid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBUINT32GRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBUINT32GRID_HAS_BEEN_INCLUDED 6 | 7 | #include "../OpenVDBGrid.h" 8 | 9 | using OpenVDBUInt32Grid = openvdbmma::OpenVDBGrid; 10 | 11 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBUINT32GRID_HAS_BEEN_INCLUDED 12 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBVec2DGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC2DGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC2DGRID_HAS_BEEN_INCLUDED 6 | 7 | #include 8 | 9 | #include "../OpenVDBGrid.h" 10 | 11 | using OpenVDBVec2DGrid = openvdbmma::OpenVDBGrid; 12 | 13 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC2DGRID_HAS_BEEN_INCLUDED 14 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBVec2IGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC2IGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC2IGRID_HAS_BEEN_INCLUDED 6 | 7 | #include 8 | 9 | #include "../OpenVDBGrid.h" 10 | 11 | using OpenVDBVec2IGrid = openvdbmma::OpenVDBGrid; 12 | 13 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC2IGRID_HAS_BEEN_INCLUDED 14 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBVec2SGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC2SGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC2SGRID_HAS_BEEN_INCLUDED 6 | 7 | #include 8 | 9 | #include "../OpenVDBGrid.h" 10 | 11 | using OpenVDBVec2SGrid = openvdbmma::OpenVDBGrid; 12 | 13 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC2SGRID_HAS_BEEN_INCLUDED 14 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBVec3DGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC3DGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC3DGRID_HAS_BEEN_INCLUDED 6 | 7 | #include 8 | 9 | #include "../OpenVDBGrid.h" 10 | 11 | using OpenVDBVec3DGrid = openvdbmma::OpenVDBGrid; 12 | 13 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC3DGRID_HAS_BEEN_INCLUDED 14 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBVec3IGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC3IGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC3IGRID_HAS_BEEN_INCLUDED 6 | 7 | #include 8 | 9 | #include "../OpenVDBGrid.h" 10 | 11 | using OpenVDBVec3IGrid = openvdbmma::OpenVDBGrid; 12 | 13 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC3IGRID_HAS_BEEN_INCLUDED 14 | -------------------------------------------------------------------------------- /openvdb_wolfram/OpenVDBLink/Source/ExplicitGrids/OpenVDBVec3SGrid.h: -------------------------------------------------------------------------------- 1 | // Copyright Contributors to the OpenVDB Project 2 | // SPDX-License-Identifier: Apache-2.0 3 | 4 | #ifndef OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC3SGRID_HAS_BEEN_INCLUDED 5 | #define OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC3SGRID_HAS_BEEN_INCLUDED 6 | 7 | #include 8 | 9 | #include "../OpenVDBGrid.h" 10 | 11 | using OpenVDBVec3SGrid = openvdbmma::OpenVDBGrid; 12 | 13 | #endif // OPENVDBLINK_EXPLICITGRIDS_OPENVDBVEC3SGRID_HAS_BEEN_INCLUDED 14 | -------------------------------------------------------------------------------- /pendingchanges/README: -------------------------------------------------------------------------------- 1 | This directory stores pending changes to our CHANGES and changes.txt 2 | files. The idea is that PRs can have their proposed changes audited 3 | without triggering false merges. We periodically collapse these into 4 | the CHANGES and changes.txt. 5 | 6 | Release versions should have this directory empty, but if you 7 | checkout the latest version you may see changes reflected here that 8 | haven't been merged into the CHANGES file yet. 9 | 10 | This README must be maintained or git removes the directory and we 11 | won't remember what directory to put changes into. 12 | -------------------------------------------------------------------------------- /pendingchanges/level_set_constructors.txt: -------------------------------------------------------------------------------- 1 | OpenVDB: 2 | New Features: 3 | - Various level set constructors. 4 | - tools::createLevelSetCapsule creates a grid containing a narrow-band level set representation of a capsule (tube with constant radius and sphere caps). 5 | - tools::createLevelSetTaperedCapsule creates a grid containing a narrow-band level set representation of a tapered capsule (tube with sphere caps and different radii at both ends, or equivalently the convex hull of two spheres with possibly different centers and radii). 6 | - tools::createLevelSetTubeComplex creates a grid containing a narrow-band level set representation of a tube complex (a collection of capsules or tapered capsules defined by endpoint coordinates and segment indices). 7 | - tools::createLevelSetDilatedMesh creates a grid containing a narrow-band level set representation of a dilated surface mesh (dilated by a radius in all directions). 8 | - Base class tools::ConvexVoxelizer, which can be inherited to implement a convex level set constructor. 9 | -------------------------------------------------------------------------------- /pendingchanges/math_nodiscard.txt: -------------------------------------------------------------------------------- 1 | OpenVDB: 2 | API Changes: 3 | Mat3 and Mat4 functions have been marked [[nodiscard]] where it 4 | may be confusing if they are operating in place or returning a 5 | result, in particular tranpose, invert, adjoint, and 6 | timesDiagonal. 7 | -------------------------------------------------------------------------------- /pendingchanges/nanovdb.txt: -------------------------------------------------------------------------------- 1 | Added nanovdb::openToIndexVDB, which can convert an OpenVDB grid into a NanoVDB IndexGrid. 2 | Added new options "--index" and "--onIndex" to the command-line tool nanovdb_convert so it can produce IndexGrids 3 | -------------------------------------------------------------------------------- /pendingchanges/nanovdb_offset_bug.txt: -------------------------------------------------------------------------------- 1 | NanoVDB: 2 | Bug fix: 3 | - Fixed offset bug in nanovdb::tools::cuda::IndexToGrid related to non-POD build types (contributed by Andreas Henne) 4 | -------------------------------------------------------------------------------- /pendingchanges/vdb_tool.txt: -------------------------------------------------------------------------------- 1 | 1) Fixed bugs that prevented build with newer namespaces in nanovdb 2 | 2) Improved read and write of PLY files so they support Vec3d and 64 bit attributes 3 | 4) Changed version number from 10.6.1 to 10.7.0 4 | -------------------------------------------------------------------------------- /tsc/ccla.md: -------------------------------------------------------------------------------- 1 | The CCLA has been moved to https://cla-signature-files-prod.s3.amazonaws.com/contract-group/28a0d3d8-b869-44e0-a4f4-06b50c49822f/template/ccla-2024-09-04T09-58-59Z.pdf -------------------------------------------------------------------------------- /tsc/icla.md: -------------------------------------------------------------------------------- 1 | The ICLA has been moved to https://cla-signature-files-prod.s3.amazonaws.com/contract-group/28a0d3d8-b869-44e0-a4f4-06b50c49822f/template/icla-2024-09-04T09-58-58Z.pdf -------------------------------------------------------------------------------- /tsc/meetings/2022-03-29.md: -------------------------------------------------------------------------------- 1 | Minutes from 127th OpenVDB TSC meeting, March 29th, 2022, (EDT) 2 | 3 | Attendees: *Ken* M., *Jeff* L., *Andre* P., *Nick* A., *Dan* B., *Rich* J. 4 | 5 | Additional Attendees: Greg Hurst (United Therapeutics) 6 | 7 | Agenda: 8 | 9 | 1) Confirm Quorum 10 | 2) Secretary 11 | 3) Forum 12 | 4) OpenVDBLink 13 | 5) Next meeting 14 | 15 | ------------------------ 16 | 1) Confirm Quorum 17 | 18 | Quorum is present. 19 | 20 | 2) Secretary 21 | 22 | Secretary is Richard Jones. 23 | 24 | 3) Forum 25 | 26 | Request (Issue #1337) for forward declarations of grid types in Grid.h. Consensus is that this would be a good addition but some care might need to be taken with nested typedefs/sharedptrs. 27 | 28 | 4) OpenVDBLink 29 | 30 | Greg has go-ahead to contribute OpenVDBLink (Mathematica OpenVDB plugin). Needs updates for docs and error handling. Has a lot of unittests already. Need to figure out CI and some dependency issues. This will be made into a feature branch to iterate upon. 31 | 32 | 5) Next meeting 33 | 34 | Next meeting is in one week, April 4th, 2022. 12pm-1pm EST (GMT-5). -------------------------------------------------------------------------------- /tsc/process/deprecation.md: -------------------------------------------------------------------------------- 1 | **Deprecation Strategy for OpenVDB** 2 | 3 | OpenVDB is committed to supporting three years of 4 | [VFX Reference Platform](http://www.vfxplatform.com/) and all releases of 5 | Houdini and Maya based on those versions of the platform. The latest supported 6 | year is that in which the VDB version listed matches the major version. 7 | 8 | For example, all 6.x versions of OpenVDB support VFX Reference Platform years 9 | 2019, 2018 and 2017. 10 | 11 | This infers the following support: 12 | 13 | * OpenVDB ABI=4, ABI=5 and ABI=6 14 | * C++11 and C++14 15 | * Houdini 16.5, 17.0 and 17.5 16 | 17 | All 7.x versions of OpenVDB support VFX Reference Platform years 2020, 2019 and 18 | 2018. Support for Houdini 16.5, C++11 and ABI=4 is removed. 19 | --------------------------------------------------------------------------------