diff -Nru ilmbase-3.1.9-imath/.clang-format ilmbase-3.1.10/.clang-format --- ilmbase-3.1.9-imath/.clang-format 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/.clang-format 2024-01-24 22:14:50.000000000 +0000 @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. --- Language: Cpp BasedOnStyle: LLVM diff -Nru ilmbase-3.1.9-imath/.git-blame-ignore-revs ilmbase-3.1.10/.git-blame-ignore-revs --- ilmbase-3.1.9-imath/.git-blame-ignore-revs 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/.git-blame-ignore-revs 2024-01-24 22:14:50.000000000 +0000 @@ -1,6 +1,10 @@ -# Disable clang-format in half.cpp -344334aef268206ed1d46399ea85ab276f3f13e6 +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + +# if you have git newer than 2.23, you can either +# specify this on the command line +# git blame foo.cpp --ignore-revs-file path/to/this/file +# or add this file to your config (use global to change your global user pref) +# git config [--global] blame.ignoreRevsFile .git-blame-ignore-revs -# Tune .clang-format to match existing style -c6014892de1acccca0deada8ab3353cd290e9fbc diff -Nru ilmbase-3.1.9-imath/.github/workflows/ci_workflow.yml ilmbase-3.1.10/.github/workflows/ci_workflow.yml --- ilmbase-3.1.9-imath/.github/workflows/ci_workflow.yml 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/.github/workflows/ci_workflow.yml 2024-01-24 22:14:50.000000000 +0000 @@ -301,7 +301,7 @@ ./bin/ImathTest # Confirm the examples compile and execute rm -rf bin CMakeCache.txt CMakeFiles cmake_install.cmake Makefile - cmake ../docs/examples \ + cmake ../website/examples \ -DCMAKE_PREFIX_PATH=../../_install \ -DCMAKE_BUILD_TYPE=${{ matrix.build-type }} \ -DCMAKE_CXX_STANDARD=${{ matrix.cxx-standard }} \ @@ -571,7 +571,6 @@ # run: | # share/ci/scripts/windows/install_python.ps1 ${{ matrix.python-version }} $HOME # share/ci/scripts/windows/install_boost.ps1 ${{ matrix.boost-version }} $HOME 3.8 - # share/ci/scripts/windows/install_zlib.ps1 ${{ matrix.zlib-version }} $HOME # shell: powershell - name: Configure run: | @@ -584,8 +583,6 @@ -DBUILD_SHARED_LIBS=${{ matrix.build-shared }} # NB: removed trailing slash from these lines # -DBOOST_ROOT:FILEPATH=$BOOST_ROOT - # -DZLIB_ROOT:FILEPATH="$ZLIB_ROOT" - # -DZLIB_LIBRARY:FILEPATH="$ZLIB_ROOT/lib/${{ matrix.zlib-lib }}" # -DPYTHON='ON' # -DPython_EXECUTABLE:FILEPATH="$PYTHON_ROOT" # -DPython_INCLUDE_DIR:FILEPATH="$PYTHON_ROOT/include" @@ -609,14 +606,14 @@ shell: bash working-directory: _build - Docs: + Website: # Build the documentation, using a process that mimics the readthedoc build. # # Note that this job does not actually build Imath libraries, # it just runs doxygen and sphinx. - name: 'Docs' + name: 'Website' runs-on: ubuntu-latest steps: @@ -628,14 +625,14 @@ # Need help2man for tool manpages run: sudo apt-get install -y doxygen help2man - name: Install sphinx requirements - run: pip3 install -r docs/requirements.txt + run: pip3 install -r website/requirements.txt - name: Configure - run: cmake .. -DBUILD_DOCS='ON' + run: cmake .. -DBUILD_WEBSITE='ON' working-directory: _build - name: Build run: | cmake --build . \ - --target docs \ + --target website \ --config Release working-directory: _build diff -Nru ilmbase-3.1.9-imath/.gitignore ilmbase-3.1.10/.gitignore --- ilmbase-3.1.9-imath/.gitignore 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/.gitignore 2024-01-24 22:14:50.000000000 +0000 @@ -1,3 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + build/ _build/ _install/ diff -Nru ilmbase-3.1.9-imath/.readthedocs.yml ilmbase-3.1.10/.readthedocs.yml --- ilmbase-3.1.9-imath/.readthedocs.yml 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/.readthedocs.yml 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,21 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright Contributors to the OpenEXR Project. +# +# .readthedocs.yml +# Read the Docs configuration file +# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details + +# Required +version: 2 + +build: + os: "ubuntu-22.04" + tools: + python: "3.9" + +sphinx: + configuration: website/conf.py + +python: + install: + - requirements: website/requirements.txt diff -Nru ilmbase-3.1.9-imath/CHANGES.md ilmbase-3.1.10/CHANGES.md --- ilmbase-3.1.9-imath/CHANGES.md 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/CHANGES.md 2024-01-24 22:14:50.000000000 +0000 @@ -1,5 +1,9 @@ + + + # Imath Release Notes +* [Version 3.1.10](#version-3110-January-26-2024) January 26, 2024 * [Version 3.1.9](#version-319-May-31-2023) May 31, 2023 * [Version 3.1.8](#version-318-May-22-2023) May 22, 2023 * [Version 3.1.7](#version-317-March-1-2023) March 1, 2023 @@ -18,6 +22,97 @@ * [Version 3.0.0-beta](#version-300-beta-march-15-2021) March 15, 2021 * [Inherited History from OpenEXR](#inherited-history-from-openexr) +## Version 3.1.10 (January 26, 2024) + +Patch release with various build/bug fixes. + +Build fixes: + + - Fix a problem where downstream projects using Imath would build + python bindings even if they weren't requested. + - Fix for missing `std::bit_cast` + - Fix missing/necessary use of IMATH_HOSTDEVICE + - IMATH_INSTALL_PKG_CONFIG is now on by default, even on Windows + - Fix calling default constructor by uniform init in TypeTraits + - Fix redundant PYIMATH_EXPORTS causing compile issues on Windows Clang + - Update to SO versioning policy: + + This change adopts a policy of appending the ``MAJOR.MINOR.PATCH`` + software release name to the ``SONAME`` to form the real name of the + shared library. + + See [website/install.rst](website/install.rst) and [PR + #339](https://github.com/AcademySoftwareFoundation/openexr/pull/339) + for more details. + +Bug fixes: + + - Fix half to float giving wrong results on older x86_64 CPUs on Windows + +Other changes: + + - succ()/pred() now use std::nextafter(). + - Expand epsilon bounds for m44x pyImath test. + - Rename "docs" to "website". + - Add missing copyright/license identifiers. + +### Merged Pull Requests + +* \[[#363](https://github.com/AcademySoftwareFoundation/Imath/pull/363)\] +Update install instructions to reflect new SO versioning policy + +* \[[#362](https://github.com/AcademySoftwareFoundation/Imath/pull/362)\] +Require sphinx 5.0 + +* \[[#361](https://github.com/AcademySoftwareFoundation/Imath/pull/361)\] +src/python/config/ModuleDefine.cmake: do not install a cmake file exporting targets for dependent projects + +* \[[#358](https://github.com/AcademySoftwareFoundation/Imath/pull/358)\] +Fix half to float giving wrong results on older x86_64 CPUs on Windows + +* \[[#353](https://github.com/AcademySoftwareFoundation/Imath/pull/353)\] +Changed implementation of succ and pred to use std::nextafter. + +* \[[#350](https://github.com/AcademySoftwareFoundation/Imath/pull/350)\] +Fix check for the availability of std::bit_cast + +* \[[#349](https://github.com/AcademySoftwareFoundation/Imath/pull/349)\] +IMATH_INSTALL_PKG_CONFIG is on by default, even on Windows + +* \[[#347](https://github.com/AcademySoftwareFoundation/Imath/pull/347)\] +Export Imath from the build tree and so on. + +* \[[#344](https://github.com/AcademySoftwareFoundation/Imath/pull/344)\] +rm unnecessary IMATH_HOSTDEVICE attributes. + +* \[[#342](https://github.com/AcademySoftwareFoundation/Imath/pull/342)\] +Add missing copyright/license identifiers + +* \[[#341](https://github.com/AcademySoftwareFoundation/Imath/pull/341)\] +Remove unnecessary files + +* \[[#340](https://github.com/AcademySoftwareFoundation/Imath/pull/340)\] +Fix calling default constructor by uniform init. + +* \[[#339](https://github.com/AcademySoftwareFoundation/Imath/pull/339)\] +Update and simply SO versioning policy + +* \[[#338](https://github.com/AcademySoftwareFoundation/Imath/pull/338)\] +Rename "docs" to "website" + +* \[[#333](https://github.com/AcademySoftwareFoundation/Imath/pull/333)\] +Expand epsilon bounds for m44x pyImath test + +* \[[#331](https://github.com/AcademySoftwareFoundation/Imath/pull/331)\] +Fixed redundant PYIMATH_EXPORTS causing compile issues on Windows Clang + +* \[[#326](https://github.com/AcademySoftwareFoundation/Imath/pull/326)\] +Use security@openexr.com for consistency + +* \[[#320](https://github.com/AcademySoftwareFoundation/Imath/pull/320)\] +Add missing IMATH_HOSTDEVICE to Matrix33::invert(bool) + + ## Version 3.1.9 (May 31, 2023) Patch release that fixes an correct .so version number introduced in diff -Nru ilmbase-3.1.9-imath/CMakeLists.txt ilmbase-3.1.10/CMakeLists.txt --- ilmbase-3.1.9-imath/CMakeLists.txt 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/CMakeLists.txt 2024-01-24 22:14:50.000000000 +0000 @@ -14,7 +14,7 @@ # Imath version -project(Imath VERSION 3.1.9 LANGUAGES C CXX) +project(Imath VERSION 3.1.10 LANGUAGES C CXX) set(IMATH_VERSION_RELEASE_TYPE "" CACHE STRING "Extra version tag string for Imath build, such as -dev, -beta1, etc.") @@ -39,7 +39,7 @@ # 3. API changed: CURRENT+1.0.0 # set(IMATH_LIBTOOL_CURRENT 29) -set(IMATH_LIBTOOL_REVISION 8) +set(IMATH_LIBTOOL_REVISION 9) set(IMATH_LIBTOOL_AGE 0) set(IMATH_LIB_VERSION "${IMATH_LIBTOOL_CURRENT}.${IMATH_LIBTOOL_REVISION}.${IMATH_LIBTOOL_AGE}") set(IMATH_LIB_SOVERSION ${IMATH_LIBTOOL_CURRENT}) @@ -73,10 +73,9 @@ add_subdirectory(src/python) endif() -option(BUILD_DOCS "Set ON to build readthedocs documentation") -if (BUILD_DOCS AND NOT IMATH_IS_SUBPROJECT) - option(INSTALL_DOCS "Set ON to install html documentation" ON) - add_subdirectory(docs) +option(BUILD_WEBSITE "Set ON to build the readthedocs website source") +if (BUILD_WEBSITE AND NOT IMATH_IS_SUBPROJECT) + add_subdirectory(website) endif() # If you want to use ctest to configure, build and diff -Nru ilmbase-3.1.9-imath/CODE_OF_CONDUCT.md ilmbase-3.1.10/CODE_OF_CONDUCT.md --- ilmbase-3.1.9-imath/CODE_OF_CONDUCT.md 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/CODE_OF_CONDUCT.md 2024-01-24 22:14:50.000000000 +0000 @@ -1,3 +1,6 @@ + + + # Code of Conduct Imath is a sub-project of the OpenEXR project, which abides by Linux diff -Nru ilmbase-3.1.9-imath/SECURITY.md ilmbase-3.1.10/SECURITY.md --- ilmbase-3.1.9-imath/SECURITY.md 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/SECURITY.md 2024-01-24 22:14:50.000000000 +0000 @@ -6,7 +6,7 @@ ## Reporting a Vulnerability If you think you've found a potential vulnerability in Imath, please -report it by emailing security@openexr.org. Only OpenEXR Technical +report it by emailing security@openexr.com. Only OpenEXR Technical Steering Committee members and Academy Software Foundation project management have access to these messages. Include detailed steps to reproduce the issue, and any other information that could aid an diff -Nru ilmbase-3.1.9-imath/config/CMakeLists.txt ilmbase-3.1.10/config/CMakeLists.txt --- ilmbase-3.1.9-imath/config/CMakeLists.txt 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/config/CMakeLists.txt 2024-01-24 22:14:50.000000000 +0000 @@ -58,8 +58,9 @@ ) endfunction() imath_pkg_config_help(Imath.pc.in) + message(STATUS "Imath pkg-config generation enabled") else() - message(STATUS "pkg-config generation disabled") + message(STATUS "Imath pkg-config generation disabled") endif() # @@ -69,12 +70,12 @@ include(CMakePackageConfigHelpers) -configure_package_config_file(ImathConfig.cmake.in +configure_package_config_file(${CMAKE_CURRENT_SOURCE_DIR}/ImathConfig.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}Config.cmake INSTALL_DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME} ) -write_basic_package_version_file("${PROJECT_NAME}ConfigVersion.cmake" +write_basic_package_version_file("${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}ConfigVersion.cmake" VERSION ${IMATH_VERSION} COMPATIBILITY SameMajorVersion ) @@ -90,3 +91,8 @@ NAMESPACE ${PROJECT_NAME}:: EXPORT_LINK_INTERFACE_LIBRARIES ) + +export(EXPORT ${PROJECT_NAME} + FILE "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}Targets.cmake" + NAMESPACE ${PROJECT_NAME}:: +) diff -Nru ilmbase-3.1.9-imath/config/ImathSetup.cmake ilmbase-3.1.10/config/ImathSetup.cmake --- ilmbase-3.1.9-imath/config/ImathSetup.cmake 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/config/ImathSetup.cmake 2024-01-24 22:14:50.000000000 +0000 @@ -38,12 +38,11 @@ # Whether to generate and install a pkg-config file Imath.pc on if(WIN32) - option(IMATH_INSTALL_PKG_CONFIG "Install Imath.pc file" OFF) option(IMATH_INSTALL_SYM_LINK "Create symbolic links for shared objects" OFF) else() - option(IMATH_INSTALL_PKG_CONFIG "Install Imath.pc file" ON) option(IMATH_INSTALL_SYM_LINK "Create symbolic links for shared objects" ON) endif() +option(IMATH_INSTALL_PKG_CONFIG "Install Imath.pc file" ON) # # Build related options diff -Nru ilmbase-3.1.9-imath/debian/changelog ilmbase-3.1.10/debian/changelog --- ilmbase-3.1.9-imath/debian/changelog 2023-10-08 01:38:38.000000000 +0000 +++ ilmbase-3.1.10/debian/changelog 2024-02-01 01:19:51.000000000 +0000 @@ -1,3 +1,15 @@ +ilmbase (3.1.10-0ubuntu1~16.04.sav0) xenial; urgency=medium + + * New upstream bugfix release + * debian/rules: Change BUILD_DOCS -> BUILD_WEBSITE per upstream rename + * debian/patches/: Rebase *sphinx*.patch for docs -> website dir name change + - Add restore-docs-website-install.patch to install docs/website as before + - Drop no-cmake-python-module-exports.patch (upstreamed) + * Due FTBFS with GCC 5.5.0 (various errors) build with GCC 7.5.0 instead: + - debian/control: Add g++ (>= 4:7.5.0-1~) BD (ppa:savoury1/gcc-defaults-7) + + -- Rob Savoury Wed, 31 Jan 2024 17:19:51 -0800 + ilmbase (3.1.9-imath-0ubuntu1~16.04.sav5) xenial; urgency=medium * Remembering that dpkg fails to resolve upgrading to a renamed package, diff -Nru ilmbase-3.1.9-imath/debian/control ilmbase-3.1.10/debian/control --- ilmbase-3.1.9-imath/debian/control 2023-10-08 01:38:38.000000000 +0000 +++ ilmbase-3.1.10/debian/control 2024-02-01 00:52:10.000000000 +0000 @@ -7,6 +7,7 @@ debhelper-compat (= 10), dh-python, doxygen , + g++ (>= 4:7.5.0-1~), libboost-python-dev, python3-breathe , python3-dev:any, diff -Nru ilmbase-3.1.9-imath/debian/patches/restore-docs-website-install.patch ilmbase-3.1.10/debian/patches/restore-docs-website-install.patch --- ilmbase-3.1.9-imath/debian/patches/restore-docs-website-install.patch 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/debian/patches/restore-docs-website-install.patch 2024-02-01 01:18:53.000000000 +0000 @@ -0,0 +1,37 @@ +From: Rob Savoury +Date: Wed, 31 Jan 2024 17:17:39 -0800 +Subject: Restore docs/website install + +Imath 3.1.10 renamed docs -> website and also removed the installation of the +built docs. Restore the installation code to still package the docs as before. +--- + CMakeLists.txt | 1 + + website/CMakeLists.txt | 6 ++++++ + 2 files changed, 7 insertions(+) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 823eea0..d5132f0 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -75,6 +75,7 @@ endif() + + option(BUILD_WEBSITE "Set ON to build the readthedocs website source") + if (BUILD_WEBSITE AND NOT IMATH_IS_SUBPROJECT) ++ option(INSTALL_WEBSITE "Set ON to install html documentation" ON) + add_subdirectory(website) + endif() + +diff --git a/website/CMakeLists.txt b/website/CMakeLists.txt +index 8e2c320..31bec80 100644 +--- a/website/CMakeLists.txt ++++ b/website/CMakeLists.txt +@@ -40,3 +40,9 @@ add_custom_command(OUTPUT ${SPHINX_INDEX_FILE} + + add_custom_target(website ALL DEPENDS ${SPHINX_INDEX_FILE} ${DOXYGEN_INDEX_FILE}) + ++# Add an install target to install the docs ++if(INSTALL_WEBSITE) ++ include(GNUInstallDirs) ++ install(DIRECTORY ${SPHINX_BUILD} ++ DESTINATION ${CMAKE_INSTALL_DOCDIR}) ++endif() diff -Nru ilmbase-3.1.9-imath/debian/patches/restore-sphinx-master-toctree.patch ilmbase-3.1.10/debian/patches/restore-sphinx-master-toctree.patch --- ilmbase-3.1.9-imath/debian/patches/restore-sphinx-master-toctree.patch 2022-04-06 22:48:59.000000000 +0000 +++ ilmbase-3.1.10/debian/patches/restore-sphinx-master-toctree.patch 2024-02-01 00:45:09.000000000 +0000 @@ -4,15 +4,17 @@ This reverts part of commit bd6f74c7373410db5ded101c67036c690354142e to fix FTBFS with older Sphinx versions due missing default contents.rst file. + +Last-Update: 2024-01-31 --- - docs/conf.py | 3 +++ + website/conf.py | 3 +++ 1 file changed, 3 insertions(+) -diff --git a/docs/conf.py b/docs/conf.py +diff --git a/website/conf.py b/website/conf.py index 0793094..ac32aec 100644 ---- a/docs/conf.py -+++ b/docs/conf.py -@@ -68,6 +68,9 @@ source_suffix = '.rst' +--- a/website/conf.py ++++ b/website/conf.py +@@ -72,6 +72,9 @@ source_suffix = '.rst' # The encoding of source files. #source_encoding = 'utf-8-sig' diff -Nru ilmbase-3.1.9-imath/debian/patches/revert-sphinx-requirement.patch ilmbase-3.1.10/debian/patches/revert-sphinx-requirement.patch --- ilmbase-3.1.9-imath/debian/patches/revert-sphinx-requirement.patch 2023-03-16 19:35:21.000000000 +0000 +++ ilmbase-3.1.10/debian/patches/revert-sphinx-requirement.patch 2024-02-01 00:44:50.000000000 +0000 @@ -7,7 +7,7 @@ Updated to partially revert commit e52b07d691707814666e0953876ae1dd39207f43 which adds requirement on sphinx-press-theme (unavailable with Sphinx < 2.0). -Last-Update: 2023-03-16 +Last-Update: 2024-01-31 --- From 2780d995ac8eb2855ff95357afbf8be292a08dc7 Mon Sep 17 00:00:00 2001 From: Cary Phillips @@ -22,14 +22,14 @@ Signed-off-by: Cary Phillips --- - docs/conf.py | 9 +-------- - docs/requirements.txt | 2 -- + website/conf.py | 9 +-------- + website/requirements.txt | 2 -- 2 files changed, 1 insertion(+), 10 deletions(-) -diff --git a/docs/conf.py b/docs/conf.py +diff --git a/website/conf.py b/website/conf.py index b8c2166..a4520b3 100644 ---- a/docs/conf.py -+++ b/docs/conf.py +--- a/website/conf.py ++++ b/website/conf.py @@ -140,16 +140,9 @@ pygments_style = 'sphinx' #html_theme = 'agogo' #html_theme = 'default' # good @@ -48,11 +48,14 @@ # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the # documentation. -diff --git a/docs/requirements.txt b/docs/requirements.txt +diff --git a/website/requirements.txt b/website/requirements.txt index d030b3b..cd6467e 100644 ---- a/docs/requirements.txt -+++ b/docs/requirements.txt -@@ -1,3 +1 @@ --sphinx == 4.4.0 +--- a/website/requirements.txt ++++ b/website/requirements.txt +@@ -1,6 +1,4 @@ + # SPDX-License-Identifier: BSD-3-Clause + # Copyright (c) Contributors to the OpenEXR Project. + +-sphinx >= 5.0 breathe -sphinx-press-theme diff -Nru ilmbase-3.1.9-imath/debian/patches/series ilmbase-3.1.10/debian/patches/series --- ilmbase-3.1.9-imath/debian/patches/series 2022-08-06 23:39:27.000000000 +0000 +++ ilmbase-3.1.10/debian/patches/series 2024-02-01 01:19:16.000000000 +0000 @@ -3,6 +3,6 @@ testBox.patch testInterval.patch PyImathTest.patch +restore-docs-website-install.patch revert-sphinx-requirement.patch restore-sphinx-master-toctree.patch -no-cmake-python-module-exports.patch diff -Nru ilmbase-3.1.9-imath/debian/rules ilmbase-3.1.10/debian/rules --- ilmbase-3.1.9-imath/debian/rules 2023-09-29 03:36:08.000000000 +0000 +++ ilmbase-3.1.10/debian/rules 2024-02-01 00:37:54.000000000 +0000 @@ -27,7 +27,7 @@ override_dh_auto_configure-indep: dh_auto_configure -- \ $(CMAKE_COMMON_ARGS) \ - -DBUILD_DOCS=$(BUILDDOC) + -DBUILD_WEBSITE=$(BUILDDOC) override_dh_auto_test: -dh_auto_test diff -Nru ilmbase-3.1.9-imath/docs/CMakeLists.txt ilmbase-3.1.10/docs/CMakeLists.txt --- ilmbase-3.1.9-imath/docs/CMakeLists.txt 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/CMakeLists.txt 1970-01-01 00:00:00.000000000 +0000 @@ -1,48 +0,0 @@ -# SPDX-License-Identifier: BSD-3-Clause -# Copyright Contributors to the OpenEXR Project. - -set(CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH}) - -find_package(Doxygen REQUIRED) -find_package(Sphinx REQUIRED) - -set(DOXYGEN_INPUT_DIR ${PROJECT_SOURCE_DIR}/src/Imath) -set(DOXYGEN_OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR}/doxygen) -set(DOXYGEN_INDEX_FILE ${DOXYGEN_OUTPUT_DIR}/html/index.html) -set(DOXYFILE_IN ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in) -set(DOXYFILE_OUT ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile) - -set(SPHINX_SOURCE ${CMAKE_CURRENT_SOURCE_DIR}) -set(SPHINX_BUILD ${CMAKE_CURRENT_BINARY_DIR}/sphinx) -set(SPHINX_INDEX_FILE ${SPHINX_BUILD}/index.html) - -configure_file(${DOXYFILE_IN} ${DOXYFILE_OUT} @ONLY) - -file(MAKE_DIRECTORY ${DOXYGEN_OUTPUT_DIR}) - -add_custom_command(OUTPUT ${DOXYGEN_INDEX_FILE} - COMMAND ${DOXYGEN_EXECUTABLE} ${DOXYFILE_OUT} - COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/fixmanpages.sh ${DOXYGEN_OUTPUT_DIR} - MAIN_DEPENDENCY ${DOXYFILE_OUT} ${DOXYFILE_IN} - COMMENT "Running doxygen" - VERBATIM) - -add_custom_command(OUTPUT ${SPHINX_INDEX_FILE} - COMMAND - ${SPHINX_EXECUTABLE} -b html - # Tell Breathe where to find the Doxygen output - -Dbreathe_projects.Imath=${DOXYGEN_OUTPUT_DIR}/xml - ${SPHINX_SOURCE} ${SPHINX_BUILD} - WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} - DEPENDS ${DOXYGEN_INDEX_FILE} - MAIN_DEPENDENCY conf.py - COMMENT "Generating documentation with Sphinx") - -add_custom_target(docs ALL DEPENDS ${SPHINX_INDEX_FILE} ${DOXYGEN_INDEX_FILE}) - -# Add an install target to install the docs -if(INSTALL_DOCS) - include(GNUInstallDirs) - install(DIRECTORY ${SPHINX_BUILD} - DESTINATION ${CMAKE_INSTALL_DOCDIR}) -endif() diff -Nru ilmbase-3.1.9-imath/docs/Doxyfile.in ilmbase-3.1.10/docs/Doxyfile.in --- ilmbase-3.1.9-imath/docs/Doxyfile.in 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/Doxyfile.in 1970-01-01 00:00:00.000000000 +0000 @@ -1,33 +0,0 @@ -# SPDX-License-Identifier: BSD-3-Clause -# Copyright Contributors to the OpenEXR Project. - -PROJECT_NAME = "Imath" -GENERATE_LATEX = NO -GENERATE_MAN = NO -GENERATE_RTF = NO -CASE_SENSE_NAMES = NO -INPUT = "@DOXYGEN_INPUT_DIR@" -OUTPUT_DIRECTORY = "@DOXYGEN_OUTPUT_DIR@" -RECURSIVE = YES -QUIET = YES -JAVADOC_AUTOBRIEF = YES -GENERATE_HTML = NO -GENERATE_XML = YES -DISTRIBUTE_GROUP_DOC = YES -MACRO_EXPANSION = YES -ENABLE_PREPROCESSING = YES -WARN_IF_UNDOCUMENTED = NO -PREDEFINED = IMATH_CONSTEXPR14=constexpr \ - IMATH_HOSTDEVICE= \ - IMATH_INTERNAL_NAMESPACE=Imath \ - IMATH_INTERNAL_NAMESPACE_SOURCE_ENTER="namespace Imath {" \ - IMATH_INTERNAL_NAMESPACE_SOURCE_EXIT="}" \ - IMATH_INTERNAL_NAMESPACE_HEADER_ENTER="namespace Imath {" \ - IMATH_INTERNAL_NAMESPACE_HEADER_EXIT="}" \ - IMATH_NOEXCEPT="noexcept" \ - IMATH_EXPORT="" \ - IMATH_EXPORT_ENUM= \ - IMATH_EXPORT_TYPE= \ - IMATH_EXPORT_TEMPLATE_TYPE= \ - imath_half_bits_t=half \ - __cplusplus=1 diff -Nru ilmbase-3.1.9-imath/docs/Makefile ilmbase-3.1.10/docs/Makefile --- ilmbase-3.1.9-imath/docs/Makefile 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/Makefile 1970-01-01 00:00:00.000000000 +0000 @@ -1,177 +0,0 @@ -# Makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -PAPER = -BUILDDIR = _build - -# User-friendly check for sphinx-build -ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1) -$(error The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/) -endif - -# Internal variables. -PAPEROPT_a4 = -D latex_paper_size=a4 -PAPEROPT_letter = -D latex_paper_size=letter -ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . -# the i18n builder cannot share the environment and doctrees with the others -I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . - -.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext - -help: - @echo "Please use \`make ' where is one of" - @echo " html to make standalone HTML files" - @echo " dirhtml to make HTML files named index.html in directories" - @echo " singlehtml to make a single large HTML file" - @echo " pickle to make pickle files" - @echo " json to make JSON files" - @echo " htmlhelp to make HTML files and a HTML help project" - @echo " qthelp to make HTML files and a qthelp project" - @echo " devhelp to make HTML files and a Devhelp project" - @echo " epub to make an epub" - @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" - @echo " latexpdf to make LaTeX files and run them through pdflatex" - @echo " latexpdfja to make LaTeX files and run them through platex/dvipdfmx" - @echo " text to make text files" - @echo " man to make manual pages" - @echo " texinfo to make Texinfo files" - @echo " info to make Texinfo files and run them through makeinfo" - @echo " gettext to make PO message catalogs" - @echo " changes to make an overview of all changed/added/deprecated items" - @echo " xml to make Docutils-native XML files" - @echo " pseudoxml to make pseudoxml-XML files for display purposes" - @echo " linkcheck to check all external links for integrity" - @echo " doctest to run all doctests embedded in the documentation (if enabled)" - -clean: - rm -rf $(BUILDDIR)/* - -html: - $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html - @echo - @echo "Build finished. The HTML pages are in $(BUILDDIR)/html." - -dirhtml: - $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml - @echo - @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml." - -singlehtml: - $(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml - @echo - @echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml." - -pickle: - $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle - @echo - @echo "Build finished; now you can process the pickle files." - -json: - $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json - @echo - @echo "Build finished; now you can process the JSON files." - -htmlhelp: - $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp - @echo - @echo "Build finished; now you can run HTML Help Workshop with the" \ - ".hhp project file in $(BUILDDIR)/htmlhelp." - -qthelp: - $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp - @echo - @echo "Build finished; now you can run "qcollectiongenerator" with the" \ - ".qhcp project file in $(BUILDDIR)/qthelp, like this:" - @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/ReadTheDocs-Breathe.qhcp" - @echo "To view the help file:" - @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/ReadTheDocs-Breathe.qhc" - -devhelp: - $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp - @echo - @echo "Build finished." - @echo "To view the help file:" - @echo "# mkdir -p $$HOME/.local/share/devhelp/ReadTheDocs-Breathe" - @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/ReadTheDocs-Breathe" - @echo "# devhelp" - -epub: - $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub - @echo - @echo "Build finished. The epub file is in $(BUILDDIR)/epub." - -latex: - $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex - @echo - @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex." - @echo "Run \`make' in that directory to run these through (pdf)latex" \ - "(use \`make latexpdf' here to do that automatically)." - -latexpdf: - $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex - @echo "Running LaTeX files through pdflatex..." - $(MAKE) -C $(BUILDDIR)/latex all-pdf - @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." - -latexpdfja: - $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex - @echo "Running LaTeX files through platex and dvipdfmx..." - $(MAKE) -C $(BUILDDIR)/latex all-pdf-ja - @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." - -text: - $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text - @echo - @echo "Build finished. The text files are in $(BUILDDIR)/text." - -man: - $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man - @echo - @echo "Build finished. The manual pages are in $(BUILDDIR)/man." - -texinfo: - $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo - @echo - @echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo." - @echo "Run \`make' in that directory to run these through makeinfo" \ - "(use \`make info' here to do that automatically)." - -info: - $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo - @echo "Running Texinfo files through makeinfo..." - make -C $(BUILDDIR)/texinfo info - @echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo." - -gettext: - $(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale - @echo - @echo "Build finished. The message catalogs are in $(BUILDDIR)/locale." - -changes: - $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes - @echo - @echo "The overview file is in $(BUILDDIR)/changes." - -linkcheck: - $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck - @echo - @echo "Link check complete; look for any errors in the above output " \ - "or in $(BUILDDIR)/linkcheck/output.txt." - -doctest: - $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest - @echo "Testing of doctests in the sources finished, look at the " \ - "results in $(BUILDDIR)/doctest/output.txt." - -xml: - $(SPHINXBUILD) -b xml $(ALLSPHINXOPTS) $(BUILDDIR)/xml - @echo - @echo "Build finished. The XML files are in $(BUILDDIR)/xml." - -pseudoxml: - $(SPHINXBUILD) -b pseudoxml $(ALLSPHINXOPTS) $(BUILDDIR)/pseudoxml - @echo - @echo "Build finished. The pseudo-XML files are in $(BUILDDIR)/pseudoxml." diff -Nru ilmbase-3.1.9-imath/docs/PortingGuide.rst ilmbase-3.1.10/docs/PortingGuide.rst --- ilmbase-3.1.9-imath/docs/PortingGuide.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/PortingGuide.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,607 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -:orphan: - -.. _porting: - -OpenEXR/Imath 2.x to 3.x Porting Guide -###################################### - -This porting guide outlines the several areas where switching from OpenEXR -2.x to OpenEXR 3.x + Imath 3.x will require source code or build changes of -downstream software. - -In each case, we will often explain both how to change if you are expecting -3.x only hereafter, or usually a more complex accommodation if you want to -keep compatibility with both 2.x and 3.x. - -OpenEXR and Imath Are Different Packages -======================================== - -If your use of OpenEXR was only for the sake of using the math classes and -utilities, maybe you were unhappy that you needed to download and build the -full OpenEXR dependency. You are in luck -- now Imath is a separate, very -lightweight open source package. You can use Imath functionality without -needing any of OpenEXR, which as of 3.x only includes the parts you need to -read and write OpenEXR image files. - -The parts of "IlmBase" that were ``Imath`` and ``half`` are now repackaged -as the ``Imath`` library. The ``IlmThread`` and ``Iex`` libraries have been -folded into the OpenEXR package, since they were were not necessary to -the rest of Imath. - -When building OpenEXR 3.x, note that if Imath 3.x library is not found -already installed at build time, it will be automatically downloaded and -built as part of the OpenEXR build. - -Background -========== - -Why is this happening? Here is the relevant history. - -The OpenEXR project has historically consisted of four separate subprojects: - -* ``OpenEXR`` - the Imf image format -* ``IlmBase`` - supporting utilities (Imath, Half, Iex, IlmThread) -* ``PyIlmBase`` - python bindings for the IlmBase libraries -* ``OpenEXR_Viewers`` - code for an example EXR image viewer - -Prior to the 2.4 release in 2019, OpenEXR relied primarily on the Gnu -autotools build system and was released as four separate tarballs -(ilmbase, pyilmbase, openexr, openexr_viewers) that were constructed -via the Gnu tools. This gave direct access to the "IlmBase" libraries -independent of the OpenEXR format library. The project also included -CMake files but CMake support was incomplete. - -With the adoption of OpenEXR by the Academy Software Foundation in -2019, the technical steering committee made several key changes: - -1. Drop support for autotools in favor of CMake. A significant portion - of the OpenEXR user base uses Windows, which the Gnu autotools does - not support. Supporting two build systems is a maintenance burden - that the TSC opted to avoid. We now assume that all modern users of - OpenEXR can reasonably be expected to rely on CMake. - -2. Rely on GitHub's automatic release packaging mechanism. This - packages the entire contents of package in a single - tarball. Separate tarballs are no longer generated by the Gnu - autotools setup. - -3. Deprecate the OpenEXR_Viewers code. It was impossibly out of date - and of little modern value. - -Thus, with the 2.4 release, the "IlmBase" libraries are no longer -distributed in a form that is readily separable from the rest of -OpenEXR. The build and installation process for the overall OpenEXR -project is complicated by the fact it consists of four separate -projects, which added significant complexity to the CMake setup. - -Because Imath is generally useful to the community, the TSC decided to -simplify the configuration by separating Imath into its own independent -project, maintained and released independently of OpenEXR, and -introducing it as a new external dependency of OpenEXR. - -To further simplify matters, the new Imath library includes the half -data type directly, rather than maintaining it in a separate -library. Also, the community at large has a strong desire for simple -vector/matrix utilities that are unencumbered by Iex, the IlmBase -library that provides higher-level exception classes, and even -further, a clear delineation between functionality that (1) relies on -exception handlings and (2) is free from exceptions. As a result, -support for Iex has been removed from Imath, and the Iex library is -now packaged as a component of OpenEXR. - -The Imath python bindings are a part of Imath as a configuration -option, although support is off by default to simplify the build process -for most users. - -New Library Names and Repository Structures -=========================================== - -The new repositories place all source code under the ``src`` top-level -subdirectory. - -Imath: ------- - -.. code-block:: - - src - ├── Imath - ├── ImathTest - └── python - ├── config - ├── PyImath - ├── PyImathNumpy - ├── PyImathTest - ├── PyImathNumpyTest - └── PyImathSpeedTest - - -OpenEXR: --------- - -The ``IlmImf`` library has been renamed ``OpenEXR``. No header files have -changed names, only their locations in the repo have changes. - -.. code-block:: - - src - ├── bin - │ ├── exr2aces - │ ├── exrbuild - │ ├── exrcheck - │ ├── exrenvmap - │ ├── exrheader - │ ├── exrmakepreview - │ ├── exrmaketiled - │ ├── exrmultipart - │ ├── exrmultiview - │ └── exrstdattr - ├── lib - │ ├── Iex - │ ├── IexMath - │ ├── IlmThread - │ ├── OpenEXR - │ └── OpenEXRUtil - ├── examples - └── test - ├── IexTest - ├── OpenEXRTest - ├── OpenEXRUtilTest - └── OpenEXRFuzzTest - - -Finding and Using OpenEXR and Imath CMake Configs -================================================= - -OpenEXR/Imath 3.x Only ----------------------- - -If you are *only* concerned with OpenEXR/Imath 3.x going forward, this is -the recommended way to find the libraries in a downstream project that uses -the CMake build system: - -.. code-block:: - - find_package(Imath CONFIG) - find_package(OpenEXR CONFIG) - -Note that the second line may be omitted if you only need the Imath -portions. - -And then your project can reference the imported targets like this: - -.. code-block:: - - target_link_libraries (my_target - PRIVATE - OpenEXR::OpenEXR - Imath::Imath - Imath::Half - ) - -You only need the parts you use, so for example, if you only need Half and -Imath, you can omit the OpenEXR target. Also note that in our example above, -we have used the ``PRIVATE`` label, but you should specify them as ``PUBLIC`` if -you are exposing those classes in your own package's public interface. - - -Accommodating OpenEXR/Imath 3.x or OpenEXR 2.x ----------------------------------------------- - -On the other hand, to accommodate both 2.x and 3.x, it's admittedly -inconvenient because the packages and the import targets have changed their -names. We have found the following idioms to work: - -Finding either/both packages: - -.. code-block:: - - # First, try to find just the right config files - find_package(Imath CONFIG) - if (NOT TARGET Imath::Imath) - # Couldn't find Imath::Imath, maybe it's older and has IlmBase? - find_package(IlmBase CONFIG) - endif () - find_package(OpenEXR CONFIG) - -To link against them, we use CMake generator expressions so that we can -reference *both* sets of targets, but it will only use the ones -corresponding to the package version that was found. - -.. code-block:: - - target_link_libraries (my_target - PRIVATE - # For OpenEXR/Imath 3.x: - $<$:OpenEXR::OpenEXR> - $<$:Imath::Imath> - $<$:Imath::Half> - # For OpenEXR 2.4/2.5: - $<$:OpenEXR::IlmImf> - $<$:IlmBase::Imath> - $<$:IlmBase::Half> - $<$:IlmBase::IlmThread> - $<$:IlmBase::Iex> - ) - -Again, you can eliminate the references to any of the individual libaries -that you don't actually need for your application. - -Simultaneous Static/Shared Build --------------------------------- - -The OpenEXR 2.x CMake configuration had options to simultaneously -build both shared and statically linked libraries. This has been -deprecated. A CMake configuration setting specifies whether to build -static or shared, but if you want both, you will need to run cmake and -build twice. - -Simultaneous Python 2/3 Build ------------------------------ - -The PyIlmBase 2.x CMake configuration had options to simultaneously -build both python2 and python3 bindings. This has been deprecated. -A CMake configuration setting specifies whether to build for -python 2 or python 3, but if you want both, you will need to run -cmake and build twice. - -Imath Include Files Are in a Different Subdirectory -=================================================== - -Imath 3.0 will copy its headers to some ``include/Imath`` subdirectory -instead of the old ``include/OpenEXR``. - -OpenEXR/Imath 3.x Only ----------------------- - -If you know that you are only using Imath 3.x, then just change any -include directions, like this: - -.. code-block:: - - #include - #include - -to the new locations: - -.. code-block:: - - #include - #include - -Accommodating OpenEXR/Imath 3.x or OpenEXR 2.x ----------------------------------------------- - -If you want your software to be able to build against either OpenEXR 2.x or -3.x (depending on which dependency is available at build time), we recommend -using a more complicated idiom: - -.. code-block:: - - // The version can reliably be found in this header file from OpenEXR, - // for both 2.x and 3.x: - #include - #define COMBINED_OPENEXR_VERSION ((10000*OPENEXR_VERSION_MAJOR) + \ - (100*OPENEXR_VERSION_MINOR) + \ - OPENEXR_VERSION_PATCH) - - // There's just no easy way to have an ``#include`` that works in both - // cases, so we use the version to switch which set of include files we - // use. - #if COMBINED_OPENEXR_VERSION >= 20599 /* 2.5.99: pre-3.0 */ - # include - # include - #else - // OpenEXR 2.x, use the old locations - # include - # include - #endif - -Include Files Include Fewer Other Headers -========================================= - -Extraneous ``#include`` statements have been removed from some header -files, which can lead to compile failures in application code that -previously included certain headers indirectly. - -For example, the Imath header files no longer include ``float.h``, so -application code that references symbols such as ``FLT_MAX`` may need -to add an explicit ``#include `` or equivalent. - -If your application code reports compile errors due to undefined or -incompletely-defined Imath or OpenEXR data types, locate the Imath or -OpenEXR header file that defines the type and include it explicitly. - -Symbols Are Hidden by Default -============================= - -To reduce library size and make linkage behavior similar across -platforms, Imath and OpenEXR now build with directives that make -symbol visibility hidden by default, with specific externally-visible -symbols explicitly marked for export. See the :doc:`SymbolVisibility` -and the appropriate ``*Export.h`` header file for more details. - -Imath Now Uses Standard C++ Exceptions and ``noexcept`` -======================================================= - -In OpenEXR 2.x, the Imath functions that threw exceptions used to throw -various Iex varieties. - -In Imath 3.x, these functions just throw ``std::exception`` varieties that -correspond to the failure (e.g., ``std::invalid_argument``, -``std::domain_error``, etc.). For that reason, all of the Iex exceptions are -now only part of the OpenEXR library (where they are still used in the same -manner they were for OpenEXR 2.x). - -Imath 3.x has very few functions that throw exceptions. Each is clearly -marked as such, and each has a version that does not throw exceptions (so -that it may be used from code where exceptions are avoided). The functions -that do not throw exceptions are now marked ``noexcept``. - -Some Headers and Classes Have Been Removed from Imath 3.x -========================================================= - -* The ``Math`` class (and ``ImathMath.h`` header file) are - deprecated. All of the ``Math`` functionality is subsumed by C++11 - ``std::`` math functions. For example, calls to - ``Imath::Math::abs(x)`` should be replaced with ``std::abs(x)``. - -* The ``Limits`` class (and the ``ImathLimits.h`` and - ``ImathHalfLimits.h`` headers) have been removed entirely. All uses of - ``Limits<>`` should be replaced with the appropriate - ``std::numeric_limits<>`` method call. The Imath-specific versions - predated C++11, and were not only redundant in a C++11 world, but - also potentially confusing because some of their functions behaved - quite differently than the ``std::numeric_limits`` method with the - same name. We are following the precept that if C++11 does something - in a standard way, we should not define our own equivalent function - (and especially not define it in a way that doesn't match the - standard behavior). - -* ``Vec::normalize()`` and ``length()`` methods, for integer ``T`` types, - have been removed. Also the standalone ``project()`` and - ``orthogonal()`` functions are no longer defined for vectors made of - integer elements. These all had behavior that was hard to understand - and probably useless. They still work as expected for vectors of - floating-point types. - -* The ``Int64`` and ``SInt64`` types are deprecated in favor of the - now-standard ``int64_t`` and ``uint64_t``. - -File/Class-specific Changes -=========================== - -``half`` in ``half.h`` ----------------------- - -* The half type is now in the ``Imath`` namespace, but a compile-time - option puts it in the global namespace, except when compiling for - CUDA, in which case the 'half' type refers to the CUDA type: - -.. code-block:: - - #ifndef __CUDACC__ - using half = IMATH_INTERNAL_NAMESPACE::half; - #else - #include - #endif - - If you desire to use Imath::half inside a CUDA kernal, you can refer - to it via the namespace, or define ``CUDA_NO_HALF`` to avoid the CUDA - type altogether. - -* ``HALF_MIN`` has changed value. It is now the smallest **normalized** - positive value, returned by ``std::numeric_limits::min()``. - -* New constructor from a bit pattern: - -.. code-block:: - - enum FromBitsTag - { - FromBits - }; - - constexpr half(FromBitsTag, unsigned short bits) noexcept; - -``Imath::Box`` in ``ImathBox.h`` ------------------------------------ - -* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` - -``Color3``, ``Color4`` in ``ImathColor.h`` ------------------------------------------------- - -* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` - -``Imath::Frustum`` in ``ImathFrustum.h`` -------------------------------------------- - -Akin to the ``Vec`` classes, there are now seperate API calls for -throwing and non-throwing functions: - -These functions previously threw exceptions but now do not throw and -are marked ``noexcept``: - -* ``Frustum::projectionMatrix() noexcept`` - -* ``Frustum::aspect() noexcept`` - -* ``Frustum::set() noexcept`` - -* ``Frustum::projectPointToScreen() noexcept`` - -* ``Frustum::ZToDepth() noexcept`` - -* ``Frustum::DepthToZ() noexcept`` - -* ``Frustum::screenRadius() noexcept`` - -* ``Frustum::localToScreen() noexcept`` - -These functions throw ``std::domain_error`` exceptions when the -associated frustum is degenerate: - -* ``Frustum::projectionMatrixExc()`` - -* ``Frustum::aspectExc()`` - -* ``Frustum::setExc()`` - -* ``Frustum::projectPointToScreenExc()`` - -* ``Frustum::ZToDepthExc()`` - -* ``Frustum::DepthToZExc()`` - -* ``Frustum::screenRadiusExc()`` - -* ``Frustum::localToScreenExc()`` - -``Imath::Interval`` in ``ImathInterval.h`` ---------------------------------------------- - -New methods/functions: - -* ``Interval::operator !=`` - -* ``Interval::makeInfinite()`` - -* ``IntervalisInfinite()`` - -* ``operator<< (std::ostream& s, const Interval&)`` - -``ImathMatrixAlgo.h`` ---------------------- - -* ``checkForZeroScaleInRow()`` and ``extractAndRemoveScalingAndShear()`` - throw ``std::domain_error`` exceptions instead of ``Iex::ZeroScale`` - -``Matrix22``, ``Matrix33``, ``Matrix44`` in ``ImathMatrix.h`` ----------------------------------------------------------------------- - -* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` - -* ``invert(bool singExc = false)`` is replace by: - - - ``invert() noexcept`` - - - ``invert(bool)`` which optionally throws an ``std::invalid_argument`` - exception. - -* ``inverse(bool singExc = false)`` is replace by: - - - ``inverse() noexcept`` - - - ``inverse(bool)`` which optionally throws an ``std::invalid_argument`` - exception. - -* ``gjInvert(bool singExc = false)`` is replace by: - - - ``gjInvert()`` noexcept - - - ``gjInvert(bool)`` which optionally throws an - ``std::invalid_argument`` exception. - -* ``gJinverse(bool singExc = false)`` is replace by: - - - ``gjInverse()`` noexcept - - - ``gjInverse(bool)`` which optionally throws an - ``std::invalid_argument`` exception. - -New functions: - -* ``operator<< (std::ostream& s, const Matrix22&)`` - -* ``operator<< (std::ostream& s, const Matrix33&)`` - -* ``operator<< (std::ostream& s, const Matrix44&)`` - -Other changes: - -* Initialization loops unrolled for efficiency - -* inline added where appropriate - -``ImathRoots.h`` ----------------- - -* When compiling for CUDA, the ``complex`` type comes from ``thrust`` - rather than ``std`` - -``Shear6`` in ``ImathShear.h`` ------------------------------- - -* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` - -``ImathVecAlgo.h`` ------------------- - -The following functions are no longer defined for integer-based -vectors, because such behavior is not clearly defined: - -* ``project (const Vec& s, const Vec& t)`` - -* ``orgthogonal (const Vec& s, const Vec& t)`` - -* ``reflect (const Vec& s, const Vec& t)`` - -``Vec2``, ``Vec3``, ``Vec4`` in ``ImathVec.h`` -------------------------------------------------------- - -* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` - -* The following methods are removed (via ``= delete``) for integer-based - vectors because the behavior is not clearly defined and thus prone - to confusion: - - - ``length()`` - although the length is indeed defined, its proper value - is floating point and can thus not be represented by the 'T' - return type. - - - ``normalize()`` - - - ``normalizeExc()`` - - - ``normalizeNonNull()`` - - - ``normalized()`` - - - ``normalizedExc()`` - - - ``normalizedNonNull()`` - -* Interoperability Constructors: The Vec and Matrix classes now have - constructors that take as an argument any data object of similar - size and layout. - -Imath Python Changes -==================== - -In general, the changes in Imath at the C++ level are reflected in the -python bindings. In particular: - -* The following methods are removed for integer-based - vector and matrix objects and arrays: - - - ``length()`` - - ``normalize()`` - - ``normalizeExc()`` - - ``normalizeNonNull()`` - - ``normalized()`` - - ``normalizedExc()`` - - ``normalizedNonNull()`` - -* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` for: - - - ``Vec2``, ``Vec3``, ``Vec4`` - - ``Color3``, ``Color4`` - - ``Matrix22``, ``Matrix33``, ``Matrix44`` - - ``Box`` - - ``Shear6`` - diff -Nru ilmbase-3.1.9-imath/docs/PortingGuide2-3.md ilmbase-3.1.10/docs/PortingGuide2-3.md --- ilmbase-3.1.9-imath/docs/PortingGuide2-3.md 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/PortingGuide2-3.md 1970-01-01 00:00:00.000000000 +0000 @@ -1,547 +0,0 @@ -# OpenEXR/Imath 2.x to 3.x Porting Guide - -This porting guide outlines the several areas where switching from OpenEXR -2.x to OpenEXR 3.x + Imath 3.x will require source code or build changes of -downstream software. - -In each case, we will often explain both how to change if you are expecting -3.x only hereafter, or usually a more complex accommodation if you want to -keep compatibility with both 2.x and 3.x. - -## OpenEXR and Imath Are Different Packages - -If your use of OpenEXR was only for the sake of using the math classes and -utilities, maybe you were unhappy that you needed to download and build the -full OpenEXR dependency. You are in luck -- now Imath is a separate, very -lightweight open source package. You can use Imath functionality without -needing any of OpenEXR, which as of 3.x only includes the parts you need to -read and write OpenEXR image files. - -The parts of "IlmBase" that were `Imath` and `half` are now repackaged -as the `Imath` library. The `IlmThread` and `Iex` libraries have been -folded into the OpenEXR package, since they were were not necessary to -the rest of Imath. - -When building OpenEXR 3.x, note that if Imath 3.x library is not found -already installed at build time, it will be automatically downloaded and -built as part of the OpenEXR build. - -## Background - -Why is this happening? Here is the relevant history. - -The OpenEXR project has historically consisted of four separate subprojects: - -* OpenEXR - the Imf image format -* IlmBase - supporting utilities (Imath, Half, Iex, IlmThread) -* PyIlmBase - python bindings for the IlmBase libraries -* OpenEXR_Viewers - code for an example EXR image viewer - -Prior to the 2.4 release in 2019, OpenEXR relied primarily on the Gnu -autotools build system and was released as four separate tarballs -(ilmbase, pyilmbase, openexr, openexr_viewers) that were constructed -via the Gnu tools. This gave direct access to the "IlmBase" libraries -independent of the OpenEXR format library. The project also included -CMake files but CMake support was incomplete. - -With the adoption of OpenEXR by the Academy Software Foundation in -2019, the technical steering committee made several key changes: - -1. Drop support for autotools in favor of CMake. A significant portion - of the OpenEXR user base uses Windows, which the Gnu autotools does - not support. Supporting two build systems is a maintenance burden - that the TSC opted to avoid. We now assume that all modern users of - OpenEXR can reasonably be expected to rely on CMake. - -2. Rely on GitHub's automatic release packaging mechanism. This - packages the entire contents of package in a single - tarball. Separate tarballs are no longer generated by the Gnu - autotools setup. - -3. Deprecate the OpenEXR_Viewers code. It was impossibly out of date - and of little modern value. - -Thus, with the 2.4 release, the "IlmBase" libraries are no longer -distributed in a form that is readily separable from the rest of -OpenEXR. The build and installation process for the overall OpenEXR -project is complicated by the fact it consists of four separate -projects, which added signifcant complexity to the CMake setup. - -Because Imath is generally useful to the community, the TSC decided to -simplify the configuration by separating Imath into its own independent -project, maintained and released independently of OpenEXR, and -introducing it as a new external dependency of OpenEXR. - -To further simplify matters, the new Imath library includes the half -data type directly, rather than maintaining it in a separate -library. Also, the community at large has a strong desire for simple -vector/matrix utilities that are unencumbered by Iex, the IlmBase -library that provides higher-level exception classes, and even -further, a clear delineation between functionality that (1) relies on -exception handlings and (2) is free from exceptions. As a result, -support for Iex has been removed from Imath, and the Iex library is -now packaged as a component of OpenEXR. - -The Imath python bindings are a part of Imath as a configuration -option, although support is off by default to simplify the build process -for most users. - -## New Library Names and Repository Structures - -The new repositories place all source code under the `src` top-level -subdirectory. - -### Imath: - - src - ├── Imath - ├── ImathTest - └── python - ├── config - ├── PyImath - ├── PyImathNumpy - ├── PyImathTest - ├── PyImathNumpyTest - └── PyImathSpeedTest - - -### OpenEXR: - -The 'IlmImf' library has been renamed 'OpenEXR'. No header files have -changed names, only their locations in the repo have changes. - - src - ├── bin - │ ├── exr2aces - │ ├── exrbuild - │ ├── exrcheck - │ ├── exrenvmap - │ ├── exrheader - │ ├── exrmakepreview - │ ├── exrmaketiled - │ ├── exrmultipart - │ ├── exrmultiview - │ └── exrstdattr - ├── lib - │ ├── Iex - │ ├── IexMath - │ ├── IlmThread - │ ├── OpenEXR - │ └── OpenEXRUtil - ├── examples - └── test - ├── IexTest - ├── OpenEXRTest - ├── OpenEXRUtilTest - └── OpenEXRFuzzTest - - -## Finding and Using OpenEXR and Imath CMake Configs - -### OpenEXR/Imath 3.x only - -If you are *only* concerned with OpenEXR/Imath 3.x going forward, this is -the recommended way to find the libraries in a downstream project that uses -the CMake build system: - - find_package(Imath CONFIG) - find_package(OpenEXR CONFIG) - -Note that the second line may be omitted if you only need the Imath -portions. - -And then your project can reference the imported targets like this: - - target_link_libraries (my_target - PRIVATE - OpenEXR::OpenEXR - Imath::Imath - Imath::Half - ) - -You only need the parts you use, so for example, if you only need Half and -Imath, you can omit the OpenEXR target. Also note that in our example above, -we have used the `PRIVATE` label, but you should specify them as `PUBLIC` if -you are exposing those classes in your own package's public interface. - - -### Accommodating OpenEXR/Imath 3.x or OpenEXR 2.x - -On the other hand, to accommodate both 2.x and 3.x, it's admittedly -inconvenient because the packages and the import targets have changed their -names. We have found the following idioms to work: - -Finding either/both packages: - - # First, try to find just the right config files - find_package(Imath CONFIG) - if (NOT TARGET Imath::Imath) - # Couldn't find Imath::Imath, maybe it's older and has IlmBase? - find_package(IlmBase CONFIG) - endif () - find_package(OpenEXR CONFIG) - -To link against them, we use CMake generator expressions so that we can -reference *both* sets of targets, but it will only use the ones -corresponding to the package version that was found. - - target_link_libraries (my_target - PRIVATE - # For OpenEXR/Imath 3.x: - $<$:OpenEXR::OpenEXR> - $<$:Imath::Imath> - $<$:Imath::Half> - # For OpenEXR 2.4/2.5: - $<$:OpenEXR::IlmImf> - $<$:IlmBase::Imath> - $<$:IlmBase::Half> - $<$:IlmBase::IlmThread> - $<$:IlmBase::Iex> - ) - -Again, you can eliminate the references to any of the individual libaries -that you don't actually need for your application. - -### Simultaneous Static/Shared Build - -The OpenEXR 2.x CMake configuration had options to simultaneously -build both shared and statically linked libraries. This has been -deprecated. A CMake configuration setting specifies whether to build -static or shared, but if you want both, you will need to run cmake and -build twice. - -### Simultaneous Python 2/3 Build - -The PyIlmBase 2.x CMake configuration had options to simultaneously -build both python2 and python3 bindings. This has been deprecated. -A CMake configuration setting specifies whether to build for -python 2 or python 3, but if you want both, you will need to run -cmake and build twice. - -## Imath Include Files Are in a Different Subdirectory - -Imath 3.0 will copy its headers to some `include/Imath` subdirectory -instead of the old `include/OpenEXR`. - -### OpenEXR/Imath 3.x only - -If you know that you are only using Imath 3.x, then just change any -include directions, like this: - - #include - #include - -to the new locations: - - #include - #include - -### Accommodating OpenEXR/Imath 3.x or OpenEXR 2.x - -If you want your software to be able to build against either OpenEXR 2.x or -3.x (depending on which dependency is available at build time), we recommend -using a more complicated idiom: - - // The version can reliably be found in this header file from OpenEXR, - // for both 2.x and 3.x: - #include - #define COMBINED_OPENEXR_VERSION ((10000*OPENEXR_VERSION_MAJOR) + \ - (100*OPENEXR_VERSION_MINOR) + \ - OPENEXR_VERSION_PATCH) - - // There's just no easy way to have an `#include` that works in both - // cases, so we use the version to switch which set of include files we - // use. - #if COMBINED_OPENEXR_VERSION >= 20599 /* 2.5.99: pre-3.0 */ - # include - # include - #else - // OpenEXR 2.x, use the old locations - # include - # include - #endif - -## Include Files Include Fewer Other Headers - -Extraneous ``#include`` statements have been removed from some header -files, which can lead to compile failures in application code that -previously included certain headers indirectly. - -For example, the Imath header files no longer include ``float.h``, so -application code that references symbols such as ``FLT_MAX`` may need -to add an explicit ``#include `` or equivalent. - -If your application code reports compile errors due to undefined or -incompletely-defined Imath or OpenEXR data types, locate the Imath or -OpenEXR header file that defines the type and include it explicitly. - -## Symbols Are Hidden by Default - -To reduce library size and make linkage behavior similar across -platforms, Imath and OpenEXR now build with directives that make -symbol visibility hidden by default, with specific externally-visible -symbols explicitly marked for export. See the [Symbol -Visibility](https://github.com/AcademySoftwareFoundation/openexr/blob/main/docs/SymbolVisibility.md) -doc and the appropriate ``*Export.h`` header file for more details. - -## Imath Now Uses Standard C++ Exceptions and `noexcept` - -In OpenEXR 2.x, the Imath functions that threw exceptions used to throw -various Iex varieties. - -In Imath 3.x, these functions just throw `std::exception` varieties that -correspond to the failure (e.g., `std::invalid_argument`, -`std::domain_error`, etc.). For that reason, all of the Iex exceptions are -now only part of the OpenEXR library (where they are still used in the same -manner they were for OpenEXR 2.x). - -Imath 3.x has very few functions that throw exceptions. Each is clearly -marked as such, and each has a version that does not throw exceptions (so -that it may be used from code where exceptions are avoided). The functions -that do not throw exceptions are now marked `noexcept`. - -## Some Headers and Classes Have Been Removed from Imath 3.x - -* The `Math` class (and `ImathMath.h` header file) are - deprecated. All of the `Math` functionality is subsumed by C++11 - `std::` math functions. For example, calls to - `Imath::Math::abs(x)` should be replaced with `std::abs(x)`. - -* The `Limits` class (and the `ImathLimits.h` and - `ImathHalfLimits.h` headers) have been removed entirely. All uses of - `Limits<>` should be replaced with the appropriate - `std::numeric_limits<>` method call. The Imath-specific versions - predated C++11, and were not only redundant in a C++11 world, but - also potentially confusing because some of their functions behaved - quite differently than the `std::numeric_limits` method with the - same name. We are following the precept that if C++11 does something - in a standard way, we should not define our own equivalent function - (and especially not define it in a way that doesn't match the - standard behavior). - -* `Vec::normalize()` and `length()` methods, for integer `T` types, - have been removed. Also the standalone `project()` and - `orthogonal()` functions are no longer defined for vectors made of - integer elements. These all had behavior that was hard to understand - and probably useless. They still work as expected for vectors of - floating-point types. - -* The ``Int64`` and ``SInt64`` types are deprecated in favor of the - now-standard ``int64_t`` and ``uint64_t``. - -## File/Class-specific changes: - -### `half` in half.h - -* The half type is now in the `Imath` namespace, but a compile-time - option puts it in the global namespace, except when compiling for - CUDA, in which case the 'half' type refers to the CUDA type: - - #ifndef __CUDACC__ - using half = IMATH_INTERNAL_NAMESPACE::half; - #else - #include - #endif - - If you desire to use Imath::half inside a CUDA kernal, you can refer - to it via the namespace, or define `CUDA_NO_HALF` to avoid the CUDA - type altogether. - -* `HALF_MIN` has changed value. It is now the smallest **normalized** - positive value, returned by `std::numeric_limits::min()`. - -* New constructor from a bit pattern: - - enum FromBitsTag - { - FromBits - }; - - constexpr half(FromBitsTag, unsigned short bits) noexcept; - -### `Imath::Box` in ImathBox.h - -* `baseTypeMin()` is replaced with `baseTypeLowest()` - -### `Color3`, `Color4` in ImathColor.h - -* `baseTypeMin()` is replaced with `baseTypeLowest()` - -### `Imath::Frustum` in ImathFrustum.h - -Akin to the `Vec` classes, there are now seperate API calls for -throwing and non-throwing functions: - -These functions previously threw exceptions but now do not throw and -are marked `noexcept`: - -* `Frustum::projectionMatrix() noexcept` - -* `Frustum::aspect() noexcept` - -* `Frustum::set() noexcept` - -* `Frustum::projectPointToScreen() noexcept` - -* `Frustum::ZToDepth() noexcept` - -* `Frustum::DepthToZ() noexcept` - -* `Frustum::screenRadius() noexcept` - -* `Frustum::localToScreen() noexcept` - -These functions throw `std::domain_error` exceptions when the -associated frustum is degenerate: - -* `Frustum::projectionMatrixExc()` - -* `Frustum::aspectExc()` - -* `Frustum::setExc()` - -* `Frustum::projectPointToScreenExc()` - -* `Frustum::ZToDepthExc()` - -* `Frustum::DepthToZExc()` - -* `Frustum::screenRadiusExc()` - -* `Frustum::localToScreenExc()` - -### `Imath::Interval` in ImathInterval.h - -New methods/functions: - -* `Interval::operator !=` - -* `Interval::makeInfinite()` - -* `IntervalisInfinite()` - -* `operator<< (std::ostream& s, const Interval&)` - -### ImathMatrixAlgo.h - -* `checkForZeroScaleInRow()` and `extractAndRemoveScalingAndShear()` - throw `std::domain_error` exceptions instead of `Iex::ZeroScale` - -### `Matrix22`, `Matrix33`, `Matrix44` in ImathMatrix.h - -* `baseTypeMin()` is replaced with `baseTypeLowest()` - -* `invert(bool singExc = false)` is replace by: - - - `invert() noexcept` - - - `invert(bool)` which optionally throws an `std::invalid_argument` - exception. - -* `inverse(bool singExc = false)` is replace by: - - - `inverse() noexcept` - - - `inverse(bool)` which optionally throws an `std::invalid_argument` - exception. - -* `gjInvert(bool singExc = false)` is replace by: - - - `gjInvert()` noexcept - - - `gjInvert(bool)` which optionally throws an - `std::invalid_argument` exception. - -* `gJinverse(bool singExc = false)` is replace by: - - - `gjInverse()` noexcept - - - `gjInverse(bool)` which optionally throws an - `std::invalid_argument` exception. - -New functions: - -* `operator<< (std::ostream& s, const Matrix22&)` - -* `operator<< (std::ostream& s, const Matrix33&)` - -* `operator<< (std::ostream& s, const Matrix44&)` - -Other changes: - -* Initialization loops unrolled for efficiency - -* inline added where appropriate - -### ImathRoots.h - -* When compiling for CUDA, the `complex` type comes from `thrust` - rather than `std` - -### `Shear6` in ImathShear.h - -* `baseTypeMin()` is replaced with `baseTypeLowest()` - -### ImathVecAlgo.h - -The following functions are no longer defined for integer-based -vectors, because such behavior is not clearly defined: - -* `project (const Vec& s, const Vec& t)` - -* `orgthogonal (const Vec& s, const Vec& t)` - -* `reflect (const Vec& s, const Vec& t)` - -### `Vec2`, `Vec3`, `Vec4` in ImathVec.h - -* `baseTypeMin()` is replaced with `baseTypeLowest()` - -* The following methods are removed (via `= delete`) for integer-based - vectors because the behavior is not clearly defined and thus prone - to confusion: - - - `length()` - although the length is indeed defined, its proper value - is floating point and can thus not be represented by the 'T' - return type. - - - `normalize()` - - - `normalizeExc()` - - - `normalizeNonNull()` - - - `normalized()` - - - `normalizedExc()` - - - `normalizedNonNull()` - -* Interoperability Constructors: The Vec and Matrix classes now have - constructors that take as an argument any data object of similar - size and layout. - -## Python Changes: - -In general, the changes at the C++ level are reflected in the python -bindings. In particular: - -* The following methods are removed for integer-based - vector and matrix objects and arrays: - - - `length()` - - `normalize()` - - `normalizeExc()` - - `normalizeNonNull()` - - `normalized()` - - `normalizedExc()` - - `normalizedNonNull()` - -* `baseTypeMin()` is replaced with `baseTypeLowest()` for: - - - `Vec2`, `Vec3`, `Vec4` - - `Color3`, `Color4` - - `Matrix22`, `Matrix33`, `Matrix44` - - `Box` - - `Shear6` - diff -Nru ilmbase-3.1.9-imath/docs/SymbolVisibility.rst ilmbase-3.1.10/docs/SymbolVisibility.rst --- ilmbase-3.1.9-imath/docs/SymbolVisibility.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/SymbolVisibility.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,156 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -:orphan: - -.. _Symbol Visibility in Imath/OpenEXR: - -Symbol Visibility in Imath/OpenEXR -################################## - -Managing symbol visibility in a C++ library can reduce library sizes, -and with the extra information, the optimizer may produce faster -code. To take advantage of this, OpenEXR 3.0 is switching to -explicitly manage symbols on all platforms, with a hidden-by-default -behavior on unix-based platforms. Managing symbols has always been -required for Windows DLLs, where one must explicitly tag functions for -import and export as appropriate. - -For C, this is trivial: just tag public functions or global variable -as default visibility and leave everything else defaulting to -hidden. However, in C++, this is not exactly the same story. Functions -and globals are of course the same. And class member functions are -largely the same, and other than the attribute specification -mechanics, follow the same rules between gcc, clang, and -msvc. However, types have richer information than they do in C. So, -unless extra work is done, concepts for RTTI like the typeinfo and the -vtable for virtual classes will be hidden, and not visible. These are -referred to as "vague" linkage objects in some discussions. - -It is with the "vague" linkage objects where different properties -arise. For example, if you have a template, it is happily instantiated -in multiple compile units. If the typeinfo is hidden for one library, -then this may cause things like dynamic_cast to fail because then the -same typeinfo is not used, and even though one might think that -``ImfAttribute`` are the same in two places, because they -are instantiated in separate places, they may be considered different -types. To compound the issue, there are different rules for this in -different implementations. For example, a default gcc under linux -allows one to link against otherwise private "vague" linkage objects -such that the typeinfo ends up as the same entity. clang, for MacOS -anyway, follows a stricter approach and keeps those types separate, -perhaps due to the two level namespace they maintain for symbols. - -Unfortunately, this is not clearly discussed as an overview of the -differences between platforms, hence this document to add -clarity. Each compiler / platform describes their own behavior, but -not how that behaves relative to others. `libc++ -`_ from -the llvm project is the closest to providing comparative information, -where by looking at how they define their macros and the comments -surrounding, one can infer the behavior among at least windows DLL -mode, then gcc vs. clang for unixen. Other compilers, for example, -Intel's icc, tend to adopt the behavior of the predominant compiler -for that platform (i.e. msvc under windows, gcc under linux), and so -can generally adopt that behavior and are ignored here. If this is not -true, the ifdef rules in the various library ``Export.h`` headers -within OpenEXR may need to be adjusted, and this table updated. - -As a summary, below is a table of the attribute or declspec that needs -to be used for a particular C++ entity to be properly exported. This -does not address weak symbols, ABI versioning, and only focusing on -visibility. Under Windows DLL rules, if one exports the entire class, -it also exports the types for the member types as well, which is not -desired, so these are marked as N/A even though the compiler does -allow that to happen. - -.. list-table:: - :header-rows: 1 - :align: left - - * - C++ vs Compiler - - MSVC - - mingw - - gcc - - clang - * - function - - ``dllexport/dllimport`` - - ``dllexport/dllimport`` - - ``visibility("default")`` - - ``visibility("default")`` - * - hide a function - - N/A - - N/A - - ``visibility("hidden")`` - - ``visibility("hidden")`` - * - ``class(typeinfo)`` - - N/A - - N/A - - ``visibility("default")`` - - ``visibility("default")`` - * - template class - - N/A - - N/A - - ``visibility("default")`` - - ``type_visibility("default")`` - * - template data - - N/A - - N/A - - ``visibility("default")`` - - ``visibility("default")`` - * - class template instantiation - - ``dllexport/dllimport`` - - N/A - - N/A - - ``visibility("default")`` - * - enum - - N/A - - N/A - - auto unhides (N/A) - - ``type_visibility("default")`` - * - extern template - - N/A - - ``dllexport/dllimport`` - - ``visibility("default")`` - - ``visibility("default")`` - -With this matrix in mind, we can see the maximal set of macros we need to -provide throughout the code. *NB*: This does not mean that we need to -declare all of these, just that they might be needed. - -.. list-table:: - :header-rows: 1 - :align: left - - * - macro name - - purpose - * - ``IMATH_EXPORT`` - - one of export or import for windows, visibility for others - * - ``IMATH_EXPORT_TYPE`` - - for declaring a class / struct as public (for typeinfo / vtable) - * - ``IMATH_HIDDEN`` - - used to explicitly hide, especially members of types - * - ``IMATH_EXPORT_TEMPLATE_TYPE`` - - stating the template type should be visible - * - ``IMATH_EXPORT_EXTERN_TEMPLATE`` - - exporting template types (i.e. extern side of extern template) - * - ``IMATH_EXPORT_TEMPLATE_INSTANCE`` - - exporting specific template instantiations (in cpp code) - * - ``IMATH_EXPORT_TEMPLATE_DATA`` - - exporting templated data blocks - * - ``IMATH_EXPORT_ENUM`` - - exporting enum types - -The preference might be to call ``IMATH_EXPORT`` something like -``IMATH_FUNC``, and rename things such as ``IMATH_EXPORT_TYPE`` to -``IMATH_TYPE`` for simplicity. However, historically, OpenEXR has used -the ``_EXPORT`` tag, and so that is preserved for consistency. - ---------- - -* LLVM libc++ visibility macros: https://libcxx.llvm.org/docs/DesignDocs/VisibilityMacros.html - -* GCC visibility wiki: https://gcc.gnu.org/wiki/Visibility - -* Apple library design docs: https://developer.apple.com/library/archive/documentation/DeveloperTools/Conceptual/DynamicLibraries/100-Articles/DynamicLibraryDesignGuidelines.html diff -Nru ilmbase-3.1.9-imath/docs/about.rst ilmbase-3.1.10/docs/about.rst --- ilmbase-3.1.9-imath/docs/about.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/about.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,71 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _About Imath: - -About Imath -=========== - -.. toctree:: - :caption: About - -Imath is maintained by the OpenEXR project, a part of the `Academy -Software Foundation `_. The library were -originally developed at Industrial Light & Magic and first released as -open source in 2003. - -Read the origin story of OpenEXR and Imath, and the ``half`` 16-bit -float type, in particular, on the `ASWF Blog -`_. - -Imath is Version 3 because it was previously distributed as a -component of OpenEXR v1 and v2. - -OpenEXR and Imath is included in the `VFX Reference Platform `_. - -New Features in 3.1 -------------------- - -The 3.1 release of Imath introduces optimized half-to-float and -float-to-half conversion using the F16C SSE instruction set extension, -if available. These single-instruction conversions offer a 5-10x -speedup for float-to-half and 2x speedup for half-to-float over -Imath/half's traditional table-based conversion (timings depend on the -data). - -In the absence of the F16C instruction set, the lookup-table-based -conversion from half to float is still the default, but Imath 3.1 also -introduces an optimized bit-shift conversion algorithm as a -compile-time option that does not require lookup tables, for -architectures where memory is limited. The float-to-half conversion -also no longer requires an exponent lookup table, further reducing -memory requirements. - -These new conversions generate the same values as the traditional -methods, which ensures backwards compatibility. See :doc:`install` -for more installation and configuration options. - -Also, ``half.h`` can now be included in pure C code for a definition -of the type and for conversions between half and float. - -OpenEXR/Imath 2.x to 3.x Porting Guide --------------------------------------- - -See the :doc:`PortingGuide` for help in restructing old code to work -with recent releases of OpenEXR and Imath. - -Credits -------- - -The ILM Imath library and the ``half`` data type were originally -designed and implemented at Industrial Light & Magic by Florian Kainz, -Wojciech Jarosz, Rod Bogart, and others. Drew Hess packaged and -adapted ILM's internal source code for public release. - -For a complete list of contributors see `CONTRIBUTORS.md -`_. - - - - diff -Nru ilmbase-3.1.9-imath/docs/classes/Box.rst ilmbase-3.1.10/docs/classes/Box.rst --- ilmbase-3.1.9-imath/docs/classes/Box.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Box.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,59 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Box -### - -.. code-block:: - - #include - -The ``Box`` class template represents 2D and 3D axis-aligned bounding -boxes, with predefined typedefs for boxes of type ``short``, ``int``, -``int64_t``, ``float``, and ``double``. - -The box is defined by minimum and maximum values along each axis, -represented by ``Vec2`` for the ``Box2`` types and by ``Vec3`` -for ``Box3`` types. - -There are also various utility functions that operate on bounding -boxes defined in ``ImathBoxAlgo.h`` and described in :ref:`Box -Functions `. - -Example: - -.. literalinclude:: ../examples/Box.cpp - :language: c++ - -.. doxygentypedef:: Box2s - -.. doxygentypedef:: Box2i - -.. doxygentypedef:: Box2i64 - -.. doxygentypedef:: Box2f - -.. doxygentypedef:: Box2d - -.. doxygentypedef:: Box3s - -.. doxygentypedef:: Box3i - -.. doxygentypedef:: Box3i64 - -.. doxygentypedef:: Box3f - -.. doxygentypedef:: Box3d - -.. doxygenclass:: Imath::Box - :undoc-members: - :members: - -.. doxygenclass:: Imath::Box< Vec2< T > > - :undoc-members: - :members: - -.. doxygenclass:: Imath::Box< Vec3< T > > - :undoc-members: - :members: diff -Nru ilmbase-3.1.9-imath/docs/classes/Color3.rst ilmbase-3.1.10/docs/classes/Color3.rst --- ilmbase-3.1.9-imath/docs/classes/Color3.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Color3.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,42 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Color3 -###### - -.. code-block:: - - #include - -The ``Color3`` class template represents a 3-component color, with -pre-defined typedefs of ``unsigned char``, ``half``, and ``float``. - -The ``Color3`` class inherits from ``Vec3`` and thus has -fields named ``x``, ``y``, and ``z``. The class itself implies no -specific interpretation of the values. - -There are also various utility functions that operate on colors -defined in ``ImathColorAlgo.h`` and described in :ref:`Color Functions -`. - -Example: - -.. literalinclude:: ../examples/Color3.cpp - :language: c++ - -.. doxygentypedef:: Color3c - -.. doxygentypedef:: Color3h - -.. doxygentypedef:: Color3f - -.. doxygentypedef:: C3c - -.. doxygentypedef:: C3h - -.. doxygentypedef:: C3f - -.. doxygenclass:: Imath::Color3 - :undoc-members: - :members: diff -Nru ilmbase-3.1.9-imath/docs/classes/Color4.rst ilmbase-3.1.10/docs/classes/Color4.rst --- ilmbase-3.1.9-imath/docs/classes/Color4.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Color4.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,46 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Color4 -###### - -.. code-block:: - - #include - -The ``Color4`` class template represents a 4-component color (red, -green, blue, and alpha), with pre-defined typedefs of ``unsigned -char``, ``half``, and ``float``. - -The ``Color4`` class is *not* derived from ``Vec4``. Its fields are -named ``r``, ``g``, ``b``, and ``a``. The class itself implies no -specific interpretation of the values. - -There are also various utility functions that operate on colors -defined in ``ImathColorAlgo.h`` and described in :ref:`Color Functions -`. - -Example: - -.. literalinclude:: ../examples/Color4.cpp - :language: c++ - -.. doxygentypedef:: Color4c - -.. doxygentypedef:: Color4h - -.. doxygentypedef:: Color4f - -.. doxygentypedef:: C4c - -.. doxygentypedef:: C4h - -.. doxygentypedef:: C4f - -.. doxygenclass:: Imath::Color4 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Color4& v) - diff -Nru ilmbase-3.1.9-imath/docs/classes/Euler.rst ilmbase-3.1.10/docs/classes/Euler.rst --- ilmbase-3.1.9-imath/docs/classes/Euler.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Euler.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,35 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Euler -##### - -.. code-block:: - - #include - -The ``Euler`` class template represents an euler angle rotation/orientation, -with predefined typedefs of type ``float`` and ``double``. - -The ``Euler`` class is derived from ``Imath::Vec3`` and thus has -fields named ``x``, ``y``, and ``z``, which correspond to the first, -second, and third rotation angles in a specified order, which, -depending on the order, may not correspond directly to x, y, or z -rotations. - -Example: - -.. literalinclude:: ../examples/Euler.cpp - :language: c++ - -.. doxygentypedef:: Eulerf - -.. doxygentypedef:: Eulerd - -.. doxygenclass:: Imath::Euler - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& o, const Euler& euler) - diff -Nru ilmbase-3.1.9-imath/docs/classes/Frustum.rst ilmbase-3.1.10/docs/classes/Frustum.rst --- ilmbase-3.1.9-imath/docs/classes/Frustum.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Frustum.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,26 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Frustum -####### - -.. code-block:: - - #include - -The ``Frustum`` class template represents a 3D viewing frustum, with -predefined typedefs of type ``float`` and ``double``. - -Example: - -.. literalinclude:: ../examples/Frustum.cpp - :language: c++ - -.. doxygentypedef:: Frustumf - -.. doxygentypedef:: Frustumd - -.. doxygenclass:: Imath::Frustum - :undoc-members: - :members: diff -Nru ilmbase-3.1.9-imath/docs/classes/Interval.rst ilmbase-3.1.10/docs/classes/Interval.rst --- ilmbase-3.1.9-imath/docs/classes/Interval.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Interval.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,36 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Interval -######## - -.. code-block:: - - #include - -The ``Interval`` class template represents a scalar interval, with -predefined typedefs for ``short``, ``int``, ``float``, and ``double``. - -An ``Interval`` is essentially a ``Box`` that allows ``T`` to be a -scalar. - -Example: - -.. literalinclude:: ../examples/Interval.cpp - :language: c++ - -.. doxygentypedef:: Intervals - -.. doxygentypedef:: Intervali - -.. doxygentypedef:: Intervalf - -.. doxygentypedef:: Intervald - -.. doxygenclass:: Imath::Interval - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Interval& v) - diff -Nru ilmbase-3.1.9-imath/docs/classes/Line3.rst ilmbase-3.1.10/docs/classes/Line3.rst --- ilmbase-3.1.9-imath/docs/classes/Line3.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Line3.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,33 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Line3 -##### - -.. code-block:: - - #include - -The ``Line3`` class template represents a line in 3D space, with -predefined typedefs for lines of type ``float`` and ``double``. - -There are also various utility functions that operate on ``Line3`` -objects defined in ``ImathLineAlgo.h`` and described in :ref:`Line -Functions `. - -Example: - -.. literalinclude:: ../examples/Line3.cpp - :language: c++ - -.. doxygentypedef:: Line3f - -.. doxygentypedef:: Line3d - -.. doxygenclass:: Imath::Line3 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Line3& line) - diff -Nru ilmbase-3.1.9-imath/docs/classes/Matrix22.rst ilmbase-3.1.10/docs/classes/Matrix22.rst --- ilmbase-3.1.9-imath/docs/classes/Matrix22.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Matrix22.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,42 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Matrix22 -######## - -.. code-block:: - - #include - -The ``Matrix22`` class template represents a 2x2 matrix, with -predefined typedefs for ``float`` and ``double``. - -There are also various utility functions that operate on matrices -defined in ``ImathMatrixAlgo.h`` and described in :ref:`Matrix -Functions `. - -Individual components of a matrix ``M`` may be referenced as either -``M[j][i]`` or ``M.x[j][i]``. While the latter is a little awkward, it has an -advantage when used in loops that may be auto-vectorized or explicitly -vectorized by ``#pragma omp simd`` or other such hints, because the function -call and pointer casting of ``operator[]`` can confuse the compiler just -enough to prevent vectorization of the loop, whereas directly addressing the -real underlying array (``M.x[j][i]``) does not. - -Example: - -.. literalinclude:: ../examples/Matrix22.cpp - :language: c++ - -.. doxygentypedef:: M22f - -.. doxygentypedef:: M22d - -.. doxygenclass:: Imath::Matrix22 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Matrix22& m) - - diff -Nru ilmbase-3.1.9-imath/docs/classes/Matrix33.rst ilmbase-3.1.10/docs/classes/Matrix33.rst --- ilmbase-3.1.9-imath/docs/classes/Matrix33.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Matrix33.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,41 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Matrix33 -######## - -.. code-block:: - - #include - -The ``Matrix33`` class template represents a 3x3 matrix, with -predefined typedefs for ``float`` and ``double``. - -There are also various utility functions that operate on matrices -defined in ``ImathMatrixAlgo.h`` and described in :ref:`Matrix -Functions `. - -Individual components of a matrix ``M`` may be referenced as either -``M[j][i]`` or ``M.x[j][i]``. While the latter is a little awkward, it has an -advantage when used in loops that may be auto-vectorized or explicitly -vectorized by ``#pragma omp simd`` or other such hints, because the function -call and pointer casting of ``operator[]`` can confuse the compiler just -enough to prevent vectorization of the loop, whereas directly addressing the -real underlying array (``M.x[j][i]``) does not. - -Example: - -.. literalinclude:: ../examples/Matrix33.cpp - :language: c++ - -.. doxygentypedef:: M33f - -.. doxygentypedef:: M33d - -.. doxygenclass:: Imath::Matrix33 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Matrix33& m) - diff -Nru ilmbase-3.1.9-imath/docs/classes/Matrix44.rst ilmbase-3.1.10/docs/classes/Matrix44.rst --- ilmbase-3.1.9-imath/docs/classes/Matrix44.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Matrix44.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,41 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Matrix44 -######## - -.. code-block:: - - #include - -The ``Matrix44`` class template represents a 4x4 matrix, with -predefined typedefs for ``float`` and ``double``. - -There are also various utility functions that operate on matrices -defined in ``ImathMatrixAlgo.h`` and described in :ref:`Matrix -Functions `. - -Individual components of a matrix ``M`` may be referenced as either -``M[j][i]`` or ``M.x[j][i]``. While the latter is a little awkward, it has an -advantage when used in loops that may be auto-vectorized or explicitly -vectorized by ``#pragma omp simd`` or other such hints, because the function -call and pointer casting of ``operator[]`` can confuse the compiler just -enough to prevent vectorization of the loop, whereas directly addressing the -real underlying array (``M.x[j][i]``) does not. - -Example: - -.. literalinclude:: ../examples/Matrix44.cpp - :language: c++ - -.. doxygentypedef:: M44f - -.. doxygentypedef:: M44d - -.. doxygenclass:: Imath::Matrix44 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Matrix44& m) - diff -Nru ilmbase-3.1.9-imath/docs/classes/Plane3.rst ilmbase-3.1.10/docs/classes/Plane3.rst --- ilmbase-3.1.9-imath/docs/classes/Plane3.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Plane3.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,29 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Plane3 -###### - -.. code-block:: - - #include - -The ``Plane3`` class template represents a plane in 3D space, with -predefined typedefs for planes of type ``float`` and ``double``. - -Example: - -.. literalinclude:: ../examples/Plane3.cpp - :language: c++ - -.. doxygentypedef:: Plane3f - -.. doxygentypedef:: Plane3d - -.. doxygenclass:: Imath::Plane3 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Plane3& plane) - diff -Nru ilmbase-3.1.9-imath/docs/classes/Quat.rst ilmbase-3.1.10/docs/classes/Quat.rst --- ilmbase-3.1.9-imath/docs/classes/Quat.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Quat.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,28 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Quat -#### - -.. code-block:: - - #include - -The ``Quat`` class template represents a quaterion -rotation/orientation, with predefined typedefs for ``float`` and -``double``. - -Example: - -.. literalinclude:: ../examples/Quat.cpp - :language: c++ - -.. doxygentypedef:: Quatf - -.. doxygenclass:: Imath::Quat - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Quat& q) - diff -Nru ilmbase-3.1.9-imath/docs/classes/Rand32.rst ilmbase-3.1.10/docs/classes/Rand32.rst --- ilmbase-3.1.9-imath/docs/classes/Rand32.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Rand32.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,18 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Rand32 -###### - -.. code-block:: - - #include - -The ``Rand32`` class is a fast pseudo-random number generator that -generates a uniformly distributed sequence with a period length of -:math:`2^32`. - -.. doxygenclass:: Imath::Rand32 - :undoc-members: - :members: diff -Nru ilmbase-3.1.9-imath/docs/classes/Rand48.rst ilmbase-3.1.10/docs/classes/Rand48.rst --- ilmbase-3.1.9-imath/docs/classes/Rand48.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Rand48.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,18 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Rand48 -###### - -.. code-block:: - - #include - -The ``Rand48`` class is a fast pseudo-random number generator based on -the C Standard Library functions erand48(), nrand48() & company. It -generates a uniformly distributed sequence. - -.. doxygenclass:: Imath::Rand48 - :undoc-members: - :members: diff -Nru ilmbase-3.1.9-imath/docs/classes/Shear6.rst ilmbase-3.1.10/docs/classes/Shear6.rst --- ilmbase-3.1.9-imath/docs/classes/Shear6.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Shear6.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,27 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Shear6 -###### - -.. code-block:: - - #include - -The ``Shear6`` class template represent a 3D shear transformation, -with predefined typedefs for ``float`` and ``double``. - -Example: - -.. literalinclude:: ../examples/Shear6.cpp - :language: c++ - -.. doxygentypedef:: Shear6f - -.. doxygenclass:: Imath::Shear6 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Shear6& h) - diff -Nru ilmbase-3.1.9-imath/docs/classes/Sphere3.rst ilmbase-3.1.10/docs/classes/Sphere3.rst --- ilmbase-3.1.9-imath/docs/classes/Sphere3.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Sphere3.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,24 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Sphere3 -####### - -.. code-block:: - - #include - -The ``Sphere3`` class template represents a sphere in 3D space, with -predefined typedefs for lines of type ``float`` and ``double``. - -Example: - -.. literalinclude:: ../examples/Sphere3.cpp - :language: c++ - -.. doxygentypedef:: Sphere3f - -.. doxygenclass:: Imath::Sphere3 - :undoc-members: - :members: diff -Nru ilmbase-3.1.9-imath/docs/classes/Vec2.rst ilmbase-3.1.10/docs/classes/Vec2.rst --- ilmbase-3.1.9-imath/docs/classes/Vec2.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Vec2.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,58 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Vec2 -#### - -.. code-block:: - - #include - -The ``Vec2`` class template represents a 2D vector, with predefined -typedefs for vectors of type ``short``, ``int``, ``int64_t``, ``float``, and -``double``. - -Note that the integer specializations of ``Vec2`` lack the -``length()`` and ``normalize()`` methods that are present in the -``float`` and ``double`` versions, because the results don't fit into -integer quantities. - -There are also various utility functions that operate on vectors -defined in ``ImathVecAlgo.h`` and described in :ref:`Vector Functions -`. - -Individual components of a vector ``V`` may be referenced as either ``V[i]`` -or ``V.x``, ``V.y``. Obviously, the ``[]`` notation is more -suited to looping over components, or in cases where a variable determines -which coordinate is needed. However, when the coordinate is known, it can be -more efficient to directly address the components, such as ``V.y`` rather than -``V[1]``. While both appear to do the same thing (and indeed do generate the -same machine operations for ordinary scalar code), when used inside loops that -you hope to parallelize (either through compiler auto-vectorization or -explicit hints such as ``#pragma omp simd``), the function call and -pointer casting of ``operator[]`` can confuse the compiler just enough to -prevent vectorization of the loop. - -Example: - -.. literalinclude:: ../examples/Vec2.cpp - :language: c++ - -.. doxygentypedef:: V2s - -.. doxygentypedef:: V2i - -.. doxygentypedef:: V2i64 - -.. doxygentypedef:: V2f - -.. doxygentypedef:: V2d - -.. doxygenclass:: Imath::Vec2 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Vec2& v) - - diff -Nru ilmbase-3.1.9-imath/docs/classes/Vec3.rst ilmbase-3.1.10/docs/classes/Vec3.rst --- ilmbase-3.1.9-imath/docs/classes/Vec3.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Vec3.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,58 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Vec3 -#### - -.. code-block:: - - #include - -The ``Vec3`` class template represents a 3D vector, with predefined -typedefs for vectors of type ``short``, ``int``, ``int64_t``, -``float``, and ``double``. - -Note that the integer specializations of ``Vec3`` lack the -``length()`` and ``normalize()`` methods that are present in the -``float`` and ``double`` versions, because the results don't fit into -integer quantities. - -There are also various utility functions that operate on vectors -defined in ``ImathVecAlgo.h`` and described in :ref:`Vector Functions -`. - -Individual components of a vector ``V`` may be referenced as either ``V[i]`` -or ``V.x``, ``V.y``, ``V.z``. Obviously, the ``[]`` notation is more -suited to looping over components, or in cases where a variable determines -which coordinate is needed. However, when the coordinate is known, it can be -more efficient to directly address the components, such as ``V.y`` rather than -``V[1]``. While both appear to do the same thing (and indeed do generate the -same machine operations for ordinary scalar code), when used inside loops that -you hope to parallelize (either through compiler auto-vectorization or -explicit hints such as ``#pragma omp simd``), the function call and -pointer casting of ``operator[]`` can confuse the compiler just enough to -prevent vectorization of the loop. - -Example: - -.. literalinclude:: ../examples/Vec3.cpp - :language: c++ - -.. doxygentypedef:: V3s - -.. doxygentypedef:: V3i - -.. doxygentypedef:: V3i64 - -.. doxygentypedef:: V3f - -.. doxygentypedef:: V3d - -.. doxygenclass:: Imath::Vec3 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Vec3& v) - - diff -Nru ilmbase-3.1.9-imath/docs/classes/Vec4.rst ilmbase-3.1.10/docs/classes/Vec4.rst --- ilmbase-3.1.9-imath/docs/classes/Vec4.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/Vec4.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,57 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Vec4 -#### - -.. code-block:: - - #include - -The ``Vec4`` class template represents a 4D vector, with predefined -typedefs for vectors of type ``short``, ``int``, ``int64_t``, -``float``, and ``double``. - -Note that the integer specializations of ``Vec4`` lack the -``length()`` and ``normalize()`` methods that are present in the -``float`` and ``double`` versions, because the results don't fit into -integer quantities. - -There are also various utility functions that operate on vectors -defined in ``ImathVecAlgo.h`` and described in :ref:`Vector Functions -`. - -Individual components of a vector ``V`` may be referenced as either ``V[i]`` -or ``V.x``, ``V.y``, ``V.z``, ``V.w``. Obviously, the ``[]`` notation is more -suited to looping over components, or in cases where a variable determines -which coordinate is needed. However, when the coordinate is known, it can be -more efficient to directly address the components, such as ``V.y`` rather than -``V[1]``. While both appear to do the same thing (and indeed do generate the -same machine operations for ordinary scalar code), when used inside loops that -you hope to parallelize (either through compiler auto-vectorization or -explicit hints such as ``#pragma omp simd``), the function call and -pointer casting of ``operator[]`` can confuse the compiler just enough to -prevent vectorization of the loop. - -Example: - -.. literalinclude:: ../examples/Vec4.cpp - :language: c++ - -.. doxygentypedef:: V4s - -.. doxygentypedef:: V4i - -.. doxygentypedef:: V4i64 - -.. doxygentypedef:: V4f - -.. doxygentypedef:: V4d - -.. doxygenclass:: Imath::Vec4 - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& s, const Vec4& v) - diff -Nru ilmbase-3.1.9-imath/docs/classes/float.rst ilmbase-3.1.10/docs/classes/float.rst --- ilmbase-3.1.9-imath/docs/classes/float.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/float.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,183 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -Floating Point Representation -############################# - -The half type is a 16-bit floating number, compatible with the -IEEE 754-2008 binary16 type. - -Representation of a 32-bit float --------------------------------- - -We assume that a float, ``f``, is an IEEE 754 single-precision -floating point number, whose bits are arranged as follows: - -.. code-block:: - - 31 (msb) - | - | 30 23 - | | | - | | | 22 0 (lsb) - | | | | | - X XXXXXXXX XXXXXXXXXXXXXXXXXXXXXXX - - s e m - -``s`` is the sign-bit, ``e`` is the exponent and ``m`` is the significand. - -If ``e`` is between 1 and 254, ``f`` is a normalized number: - -.. math:: {\tt f} = (-1)^{\tt s} \times 2^{\tt e-127} \times {\tt 1.m} - -If ``e`` is 0, and ``m`` is not zero, ``f`` is a denormalized number: - -.. math:: {\tt f} = (-1)^{\tt s} \times 2^{\tt e-126} \times {\tt 0.m} - -If ``e`` and ``m`` are both zero, ``f`` is zero: - -.. math:: {\tt f} = 0.0 - -If ``e`` is 255, ``f`` is an "infinity" or "not a number" (NAN), -depending on whether ``m`` is zero or not. - -Examples: - -.. code-block:: - - 0 00000000 00000000000000000000000 = 0.0 - 0 01111110 00000000000000000000000 = 0.5 - 0 01111111 00000000000000000000000 = 1.0 - 0 10000000 00000000000000000000000 = 2.0 - 0 10000000 10000000000000000000000 = 3.0 - 1 10000101 11110000010000000000000 = -124.0625 - 0 11111111 00000000000000000000000 = +infinity - 1 11111111 00000000000000000000000 = -infinity - 0 11111111 10000000000000000000000 = NAN - 1 11111111 11111111111111111111111 = NAN - -Representation of a 16-bit half -------------------------------- - -Here is the bit-layout for a half number, ``h``: - -.. code-block:: - - 15 (msb) - | - | 14 10 - | | | - | | | 9 0 (lsb) - | | | | | - X XXXXX XXXXXXXXXX - - s e m - -``s`` is the sign-bit, ``e`` is the exponent and ``m`` is the significand. - -If ``e`` is between 1 and 30, ``h`` is a normalized number: - -.. math:: {\tt h} = (-1)^{\tt s} \times 2^{\tt e-15} \times {\tt 1.m} - -If ``e`` is 0, and ``m`` is not zero, ``h`` is a denormalized number: - -.. math:: {\tt h} = (-1)^{\tt s} \times 2^{\tt -14} \times {\tt 0.m} - -If ``e`` and ``m`` are both zero, ``h`` is zero: - -.. math:: {\tt h} = 0.0 - -If ``e`` is 31, ``h`` is an "infinity" or "not a number" (NAN), -depending on whether ``m`` is zero or not. - -Examples: - -.. code-block:: - - 0 00000 0000000000 = 0.0 - 0 01110 0000000000 = 0.5 - 0 01111 0000000000 = 1.0 - 0 10000 0000000000 = 2.0 - 0 10000 1000000000 = 3.0 - 1 10101 1111000001 = -124.0625 - 0 11111 0000000000 = +infinity - 1 11111 0000000000 = -infinity - 0 11111 1000000000 = NAN - 1 11111 1111111111 = NAN - -Conversion via Lookup Table ---------------------------- - -Converting from half to float is performed by default using a -lookup table. There are only 65,536 different half numbers; each -of these numbers has been converted and stored in a table pointed -to by the ``imath_half_to_float_table`` pointer. - -Prior to Imath v3.1, conversion from float to half was -accomplished with the help of an exponent look table, but this is -now replaced with explicit bit shifting. - -Conversion via Hardware ------------------------ - -For Imath v3.1, the conversion routines have been extended to use -F16C SSE instructions whenever present and enabled by compiler -flags. - -Conversion via Bit-Shifting ---------------------------- - -If F16C SSE instructions are not available, conversion can be -accomplished by a bit-shifting algorithm. For half-to-float -conversion, this is generally slower than the lookup table, but it -may be preferable when memory limits preclude storing of the -65,536-entry lookup table. - -The lookup table symbol is included in the compilation even if -``IMATH_HALF_USE_LOOKUP_TABLE`` is false, because application code -using the exported ``half.h`` may choose to enable the use of the table. - -An implementation can eliminate the table from compilation by -defining the ``IMATH_HALF_NO_LOOKUP_TABLE`` preprocessor symbol. -Simply add: - -.. code-block:: - - #define IMATH_HALF_NO_LOOKUP_TABLE - -before including ``half.h``, or define the symbol on the compile -command line. - -Furthermore, an implementation wishing to receive ``FE_OVERFLOW`` -and ``FE_UNDERFLOW`` floating point exceptions when converting -float to half by the bit-shift algorithm can define the -preprocessor symbol ``IMATH_HALF_ENABLE_FP_EXCEPTIONS`` prior to -including ``half.h``: - -.. code-block:: - - #define IMATH_HALF_ENABLE_FP_EXCEPTIONS - -Conversion Performance Comparison ---------------------------------- - -Testing on a Core i9, the timings are approximately: - -- half to float: - - * table: 0.71 ns / call - * no table: 1.06 ns / call - * f16c: 0.45 ns / call - -- float-to-half: - - * original: 5.2 ns / call - * no exp table + opt: 1.27 ns / call - * f16c: 0.45 ns / call - -**Note:** the timing above depends on the distribution of the -floats in question. - - diff -Nru ilmbase-3.1.9-imath/docs/classes/half.rst ilmbase-3.1.10/docs/classes/half.rst --- ilmbase-3.1.9-imath/docs/classes/half.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/half.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,36 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _half: - -half -#### - -.. code-block:: - - #include - -``half`` is a 16-bit floating point number. See :doc:`float` for an -explanation of the representation. - -See :doc:`half_c` for C-language functions for conversion -between ``half`` and ``float``. Also, see :doc:`half_conversion` -for information about building Imath with support for the F16C SSE -instruction set. - -Example: - -.. literalinclude:: ../examples/half.cpp - :language: c++ - -.. toctree:: - :caption: half - :maxdepth: 1 - - half_class - half_limits - half_c - half_conversion - float - diff -Nru ilmbase-3.1.9-imath/docs/classes/half_c.rst ilmbase-3.1.10/docs/classes/half_c.rst --- ilmbase-3.1.9-imath/docs/classes/half_c.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/half_c.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,21 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -C-language half-float Conversion -################################ - -The ``half.h`` header can be included in pure C code: - -.. literalinclude:: ../examples/half.c - :language: c - -The only C-language operations supported for the ``half`` type are -conversion to and from ``float``. No arithmetic operations are -currently implemented in the C interface. - -.. doxygenfunction:: imath_half_to_float - -.. doxygenfunction:: imath_float_to_half - - diff -Nru ilmbase-3.1.9-imath/docs/classes/half_class.rst ilmbase-3.1.10/docs/classes/half_class.rst --- ilmbase-3.1.9-imath/docs/classes/half_class.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/half_class.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,16 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -The half Class -############## - -.. doxygenclass:: Imath::half - :undoc-members: - :members: - -.. doxygenfunction:: operator<<(std::ostream& os, Imath::half h) - -.. doxygenfunction:: operator>>(std::istream&, Imath::half&) - - diff -Nru ilmbase-3.1.9-imath/docs/classes/half_conversion.rst ilmbase-3.1.10/docs/classes/half_conversion.rst --- ilmbase-3.1.9-imath/docs/classes/half_conversion.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/half_conversion.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,75 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _half-float-conversion-configuration-options: - -Build-time half-float Conversion Configuration Options -###################################################### - -The Imath library supports three options for conversion between 16-bit -half and 32-bit float: - -1. Conversion from half to float via a 16-bit lookup table. Prior to - Imath v3.1, this was the only method supported. - -2. F16C SSE instructions: single-instruction conversion for machine - architectures that support it. When available, this is the fastest - option, by far. - -3. Bit-shift conversion algorithm. - -To use the F16C SSE instruction set on an architecture that supports -it, simply provide the appropriate compiler flags when building an -application that includes ``half.h``. For g++ and clang, -for example: -:: - - $ cmake -DCMAKE_CXX_FLAGS="-m16fc" - -When code including ``half.h`` is compiled with F16C enabled, it will -automatically perform conversions using the instruction set. F16C -compiler flags take precedence over other lookup-table-related Imath -CMake settings. - -On architectures that do not support F16C, you may choose at -compile-time between the bit-shift conversion and lookup table -conversion via the ``IMATH_HALF_USE_LOOKUP_TABLE`` CMake option: -:: - - $ cmake -DIMATH_HALF_USE_LOOKUP_TABLE=OFF - -Note that when building and installing the Imath library itself, the -65,536-entry lookup table symbol will be compiled into the library -even if the ``IMATH_HALF_USE_LOOKUP_TABLE`` setting is false. This -allows applications using that installed Imath library downstream to -choose at compile time which conversion method to use. - -Applications with memory limitations that cannot accomodate the -conversion lookup table can eliminate it from the library by building -Imath with the C preprocessor define ``IMATH_HALF_NO_LOOKUP_TABLE`` -defined. Note that this is a compile-time option, not a CMake setting -(making it possible for application code to choose the desired -behavior). Simply add: -:: - - #define IMATH_HALF_NO_LOOKUP_TABLE - -before including ``half.h``, or define the symbol on the compile -command line. - -Furthermore, an implementation wishing to receive ``FE_OVERFLOW`` and -``FE_UNDERFLOW`` floating point exceptions when converting float to -half by the bit-shift algorithm can define the preprocessor symbol -``IMATH_HALF_ENABLE_FP_EXCEPTIONS`` prior to including ``half.h``: -:: - - #define IMATH_HALF_ENABLE_FP_EXCEPTIONS - -By default, no exceptions are raised on overflow and underflow. - - - - - - diff -Nru ilmbase-3.1.9-imath/docs/classes/half_limits.rst ilmbase-3.1.10/docs/classes/half_limits.rst --- ilmbase-3.1.9-imath/docs/classes/half_limits.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes/half_limits.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,117 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -half Limits -########### - -Constants ---------- - -``HALF_DENORM_MIN`` - Smallest positive denormalized half. - -``HALF_NRM_MIN`` - Smallest positive normalized half. - -``HALF_MIN`` - Smallest positive normalized half. - -``HALF_MAX`` - Largest positive half. - -``HALF_EPSILON`` - Smallest positive e for which half(1.0 + e) != half(1.0) - -``HALF_MANT_DIG`` - Number of digits in mantissa (significand + hidden leading 1) - -``HALF_DIG`` - Number of base 10 digits that can be represented without change: - - floor( (``HALF_MANT_DIG`` - 1) * log10(2) ) => 3.01... -> 3 - -``HALF_DECIMAL_DIG`` - Number of base-10 digits that are necessary to uniquely represent - all distinct values: - - ceil(``HALF_MANT_DIG`` * log10(2) + 1) => 4.31... -> 5 - -``HALF_RADIX`` - Base of the exponent. - -``HALF_DENORM_MIN_EXP`` - Minimum negative integer such that ``HALF_RADIX`` raised to the - power of one less than that integer is a normalized half. - -``HALF_MAX_EXP`` - Maximum positive integer such that ``HALF_RADIX`` raised to the - power of one less than that integer is a normalized half. - -``HALF_DENORM_MIN_10_EXP`` - Minimum positive integer such that 10 raised to that power is a - normalized half. - -``HALF_MAX_10_EXP`` - Maximum positive integer such that 10 raised to that power is a - normalized half. - -``std::numeric_limits`` ------------------------------ - -The ``half`` type provides specializations for -``std::numeric_limits``: - -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::min() `_ | ``HALF_MIN`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::max() `_ | ``HALF_MAX`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::lowest() `_ | ``-HALF_MAX`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::digits `_ | ``HALF_MANT_DIG`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::digits10 `_ | ``HALF_DIG`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::max_digits10 `_ | ``HALF_DECIMAL_DIG`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::is_signed `_ | ``true`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::is_integer `_ | ``false`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::is_exact `_ | ``false`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::radix `_ | ``HALF_RADIX`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::epsilon() `_ | ``HALF_EPSILON`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::round_error() `_ | ``0.5`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::min_exponent `_ | ``HALF_DENORM_MIN_EXP`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::min_exponent10 `_ | ``HALF_DENORM_MIN_10_EXP`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::max_exponent `_ | ``HALF_MAX_EXP`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::max_exponent10 `_ | ``HALF_MAX_10_EXP`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::has_infinity `_ | ``true`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::has_quiet_NaN `_ | ``true`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::has_signaling_NaN `_ | ``true`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::has_denorm `_ | ``std::denorm_present`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::has_denorm_loss `_ | ``false`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::infinity() `_ | ``half::posInf()`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::quiet_NaN() `_ | ``half::qNan()`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::signaling_NaN() `_ | ``half::sNan()`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ -| `std::numeric_limits::denorm_min() `_ | ``HALF_DENORM_MIN`` | -+----------------------------------------------------------------------------------------------------------------------------+----------------------------+ - - diff -Nru ilmbase-3.1.9-imath/docs/classes.rst ilmbase-3.1.10/docs/classes.rst --- ilmbase-3.1.9-imath/docs/classes.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/classes.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,34 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _Imath Classes: - -Imath Classes -############# - -.. toctree:: - :caption: Classes - :maxdepth: 2 - - classes/half - classes/Box - classes/Color3 - classes/Color4 - classes/Euler - classes/Frustum - classes/Interval - classes/Line3 - classes/Matrix22 - classes/Matrix33 - classes/Matrix44 - classes/Plane3 - classes/Quat - classes/Rand32 - classes/Rand48 - classes/Shear6 - classes/Sphere3 - classes/Vec2 - classes/Vec3 - classes/Vec4 - diff -Nru ilmbase-3.1.9-imath/docs/concepts.rst ilmbase-3.1.10/docs/concepts.rst --- ilmbase-3.1.9-imath/docs/concepts.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/concepts.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,143 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _Concepts: - -Concepts -######## - -.. toctree:: - :caption: Concepts - :maxdepth: 0 - -The Imath library emphasizes simplicity, ease of use, correctness and -verifiability, performance, and breadth of adoption. Imath is not -intended to be a comprehensive linear algebra or numerical analysis -package. - -Imath is not a substitute for `Eigen `_! -It's not a full-featured linear algebra package, and it doesn't -represent vectors and matrices of arbitrary dimension. Its greatest -utility is as a geometric data representation, primarily for 2D images -and 3D scenes and coordinate transformations, along with an -accompanying set of utility methods and functions. - -Example -======= - -A basic program: - -.. literalinclude:: examples/intro.cpp - -Matrices Are Row-Major -====================== - -Imath stores matrices in row-major layout, originally inspired by -compatibility with OpenGL matrices. - -A matrix described as: - -.. math:: - \begin{bmatrix} - m_{00} & m_{01} & m_{02} & m_{03} \\ - m_{10} & m_{11} & m_{12} & m_{13} \\ - m_{20} & m_{21} & m_{22} & m_{23} \\ - m_{30} & m_{31} & m_{32} & m_{33} \\ - \end{bmatrix} - -is laid out in memory as: - -.. list-table:: - :widths: 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 - :header-rows: 1 - - * - 0 - - 1 - - 2 - - 3 - - 4 - - 5 - - 6 - - 7 - - 8 - - 9 - - 10 - - 11 - - 12 - - 13 - - 14 - - 15 - * - :math:`m_{00}` - - :math:`m_{01}` - - :math:`m_{02}` - - :math:`m_{03}` - - :math:`m_{10}` - - :math:`m_{11}` - - :math:`m_{12}` - - :math:`m_{13}` - - :math:`m_{20}` - - :math:`m_{21}` - - :math:`m_{22}` - - :math:`m_{23}` - - :math:`m_{30}` - - :math:`m_{31}` - - :math:`m_{32}` - - :math:`m_{33}` - -A matrix representing a homogeneous transform has a right-hand column -of :math:`\begin{bmatrix} 0 & 0 & 0 & 1\end{bmatrix}` and the -translation component across the bottom row. - -As a result, it is best to think of Imath vectors as row-vectors, and -vector-matrix multiplication with the vector on the left and matrix on -the right: - -.. math:: - \begin{bmatrix} v_{0}' & v_{1}' & v_{2}' & 1' \end{bmatrix} - = - \begin{bmatrix} v_{0} & v_{1} & v_{2} & 1 \end{bmatrix} - \begin{bmatrix} m_{00} & m_{01} & m_{02} & 0 \\ - m_{10} & m_{11} & m_{12} & 0 \\ - m_{20} & m_{21} & m_{22} & 0 \\ - m_{30} & m_{31} & m_{32} & 1 - \end{bmatrix} - -This further implies that you should interpret local transformations -as pre-multiplication: - -.. code-block:: - - M44f M; - M.translate (tx, ty, tz); - m.rotate (r, 0, 0); - m.scale (s); - -.. math:: - \begin{bmatrix} - m_{00} & m_{01} & m_{02} & m_{03} \\ - m_{10} & m_{11} & m_{12} & m_{13} \\ - m_{20} & m_{21} & m_{22} & m_{23} \\ - m_{30} & m_{31} & m_{32} & m_{33} \\ - \end{bmatrix} - = - \begin{bmatrix} - s & 0 & 0 & 0 \\ - 0 & s & 0 & 0 \\ - 0 & 0 & s & 0 \\ - 0 & 0 & 0 & 1 \\ - \end{bmatrix} - \begin{bmatrix} - 1 & 0 & 0 & 0 \\ - 0 & \cos(r) & \sin(r) & 0 \\ - 0 & -\sin(r) & \cos(r) & 0 \\ - 0 & 0 & 0 & 1 \\ - \end{bmatrix} - \begin{bmatrix} - 1 & 0 & 0 & 0 \\ - 0 & 1 & 0 & 0 \\ - 0 & 0 & 1 & 0 \\ - tx & ty & tz & 1 \\ - \end{bmatrix} - - diff -Nru ilmbase-3.1.9-imath/docs/conf.py ilmbase-3.1.10/docs/conf.py --- ilmbase-3.1.9-imath/docs/conf.py 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/conf.py 1970-01-01 00:00:00.000000000 +0000 @@ -1,309 +0,0 @@ -#!/usr/bin/env python3 - -# SPDX-License-Identifier: BSD-3-Clause -# Copyright Contributors to the OpenEXR Project. - -# -*- coding: utf-8 -*- -# -# ReadTheDocs-Breathe documentation build configuration file, created by -# sphinx-quickstart on Mon Feb 10 20:03:57 2014. -# -# This file is execfile()d with the current directory set to its -# containing dir. -# -# Note that not all possible configuration values are present in this -# autogenerated file. -# -# All configuration values have a default; values that are commented out -# serve to show the default. - -import sys -import os - -# If extensions (or modules to document with autodoc) are in another directory, -# add these directories to sys.path here. If the directory is relative to the -# documentation root, use os.path.abspath to make it absolute, like shown here. -#sys.path.insert(0, os.path.abspath('.')) - -# hack for readthedocs to cause it to run doxygen first -# https://github.com/rtfd/readthedocs.org/issues/388 - -on_rtd = os.environ.get('READTHEDOCS', None) == 'True' -if on_rtd: - - with open("Doxyfile.in", "r") as file: - filedata = file.read() - - doxygen_output_dir = "_build" - filedata = filedata.replace('@DOXYGEN_INPUT_DIR@', "../src/Imath") - filedata = filedata.replace('@DOXYGEN_OUTPUT_DIR@', "doxygen") - - with open("Doxyfile", "w") as file: - file.write(filedata) - - from subprocess import call - call('doxygen') - -# -- General configuration ------------------------------------------------ - -# If your documentation needs a minimal Sphinx version, state it here. -#needs_sphinx = '1.0' - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom -# ones. -extensions = [ - 'sphinx.ext.autodoc', - 'sphinx.ext.todo', - 'sphinx.ext.viewcode', - 'breathe', -] - -# Breathe extension variables -breathe_projects = { "Imath": "doxygen/xml" } -breathe_default_project = "Imath" - -# Add any paths that contain templates here, relative to this directory. -templates_path = ['_templates'] - -# The suffix of source filenames. -source_suffix = '.rst' - -# The encoding of source files. -#source_encoding = 'utf-8-sig' - -# General information about the project. -project = 'Imath' -copyright = '2021, Contributors to the OpenEXR Project' - -# The version info for the project you're documenting, acts as replacement for -# |version| and |release|, also used in various other places throughout the -# built documents. -# -project_Imath_VERSION = "project(Imath VERSION " -release = None -for l in open ("../CMakeLists.txt"): - if l.startswith (project_Imath_VERSION): - release = l.split (' ')[2] - break -if release == None: - print ("Error in conf.py: can't find Imath VERSION in ../CMakeList.txt") - exit(-1) - -v = release.split('.') -# The short X.Y version. -version = "%s.%s" % (v[0], v[1]) - -# The language for content autogenerated by Sphinx. Refer to documentation -# for a list of supported languages. -#language = None - -# There are two options for replacing |today|: either, you set today to some -# non-false value, then it is used: -#today = '' -# Else, today_fmt is used as the format for a strftime call. -#today_fmt = '%B %d, %Y' - -# List of patterns, relative to source directory, that match files and -# directories to ignore when looking for source files. -exclude_patterns = ['_build'] - -# The reST default role (used for this markup: `text`) to use for all -# documents. -#default_role = None - -# If true, '()' will be appended to :func: etc. cross-reference text. -#add_function_parentheses = True - -# If true, the current module name will be prepended to all description -# unit titles (such as .. function::). -#add_module_names = True - -# If true, sectionauthor and moduleauthor directives will be shown in the -# output. They are ignored by default. -#show_authors = False - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'sphinx' - -# A list of ignored prefixes for module index sorting. -#modindex_common_prefix = [] - -# If true, keep warnings as "system message" paragraphs in the built documents. -#keep_warnings = False - - -# -- Options for HTML output ---------------------------------------------- - -# The theme to use for HTML and HTML Help pages. See the documentation for -# a list of builtin themes. -#html_theme = 'agogo' -#html_theme = 'default' # good -#html_theme = 'nature' # too green -#html_theme = 'bizstyle' # OK -#html_theme = 'sphinxdoc' - -html_theme = "press" -html_theme_options = { - "external_links": [ - ("Github", "https://github.com/AcademySoftwareFoundation/Imath"), - ] -} - -# Theme options are theme-specific and customize the look and feel of a theme -# further. For a list of options available for each theme, see the -# documentation. -#html_theme_options = {} - -# Add any paths that contain custom themes here, relative to this directory. -#html_theme_path = [] - -# The name for this set of Sphinx documents. If None, it defaults to -# " v documentation". -html_title = "Imath Documentation" - -# A shorter title for the navigation bar. Default is the same as html_title. -html_short_title = "Imath" - -# The name of an image file (relative to this directory) to place at the top -# of the sidebar. -html_logo = "images/imath-logo-blue.png" - -# The name of an image file (within the static path) to use as favicon of the -# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 -# pixels large. -html_favicon = "images/imath-fav.ico" - -# Add any paths that contain custom static files (such as style sheets) here, -# relative to this directory. They are copied after the builtin static files, -# so a file named "default.css" will overwrite the builtin "default.css". -#html_static_path = ['_static'] - -# Add any extra paths that contain custom files (such as robots.txt or -# .htaccess) here, relative to this directory. These files are copied -# directly to the root of the documentation. -#html_extra_path = [] - -# If not '', a 'Last updated on:' timestamp is inserted at every page bottom, -# using the given strftime format. -html_last_updated_fmt = '%b %d, %Y' - -# If true, SmartyPants will be used to convert quotes and dashes to -# typographically correct entities. -html_use_smartypants = True - -# Custom sidebar templates, maps document names to template names. -#html_sidebars = {} - -# Additional templates that should be rendered to pages, maps page names to -# template names. -#html_additional_pages = {} - -# If false, no module index is generated. -#html_domain_indices = True - -# If false, no index is generated. -#html_use_index = True - -# If true, the index is split into individual pages for each letter. -#html_split_index = False - -# If true, links to the reST sources are added to the pages. -#html_show_sourcelink = True - -# If true, "Created using Sphinx" is shown in the HTML footer. Default is True. -#html_show_sphinx = True - -# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True. -#html_show_copyright = True - -# If true, an OpenSearch description file will be output, and all pages will -# contain a tag referring to it. The value of this option must be the -# base URL from which the finished HTML is served. -#html_use_opensearch = '' - -# This is the file name suffix for HTML files (e.g. ".xhtml"). -#html_file_suffix = None - -# Output file base name for HTML help builder. -htmlhelp_basename = 'Imath' - - -# -- Options for LaTeX output --------------------------------------------- - -#latex_elements = { -# The paper size ('letterpaper' or 'a4paper'). -#'papersize': 'letterpaper', - -# The font size ('10pt', '11pt' or '12pt'). -#'pointsize': '10pt', - -# Additional stuff for the LaTeX preamble. -#'preamble': '', -#} - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, -# author, documentclass [howto, manual, or own class]). -#latex_documents = [ -# ('index', 'Imath.tex', 'Imath Documentation', -# 'Contributors to the OpenEXR Project', 'manual'), -#] - -# The name of an image file (relative to this directory) to place at the top of -# the title page. -#latex_logo = None - -# For "manual" documents, if this is true, then toplevel headings are parts, -# not chapters. -#latex_use_parts = False - -# If true, show page references after internal links. -#latex_show_pagerefs = False - -# If true, show URL addresses after external links. -#latex_show_urls = False - -# Documents to append as an appendix to all manuals. -#latex_appendices = [] - -# If false, no module index is generated. -#latex_domain_indices = True - - -# -- Options for manual page output --------------------------------------- - -# One entry per manual page. List of tuples -# (source start file, name, description, authors, manual section). -man_pages = [ - ('index', 'imath', 'Imath Documentation', - ['Contributors to the OpenEXR Project'], 1) -] - -# If true, show URL addresses after external links. -#man_show_urls = False - - -# -- Options for Texinfo output ------------------------------------------- - -# Grouping the document tree into Texinfo files. List of tuples -# (source start file, target name, title, author, -# dir menu entry, description, category) -texinfo_documents = [ - ('index', 'Imath', 'Imath Documentation', - 'Contributors to the OpenEXR Project', 'Imath', - '2D and 3D vectors and matrices, half 16-bit floating-point type', - 'Miscellaneous'), -] - -# Documents to append as an appendix to all manuals. -#texinfo_appendices = [] - -# If false, no module index is generated. -#texinfo_domain_indices = True - -# How to display URL addresses: 'footnote', 'no', or 'inline'. -#texinfo_show_urls = 'footnote' - -# If true, do not generate a @detailmenu in the "Top" node's menu. -#texinfo_no_detailmenu = False diff -Nru ilmbase-3.1.9-imath/docs/examples/Box.cpp ilmbase-3.1.10/docs/examples/Box.cpp --- ilmbase-3.1.9-imath/docs/examples/Box.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Box.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,25 +0,0 @@ -#include - -void -box_example() -{ - Imath::V3f a (0, 0, 0); - Imath::V3f b (1, 1, 1); - Imath::V3f c (2, 9, 2); - - Imath::Box3f box (a); - - assert (box.isEmpty()); - assert (!box.isInfinite()); - assert (!box.hasVolume()); - - box.extendBy (c); - - assert (box.size() == (c-a)); - assert (box.intersects (b)); - assert (box.max[0] > box.min[0]); - assert (box.max[1] > box.min[1]); - assert (box.max[2] > box.min[2]); - assert (box.hasVolume()); - assert (box.majorAxis() == 1); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/CMakeLists.txt ilmbase-3.1.10/docs/examples/CMakeLists.txt --- ilmbase-3.1.9-imath/docs/examples/CMakeLists.txt 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/CMakeLists.txt 1970-01-01 00:00:00.000000000 +0000 @@ -1,48 +0,0 @@ -# SPDX-License-Identifier: BSD-3-Clause -# Copyright Contributors to the OpenEXR Project. - -cmake_minimum_required(VERSION 3.10) - -project(imath-examples) - -find_package(Imath) - -# The introductory example on the main docs page -add_executable(imath-intro intro.cpp) - -# A main() that executes all the example code snippets -add_executable(imath-examples - main.cpp - Color3.cpp - Color4.cpp - Euler.cpp - Frustum.cpp - Interval.cpp - Line3.cpp - Matrix22.cpp - Matrix33.cpp - Matrix44.cpp - Plane3.cpp - Quat.cpp - Shear6.cpp - Sphere3.cpp - Vec2.cpp - Vec3.cpp - Vec4.cpp - half.cpp -) - -target_link_libraries(imath-intro Imath::Imath) -target_link_libraries(imath-examples Imath::Imath) - -set_target_properties(imath-examples PROPERTIES - RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin" -) -set_target_properties(imath-intro PROPERTIES - RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin" -) - -add_test(NAME Imath.imath-intro COMMAND $) -add_test(NAME Imath.imath-examples COMMAND $) - -enable_testing() diff -Nru ilmbase-3.1.9-imath/docs/examples/Color3.cpp ilmbase-3.1.10/docs/examples/Color3.cpp --- ilmbase-3.1.9-imath/docs/examples/Color3.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Color3.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,16 +0,0 @@ -#include -#include - -void -color3_example() -{ - Imath::C3c r (255, 0, 0); - Imath::C3c g (0, 255, 0); - Imath::C3c b (0, 0, 255); - - Imath::C3c c = r + g + b; - - assert (c.x == 255); - assert (c.x == 255); - assert (c.x == 255); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Color4.cpp ilmbase-3.1.10/docs/examples/Color4.cpp --- ilmbase-3.1.9-imath/docs/examples/Color4.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Color4.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,17 +0,0 @@ -#include -#include - -void -color4_example() -{ - Imath::C4f r (1.0f, 0.0f, 0.0f, 1.0f); - Imath::C4f g (0.0f, 1.0f, 0.0f, 1.0f); - Imath::C4f b (0.0f, 0.0f, 1.0f, 1.0f); - - Imath::C4f w = r + g + b; - - assert (w.r == 1.0f); - assert (w.g == 1.0f); - assert (w.b == 1.0f); - assert (w.a == 3.0f); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Euler.cpp ilmbase-3.1.10/docs/examples/Euler.cpp --- ilmbase-3.1.9-imath/docs/examples/Euler.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Euler.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,25 +0,0 @@ -#include -#include -#include - -void -euler_example() -{ - int i, j, k; - - Imath::Eulerf xyz (Imath::Eulerf::XYZ); - xyz.angleOrder (i, j, k); - assert (i == 0 && j == 1 && k == 2); - - Imath::Eulerf xzy (Imath::Eulerf::XZY); - xzy.angleOrder (i, j, k); - assert (i == 0 && j == 2 && k == 1); - - Imath::Eulerf e1 (0.0f, 0.0f, 0.1f + 2 * M_PI); - Imath::Eulerf e2 (0.0f, 0.0f, 0.1f); - - e1.makeNear (e2); - Imath::V3f v = e2.toXYZVector(); - assert (v.equalWithAbsError (Imath::V3f (0.0f, 0.0f, 0.1f), 0.00001f)); -} - diff -Nru ilmbase-3.1.9-imath/docs/examples/Frustum.cpp ilmbase-3.1.10/docs/examples/Frustum.cpp --- ilmbase-3.1.9-imath/docs/examples/Frustum.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Frustum.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,22 +0,0 @@ -#include -#include - -void -frustum_example() -{ - float near = 1.7f; - float far = 567.0f; - float left = -3.5f; - float right = 2.0f; - float top = 0.9f; - float bottom = -1.3f; - - Imath::Frustumf frustum (near, far, left, right, top, bottom, false); - - Imath::M44f m = frustum.projectionMatrix(); - - Imath::V3f p (1.0f, 1.0f, 1.0f); - Imath::V2f s = frustum.projectPointToScreen (p); - - assert (s.equalWithAbsError (Imath::V2f (-0.345455f, -1.36364f), 0.0001f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Interval.cpp ilmbase-3.1.10/docs/examples/Interval.cpp --- ilmbase-3.1.9-imath/docs/examples/Interval.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Interval.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,19 +0,0 @@ -#include -#include - -void -interval_example() -{ - Imath::Intervalf v; - - assert (v.isEmpty()); - assert (!v.hasVolume()); - assert (!v.isInfinite()); - - v.extendBy (1.0f); - assert (!v.isEmpty()); - - v.extendBy (2.0f); - assert (v.hasVolume()); - assert (v.intersects (1.5f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Line3.cpp ilmbase-3.1.10/docs/examples/Line3.cpp --- ilmbase-3.1.9-imath/docs/examples/Line3.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Line3.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,23 +0,0 @@ -#include -#include - -void -line3_example() -{ - Imath::V3f a (0.0f, 0.0f, 0.0f); - Imath::V3f b (1.0f, 1.0f, 1.0f); - - Imath::Line3f line (a, b); - - assert (line.pos == a); - assert (line.dir == (b-a).normalized()); - - Imath::V3f c (0.5f, 0.5f, 0.5f); - - float f = line.distanceTo (c); - assert (Imath::equalWithAbsError (f, 0.0f, 0.0001f)); - - Imath::V3f p = line (0.5f); // midpoint, i.e. 0.5 units from a along (b-a) - - assert (p.equalWithAbsError (Imath::V3f (0.288675f, 0.288675f, 0.288675f), 0.0001f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Matrix22.cpp ilmbase-3.1.10/docs/examples/Matrix22.cpp --- ilmbase-3.1.9-imath/docs/examples/Matrix22.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Matrix22.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,27 +0,0 @@ -#include -#include -#include - -void -matrix22_example() -{ - Imath::M22f M (Imath::UNINITIALIZED); // uninitialized - - M.makeIdentity(); - assert (M[0][0] == 1.0f); - assert (M[0][1] == 0.0f); - - Imath::M22f Minv = M.inverse(); - - Imath::M22f R; - assert (R == Imath::identity22f); - - R.rotate (M_PI/4); - - M = R * M; - - Imath::V2f v2 (1.0f, 0.0f); - Imath::V2f r2 = v2 * M; - - assert (r2.equalWithAbsError (Imath::V2f (0.707107f, 0.707107f), 1e-6f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Matrix33.cpp ilmbase-3.1.10/docs/examples/Matrix33.cpp --- ilmbase-3.1.9-imath/docs/examples/Matrix33.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Matrix33.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,27 +0,0 @@ -#include -#include -#include - -void -matrix33_example() -{ - Imath::M33f M (Imath::UNINITIALIZED); // uninitialized - - M.makeIdentity(); - assert (M[0][0] == 1.0f); - assert (M[0][1] == 0.0f); - - Imath::M33f Minv = M.inverse(); - - Imath::M33f R; - assert (R == Imath::identity33f); - - R.rotate (M_PI/4); - - M = R * M; - - Imath::V3f v3 (1.0f, 0.0f, 0.0f); - Imath::V3f r3 = v3 * M; - - assert (r3.equalWithAbsError (Imath::V3f (0.707107f, 0.7071070f, 0.0f), 1e-6f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Matrix44.cpp ilmbase-3.1.10/docs/examples/Matrix44.cpp --- ilmbase-3.1.9-imath/docs/examples/Matrix44.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Matrix44.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,31 +0,0 @@ -#include -#include -#include - -void -matrix44_example() -{ - Imath::M44f M (Imath::UNINITIALIZED); // uninitialized - - M.makeIdentity(); - assert (M[0][0] == 1.0f); - assert (M[0][1] == 0.0f); - - Imath::M44f Minv = M.inverse(); - - Imath::M44f R; - assert (R == Imath::identity44f); - - R.rotate (Imath::V3f (0.02f, M_PI/4, 0.0f)); - - M = R * M; - - Imath::V3f v3 (1.0f, 0.0f, 0.0f); - Imath::V4f v4 (1.0f, 0.0f, 0.0f, 1.0f); - - Imath::V3f r3 = v3 * M; - assert (r3.equalWithAbsError (Imath::V3f (0.707107f, 0.0f, -0.7071070f), 1e-6f)); - - Imath::V4f r4 = v4 * M; - assert (r4.equalWithAbsError (Imath::V4f (0.707107f, 0.0f, -0.7071070f, 1.0f), 1e-6f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Plane3.cpp ilmbase-3.1.10/docs/examples/Plane3.cpp --- ilmbase-3.1.9-imath/docs/examples/Plane3.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Plane3.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,21 +0,0 @@ -#include -#include - -void -plane3_example() -{ - Imath::V3f a (1.0f, 0.0f, 0.0f); - Imath::V3f b (0.0f, 1.0f, 0.0f); - Imath::V3f c (0.0f, 0.0f, 1.0f); - - Imath::Plane3f p (a, b, c); - - Imath::V3f n (1.0f, 1.0f, 1.0f); - n.normalize(); - - assert (p.normal == n); - - Imath::V3f o (0.0f, 0.0f, 0.0f); - float d = p.distanceTo (o); - assert (Imath::equalWithAbsError (d, -0.57735f, 1e-6f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Quat.cpp ilmbase-3.1.10/docs/examples/Quat.cpp --- ilmbase-3.1.9-imath/docs/examples/Quat.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Quat.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,12 +0,0 @@ -#include -#include - -void -quat_example() -{ - Imath::Quatf q (2.0f, 3.0f, 4.0f, 5.0f); - assert (q.r == 2.0f && q.v == Imath::V3f (3.0f, 4.0f, 5.0f)); - - Imath::Quatf r (1.0f, 0.0f, 0.0f, 1.0f); - assert (r.inverse() == Imath::Quatf (0.5f, 0.0f, 0.0f, -0.5f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Shear6.cpp ilmbase-3.1.10/docs/examples/Shear6.cpp --- ilmbase-3.1.9-imath/docs/examples/Shear6.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Shear6.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,11 +0,0 @@ -#include -#include - -void -shear6_example() -{ - Imath::Shear6f s (0.330f, 0.710f, 0.010f, 0.999f, -0.531f, -0.012f); - - Imath::M44f M; - M.setShear (s); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Sphere3.cpp ilmbase-3.1.10/docs/examples/Sphere3.cpp --- ilmbase-3.1.9-imath/docs/examples/Sphere3.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Sphere3.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,21 +0,0 @@ -#include -#include - -void -sphere3_example() -{ - Imath::V3f center (1.0f, 1.0f, 1.0f); - float radius = 2.0f; - Imath::Sphere3f s (center, radius); - - assert (s.center == center); - assert (s.radius == radius); - - Imath::Line3f line (Imath::V3f (0.0f, 0.0f, 0.0f), - Imath::V3f (1.0f, 1.0f, 1.0f)); - - Imath::V3f v; - assert (s.intersect (line, v)); - - assert (v.equalWithAbsError (Imath::V3f(2.1547f, 2.1547f, 2.1547f), 1e-6f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Vec2.cpp ilmbase-3.1.10/docs/examples/Vec2.cpp --- ilmbase-3.1.9-imath/docs/examples/Vec2.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Vec2.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,19 +0,0 @@ -#include -#include - -void -vec2_example() -{ - Imath::V2f a (1.0f, 2.0f); - Imath::V2f b; // b is uninitialized - - b.x = a[0]; - b.y = a[1]; - - assert (a == b); - - assert (a.length() == sqrt (a ^ a)); - - a.normalize(); - assert (Imath::equalWithAbsError (a.length(), 1.0f, 1e-6f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Vec3.cpp ilmbase-3.1.10/docs/examples/Vec3.cpp --- ilmbase-3.1.9-imath/docs/examples/Vec3.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Vec3.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,20 +0,0 @@ -#include -#include - -void -vec3_example() -{ - Imath::V3f a (1.0f, 2.0f, 3.0f); - Imath::V3f b; // b is uninitialized - - b.x = a[0]; - b.y = a[1]; - b.z = a[2]; - - assert (a == b); - - assert (a.length() == sqrt (a ^ a)); - - a.normalize(); - assert (Imath::equalWithAbsError (a.length(), 1.0f, 1e-6f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/Vec4.cpp ilmbase-3.1.10/docs/examples/Vec4.cpp --- ilmbase-3.1.9-imath/docs/examples/Vec4.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/Vec4.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,21 +0,0 @@ -#include -#include - -void -vec4_example() -{ - Imath::V4f a (1.0f, 2.0f, 3.0f, 4.0f); - Imath::V4f b; // b is uninitialized - - b.x = a[0]; - b.y = a[1]; - b.z = a[2]; - b.w = a[3]; - - assert (a == b); - - assert (a.length() == sqrt (a ^ a)); - - a.normalize(); - assert (Imath::equalWithAbsError (a.length(), 1.0f, 1e-6f)); -} diff -Nru ilmbase-3.1.9-imath/docs/examples/gl.cpp ilmbase-3.1.10/docs/examples/gl.cpp --- ilmbase-3.1.9-imath/docs/examples/gl.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/gl.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,12 +0,0 @@ -#include - -void -gl_example() -{ - Imath::M44f M; - glPushMatrix (M); - - Imath::V3f v (0.0f, 1.0f, 2.0f); - glVertex (v); -} - diff -Nru ilmbase-3.1.9-imath/docs/examples/half.c ilmbase-3.1.10/docs/examples/half.c --- ilmbase-3.1.9-imath/docs/examples/half.c 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/half.c 1970-01-01 00:00:00.000000000 +0000 @@ -1,12 +0,0 @@ -#include - -void -half_example() -{ - float f = 3.5f; - - half h = imath_float_to_half (f) - - float hh = imath_half_to_float (h) -} - diff -Nru ilmbase-3.1.9-imath/docs/examples/half.cpp ilmbase-3.1.10/docs/examples/half.cpp --- ilmbase-3.1.9-imath/docs/examples/half.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/half.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ -#include -#include - -void -half_example() -{ - half a (3.5); - float b (a + sqrt (a)); - a += b; - b += a; - b = a + 7; -} - diff -Nru ilmbase-3.1.9-imath/docs/examples/intro.cpp ilmbase-3.1.10/docs/examples/intro.cpp --- ilmbase-3.1.9-imath/docs/examples/intro.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/intro.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,24 +0,0 @@ -#include -#include -#include -#include - -int -main() -{ - const Imath::V3f v (3.0f, 4.0f, 5.0f); - - Imath::M44f M; - const Imath::V3f t(1.0f, 2.0f, 3.0f); - M.translate (t); - - Imath::V3f p; - M.multVecMatrix(v, p); - - std::cout << "What's your vector, Victor? " << p << std::endl; - - Imath::V3f vt = v + t; - assert (p.equalWithAbsError(vt, 1e-6f)); - - return 0; -} diff -Nru ilmbase-3.1.9-imath/docs/examples/main.cpp ilmbase-3.1.10/docs/examples/main.cpp --- ilmbase-3.1.9-imath/docs/examples/main.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/examples/main.cpp 1970-01-01 00:00:00.000000000 +0000 @@ -1,50 +0,0 @@ -// SPDX-License-Identifier: BSD-3-Clause -// Copyright Contributors to the OpenEXR Project. - -#include - -void color3_example(); -void color4_example(); -void euler_example(); -void frustum_example(); -void interval_example(); -void line3_example(); -void matrix22_example(); -void matrix33_example(); -void matrix44_example(); -void plane3_example(); -void quat_example(); -void shear6_example(); -void sphere3_example(); -void vec2_example(); -void vec3_example(); -void vec4_example(); -void half_example(); - -int -main (int argc, char* argv[]) -{ - std::cout << "imath examples..." << std::endl; - - color3_example(); - color4_example(); - euler_example(); - frustum_example(); - interval_example(); - line3_example(); - matrix22_example(); - matrix33_example(); - matrix44_example(); - plane3_example(); - quat_example(); - shear6_example(); - sphere3_example(); - vec2_example(); - vec3_example(); - vec4_example(); - half_example(); - - std::cout << "done." << std::endl; - - return 0; -} diff -Nru ilmbase-3.1.9-imath/docs/fixmanpages.sh ilmbase-3.1.10/docs/fixmanpages.sh --- ilmbase-3.1.9-imath/docs/fixmanpages.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/fixmanpages.sh 1970-01-01 00:00:00.000000000 +0000 @@ -1,21 +0,0 @@ -#!/bin/bash - -# Fix the names of doxygen-generated man page files: -# * Strip "_ Vec" and "_ T _ _" from "Imath_Box_ Vec2_ T _ _.3" -# * and rename "Imath_*" to "Imath::*" - -if [ -d $1/man/man3 ]; then - - cd $1/man/man3 - echo cd $1/man/man3 - shopt -s nullglob - for file in Imath_*.3; - do - new=`echo $file | sed -e 's/_ T _ _//g' -e 's/_ Vec//g' -e s/_/::/g` - echo /bin/mv "$file" $new - /bin/mv "$file" $new - done -fi - - - diff -Nru ilmbase-3.1.9-imath/docs/functions/box.rst ilmbase-3.1.10/docs/functions/box.rst --- ilmbase-3.1.9-imath/docs/functions/box.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/box.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,26 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _box-functions: - -Box Functions -############# - -Functions that operate on bounding boxes. - -.. code-block:: - - #include - -.. doxygenfunction:: clip - -.. doxygenfunction:: closestPointInBox - -.. doxygenfunction:: transform(const Box>& box, const Matrix44& m) noexcept - -.. doxygenfunction:: affineTransform(const Box>& box, const Matrix44& m) noexcept - -.. doxygenfunction:: findEntryAndExitPoints - -.. doxygenfunction:: intersects(const Box>& b, const Line3& r, Vec3& ip) noexcept diff -Nru ilmbase-3.1.9-imath/docs/functions/color.rst ilmbase-3.1.10/docs/functions/color.rst --- ilmbase-3.1.9-imath/docs/functions/color.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/color.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,32 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _color-functions: - -Color Functions -############### - -Functions that operate on colors. - -.. code-block:: - - #include - -.. doxygenfunction:: hsv2rgb(const Vec3& hsv) noexcept - -.. doxygenfunction:: hsv2rgb(const Color4& hsv) noexcept - -.. doxygenfunction:: rgb2hsv(const Color4 &rgb) noexcept - -.. doxygenfunction:: rgb2hsv(const Vec3 &rgb) noexcept - -.. doxygenfunction:: rgb2packed(const Color4 &c) noexcept - -.. doxygenfunction:: rgb2packed(const Vec3 &c) noexcept - -.. doxygenfunction:: packed2rgb(PackedColor packed, Color4 &out) noexcept - -.. doxygenfunction:: packed2rgb(PackedColor packed, Vec3 &out) noexcept - - diff -Nru ilmbase-3.1.9-imath/docs/functions/frame.rst ilmbase-3.1.10/docs/functions/frame.rst --- ilmbase-3.1.9-imath/docs/functions/frame.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/frame.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,20 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _frame-functions: - -Frame Functions -############### - -Functions to compute coordinate frames. - -.. code-block:: - - #include - -.. doxygenfunction:: firstFrame - -.. doxygenfunction:: nextFrame - -.. doxygenfunction:: lastFrame diff -Nru ilmbase-3.1.9-imath/docs/functions/gl.rst ilmbase-3.1.10/docs/functions/gl.rst --- ilmbase-3.1.9-imath/docs/functions/gl.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/gl.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,53 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _gl-functions: - -GL Functions -############ - -Functions that wrap OpenGL calls to accept Imath vectors and matrices. - -.. code-block:: - - #include - -Example: - -.. literalinclude:: ../examples/gl.cpp - :language: c++ - -.. doxygenfunction:: glVertex(const Imath::V2f &v) - -.. doxygenfunction:: glVertex(const Imath::V3f &v) - -.. doxygenfunction:: glNormal(const Imath::V3f &v) - -.. doxygenfunction:: glColor(const Imath::V3f &v) - -.. doxygenfunction:: glTranslate - -.. doxygenfunction:: glTexCoord - -.. doxygenfunction:: throwBadMatrix - -.. doxygenfunction:: glMultMatrix( const Imath::M44f &m ) - -.. doxygenfunction:: glMultMatrix( const Imath::M44f *m ) - -.. doxygenfunction:: glLoadMatrix(const Imath::M44f &m) - -.. doxygenfunction:: glLoadMatrix(const Imath::M44f *m) - -.. doxygenclass:: Imath::GLPushMatrix - :members: - :undoc-members: - -.. doxygenclass:: Imath::GLPushAttrib - :members: - :undoc-members: - -.. doxygenclass:: Imath::GLBegin - :members: - :undoc-members: diff -Nru ilmbase-3.1.9-imath/docs/functions/glu.rst ilmbase-3.1.10/docs/functions/glu.rst --- ilmbase-3.1.9-imath/docs/functions/glu.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/glu.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,16 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _glu-functions: - -GLU Functions -############# - -Functions that wrap GLU calls to accept Imath vectors. - -.. code-block:: - - #include - -.. doxygenfunction:: gluLookAt(const Imath::V3f& pos, const Imath::V3f& interest, const Imath::V3f& up) diff -Nru ilmbase-3.1.9-imath/docs/functions/line.rst ilmbase-3.1.10/docs/functions/line.rst --- ilmbase-3.1.9-imath/docs/functions/line.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/line.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,22 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _line-functions: - -Line3 Functions -############### - -.. code-block:: - - #include - -Functions that operate on the ``Line3`` object. - -.. doxygenfunction:: closestPoints - -.. doxygenfunction:: intersect(const Line3& line, const Vec3&v0, const Vec3& v1, const Vec3& v2, Vec3& pt, Vec3& barycentric, bool& front) noexcept - -.. doxygenfunction:: closestVertex(const Vec3& v0, const Vec3& v1, const Vec3& v2, const Line3& l) noexcept - -.. doxygenfunction:: rotatePoint diff -Nru ilmbase-3.1.9-imath/docs/functions/matrix.rst ilmbase-3.1.10/docs/functions/matrix.rst --- ilmbase-3.1.9-imath/docs/functions/matrix.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/matrix.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,104 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _matrix-functions: - -Matrix Functions -################ - -.. code-block:: - - #include - -Functions that operate on matrices - -.. doxygenfunction:: extractScaling(const Matrix44& mat, Vec3& scl, bool exc) - -.. doxygenfunction:: sansScaling(const Matrix44& mat, bool exc) - -.. doxygenfunction:: removeScaling(Matrix44& mat, bool exc) - -.. doxygenfunction:: extractScalingAndShear(const Matrix44& mat, Vec3& scl, Vec3& shr, bool exc) - -.. doxygenfunction:: sansScalingAndShear(const Matrix44& mat, bool exc) - -.. doxygenfunction:: sansScalingAndShear(Matrix44& result, const Matrix44& mat, bool exc) - -.. doxygenfunction:: removeScalingAndShear(Matrix44& mat, bool exc) - -.. doxygenfunction:: extractAndRemoveScalingAndShear(Matrix44& mat, Vec3& scl, Vec3& shr, bool exc) - -.. doxygenfunction:: extractEulerXYZ(const Matrix44& mat, Vec3& rot) - -.. doxygenfunction:: extractEulerZYX(const Matrix44& mat, Vec3& rot) - -.. doxygenfunction:: extractQuat(const Matrix44& mat) - -.. doxygenfunction:: extractSHRT(const Matrix44& mat, Vec3& s, Vec3& h, Vec3& r, Vec3& t, bool exc, typename Euler::Order rOrder) - -.. doxygenfunction:: extractSHRT(const Matrix44& mat, Vec3& s, Vec3& h, Vec3& r, Vec3& t, bool exc) - -.. doxygenfunction:: extractSHRT(const Matrix44& mat, Vec3& s, Vec3& h, Euler& r, Vec3& t, bool exc) - -.. doxygenfunction:: checkForZeroScaleInRow(const T& scl, const Vec3& row, bool exc) - -.. doxygenfunction:: outerProduct(const Vec4& a, const Vec4& b) - -.. doxygenfunction:: rotationMatrix(const Vec3& fromDirection, const Vec3& toDirection) - -.. doxygenfunction:: rotationMatrixWithUpDir(const Vec3& fromDir, const Vec3& toDir, const Vec3& upDir) - -.. doxygenfunction:: alignZAxisWithTargetDir(Matrix44& result, Vec3 targetDir, Vec3 upDir) - -.. doxygenfunction:: computeLocalFrame(const Vec3& p, const Vec3& xDir, const Vec3& normal) - -.. doxygenfunction:: addOffset(const Matrix44& inMat, const Vec3& tOffset, const Vec3& rOffset, const Vec3& sOffset, const Vec3& ref) - -.. doxygenfunction:: computeRSMatrix(bool keepRotateA, bool keepScaleA, const Matrix44& A, const Matrix44& B) - -.. doxygenfunction:: extractScaling(const Matrix33& mat, Vec2& scl, bool exc) - -.. doxygenfunction:: sansScaling(const Matrix33& mat, bool exc) - -.. doxygenfunction:: removeScaling(Matrix33& mat, bool exc) - -.. doxygenfunction:: extractScalingAndShear(const Matrix33& mat, Vec2& scl, T& shr, bool exc) - -.. doxygenfunction:: sansScalingAndShear(const Matrix33& mat, bool exc) - -.. doxygenfunction:: removeScalingAndShear(Matrix33& mat, bool exc) - -.. doxygenfunction:: extractAndRemoveScalingAndShear(Matrix33& mat, Vec2& scl, T& shr, bool exc) - -.. doxygenfunction:: extractEuler(const Matrix22& mat, T& rot) - -.. doxygenfunction:: extractEuler(const Matrix33& mat, T& rot) - -.. doxygenfunction:: extractSHRT(const Matrix33& mat, Vec2& s, T& h, T& r, Vec2& t, bool exc) - -.. doxygenfunction:: checkForZeroScaleInRow(const T& scl, const Vec2& row, bool exc) - -.. doxygenfunction:: outerProduct(const Vec3& a, const Vec3& b) - -.. doxygenfunction:: procrustesRotationAndTranslation(const Vec3* A, const Vec3* B, const T* weights, const size_t numPoints, const bool doScaling) - -.. doxygenfunction:: procrustesRotationAndTranslation(const Vec3* A, const Vec3* B, const size_t numPoints, const bool doScaling) - -.. doxygenfunction:: jacobiSVD(const Matrix33& A, Matrix33& U, Vec3& S, Matrix33& V, const T tol, const bool forcePositiveDeterminant) - -.. doxygenfunction:: jacobiSVD(const Matrix44& A, Matrix44& U, Vec4& S, Matrix44& V, const T tol, const bool forcePositiveDeterminant) - -.. doxygenfunction:: jacobiEigenSolver(Matrix33& A, Vec3& S, Matrix33& V, const T tol) - -.. doxygenfunction:: jacobiEigenSolver(Matrix33& A, Vec3& S, Matrix33& V) - -.. doxygenfunction:: jacobiEigenSolver(Matrix44& A, Vec4& S, Matrix44& V, const T tol) - -.. doxygenfunction:: jacobiEigenSolver(Matrix44& A, Vec4& S, Matrix44& V) - -.. doxygenfunction:: maxEigenVector(TM& A, TV& S) - -.. doxygenfunction:: minEigenVector(TM& A, TV& S) - - diff -Nru ilmbase-3.1.9-imath/docs/functions/random.rst ilmbase-3.1.10/docs/functions/random.rst --- ilmbase-3.1.9-imath/docs/functions/random.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/random.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,33 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _random-number-functions: - -Random Numbers -############## - -Functions to compute pseudo-random numbers. - -.. code-block:: - - #include - -.. doxygenfunction:: solidSphereRand - -.. doxygenfunction:: hollowSphereRand - -.. doxygenfunction:: gaussSphereRand - -.. doxygenfunction:: gaussRand - -.. doxygenfunction:: erand48 - -.. doxygenfunction:: drand48 - -.. doxygenfunction:: nrand48 - -.. doxygenfunction:: lrand48 - -.. doxygenfunction:: srand48 - diff -Nru ilmbase-3.1.9-imath/docs/functions/roots.rst ilmbase-3.1.10/docs/functions/roots.rst --- ilmbase-3.1.9-imath/docs/functions/roots.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/roots.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,22 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _roots: - -Roots -##### - -Functions to compute roots of simple equations. - -.. code-block:: - - #include - -.. doxygenfunction:: solveLinear - -.. doxygenfunction:: solveQuadratic - -.. doxygenfunction:: solveNormalizedCubic - -.. doxygenfunction:: solveCubic diff -Nru ilmbase-3.1.9-imath/docs/functions/vec.rst ilmbase-3.1.10/docs/functions/vec.rst --- ilmbase-3.1.9-imath/docs/functions/vec.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions/vec.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,19 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _vector-functions: - -Vector Functions -################ - -.. code-block:: - - #include - -Functions that operate on vectors. - -.. doxygenfunction:: closestVertex(const Vec& v0, const Vec& v1, const Vec& v2, const Vec& p) noexcept - - - diff -Nru ilmbase-3.1.9-imath/docs/functions.rst ilmbase-3.1.10/docs/functions.rst --- ilmbase-3.1.9-imath/docs/functions.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/functions.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,24 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _Imath Functions: - -Imath Functions -############### - -.. toctree:: - :caption: Functions - :maxdepth: 3 - - functions/box - functions/color - functions/frame - functions/gl - functions/glu - functions/line - functions/matrix - functions/random - functions/roots - functions/vec - Binary files /tmp/tmprrmz8hd1/9jqJmQmhRl/ilmbase-3.1.9-imath/docs/images/imath-fav.ico and /tmp/tmprrmz8hd1/Ew6aKMySnx/ilmbase-3.1.10/docs/images/imath-fav.ico differ Binary files /tmp/tmprrmz8hd1/9jqJmQmhRl/ilmbase-3.1.9-imath/docs/images/imath-logo-black.png and /tmp/tmprrmz8hd1/Ew6aKMySnx/ilmbase-3.1.10/docs/images/imath-logo-black.png differ Binary files /tmp/tmprrmz8hd1/9jqJmQmhRl/ilmbase-3.1.9-imath/docs/images/imath-logo-blue.png and /tmp/tmprrmz8hd1/Ew6aKMySnx/ilmbase-3.1.10/docs/images/imath-logo-blue.png differ Binary files /tmp/tmprrmz8hd1/9jqJmQmhRl/ilmbase-3.1.9-imath/docs/images/imath-logo-white.png and /tmp/tmprrmz8hd1/Ew6aKMySnx/ilmbase-3.1.10/docs/images/imath-logo-white.png differ diff -Nru ilmbase-3.1.9-imath/docs/index.rst ilmbase-3.1.10/docs/index.rst --- ilmbase-3.1.9-imath/docs/index.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/index.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,77 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _Overview: - -Imath -##### - -.. toctree:: - :caption: Imath - :maxdepth: 1 - -Imath is a basic, light-weight, and efficient C++ representation of 2D -and 3D vectors, 2x2, 3x3, and 4x4 matrices, and other simple but useful -mathematical objects, functions, and data types common in computer -graphics applications, including the :doc:`classes/half` 16-bit floating-point -type. - -Imath also includes optional python bindings for all types and -functions, including optimized implementations of vector and matrix -arrays. - -Imath is maintained by the `OpenEXR project `_, a part of the `Academy -Software Foundation `_. - -Community -========= - -* **Ask a question:** - - - Email: `openexr-dev@lists.aswf.io `_ - - - Slack: `academysoftwarefdn#openexr `_ - -* **Attend a meeting:** - - - Technical Steering Committee meetings are open to the - public, fortnightly on Thursdays, 1:30pm Pacific Time. - - - Calendar: https://lists.aswf.io/g/openexr-dev/calendar - -* **Report a bug:** - - - Submit an Issue: https://github.com/AcademySoftwareFoundation/Imath/issues - -* **Report a security vulnerability:** - - - Email security@openexr.com - -* **Contribute a Fix, Feature, or Improvement:** - - - Read the `Contribution Guidelines - `_ - and `Code of Conduct `_ - - - Sign the `Contributor License Agreement - `_ - - - Submit a Pull Request: https://github.com/AcademySoftwareFoundation/Imath/pulls - -Resources -========= - -- Security policy: `SECURITY.md `_ -- Release notes: `CHANGES.md - `_ -- Contributors: `CONTRIBUTORS.md `_ -- Porting Guide: :doc:`PortingGuide` - -Index -===== - -:ref:`genindex` - -.. include:: toc_redirect.rst - diff -Nru ilmbase-3.1.9-imath/docs/install.rst ilmbase-3.1.10/docs/install.rst --- ilmbase-3.1.9-imath/docs/install.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/install.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,310 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _Install: - -Install -======== - -.. toctree:: - :caption: Install - -The Imath library is available for download and installation in -binary form via package managers on many Linux distributions. See -`https://pkgs.org/download/Imath -`_ for a complete list. The common -ones that generally provide current releases include: - -* `Fedora `_ -* `Gentoo `_ -* `Ubuntu `_ - -Beware that some distributions are out of date and only provide -distributions of outdated releases OpenEXR. We recommend against using -OpenEXR v2, and we *strongly* recommend against using OpenEXR v1. - -On macOS, we do not recommend installation via HomeBrew because the -distribution is outdated. - -Please note that ``pip install openexr`` installs the `openexrpython -`_ module, which is not -affiliated with the OpenEXR project or the ASWF. Please direct -questions there. - -Build from Source ------------------ - -Imath builds on Linux, macOS, Microsoft Windows via CMake, and is -cross-compilable on other systems. - -Download the source from the `GitHub releases page -`_ -page, or clone the `repo `_. - -The ``release`` branch of the repo always points to the most advanced -release. - - -Prerequisites -~~~~~~~~~~~~~ - -Make sure these are installed on your system before building Imath: - -* Imath requires CMake version 3.12 or newer -* C++ compiler that supports C++11 - -The instructions that follow describe building Imath with CMake. - -Linux/macOS -~~~~~~~~~~~ - -To build via CMake, you need to first identify three directories: - -1. The source directory, i.e. the top-level directory of the - downloaded source archive or cloned repo, referred to below as ``$srcdir`` -2. A temporary directory to hold the build artifacts, referred to below as - ``$builddir`` -3. A destination directory into which to install the - libraries and headers, referred to below as ``$installdir``. - -To build: -.. code-block:: - - $ cd $builddir - $ cmake $srcdir --install-prefix $installdir - $ cmake --build $builddir --target install --config Release - -Note that the CMake configuration prefers to apply an out-of-tree -build process, since there may be multiple build configurations -(i.e. debug and release), one per folder, all pointing at once source -tree, hence the ``$builddir`` noted above, referred to in CMake -parlance as the *build directory*. You can place this directory -wherever you like. - -See the CMake Configuration Options section below for the most common -configuration options especially the install directory. Note that with -no arguments, as above, ``make install`` installs the header files in -``/usr/local/include``, the object libraries in ``/usr/local/lib``, and the -executable programs in ``/usr/local/bin``. - -Windows -~~~~~~~ - -Under Windows, if you are using a command line-based setup, such as -cygwin, you can of course follow the above. For Visual Studio, cmake -generators are "multiple configuration", so you don't even have to set -the build type, although you will most likely need to specify the -install location. Install Directory By default, ``make install`` -installs the headers, libraries, and programs into ``/usr/local``, but you -can specify a local install directory to cmake via the -``CMAKE_INSTALL_PREFIX`` variable: - -.. code-block:: - - $ cmake .. -DCMAKE_INSTALL_PREFIX=$Imath_install_directory - -Library Names -------------- - -By default the installed libraries follow a pattern for how they are -named. This is done to enable multiple versions of the library to be -installed and targeted by different builds depending on the needs of -the project. A simple example of this would be to have different -versions of the library installed to allow for applications targeting -different VFX Platform years to co-exist. - -If you are building dynamic libraries, once you have configured, built, -and installed the libraries, you should see the following pattern of -symlinks and files in the install lib folder: - -.. code-block:: - - libImath.so -> libImath-3_1.so - libImath-3_1.so -> libImath-3_1.so.30 - libImath-3_1.so.30 -> libImath-3_1.so.30.3.0 - libImath-3_1.so.30.3.0 (the shared object file) - -The ``-3_1`` suffix encodes the major and minor version, which can be -configured via the ``IMATH_LIB_SUFFIX`` CMake setting. The ``30`` -corresponds to the so version, or in ``libtool`` terminology the -``current`` shared object version; the `3` denotes the ``libtool`` -``revision``, and the ``0`` denotes the ``libtool`` ``age``. See the -`libtool -`_ -documentation for more details. - -Porting Applications from OpenEXR v2 to v3 ------------------------------------------- - -See the :doc:`PortingGuide` for details about differences from previous -releases and how to address them. Also refer to the porting guide for -details about changes to Imath. - -Building the Documentation --------------------------- - -The Imath technical documentation at `https://imath.readthedocs.io -`_ is generated via `Sphinx -`_ with the `Breathe -`_ extension using information -extracted from header comments by `Doxygen `_. - -To build the documentation locally from the source headers and -``.rst`` files, set the CMake option ``BUILD_DOCS=ON``. This adds -``Doxygen`` and ``Sphinx`` CMake targets and enables building the docs -by default. generation is off by default. - -Building the documentation requires that ``sphinx``, ``breathe``, and -``doxygen`` are installed. It further requires the `sphinx-press-theme -`_, as indicated in the -`requirements.txt -`_ -file. - -CMake Build-time Configuration Options --------------------------------------- - -The default CMake configuration options are stored in -``cmake/ImathSetup.cmake``. To see a complete set of option -variables, run: - -.. code-block:: - - $ cmake -LAH $imath_source_directory - -You can customize these options three ways: - -1. Modify the ``.cmake`` files in place. -2. Use the UI ``cmake-gui`` or ``ccmake``. -3. Specify them as command-line arguments when you invoke cmake. - -Library Naming Options -~~~~~~~~~~~~~~~~~~~~~~ - -* ``IMATH_LIB_SUFFIX`` - - Append the given string to the end of all the Imath - libraries. Default is ``-_`` version string. Please - see the section on library names - -Imath Dependency -~~~~~~~~~~~~~~~~ - -* ``CMAKE_PREFIX_PATH`` - - The standard CMake path in which to - search for dependencies, Imath in particular. A comma-separated - path. Add the root directory where Imath is installed. - -Namespace Options -~~~~~~~~~~~~~~~~~ - -* ``IMATH_NAMESPACE`` - - Public namespace alias for Imath. Default is ``Imath``. - -* ``IMATH_INTERNAL_NAMESPACE`` - - Real namespace for Imath that will end up in compiled - symbols. Default is ``Imath__``. - -* ``IMATH_NAMESPACE_CUSTOM`` - - Whether the namespace has been customized (so external users know) - -Component Options -~~~~~~~~~~~~~~~~~ - -* ``BUILD_TESTING`` - - Build the testing tree. Default is ``ON``. Note that - this causes the test suite to be compiled, but it is not - executed. To execute the suite, run "make test". - -Additional CMake Options -~~~~~~~~~~~~~~~~~~~~~~~~ - -See the CMake documentation for more information (https://cmake.org/cmake/help/v3.12/). - -* ``CMAKE_BUILD_TYPE`` - - For builds when not using a multi-configuration generator. Available - values: ``Debug``, ``Release``, ``RelWithDebInfo``, ``MinSizeRel`` - -* ``BUILD_SHARED_LIBS`` - - This is the primary control whether to build static libraries or - shared libraries / dlls (side note: technically a convention, hence - not an official ``CMAKE_`` variable, it is defined within cmake and - used everywhere to control this static / shared behavior) - -* ``IMATH_CXX_STANDARD`` - - C++ standard to compile against. This obeys the global - ``CMAKE_CXX_STANDARD`` but doesn’t force the global setting to - enable sub-project inclusion. Default is ``14``. - -* ``CMAKE_CXX_COMPILER`` - - The C++ compiler. - -* ``CMAKE_C_COMPILER`` - - The C compiler. - -* ``CMAKE_INSTALL_RPATH`` - - For non-standard install locations where you don’t want to have to - set ``LD_LIBRARY_PATH`` to use them - -* ``CMAKE_EXPORT_COMPILE_COMMANDS`` - - Enable/Disable output of compile commands during generation. Default - is ``OFF``. - -* ``CMAKE_VERBOSE_MAKEFILE`` - - Echo all compile commands during make. Default is ``OFF``. - -Cross Compiling / Specifying Specific Compilers ------------------------------------------------ - -When trying to either cross-compile for a different platform, or for -tasks such as specifying a compiler set to match the `VFX reference -platform `_, cmake provides the idea of a -toolchain which may be useful instead of having to remember a chain of -configuration options. It also means that platform-specific compiler -names and options are out of the main cmake file, providing better -isolation. - -A toolchain file is simply just a cmake script that sets all the -compiler and related flags and is run very early in the configuration -step to be able to set all the compiler options and such for the -discovery that cmake performs automatically. These options can be set -on the command line still if that is clearer, but a theoretical -toolchain file for compiling for VFX Platform 2015 is provided in the -source tree at ``cmake/Toolchain-Linux-VFX_Platform15.cmake`` which -will hopefully provide a guide how this might work. - -For cross-compiling for additional platforms, there is also an -included sample script in ``cmake/Toolchain-mingw.cmake`` which shows -how cross compiling from Linux for Windows may work. The compiler -names and paths may need to be changed for your environment. - -More documentation: - -* Toolchains: https://cmake.org/cmake/help/v3.12/manual/cmake-toolchains.7.html -* Cross compiling: https://gitlab.kitware.com/cmake/community/wikis/doc/cmake/ - -Ninja ------ - -If you have `Ninja `_ installed, it is faster -than make. You can generate ninja files using cmake when doing the -initial generation: - -.. code-block:: - - $ cmake -G “Ninja” .. - diff -Nru ilmbase-3.1.9-imath/docs/license.rst ilmbase-3.1.10/docs/license.rst --- ilmbase-3.1.9-imath/docs/license.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/license.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,33 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. _License: - -License -======= - -.. toctree:: - :caption: License - -Imath is licensed under the BSD-3-Clause license. Contributions to the -library should abide by that license unless otherwised approved by the OpenEXR -TSC and ASWF Governing Board. - -See `LICENSE.md -`__ -on GitHub. - -Copyright (c) Contributors to the OpenEXR Project. All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - - diff -Nru ilmbase-3.1.9-imath/docs/requirements.txt ilmbase-3.1.10/docs/requirements.txt --- ilmbase-3.1.9-imath/docs/requirements.txt 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/requirements.txt 1970-01-01 00:00:00.000000000 +0000 @@ -1,3 +0,0 @@ -sphinx == 4.4.0 -breathe -sphinx-press-theme diff -Nru ilmbase-3.1.9-imath/docs/toc_redirect.rst ilmbase-3.1.10/docs/toc_redirect.rst --- ilmbase-3.1.9-imath/docs/toc_redirect.rst 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/docs/toc_redirect.rst 1970-01-01 00:00:00.000000000 +0000 @@ -1,38 +0,0 @@ -.. - SPDX-License-Identifier: BSD-3-Clause - Copyright Contributors to the OpenEXR Project. - -.. toctree:: - :hidden: - - concepts - -.. toctree:: - :hidden: - - classes - -.. toctree:: - :hidden: - - functions - -.. toctree:: - :hidden: - - install - -.. toctree:: - :hidden: - - license - -.. toctree:: - :hidden: - - about - - - - - diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/linux/install_boost.sh ilmbase-3.1.10/share/ci/scripts/linux/install_boost.sh --- ilmbase-3.1.9-imath/share/ci/scripts/linux/install_boost.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/linux/install_boost.sh 2024-01-24 22:14:50.000000000 +0000 @@ -1,5 +1,8 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + set -ex BOOST_VERSION="$1" diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/linux/install_cmake.sh ilmbase-3.1.10/share/ci/scripts/linux/install_cmake.sh --- ilmbase-3.1.9-imath/share/ci/scripts/linux/install_cmake.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/linux/install_cmake.sh 2024-01-24 22:14:50.000000000 +0000 @@ -1,5 +1,8 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + set -ex echo "Updating to newer cmake to enable python-3" diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/linux/install_gdb.sh ilmbase-3.1.10/share/ci/scripts/linux/install_gdb.sh --- ilmbase-3.1.9-imath/share/ci/scripts/linux/install_gdb.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/linux/install_gdb.sh 2024-01-24 22:14:50.000000000 +0000 @@ -1,5 +1,8 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + set -ex GDB_VERSION="8.3" diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/linux/install_six.sh ilmbase-3.1.10/share/ci/scripts/linux/install_six.sh --- ilmbase-3.1.9-imath/share/ci/scripts/linux/install_six.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/linux/install_six.sh 2024-01-24 22:14:50.000000000 +0000 @@ -1,5 +1,8 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + set -ex SIX_VERSION="1.12.0" diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/linux/install_sonar.sh ilmbase-3.1.10/share/ci/scripts/linux/install_sonar.sh --- ilmbase-3.1.9-imath/share/ci/scripts/linux/install_sonar.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/linux/install_sonar.sh 2024-01-24 22:14:50.000000000 +0000 @@ -1,5 +1,8 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + set -ex SONAR_VERSION="$1" diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/linux/install_valgrind.sh ilmbase-3.1.10/share/ci/scripts/linux/install_valgrind.sh --- ilmbase-3.1.9-imath/share/ci/scripts/linux/install_valgrind.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/linux/install_valgrind.sh 2024-01-24 22:14:50.000000000 +0000 @@ -1,5 +1,8 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + set -ex VALGRIND_VERSION="3.15.0" diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/linux/log_valgrind.sh ilmbase-3.1.10/share/ci/scripts/linux/log_valgrind.sh --- ilmbase-3.1.9-imath/share/ci/scripts/linux/log_valgrind.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/linux/log_valgrind.sh 2024-01-24 22:14:50.000000000 +0000 @@ -1,5 +1,8 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + set -ex LOGDIR="$1" diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/linux/run_gcov.sh ilmbase-3.1.10/share/ci/scripts/linux/run_gcov.sh --- ilmbase-3.1.9-imath/share/ci/scripts/linux/run_gcov.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/linux/run_gcov.sh 2024-01-24 22:14:50.000000000 +0000 @@ -3,6 +3,9 @@ # SPDX-License-Identifier: BSD-3-Clause # Copyright (c) Contributors to the OpenEXR Project. +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + set -ex if [ $# -gt 0 ] diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/macos/install_python.sh ilmbase-3.1.10/share/ci/scripts/macos/install_python.sh --- ilmbase-3.1.9-imath/share/ci/scripts/macos/install_python.sh 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/macos/install_python.sh 2024-01-24 22:14:50.000000000 +0000 @@ -1,5 +1,8 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + set -ex PYTHON_VERSION="$1" diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/windows/install_boost.ps1 ilmbase-3.1.10/share/ci/scripts/windows/install_boost.ps1 --- ilmbase-3.1.9-imath/share/ci/scripts/windows/install_boost.ps1 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/windows/install_boost.ps1 2024-01-24 22:14:50.000000000 +0000 @@ -1,3 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + # # TODO: fix this script to work with sourceforge archive! # diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/windows/install_cmake.ps1 ilmbase-3.1.10/share/ci/scripts/windows/install_cmake.ps1 --- ilmbase-3.1.9-imath/share/ci/scripts/windows/install_cmake.ps1 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/windows/install_cmake.ps1 2024-01-24 22:14:50.000000000 +0000 @@ -1,3 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + $cmakeVersion = $Args[0] $cmakeMajorMinor = [io.path]::GetFileNameWithoutExtension("$cmakeVersion") diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/windows/install_python.ps1 ilmbase-3.1.10/share/ci/scripts/windows/install_python.ps1 --- ilmbase-3.1.9-imath/share/ci/scripts/windows/install_python.ps1 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/windows/install_python.ps1 2024-01-24 22:14:50.000000000 +0000 @@ -1,3 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + $homeDir = (pwd) $pythonVersion = $Args[0] diff -Nru ilmbase-3.1.9-imath/share/ci/scripts/windows/install_zlib.ps1 ilmbase-3.1.10/share/ci/scripts/windows/install_zlib.ps1 --- ilmbase-3.1.9-imath/share/ci/scripts/windows/install_zlib.ps1 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/share/ci/scripts/windows/install_zlib.ps1 1970-01-01 00:00:00.000000000 +0000 @@ -1,36 +0,0 @@ -$homeDir = (pwd) - -$zlibVersion = $Args[0] -$zlibWorkingDir = $Args[1] - -$zlibMajorMinor = [io.path]::GetFileNameWithoutExtension("$zlibVersion") -$zlibVersionConcise = $zlibVersion -replace '[.]','' -$zlibArchive = "https://www.zlib.net/zlib${zlibVersionConcise}.zip" - -$zlibRoot = "${zlibWorkingDir}\_zlib" -$zlibBuildPath = "${zlibWorkingDir}\zlib-${zlibVersion}" -$zlibDllPath = "${zlibRoot}\bin" -$msbuild = "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\Bin\msbuild.exe" - -Write-Host "Retrieving ${zlibArchive}" -Invoke-WebRequest "${zlibArchive}" -OutFile "${zlibBuildPath}.zip" -Write-Host "Expanding archive ${zlibBuildPath}.zip" -Expand-Archive "${zlibBuildPath}.zip" -DestinationPath "${zlibWorkingDir}" - -if (-NOT (Test-Path $zlibRoot)) -{ - New-Item -ItemType Directory $zlibRoot -} - -cd $zlibBuildPath -mkdir _build -cd _build -cmake .. -G"Visual Studio 16 2019" -DCMAKE_INSTALL_PREFIX="${zlibRoot}" - -Write-Host "Building ${zlibBuildPath}\_build\INSTALL.vcxproj" -foregroundcolor green -& "${msbuild}" "${zlibBuildPath}\_build\INSTALL.vcxproj" /P:Configuration=Release - -cd $homeDir - -echo "::set-env name=ZLIB_ROOT::$zlibRoot" -echo "::add-path::$zlibDllPath" diff -Nru ilmbase-3.1.9-imath/src/Imath/ImathFun.cpp ilmbase-3.1.10/src/Imath/ImathFun.cpp --- ilmbase-3.1.9-imath/src/Imath/ImathFun.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/Imath/ImathFun.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -4,159 +4,32 @@ // #include "ImathFun.h" +#include IMATH_INTERNAL_NAMESPACE_SOURCE_ENTER -float -succf (float f) IMATH_NOEXCEPT +float succf(float f) IMATH_NOEXCEPT { - union - { - float f; - uint32_t i; - } u; - u.f = f; - - if (isinf(f) || isnan (f)) - { - // Nan or infinity; don't change value. - } - else if (u.i == 0x00000000 || u.i == 0x80000000) - { - // Plus or minus zero. - - u.i = 0x00000001; - } - else if (u.f > 0) - { - // Positive float, normalized or denormalized. - // Incrementing the largest positive float - // produces +infinity. - - ++u.i; - } - else - { - // Negative normalized or denormalized float. - - --u.i; - } - - return u.f; + return isfinite(f) ? + std::nextafter(f, std::numeric_limits::infinity()) : f; } -float -predf (float f) IMATH_NOEXCEPT +float predf(float f) IMATH_NOEXCEPT { - union - { - float f; - uint32_t i; - } u; - u.f = f; - - if (isinf(f) || isnan (f)) - { - // Nan or infinity; don't change value. - } - else if (u.i == 0x00000000 || u.i == 0x80000000) - { - // Plus or minus zero. - - u.i = 0x80000001; - } - else if (u.f > 0) - { - // Positive float, normalized or denormalized. - - --u.i; - } - else - { - // Negative normalized or denormalized float. - // Decrementing the largest negative float - // produces -infinity. - - ++u.i; - } - - return u.f; + return isfinite(f) ? + std::nextafter(f, -std::numeric_limits::infinity()) : f; } -double -succd (double d) IMATH_NOEXCEPT +double succd(double d) IMATH_NOEXCEPT { - union - { - double d; - uint64_t i; - } u; - u.d = d; - - if (isinf(d) || isnan (d)) - { - // Nan or infinity; don't change value. - } - else if (u.i == 0x0000000000000000LL || u.i == 0x8000000000000000LL) - { - // Plus or minus zero. - - u.i = 0x0000000000000001LL; - } - else if (u.d > 0) - { - // Positive double, normalized or denormalized. - // Incrementing the largest positive double - // produces +infinity. - - ++u.i; - } - else - { - // Negative normalized or denormalized double. - - --u.i; - } - - return u.d; + return isfinite(d) ? + std::nextafter(d, std::numeric_limits::infinity()) : d; } -double -predd (double d) IMATH_NOEXCEPT +double predd(double d) IMATH_NOEXCEPT { - union - { - double d; - uint64_t i; - } u; - u.d = d; - - if ((u.i & 0x7ff0000000000000LL) == 0x7ff0000000000000LL) - { - // Nan or infinity; don't change value. - } - else if (u.i == 0x0000000000000000LL || u.i == 0x8000000000000000LL) - { - // Plus or minus zero. - - u.i = 0x8000000000000001LL; - } - else if (u.d > 0) - { - // Positive double, normalized or denormalized. - - --u.i; - } - else - { - // Negative normalized or denormalized double. - // Decrementing the largest negative double - // produces -infinity. - - ++u.i; - } - - return u.d; + return isfinite(d) ? + std::nextafter(d, -std::numeric_limits::infinity()) : d; } IMATH_INTERNAL_NAMESPACE_SOURCE_EXIT diff -Nru ilmbase-3.1.9-imath/src/Imath/ImathMatrix.h ilmbase-3.1.10/src/Imath/ImathMatrix.h --- ilmbase-3.1.9-imath/src/Imath/ImathMatrix.h 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/Imath/ImathMatrix.h 2024-01-24 22:14:50.000000000 +0000 @@ -4782,7 +4782,7 @@ template IMATH_HOSTDEVICE inline Vec3 -IMATH_HOSTDEVICE operator* (const Vec3& v, const Matrix44& m) IMATH_NOEXCEPT +operator* (const Vec3& v, const Matrix44& m) IMATH_NOEXCEPT { S x = S (v.x * m.x[0][0] + v.y * m.x[1][0] + v.z * m.x[2][0] + m.x[3][0]); S y = S (v.x * m.x[0][1] + v.y * m.x[1][1] + v.z * m.x[2][1] + m.x[3][1]); @@ -4794,7 +4794,7 @@ template IMATH_HOSTDEVICE inline const Vec4& -IMATH_HOSTDEVICE operator*= (Vec4& v, const Matrix44& m) IMATH_NOEXCEPT +operator*= (Vec4& v, const Matrix44& m) IMATH_NOEXCEPT { S x = S (v.x * m.x[0][0] + v.y * m.x[1][0] + v.z * m.x[2][0] + v.w * m.x[3][0]); S y = S (v.x * m.x[0][1] + v.y * m.x[1][1] + v.z * m.x[2][1] + v.w * m.x[3][1]); @@ -4811,7 +4811,7 @@ template IMATH_HOSTDEVICE inline Vec4 -IMATH_HOSTDEVICE operator* (const Vec4& v, const Matrix44& m) IMATH_NOEXCEPT +operator* (const Vec4& v, const Matrix44& m) IMATH_NOEXCEPT { S x = S (v.x * m.x[0][0] + v.y * m.x[1][0] + v.z * m.x[2][0] + v.w * m.x[3][0]); S y = S (v.x * m.x[0][1] + v.y * m.x[1][1] + v.z * m.x[2][1] + v.w * m.x[3][1]); diff -Nru ilmbase-3.1.9-imath/src/Imath/ImathTypeTraits.h ilmbase-3.1.10/src/Imath/ImathTypeTraits.h --- ilmbase-3.1.9-imath/src/Imath/ImathTypeTraits.h 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/Imath/ImathTypeTraits.h 2024-01-24 22:14:50.000000000 +0000 @@ -86,10 +86,11 @@ typedef char No[2]; // Valid only if .x, .y exist and are the right type: return a Yes. - template::value), - IMATH_ENABLE_IF(std::is_same::value)> - static Yes& test(int); + template < + typename C, + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value)> + static Yes& test (int); // Fallback, default to returning a No. template static No& test(...); @@ -110,11 +111,12 @@ typedef char No[2]; // Valid only if .x, .y, .z exist and are the right type: return a Yes. - template::value), - IMATH_ENABLE_IF(std::is_same::value), - IMATH_ENABLE_IF(std::is_same::value)> - static Yes& test(int); + template < + typename C, + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value)> + static Yes& test (int); // Fallback, default to returning a No. template static No& test(...); @@ -135,12 +137,13 @@ typedef char No[2]; // Valid only if .x, .y, .z, .w exist and are the right type: return a Yes. - template::value), - IMATH_ENABLE_IF(std::is_same::value), - IMATH_ENABLE_IF(std::is_same::value), - IMATH_ENABLE_IF(std::is_same::value)> - static Yes& test(int); + template < + typename C, + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value)> + static Yes& test (int); // Fallback, default to returning a No. template static No& test(...); @@ -162,9 +165,12 @@ typedef char No[2]; // Valid only if T[] is possible and is the right type: return a Yes. - template::type, Base>::value)> - static Yes& test(int); + template < + typename C, + IMATH_ENABLE_IF (std::is_same< + typename std::decay::type, + Base>::value)> + static Yes& test (int); // Fallback, default to returning a No. template static No& test(...); @@ -191,9 +197,12 @@ typedef char No[2]; // Valid only if T[][] is possible and is the right type: return a Yes. - template::type, Base>::value)> - static Yes& test(int); + template < + typename C, + IMATH_ENABLE_IF (std::is_same< + typename std::decay::type, + Base>::value)> + static Yes& test (int); // Fallback, default to returning a No. template static No& test(...); diff -Nru ilmbase-3.1.9-imath/src/Imath/half.h ilmbase-3.1.10/src/Imath/half.h --- ilmbase-3.1.9-imath/src/Imath/half.h 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/Imath/half.h 2024-01-24 22:14:50.000000000 +0000 @@ -327,8 +327,14 @@ // other compilers may provide count-leading-zeros primitives, // but we need the community to inform us of the variants uint32_t lc; -# if defined(_MSC_VER) && (_M_IX86 || _M_X64) - lc = __lzcnt (hexpmant); +# if defined(_MSC_VER) + // The direct intrinsic for this is __lznct, but that is not supported + // on older x86_64 hardware or ARM. Instead uses the bsr instruction + // and one additional subtraction. This assumes hexpmant != 0, for 0 + // bsr and lznct would behave differently. + unsigned long bsr; + _BitScanReverse (&bsr, hexpmant); + lc = (31 - bsr); # elif defined(__GNUC__) || defined(__clang__) lc = (uint32_t) __builtin_clz (hexpmant); # else diff -Nru ilmbase-3.1.9-imath/src/ImathTest/testFun.cpp ilmbase-3.1.10/src/ImathTest/testFun.cpp --- ilmbase-3.1.9-imath/src/ImathTest/testFun.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/ImathTest/testFun.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -8,7 +8,7 @@ #endif #include -#if __cplusplus >= 202002L +#if defined(__cpp_lib_bit_cast) && __cpp_lib_bit_cast >= 201806L # include #endif #include @@ -20,20 +20,20 @@ using namespace std; -#if __cplusplus < 202002L - template - static inline To - bit_cast (From from) +#if !defined(__cpp_lib_bit_cast) || __cpp_lib_bit_cast < 201806L +template +static inline To +bit_cast (From from) +{ + static_assert (sizeof (From) == sizeof (To), "Type sizes do not match"); + union { - static_assert (sizeof (From) == sizeof (To), "Type sizes do not match"); - union - { - From f; - To t; - } u; - u.f = from; - return u.t; - } + From f; + To t; + } u; + u.f = from; + return u.t; +} #endif void diff -Nru ilmbase-3.1.9-imath/src/python/PyImath/PyImathStringTable.cpp ilmbase-3.1.10/src/python/PyImath/PyImathStringTable.cpp --- ilmbase-3.1.9-imath/src/python/PyImath/PyImathStringTable.cpp 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/python/PyImath/PyImathStringTable.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -89,8 +89,8 @@ } namespace { -template class PYIMATH_EXPORT StringTableDetailT; -template class PYIMATH_EXPORT StringTableDetailT; +template class StringTableDetailT; +template class StringTableDetailT; } template class PYIMATH_EXPORT StringTableT; diff -Nru ilmbase-3.1.9-imath/src/python/PyImath/PyImathUtil.h ilmbase-3.1.10/src/python/PyImath/PyImathUtil.h --- ilmbase-3.1.9-imath/src/python/PyImath/PyImathUtil.h 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/python/PyImath/PyImathUtil.h 2024-01-24 22:14:50.000000000 +0000 @@ -40,10 +40,10 @@ PYIMATH_EXPORT PyAcquireLock(); PYIMATH_EXPORT ~PyAcquireLock(); - PYIMATH_EXPORT PyAcquireLock(const PyAcquireLock& other) = delete; - PYIMATH_EXPORT PyAcquireLock & operator = (PyAcquireLock& other) = delete; - PYIMATH_EXPORT PyAcquireLock(PyAcquireLock&& other) = delete; - PYIMATH_EXPORT PyAcquireLock & operator = (PyAcquireLock&& other) = delete; + PyAcquireLock(const PyAcquireLock& other) = delete; + PyAcquireLock & operator = (PyAcquireLock& other) = delete; + PyAcquireLock(PyAcquireLock&& other) = delete; + PyAcquireLock & operator = (PyAcquireLock&& other) = delete; private: PyGILState_STATE _gstate; @@ -64,10 +64,10 @@ public: PYIMATH_EXPORT PyReleaseLock(); PYIMATH_EXPORT ~PyReleaseLock(); - PYIMATH_EXPORT PyReleaseLock(const PyReleaseLock& other) = delete; - PYIMATH_EXPORT PyReleaseLock & operator = (PyReleaseLock& other) = delete; - PYIMATH_EXPORT PyReleaseLock(PyReleaseLock&& other) = delete; - PYIMATH_EXPORT PyReleaseLock & operator = (PyReleaseLock&& other) = delete; + PyReleaseLock(const PyReleaseLock& other) = delete; + PyReleaseLock & operator = (PyReleaseLock& other) = delete; + PyReleaseLock(PyReleaseLock&& other) = delete; + PyReleaseLock & operator = (PyReleaseLock&& other) = delete; private: PyThreadState *_save; diff -Nru ilmbase-3.1.9-imath/src/python/PyImathTest/pyImathTest.in ilmbase-3.1.10/src/python/PyImathTest/pyImathTest.in --- ilmbase-3.1.9-imath/src/python/PyImathTest/pyImathTest.in 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/python/PyImathTest/pyImathTest.in 2024-01-24 22:14:50.000000000 +0000 @@ -6137,7 +6137,7 @@ b = m.extractSHRT(sInq, hInq, rInq, tInq) - assert sInq.equalWithAbsError(s, sInq.baseTypeEpsilon()) + assert sInq.equalWithAbsError(s, 2 * sInq.baseTypeEpsilon()) assert hInq.equalWithAbsError(h, hInq.baseTypeEpsilon()) assert rInq.equalWithAbsError((0, 0, -a), 2 * rInq.baseTypeEpsilon()) assert tInq.equalWithAbsError(t, tInq.baseTypeEpsilon()) diff -Nru ilmbase-3.1.9-imath/src/python/PyImathTest/testStringTable.h ilmbase-3.1.10/src/python/PyImathTest/testStringTable.h --- ilmbase-3.1.9-imath/src/python/PyImathTest/testStringTable.h 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/python/PyImathTest/testStringTable.h 2024-01-24 22:14:50.000000000 +0000 @@ -1,2 +1,7 @@ +// +// SPDX-License-Identifier: BSD-3-Clause +// Copyright Contributors to the OpenEXR Project. +// + void testStringTable(); diff -Nru ilmbase-3.1.9-imath/src/python/config/ModuleDefine.cmake ilmbase-3.1.10/src/python/config/ModuleDefine.cmake --- ilmbase-3.1.9-imath/src/python/config/ModuleDefine.cmake 2023-05-31 17:31:18.000000000 +0000 +++ ilmbase-3.1.10/src/python/config/ModuleDefine.cmake 2024-01-24 22:14:50.000000000 +0000 @@ -52,7 +52,6 @@ add_library(${PROJECT_NAME}::${libname} ALIAS ${libname}) install(TARGETS ${libname} - EXPORT ${PROJECT_NAME} RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} diff -Nru ilmbase-3.1.9-imath/website/CMakeLists.txt ilmbase-3.1.10/website/CMakeLists.txt --- ilmbase-3.1.9-imath/website/CMakeLists.txt 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/CMakeLists.txt 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,42 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright Contributors to the OpenEXR Project. + +set(CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH}) + +find_package(Doxygen REQUIRED) +find_package(Sphinx REQUIRED) + +set(DOXYGEN_INPUT_DIR ${PROJECT_SOURCE_DIR}/src/Imath) +set(DOXYGEN_OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR}/doxygen) +set(DOXYGEN_INDEX_FILE ${DOXYGEN_OUTPUT_DIR}/html/index.html) +set(DOXYFILE_IN ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in) +set(DOXYFILE_OUT ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile) + +set(SPHINX_SOURCE ${CMAKE_CURRENT_SOURCE_DIR}) +set(SPHINX_BUILD ${CMAKE_CURRENT_BINARY_DIR}/sphinx) +set(SPHINX_INDEX_FILE ${SPHINX_BUILD}/index.html) + +configure_file(${DOXYFILE_IN} ${DOXYFILE_OUT} @ONLY) + +file(MAKE_DIRECTORY ${DOXYGEN_OUTPUT_DIR}) + +add_custom_command(OUTPUT ${DOXYGEN_INDEX_FILE} + COMMAND ${DOXYGEN_EXECUTABLE} ${DOXYFILE_OUT} + COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/fixmanpages.sh ${DOXYGEN_OUTPUT_DIR} + MAIN_DEPENDENCY ${DOXYFILE_OUT} ${DOXYFILE_IN} + COMMENT "Running doxygen" + VERBATIM) + +add_custom_command(OUTPUT ${SPHINX_INDEX_FILE} + COMMAND + ${SPHINX_EXECUTABLE} -b html + # Tell Breathe where to find the Doxygen output + -Dbreathe_projects.Imath=${DOXYGEN_OUTPUT_DIR}/xml + ${SPHINX_SOURCE} ${SPHINX_BUILD} + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} + DEPENDS ${DOXYGEN_INDEX_FILE} + MAIN_DEPENDENCY conf.py + COMMENT "Generating documentation with Sphinx") + +add_custom_target(website ALL DEPENDS ${SPHINX_INDEX_FILE} ${DOXYGEN_INDEX_FILE}) + diff -Nru ilmbase-3.1.9-imath/website/Doxyfile.in ilmbase-3.1.10/website/Doxyfile.in --- ilmbase-3.1.9-imath/website/Doxyfile.in 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/Doxyfile.in 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,33 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright Contributors to the OpenEXR Project. + +PROJECT_NAME = "Imath" +GENERATE_LATEX = NO +GENERATE_MAN = NO +GENERATE_RTF = NO +CASE_SENSE_NAMES = NO +INPUT = "@DOXYGEN_INPUT_DIR@" +OUTPUT_DIRECTORY = "@DOXYGEN_OUTPUT_DIR@" +RECURSIVE = YES +QUIET = YES +JAVADOC_AUTOBRIEF = YES +GENERATE_HTML = NO +GENERATE_XML = YES +DISTRIBUTE_GROUP_DOC = YES +MACRO_EXPANSION = YES +ENABLE_PREPROCESSING = YES +WARN_IF_UNDOCUMENTED = NO +PREDEFINED = IMATH_CONSTEXPR14=constexpr \ + IMATH_HOSTDEVICE= \ + IMATH_INTERNAL_NAMESPACE=Imath \ + IMATH_INTERNAL_NAMESPACE_SOURCE_ENTER="namespace Imath {" \ + IMATH_INTERNAL_NAMESPACE_SOURCE_EXIT="}" \ + IMATH_INTERNAL_NAMESPACE_HEADER_ENTER="namespace Imath {" \ + IMATH_INTERNAL_NAMESPACE_HEADER_EXIT="}" \ + IMATH_NOEXCEPT="noexcept" \ + IMATH_EXPORT="" \ + IMATH_EXPORT_ENUM= \ + IMATH_EXPORT_TYPE= \ + IMATH_EXPORT_TEMPLATE_TYPE= \ + imath_half_bits_t=half \ + __cplusplus=1 diff -Nru ilmbase-3.1.9-imath/website/PortingGuide.rst ilmbase-3.1.10/website/PortingGuide.rst --- ilmbase-3.1.9-imath/website/PortingGuide.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/PortingGuide.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,607 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +:orphan: + +.. _porting: + +OpenEXR/Imath 2.x to 3.x Porting Guide +###################################### + +This porting guide outlines the several areas where switching from OpenEXR +2.x to OpenEXR 3.x + Imath 3.x will require source code or build changes of +downstream software. + +In each case, we will often explain both how to change if you are expecting +3.x only hereafter, or usually a more complex accommodation if you want to +keep compatibility with both 2.x and 3.x. + +OpenEXR and Imath Are Different Packages +======================================== + +If your use of OpenEXR was only for the sake of using the math classes and +utilities, maybe you were unhappy that you needed to download and build the +full OpenEXR dependency. You are in luck -- now Imath is a separate, very +lightweight open source package. You can use Imath functionality without +needing any of OpenEXR, which as of 3.x only includes the parts you need to +read and write OpenEXR image files. + +The parts of "IlmBase" that were ``Imath`` and ``half`` are now repackaged +as the ``Imath`` library. The ``IlmThread`` and ``Iex`` libraries have been +folded into the OpenEXR package, since they were were not necessary to +the rest of Imath. + +When building OpenEXR 3.x, note that if Imath 3.x library is not found +already installed at build time, it will be automatically downloaded and +built as part of the OpenEXR build. + +Background +========== + +Why is this happening? Here is the relevant history. + +The OpenEXR project has historically consisted of four separate subprojects: + +* ``OpenEXR`` - the Imf image format +* ``IlmBase`` - supporting utilities (Imath, Half, Iex, IlmThread) +* ``PyIlmBase`` - python bindings for the IlmBase libraries +* ``OpenEXR_Viewers`` - code for an example EXR image viewer + +Prior to the 2.4 release in 2019, OpenEXR relied primarily on the Gnu +autotools build system and was released as four separate tarballs +(ilmbase, pyilmbase, openexr, openexr_viewers) that were constructed +via the Gnu tools. This gave direct access to the "IlmBase" libraries +independent of the OpenEXR format library. The project also included +CMake files but CMake support was incomplete. + +With the adoption of OpenEXR by the Academy Software Foundation in +2019, the technical steering committee made several key changes: + +1. Drop support for autotools in favor of CMake. A significant portion + of the OpenEXR user base uses Windows, which the Gnu autotools does + not support. Supporting two build systems is a maintenance burden + that the TSC opted to avoid. We now assume that all modern users of + OpenEXR can reasonably be expected to rely on CMake. + +2. Rely on GitHub's automatic release packaging mechanism. This + packages the entire contents of package in a single + tarball. Separate tarballs are no longer generated by the Gnu + autotools setup. + +3. Deprecate the OpenEXR_Viewers code. It was impossibly out of date + and of little modern value. + +Thus, with the 2.4 release, the "IlmBase" libraries are no longer +distributed in a form that is readily separable from the rest of +OpenEXR. The build and installation process for the overall OpenEXR +project is complicated by the fact it consists of four separate +projects, which added significant complexity to the CMake setup. + +Because Imath is generally useful to the community, the TSC decided to +simplify the configuration by separating Imath into its own independent +project, maintained and released independently of OpenEXR, and +introducing it as a new external dependency of OpenEXR. + +To further simplify matters, the new Imath library includes the half +data type directly, rather than maintaining it in a separate +library. Also, the community at large has a strong desire for simple +vector/matrix utilities that are unencumbered by Iex, the IlmBase +library that provides higher-level exception classes, and even +further, a clear delineation between functionality that (1) relies on +exception handlings and (2) is free from exceptions. As a result, +support for Iex has been removed from Imath, and the Iex library is +now packaged as a component of OpenEXR. + +The Imath python bindings are a part of Imath as a configuration +option, although support is off by default to simplify the build process +for most users. + +New Library Names and Repository Structures +=========================================== + +The new repositories place all source code under the ``src`` top-level +subdirectory. + +Imath: +------ + +.. code-block:: + + src + ├── Imath + ├── ImathTest + └── python + ├── config + ├── PyImath + ├── PyImathNumpy + ├── PyImathTest + ├── PyImathNumpyTest + └── PyImathSpeedTest + + +OpenEXR: +-------- + +The ``IlmImf`` library has been renamed ``OpenEXR``. No header files have +changed names, only their locations in the repo have changes. + +.. code-block:: + + src + ├── bin + │ ├── exr2aces + │ ├── exrbuild + │ ├── exrcheck + │ ├── exrenvmap + │ ├── exrheader + │ ├── exrmakepreview + │ ├── exrmaketiled + │ ├── exrmultipart + │ ├── exrmultiview + │ └── exrstdattr + ├── lib + │ ├── Iex + │ ├── IexMath + │ ├── IlmThread + │ ├── OpenEXR + │ └── OpenEXRUtil + ├── examples + └── test + ├── IexTest + ├── OpenEXRTest + ├── OpenEXRUtilTest + └── OpenEXRFuzzTest + + +Finding and Using OpenEXR and Imath CMake Configs +================================================= + +OpenEXR/Imath 3.x Only +---------------------- + +If you are *only* concerned with OpenEXR/Imath 3.x going forward, this is +the recommended way to find the libraries in a downstream project that uses +the CMake build system: + +.. code-block:: + + find_package(Imath CONFIG) + find_package(OpenEXR CONFIG) + +Note that the second line may be omitted if you only need the Imath +portions. + +And then your project can reference the imported targets like this: + +.. code-block:: + + target_link_libraries (my_target + PRIVATE + OpenEXR::OpenEXR + Imath::Imath + Imath::Half + ) + +You only need the parts you use, so for example, if you only need Half and +Imath, you can omit the OpenEXR target. Also note that in our example above, +we have used the ``PRIVATE`` label, but you should specify them as ``PUBLIC`` if +you are exposing those classes in your own package's public interface. + + +Accommodating OpenEXR/Imath 3.x or OpenEXR 2.x +---------------------------------------------- + +On the other hand, to accommodate both 2.x and 3.x, it's admittedly +inconvenient because the packages and the import targets have changed their +names. We have found the following idioms to work: + +Finding either/both packages: + +.. code-block:: + + # First, try to find just the right config files + find_package(Imath CONFIG) + if (NOT TARGET Imath::Imath) + # Couldn't find Imath::Imath, maybe it's older and has IlmBase? + find_package(IlmBase CONFIG) + endif () + find_package(OpenEXR CONFIG) + +To link against them, we use CMake generator expressions so that we can +reference *both* sets of targets, but it will only use the ones +corresponding to the package version that was found. + +.. code-block:: + + target_link_libraries (my_target + PRIVATE + # For OpenEXR/Imath 3.x: + $<$:OpenEXR::OpenEXR> + $<$:Imath::Imath> + $<$:Imath::Half> + # For OpenEXR 2.4/2.5: + $<$:OpenEXR::IlmImf> + $<$:IlmBase::Imath> + $<$:IlmBase::Half> + $<$:IlmBase::IlmThread> + $<$:IlmBase::Iex> + ) + +Again, you can eliminate the references to any of the individual libaries +that you don't actually need for your application. + +Simultaneous Static/Shared Build +-------------------------------- + +The OpenEXR 2.x CMake configuration had options to simultaneously +build both shared and statically linked libraries. This has been +deprecated. A CMake configuration setting specifies whether to build +static or shared, but if you want both, you will need to run cmake and +build twice. + +Simultaneous Python 2/3 Build +----------------------------- + +The PyIlmBase 2.x CMake configuration had options to simultaneously +build both python2 and python3 bindings. This has been deprecated. +A CMake configuration setting specifies whether to build for +python 2 or python 3, but if you want both, you will need to run +cmake and build twice. + +Imath Include Files Are in a Different Subdirectory +=================================================== + +Imath 3.0 will copy its headers to some ``include/Imath`` subdirectory +instead of the old ``include/OpenEXR``. + +OpenEXR/Imath 3.x Only +---------------------- + +If you know that you are only using Imath 3.x, then just change any +include directions, like this: + +.. code-block:: + + #include + #include + +to the new locations: + +.. code-block:: + + #include + #include + +Accommodating OpenEXR/Imath 3.x or OpenEXR 2.x +---------------------------------------------- + +If you want your software to be able to build against either OpenEXR 2.x or +3.x (depending on which dependency is available at build time), we recommend +using a more complicated idiom: + +.. code-block:: + + // The version can reliably be found in this header file from OpenEXR, + // for both 2.x and 3.x: + #include + #define COMBINED_OPENEXR_VERSION ((10000*OPENEXR_VERSION_MAJOR) + \ + (100*OPENEXR_VERSION_MINOR) + \ + OPENEXR_VERSION_PATCH) + + // There's just no easy way to have an ``#include`` that works in both + // cases, so we use the version to switch which set of include files we + // use. + #if COMBINED_OPENEXR_VERSION >= 20599 /* 2.5.99: pre-3.0 */ + # include + # include + #else + // OpenEXR 2.x, use the old locations + # include + # include + #endif + +Include Files Include Fewer Other Headers +========================================= + +Extraneous ``#include`` statements have been removed from some header +files, which can lead to compile failures in application code that +previously included certain headers indirectly. + +For example, the Imath header files no longer include ``float.h``, so +application code that references symbols such as ``FLT_MAX`` may need +to add an explicit ``#include `` or equivalent. + +If your application code reports compile errors due to undefined or +incompletely-defined Imath or OpenEXR data types, locate the Imath or +OpenEXR header file that defines the type and include it explicitly. + +Symbols Are Hidden by Default +============================= + +To reduce library size and make linkage behavior similar across +platforms, Imath and OpenEXR now build with directives that make +symbol visibility hidden by default, with specific externally-visible +symbols explicitly marked for export. See the :doc:`SymbolVisibility` +and the appropriate ``*Export.h`` header file for more details. + +Imath Now Uses Standard C++ Exceptions and ``noexcept`` +======================================================= + +In OpenEXR 2.x, the Imath functions that threw exceptions used to throw +various Iex varieties. + +In Imath 3.x, these functions just throw ``std::exception`` varieties that +correspond to the failure (e.g., ``std::invalid_argument``, +``std::domain_error``, etc.). For that reason, all of the Iex exceptions are +now only part of the OpenEXR library (where they are still used in the same +manner they were for OpenEXR 2.x). + +Imath 3.x has very few functions that throw exceptions. Each is clearly +marked as such, and each has a version that does not throw exceptions (so +that it may be used from code where exceptions are avoided). The functions +that do not throw exceptions are now marked ``noexcept``. + +Some Headers and Classes Have Been Removed from Imath 3.x +========================================================= + +* The ``Math`` class (and ``ImathMath.h`` header file) are + deprecated. All of the ``Math`` functionality is subsumed by C++11 + ``std::`` math functions. For example, calls to + ``Imath::Math::abs(x)`` should be replaced with ``std::abs(x)``. + +* The ``Limits`` class (and the ``ImathLimits.h`` and + ``ImathHalfLimits.h`` headers) have been removed entirely. All uses of + ``Limits<>`` should be replaced with the appropriate + ``std::numeric_limits<>`` method call. The Imath-specific versions + predated C++11, and were not only redundant in a C++11 world, but + also potentially confusing because some of their functions behaved + quite differently than the ``std::numeric_limits`` method with the + same name. We are following the precept that if C++11 does something + in a standard way, we should not define our own equivalent function + (and especially not define it in a way that doesn't match the + standard behavior). + +* ``Vec::normalize()`` and ``length()`` methods, for integer ``T`` types, + have been removed. Also the standalone ``project()`` and + ``orthogonal()`` functions are no longer defined for vectors made of + integer elements. These all had behavior that was hard to understand + and probably useless. They still work as expected for vectors of + floating-point types. + +* The ``Int64`` and ``SInt64`` types are deprecated in favor of the + now-standard ``int64_t`` and ``uint64_t``. + +File/Class-specific Changes +=========================== + +``half`` in ``half.h`` +---------------------- + +* The half type is now in the ``Imath`` namespace, but a compile-time + option puts it in the global namespace, except when compiling for + CUDA, in which case the 'half' type refers to the CUDA type: + +.. code-block:: + + #ifndef __CUDACC__ + using half = IMATH_INTERNAL_NAMESPACE::half; + #else + #include + #endif + + If you desire to use Imath::half inside a CUDA kernal, you can refer + to it via the namespace, or define ``CUDA_NO_HALF`` to avoid the CUDA + type altogether. + +* ``HALF_MIN`` has changed value. It is now the smallest **normalized** + positive value, returned by ``std::numeric_limits::min()``. + +* New constructor from a bit pattern: + +.. code-block:: + + enum FromBitsTag + { + FromBits + }; + + constexpr half(FromBitsTag, unsigned short bits) noexcept; + +``Imath::Box`` in ``ImathBox.h`` +----------------------------------- + +* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` + +``Color3``, ``Color4`` in ``ImathColor.h`` +------------------------------------------------ + +* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` + +``Imath::Frustum`` in ``ImathFrustum.h`` +------------------------------------------- + +Akin to the ``Vec`` classes, there are now seperate API calls for +throwing and non-throwing functions: + +These functions previously threw exceptions but now do not throw and +are marked ``noexcept``: + +* ``Frustum::projectionMatrix() noexcept`` + +* ``Frustum::aspect() noexcept`` + +* ``Frustum::set() noexcept`` + +* ``Frustum::projectPointToScreen() noexcept`` + +* ``Frustum::ZToDepth() noexcept`` + +* ``Frustum::DepthToZ() noexcept`` + +* ``Frustum::screenRadius() noexcept`` + +* ``Frustum::localToScreen() noexcept`` + +These functions throw ``std::domain_error`` exceptions when the +associated frustum is degenerate: + +* ``Frustum::projectionMatrixExc()`` + +* ``Frustum::aspectExc()`` + +* ``Frustum::setExc()`` + +* ``Frustum::projectPointToScreenExc()`` + +* ``Frustum::ZToDepthExc()`` + +* ``Frustum::DepthToZExc()`` + +* ``Frustum::screenRadiusExc()`` + +* ``Frustum::localToScreenExc()`` + +``Imath::Interval`` in ``ImathInterval.h`` +--------------------------------------------- + +New methods/functions: + +* ``Interval::operator !=`` + +* ``Interval::makeInfinite()`` + +* ``IntervalisInfinite()`` + +* ``operator<< (std::ostream& s, const Interval&)`` + +``ImathMatrixAlgo.h`` +--------------------- + +* ``checkForZeroScaleInRow()`` and ``extractAndRemoveScalingAndShear()`` + throw ``std::domain_error`` exceptions instead of ``Iex::ZeroScale`` + +``Matrix22``, ``Matrix33``, ``Matrix44`` in ``ImathMatrix.h`` +---------------------------------------------------------------------- + +* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` + +* ``invert(bool singExc = false)`` is replace by: + + - ``invert() noexcept`` + + - ``invert(bool)`` which optionally throws an ``std::invalid_argument`` + exception. + +* ``inverse(bool singExc = false)`` is replace by: + + - ``inverse() noexcept`` + + - ``inverse(bool)`` which optionally throws an ``std::invalid_argument`` + exception. + +* ``gjInvert(bool singExc = false)`` is replace by: + + - ``gjInvert()`` noexcept + + - ``gjInvert(bool)`` which optionally throws an + ``std::invalid_argument`` exception. + +* ``gJinverse(bool singExc = false)`` is replace by: + + - ``gjInverse()`` noexcept + + - ``gjInverse(bool)`` which optionally throws an + ``std::invalid_argument`` exception. + +New functions: + +* ``operator<< (std::ostream& s, const Matrix22&)`` + +* ``operator<< (std::ostream& s, const Matrix33&)`` + +* ``operator<< (std::ostream& s, const Matrix44&)`` + +Other changes: + +* Initialization loops unrolled for efficiency + +* inline added where appropriate + +``ImathRoots.h`` +---------------- + +* When compiling for CUDA, the ``complex`` type comes from ``thrust`` + rather than ``std`` + +``Shear6`` in ``ImathShear.h`` +------------------------------ + +* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` + +``ImathVecAlgo.h`` +------------------ + +The following functions are no longer defined for integer-based +vectors, because such behavior is not clearly defined: + +* ``project (const Vec& s, const Vec& t)`` + +* ``orgthogonal (const Vec& s, const Vec& t)`` + +* ``reflect (const Vec& s, const Vec& t)`` + +``Vec2``, ``Vec3``, ``Vec4`` in ``ImathVec.h`` +------------------------------------------------------- + +* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` + +* The following methods are removed (via ``= delete``) for integer-based + vectors because the behavior is not clearly defined and thus prone + to confusion: + + - ``length()`` - although the length is indeed defined, its proper value + is floating point and can thus not be represented by the 'T' + return type. + + - ``normalize()`` + + - ``normalizeExc()`` + + - ``normalizeNonNull()`` + + - ``normalized()`` + + - ``normalizedExc()`` + + - ``normalizedNonNull()`` + +* Interoperability Constructors: The Vec and Matrix classes now have + constructors that take as an argument any data object of similar + size and layout. + +Imath Python Changes +==================== + +In general, the changes in Imath at the C++ level are reflected in the +python bindings. In particular: + +* The following methods are removed for integer-based + vector and matrix objects and arrays: + + - ``length()`` + - ``normalize()`` + - ``normalizeExc()`` + - ``normalizeNonNull()`` + - ``normalized()`` + - ``normalizedExc()`` + - ``normalizedNonNull()`` + +* ``baseTypeMin()`` is replaced with ``baseTypeLowest()`` for: + + - ``Vec2``, ``Vec3``, ``Vec4`` + - ``Color3``, ``Color4`` + - ``Matrix22``, ``Matrix33``, ``Matrix44`` + - ``Box`` + - ``Shear6`` + diff -Nru ilmbase-3.1.9-imath/website/SymbolVisibility.rst ilmbase-3.1.10/website/SymbolVisibility.rst --- ilmbase-3.1.9-imath/website/SymbolVisibility.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/SymbolVisibility.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,156 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +:orphan: + +.. _Symbol Visibility in Imath/OpenEXR: + +Symbol Visibility in Imath/OpenEXR +################################## + +Managing symbol visibility in a C++ library can reduce library sizes, +and with the extra information, the optimizer may produce faster +code. To take advantage of this, OpenEXR 3.0 is switching to +explicitly manage symbols on all platforms, with a hidden-by-default +behavior on unix-based platforms. Managing symbols has always been +required for Windows DLLs, where one must explicitly tag functions for +import and export as appropriate. + +For C, this is trivial: just tag public functions or global variable +as default visibility and leave everything else defaulting to +hidden. However, in C++, this is not exactly the same story. Functions +and globals are of course the same. And class member functions are +largely the same, and other than the attribute specification +mechanics, follow the same rules between gcc, clang, and +msvc. However, types have richer information than they do in C. So, +unless extra work is done, concepts for RTTI like the typeinfo and the +vtable for virtual classes will be hidden, and not visible. These are +referred to as "vague" linkage objects in some discussions. + +It is with the "vague" linkage objects where different properties +arise. For example, if you have a template, it is happily instantiated +in multiple compile units. If the typeinfo is hidden for one library, +then this may cause things like dynamic_cast to fail because then the +same typeinfo is not used, and even though one might think that +``ImfAttribute`` are the same in two places, because they +are instantiated in separate places, they may be considered different +types. To compound the issue, there are different rules for this in +different implementations. For example, a default gcc under linux +allows one to link against otherwise private "vague" linkage objects +such that the typeinfo ends up as the same entity. clang, for MacOS +anyway, follows a stricter approach and keeps those types separate, +perhaps due to the two level namespace they maintain for symbols. + +Unfortunately, this is not clearly discussed as an overview of the +differences between platforms, hence this document to add +clarity. Each compiler / platform describes their own behavior, but +not how that behaves relative to others. `libc++ +`_ from +the llvm project is the closest to providing comparative information, +where by looking at how they define their macros and the comments +surrounding, one can infer the behavior among at least windows DLL +mode, then gcc vs. clang for unixen. Other compilers, for example, +Intel's icc, tend to adopt the behavior of the predominant compiler +for that platform (i.e. msvc under windows, gcc under linux), and so +can generally adopt that behavior and are ignored here. If this is not +true, the ifdef rules in the various library ``Export.h`` headers +within OpenEXR may need to be adjusted, and this table updated. + +As a summary, below is a table of the attribute or declspec that needs +to be used for a particular C++ entity to be properly exported. This +does not address weak symbols, ABI versioning, and only focusing on +visibility. Under Windows DLL rules, if one exports the entire class, +it also exports the types for the member types as well, which is not +desired, so these are marked as N/A even though the compiler does +allow that to happen. + +.. list-table:: + :header-rows: 1 + :align: left + + * - C++ vs Compiler + - MSVC + - mingw + - gcc + - clang + * - function + - ``dllexport/dllimport`` + - ``dllexport/dllimport`` + - ``visibility("default")`` + - ``visibility("default")`` + * - hide a function + - N/A + - N/A + - ``visibility("hidden")`` + - ``visibility("hidden")`` + * - ``class(typeinfo)`` + - N/A + - N/A + - ``visibility("default")`` + - ``visibility("default")`` + * - template class + - N/A + - N/A + - ``visibility("default")`` + - ``type_visibility("default")`` + * - template data + - N/A + - N/A + - ``visibility("default")`` + - ``visibility("default")`` + * - class template instantiation + - ``dllexport/dllimport`` + - N/A + - N/A + - ``visibility("default")`` + * - enum + - N/A + - N/A + - auto unhides (N/A) + - ``type_visibility("default")`` + * - extern template + - N/A + - ``dllexport/dllimport`` + - ``visibility("default")`` + - ``visibility("default")`` + +With this matrix in mind, we can see the maximal set of macros we need to +provide throughout the code. *NB*: This does not mean that we need to +declare all of these, just that they might be needed. + +.. list-table:: + :header-rows: 1 + :align: left + + * - macro name + - purpose + * - ``IMATH_EXPORT`` + - one of export or import for windows, visibility for others + * - ``IMATH_EXPORT_TYPE`` + - for declaring a class / struct as public (for typeinfo / vtable) + * - ``IMATH_HIDDEN`` + - used to explicitly hide, especially members of types + * - ``IMATH_EXPORT_TEMPLATE_TYPE`` + - stating the template type should be visible + * - ``IMATH_EXPORT_EXTERN_TEMPLATE`` + - exporting template types (i.e. extern side of extern template) + * - ``IMATH_EXPORT_TEMPLATE_INSTANCE`` + - exporting specific template instantiations (in cpp code) + * - ``IMATH_EXPORT_TEMPLATE_DATA`` + - exporting templated data blocks + * - ``IMATH_EXPORT_ENUM`` + - exporting enum types + +The preference might be to call ``IMATH_EXPORT`` something like +``IMATH_FUNC``, and rename things such as ``IMATH_EXPORT_TYPE`` to +``IMATH_TYPE`` for simplicity. However, historically, OpenEXR has used +the ``_EXPORT`` tag, and so that is preserved for consistency. + +--------- + +* LLVM libc++ visibility macros: https://libcxx.llvm.org/docs/DesignDocs/VisibilityMacros.html + +* GCC visibility wiki: https://gcc.gnu.org/wiki/Visibility + +* Apple library design docs: https://developer.apple.com/library/archive/documentation/DeveloperTools/Conceptual/DynamicLibraries/100-Articles/DynamicLibraryDesignGuidelines.html diff -Nru ilmbase-3.1.9-imath/website/about.rst ilmbase-3.1.10/website/about.rst --- ilmbase-3.1.9-imath/website/about.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/about.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,71 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _About Imath: + +About Imath +=========== + +.. toctree:: + :caption: About + +Imath is maintained by the OpenEXR project, a part of the `Academy +Software Foundation `_. The library were +originally developed at Industrial Light & Magic and first released as +open source in 2003. + +Read the origin story of OpenEXR and Imath, and the ``half`` 16-bit +float type, in particular, on the `ASWF Blog +`_. + +Imath is Version 3 because it was previously distributed as a +component of OpenEXR v1 and v2. + +OpenEXR and Imath is included in the `VFX Reference Platform `_. + +New Features in 3.1 +------------------- + +The 3.1 release of Imath introduces optimized half-to-float and +float-to-half conversion using the F16C SSE instruction set extension, +if available. These single-instruction conversions offer a 5-10x +speedup for float-to-half and 2x speedup for half-to-float over +Imath/half's traditional table-based conversion (timings depend on the +data). + +In the absence of the F16C instruction set, the lookup-table-based +conversion from half to float is still the default, but Imath 3.1 also +introduces an optimized bit-shift conversion algorithm as a +compile-time option that does not require lookup tables, for +architectures where memory is limited. The float-to-half conversion +also no longer requires an exponent lookup table, further reducing +memory requirements. + +These new conversions generate the same values as the traditional +methods, which ensures backwards compatibility. See :doc:`install` +for more installation and configuration options. + +Also, ``half.h`` can now be included in pure C code for a definition +of the type and for conversions between half and float. + +OpenEXR/Imath 2.x to 3.x Porting Guide +-------------------------------------- + +See the :doc:`PortingGuide` for help in restructing old code to work +with recent releases of OpenEXR and Imath. + +Credits +------- + +The ILM Imath library and the ``half`` data type were originally +designed and implemented at Industrial Light & Magic by Florian Kainz, +Wojciech Jarosz, Rod Bogart, and others. Drew Hess packaged and +adapted ILM's internal source code for public release. + +For a complete list of contributors see `CONTRIBUTORS.md +`_. + + + + diff -Nru ilmbase-3.1.9-imath/website/classes/Box.rst ilmbase-3.1.10/website/classes/Box.rst --- ilmbase-3.1.9-imath/website/classes/Box.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Box.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,59 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Box +### + +.. code-block:: + + #include + +The ``Box`` class template represents 2D and 3D axis-aligned bounding +boxes, with predefined typedefs for boxes of type ``short``, ``int``, +``int64_t``, ``float``, and ``double``. + +The box is defined by minimum and maximum values along each axis, +represented by ``Vec2`` for the ``Box2`` types and by ``Vec3`` +for ``Box3`` types. + +There are also various utility functions that operate on bounding +boxes defined in ``ImathBoxAlgo.h`` and described in :ref:`Box +Functions `. + +Example: + +.. literalinclude:: ../examples/Box.cpp + :language: c++ + +.. doxygentypedef:: Box2s + +.. doxygentypedef:: Box2i + +.. doxygentypedef:: Box2i64 + +.. doxygentypedef:: Box2f + +.. doxygentypedef:: Box2d + +.. doxygentypedef:: Box3s + +.. doxygentypedef:: Box3i + +.. doxygentypedef:: Box3i64 + +.. doxygentypedef:: Box3f + +.. doxygentypedef:: Box3d + +.. doxygenclass:: Imath::Box + :undoc-members: + :members: + +.. doxygenclass:: Imath::Box< Vec2< T > > + :undoc-members: + :members: + +.. doxygenclass:: Imath::Box< Vec3< T > > + :undoc-members: + :members: diff -Nru ilmbase-3.1.9-imath/website/classes/Color3.rst ilmbase-3.1.10/website/classes/Color3.rst --- ilmbase-3.1.9-imath/website/classes/Color3.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Color3.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,42 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Color3 +###### + +.. code-block:: + + #include + +The ``Color3`` class template represents a 3-component color, with +pre-defined typedefs of ``unsigned char``, ``half``, and ``float``. + +The ``Color3`` class inherits from ``Vec3`` and thus has +fields named ``x``, ``y``, and ``z``. The class itself implies no +specific interpretation of the values. + +There are also various utility functions that operate on colors +defined in ``ImathColorAlgo.h`` and described in :ref:`Color Functions +`. + +Example: + +.. literalinclude:: ../examples/Color3.cpp + :language: c++ + +.. doxygentypedef:: Color3c + +.. doxygentypedef:: Color3h + +.. doxygentypedef:: Color3f + +.. doxygentypedef:: C3c + +.. doxygentypedef:: C3h + +.. doxygentypedef:: C3f + +.. doxygenclass:: Imath::Color3 + :undoc-members: + :members: diff -Nru ilmbase-3.1.9-imath/website/classes/Color4.rst ilmbase-3.1.10/website/classes/Color4.rst --- ilmbase-3.1.9-imath/website/classes/Color4.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Color4.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,46 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Color4 +###### + +.. code-block:: + + #include + +The ``Color4`` class template represents a 4-component color (red, +green, blue, and alpha), with pre-defined typedefs of ``unsigned +char``, ``half``, and ``float``. + +The ``Color4`` class is *not* derived from ``Vec4``. Its fields are +named ``r``, ``g``, ``b``, and ``a``. The class itself implies no +specific interpretation of the values. + +There are also various utility functions that operate on colors +defined in ``ImathColorAlgo.h`` and described in :ref:`Color Functions +`. + +Example: + +.. literalinclude:: ../examples/Color4.cpp + :language: c++ + +.. doxygentypedef:: Color4c + +.. doxygentypedef:: Color4h + +.. doxygentypedef:: Color4f + +.. doxygentypedef:: C4c + +.. doxygentypedef:: C4h + +.. doxygentypedef:: C4f + +.. doxygenclass:: Imath::Color4 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Color4& v) + diff -Nru ilmbase-3.1.9-imath/website/classes/Euler.rst ilmbase-3.1.10/website/classes/Euler.rst --- ilmbase-3.1.9-imath/website/classes/Euler.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Euler.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,35 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Euler +##### + +.. code-block:: + + #include + +The ``Euler`` class template represents an euler angle rotation/orientation, +with predefined typedefs of type ``float`` and ``double``. + +The ``Euler`` class is derived from ``Imath::Vec3`` and thus has +fields named ``x``, ``y``, and ``z``, which correspond to the first, +second, and third rotation angles in a specified order, which, +depending on the order, may not correspond directly to x, y, or z +rotations. + +Example: + +.. literalinclude:: ../examples/Euler.cpp + :language: c++ + +.. doxygentypedef:: Eulerf + +.. doxygentypedef:: Eulerd + +.. doxygenclass:: Imath::Euler + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& o, const Euler& euler) + diff -Nru ilmbase-3.1.9-imath/website/classes/Frustum.rst ilmbase-3.1.10/website/classes/Frustum.rst --- ilmbase-3.1.9-imath/website/classes/Frustum.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Frustum.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,26 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Frustum +####### + +.. code-block:: + + #include + +The ``Frustum`` class template represents a 3D viewing frustum, with +predefined typedefs of type ``float`` and ``double``. + +Example: + +.. literalinclude:: ../examples/Frustum.cpp + :language: c++ + +.. doxygentypedef:: Frustumf + +.. doxygentypedef:: Frustumd + +.. doxygenclass:: Imath::Frustum + :undoc-members: + :members: diff -Nru ilmbase-3.1.9-imath/website/classes/Interval.rst ilmbase-3.1.10/website/classes/Interval.rst --- ilmbase-3.1.9-imath/website/classes/Interval.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Interval.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,36 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Interval +######## + +.. code-block:: + + #include + +The ``Interval`` class template represents a scalar interval, with +predefined typedefs for ``short``, ``int``, ``float``, and ``double``. + +An ``Interval`` is essentially a ``Box`` that allows ``T`` to be a +scalar. + +Example: + +.. literalinclude:: ../examples/Interval.cpp + :language: c++ + +.. doxygentypedef:: Intervals + +.. doxygentypedef:: Intervali + +.. doxygentypedef:: Intervalf + +.. doxygentypedef:: Intervald + +.. doxygenclass:: Imath::Interval + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Interval& v) + diff -Nru ilmbase-3.1.9-imath/website/classes/Line3.rst ilmbase-3.1.10/website/classes/Line3.rst --- ilmbase-3.1.9-imath/website/classes/Line3.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Line3.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,33 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Line3 +##### + +.. code-block:: + + #include + +The ``Line3`` class template represents a line in 3D space, with +predefined typedefs for lines of type ``float`` and ``double``. + +There are also various utility functions that operate on ``Line3`` +objects defined in ``ImathLineAlgo.h`` and described in :ref:`Line +Functions `. + +Example: + +.. literalinclude:: ../examples/Line3.cpp + :language: c++ + +.. doxygentypedef:: Line3f + +.. doxygentypedef:: Line3d + +.. doxygenclass:: Imath::Line3 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Line3& line) + diff -Nru ilmbase-3.1.9-imath/website/classes/Matrix22.rst ilmbase-3.1.10/website/classes/Matrix22.rst --- ilmbase-3.1.9-imath/website/classes/Matrix22.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Matrix22.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,42 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Matrix22 +######## + +.. code-block:: + + #include + +The ``Matrix22`` class template represents a 2x2 matrix, with +predefined typedefs for ``float`` and ``double``. + +There are also various utility functions that operate on matrices +defined in ``ImathMatrixAlgo.h`` and described in :ref:`Matrix +Functions `. + +Individual components of a matrix ``M`` may be referenced as either +``M[j][i]`` or ``M.x[j][i]``. While the latter is a little awkward, it has an +advantage when used in loops that may be auto-vectorized or explicitly +vectorized by ``#pragma omp simd`` or other such hints, because the function +call and pointer casting of ``operator[]`` can confuse the compiler just +enough to prevent vectorization of the loop, whereas directly addressing the +real underlying array (``M.x[j][i]``) does not. + +Example: + +.. literalinclude:: ../examples/Matrix22.cpp + :language: c++ + +.. doxygentypedef:: M22f + +.. doxygentypedef:: M22d + +.. doxygenclass:: Imath::Matrix22 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Matrix22& m) + + diff -Nru ilmbase-3.1.9-imath/website/classes/Matrix33.rst ilmbase-3.1.10/website/classes/Matrix33.rst --- ilmbase-3.1.9-imath/website/classes/Matrix33.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Matrix33.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,41 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Matrix33 +######## + +.. code-block:: + + #include + +The ``Matrix33`` class template represents a 3x3 matrix, with +predefined typedefs for ``float`` and ``double``. + +There are also various utility functions that operate on matrices +defined in ``ImathMatrixAlgo.h`` and described in :ref:`Matrix +Functions `. + +Individual components of a matrix ``M`` may be referenced as either +``M[j][i]`` or ``M.x[j][i]``. While the latter is a little awkward, it has an +advantage when used in loops that may be auto-vectorized or explicitly +vectorized by ``#pragma omp simd`` or other such hints, because the function +call and pointer casting of ``operator[]`` can confuse the compiler just +enough to prevent vectorization of the loop, whereas directly addressing the +real underlying array (``M.x[j][i]``) does not. + +Example: + +.. literalinclude:: ../examples/Matrix33.cpp + :language: c++ + +.. doxygentypedef:: M33f + +.. doxygentypedef:: M33d + +.. doxygenclass:: Imath::Matrix33 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Matrix33& m) + diff -Nru ilmbase-3.1.9-imath/website/classes/Matrix44.rst ilmbase-3.1.10/website/classes/Matrix44.rst --- ilmbase-3.1.9-imath/website/classes/Matrix44.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Matrix44.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,41 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Matrix44 +######## + +.. code-block:: + + #include + +The ``Matrix44`` class template represents a 4x4 matrix, with +predefined typedefs for ``float`` and ``double``. + +There are also various utility functions that operate on matrices +defined in ``ImathMatrixAlgo.h`` and described in :ref:`Matrix +Functions `. + +Individual components of a matrix ``M`` may be referenced as either +``M[j][i]`` or ``M.x[j][i]``. While the latter is a little awkward, it has an +advantage when used in loops that may be auto-vectorized or explicitly +vectorized by ``#pragma omp simd`` or other such hints, because the function +call and pointer casting of ``operator[]`` can confuse the compiler just +enough to prevent vectorization of the loop, whereas directly addressing the +real underlying array (``M.x[j][i]``) does not. + +Example: + +.. literalinclude:: ../examples/Matrix44.cpp + :language: c++ + +.. doxygentypedef:: M44f + +.. doxygentypedef:: M44d + +.. doxygenclass:: Imath::Matrix44 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Matrix44& m) + diff -Nru ilmbase-3.1.9-imath/website/classes/Plane3.rst ilmbase-3.1.10/website/classes/Plane3.rst --- ilmbase-3.1.9-imath/website/classes/Plane3.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Plane3.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,29 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Plane3 +###### + +.. code-block:: + + #include + +The ``Plane3`` class template represents a plane in 3D space, with +predefined typedefs for planes of type ``float`` and ``double``. + +Example: + +.. literalinclude:: ../examples/Plane3.cpp + :language: c++ + +.. doxygentypedef:: Plane3f + +.. doxygentypedef:: Plane3d + +.. doxygenclass:: Imath::Plane3 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Plane3& plane) + diff -Nru ilmbase-3.1.9-imath/website/classes/Quat.rst ilmbase-3.1.10/website/classes/Quat.rst --- ilmbase-3.1.9-imath/website/classes/Quat.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Quat.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,28 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Quat +#### + +.. code-block:: + + #include + +The ``Quat`` class template represents a quaterion +rotation/orientation, with predefined typedefs for ``float`` and +``double``. + +Example: + +.. literalinclude:: ../examples/Quat.cpp + :language: c++ + +.. doxygentypedef:: Quatf + +.. doxygenclass:: Imath::Quat + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Quat& q) + diff -Nru ilmbase-3.1.9-imath/website/classes/Rand32.rst ilmbase-3.1.10/website/classes/Rand32.rst --- ilmbase-3.1.9-imath/website/classes/Rand32.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Rand32.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,18 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Rand32 +###### + +.. code-block:: + + #include + +The ``Rand32`` class is a fast pseudo-random number generator that +generates a uniformly distributed sequence with a period length of +:math:`2^32`. + +.. doxygenclass:: Imath::Rand32 + :undoc-members: + :members: diff -Nru ilmbase-3.1.9-imath/website/classes/Rand48.rst ilmbase-3.1.10/website/classes/Rand48.rst --- ilmbase-3.1.9-imath/website/classes/Rand48.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Rand48.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,18 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Rand48 +###### + +.. code-block:: + + #include + +The ``Rand48`` class is a fast pseudo-random number generator based on +the C Standard Library functions erand48(), nrand48() & company. It +generates a uniformly distributed sequence. + +.. doxygenclass:: Imath::Rand48 + :undoc-members: + :members: diff -Nru ilmbase-3.1.9-imath/website/classes/Shear6.rst ilmbase-3.1.10/website/classes/Shear6.rst --- ilmbase-3.1.9-imath/website/classes/Shear6.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Shear6.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,27 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Shear6 +###### + +.. code-block:: + + #include + +The ``Shear6`` class template represent a 3D shear transformation, +with predefined typedefs for ``float`` and ``double``. + +Example: + +.. literalinclude:: ../examples/Shear6.cpp + :language: c++ + +.. doxygentypedef:: Shear6f + +.. doxygenclass:: Imath::Shear6 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Shear6& h) + diff -Nru ilmbase-3.1.9-imath/website/classes/Sphere3.rst ilmbase-3.1.10/website/classes/Sphere3.rst --- ilmbase-3.1.9-imath/website/classes/Sphere3.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Sphere3.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,24 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Sphere3 +####### + +.. code-block:: + + #include + +The ``Sphere3`` class template represents a sphere in 3D space, with +predefined typedefs for lines of type ``float`` and ``double``. + +Example: + +.. literalinclude:: ../examples/Sphere3.cpp + :language: c++ + +.. doxygentypedef:: Sphere3f + +.. doxygenclass:: Imath::Sphere3 + :undoc-members: + :members: diff -Nru ilmbase-3.1.9-imath/website/classes/Vec2.rst ilmbase-3.1.10/website/classes/Vec2.rst --- ilmbase-3.1.9-imath/website/classes/Vec2.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Vec2.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,58 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Vec2 +#### + +.. code-block:: + + #include + +The ``Vec2`` class template represents a 2D vector, with predefined +typedefs for vectors of type ``short``, ``int``, ``int64_t``, ``float``, and +``double``. + +Note that the integer specializations of ``Vec2`` lack the +``length()`` and ``normalize()`` methods that are present in the +``float`` and ``double`` versions, because the results don't fit into +integer quantities. + +There are also various utility functions that operate on vectors +defined in ``ImathVecAlgo.h`` and described in :ref:`Vector Functions +`. + +Individual components of a vector ``V`` may be referenced as either ``V[i]`` +or ``V.x``, ``V.y``. Obviously, the ``[]`` notation is more +suited to looping over components, or in cases where a variable determines +which coordinate is needed. However, when the coordinate is known, it can be +more efficient to directly address the components, such as ``V.y`` rather than +``V[1]``. While both appear to do the same thing (and indeed do generate the +same machine operations for ordinary scalar code), when used inside loops that +you hope to parallelize (either through compiler auto-vectorization or +explicit hints such as ``#pragma omp simd``), the function call and +pointer casting of ``operator[]`` can confuse the compiler just enough to +prevent vectorization of the loop. + +Example: + +.. literalinclude:: ../examples/Vec2.cpp + :language: c++ + +.. doxygentypedef:: V2s + +.. doxygentypedef:: V2i + +.. doxygentypedef:: V2i64 + +.. doxygentypedef:: V2f + +.. doxygentypedef:: V2d + +.. doxygenclass:: Imath::Vec2 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Vec2& v) + + diff -Nru ilmbase-3.1.9-imath/website/classes/Vec3.rst ilmbase-3.1.10/website/classes/Vec3.rst --- ilmbase-3.1.9-imath/website/classes/Vec3.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Vec3.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,58 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Vec3 +#### + +.. code-block:: + + #include + +The ``Vec3`` class template represents a 3D vector, with predefined +typedefs for vectors of type ``short``, ``int``, ``int64_t``, +``float``, and ``double``. + +Note that the integer specializations of ``Vec3`` lack the +``length()`` and ``normalize()`` methods that are present in the +``float`` and ``double`` versions, because the results don't fit into +integer quantities. + +There are also various utility functions that operate on vectors +defined in ``ImathVecAlgo.h`` and described in :ref:`Vector Functions +`. + +Individual components of a vector ``V`` may be referenced as either ``V[i]`` +or ``V.x``, ``V.y``, ``V.z``. Obviously, the ``[]`` notation is more +suited to looping over components, or in cases where a variable determines +which coordinate is needed. However, when the coordinate is known, it can be +more efficient to directly address the components, such as ``V.y`` rather than +``V[1]``. While both appear to do the same thing (and indeed do generate the +same machine operations for ordinary scalar code), when used inside loops that +you hope to parallelize (either through compiler auto-vectorization or +explicit hints such as ``#pragma omp simd``), the function call and +pointer casting of ``operator[]`` can confuse the compiler just enough to +prevent vectorization of the loop. + +Example: + +.. literalinclude:: ../examples/Vec3.cpp + :language: c++ + +.. doxygentypedef:: V3s + +.. doxygentypedef:: V3i + +.. doxygentypedef:: V3i64 + +.. doxygentypedef:: V3f + +.. doxygentypedef:: V3d + +.. doxygenclass:: Imath::Vec3 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Vec3& v) + + diff -Nru ilmbase-3.1.9-imath/website/classes/Vec4.rst ilmbase-3.1.10/website/classes/Vec4.rst --- ilmbase-3.1.9-imath/website/classes/Vec4.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/Vec4.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,57 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Vec4 +#### + +.. code-block:: + + #include + +The ``Vec4`` class template represents a 4D vector, with predefined +typedefs for vectors of type ``short``, ``int``, ``int64_t``, +``float``, and ``double``. + +Note that the integer specializations of ``Vec4`` lack the +``length()`` and ``normalize()`` methods that are present in the +``float`` and ``double`` versions, because the results don't fit into +integer quantities. + +There are also various utility functions that operate on vectors +defined in ``ImathVecAlgo.h`` and described in :ref:`Vector Functions +`. + +Individual components of a vector ``V`` may be referenced as either ``V[i]`` +or ``V.x``, ``V.y``, ``V.z``, ``V.w``. Obviously, the ``[]`` notation is more +suited to looping over components, or in cases where a variable determines +which coordinate is needed. However, when the coordinate is known, it can be +more efficient to directly address the components, such as ``V.y`` rather than +``V[1]``. While both appear to do the same thing (and indeed do generate the +same machine operations for ordinary scalar code), when used inside loops that +you hope to parallelize (either through compiler auto-vectorization or +explicit hints such as ``#pragma omp simd``), the function call and +pointer casting of ``operator[]`` can confuse the compiler just enough to +prevent vectorization of the loop. + +Example: + +.. literalinclude:: ../examples/Vec4.cpp + :language: c++ + +.. doxygentypedef:: V4s + +.. doxygentypedef:: V4i + +.. doxygentypedef:: V4i64 + +.. doxygentypedef:: V4f + +.. doxygentypedef:: V4d + +.. doxygenclass:: Imath::Vec4 + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& s, const Vec4& v) + diff -Nru ilmbase-3.1.9-imath/website/classes/float.rst ilmbase-3.1.10/website/classes/float.rst --- ilmbase-3.1.9-imath/website/classes/float.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/float.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,183 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +Floating Point Representation +############################# + +The half type is a 16-bit floating number, compatible with the +IEEE 754-2008 binary16 type. + +Representation of a 32-bit float +-------------------------------- + +We assume that a float, ``f``, is an IEEE 754 single-precision +floating point number, whose bits are arranged as follows: + +.. code-block:: + + 31 (msb) + | + | 30 23 + | | | + | | | 22 0 (lsb) + | | | | | + X XXXXXXXX XXXXXXXXXXXXXXXXXXXXXXX + + s e m + +``s`` is the sign-bit, ``e`` is the exponent and ``m`` is the significand. + +If ``e`` is between 1 and 254, ``f`` is a normalized number: + +.. math:: {\tt f} = (-1)^{\tt s} \times 2^{\tt e-127} \times {\tt 1.m} + +If ``e`` is 0, and ``m`` is not zero, ``f`` is a denormalized number: + +.. math:: {\tt f} = (-1)^{\tt s} \times 2^{\tt e-126} \times {\tt 0.m} + +If ``e`` and ``m`` are both zero, ``f`` is zero: + +.. math:: {\tt f} = 0.0 + +If ``e`` is 255, ``f`` is an "infinity" or "not a number" (NAN), +depending on whether ``m`` is zero or not. + +Examples: + +.. code-block:: + + 0 00000000 00000000000000000000000 = 0.0 + 0 01111110 00000000000000000000000 = 0.5 + 0 01111111 00000000000000000000000 = 1.0 + 0 10000000 00000000000000000000000 = 2.0 + 0 10000000 10000000000000000000000 = 3.0 + 1 10000101 11110000010000000000000 = -124.0625 + 0 11111111 00000000000000000000000 = +infinity + 1 11111111 00000000000000000000000 = -infinity + 0 11111111 10000000000000000000000 = NAN + 1 11111111 11111111111111111111111 = NAN + +Representation of a 16-bit half +------------------------------- + +Here is the bit-layout for a half number, ``h``: + +.. code-block:: + + 15 (msb) + | + | 14 10 + | | | + | | | 9 0 (lsb) + | | | | | + X XXXXX XXXXXXXXXX + + s e m + +``s`` is the sign-bit, ``e`` is the exponent and ``m`` is the significand. + +If ``e`` is between 1 and 30, ``h`` is a normalized number: + +.. math:: {\tt h} = (-1)^{\tt s} \times 2^{\tt e-15} \times {\tt 1.m} + +If ``e`` is 0, and ``m`` is not zero, ``h`` is a denormalized number: + +.. math:: {\tt h} = (-1)^{\tt s} \times 2^{\tt -14} \times {\tt 0.m} + +If ``e`` and ``m`` are both zero, ``h`` is zero: + +.. math:: {\tt h} = 0.0 + +If ``e`` is 31, ``h`` is an "infinity" or "not a number" (NAN), +depending on whether ``m`` is zero or not. + +Examples: + +.. code-block:: + + 0 00000 0000000000 = 0.0 + 0 01110 0000000000 = 0.5 + 0 01111 0000000000 = 1.0 + 0 10000 0000000000 = 2.0 + 0 10000 1000000000 = 3.0 + 1 10101 1111000001 = -124.0625 + 0 11111 0000000000 = +infinity + 1 11111 0000000000 = -infinity + 0 11111 1000000000 = NAN + 1 11111 1111111111 = NAN + +Conversion via Lookup Table +--------------------------- + +Converting from half to float is performed by default using a +lookup table. There are only 65,536 different half numbers; each +of these numbers has been converted and stored in a table pointed +to by the ``imath_half_to_float_table`` pointer. + +Prior to Imath v3.1, conversion from float to half was +accomplished with the help of an exponent look table, but this is +now replaced with explicit bit shifting. + +Conversion via Hardware +----------------------- + +For Imath v3.1, the conversion routines have been extended to use +F16C SSE instructions whenever present and enabled by compiler +flags. + +Conversion via Bit-Shifting +--------------------------- + +If F16C SSE instructions are not available, conversion can be +accomplished by a bit-shifting algorithm. For half-to-float +conversion, this is generally slower than the lookup table, but it +may be preferable when memory limits preclude storing of the +65,536-entry lookup table. + +The lookup table symbol is included in the compilation even if +``IMATH_HALF_USE_LOOKUP_TABLE`` is false, because application code +using the exported ``half.h`` may choose to enable the use of the table. + +An implementation can eliminate the table from compilation by +defining the ``IMATH_HALF_NO_LOOKUP_TABLE`` preprocessor symbol. +Simply add: + +.. code-block:: + + #define IMATH_HALF_NO_LOOKUP_TABLE + +before including ``half.h``, or define the symbol on the compile +command line. + +Furthermore, an implementation wishing to receive ``FE_OVERFLOW`` +and ``FE_UNDERFLOW`` floating point exceptions when converting +float to half by the bit-shift algorithm can define the +preprocessor symbol ``IMATH_HALF_ENABLE_FP_EXCEPTIONS`` prior to +including ``half.h``: + +.. code-block:: + + #define IMATH_HALF_ENABLE_FP_EXCEPTIONS + +Conversion Performance Comparison +--------------------------------- + +Testing on a Core i9, the timings are approximately: + +- half to float: + + * table: 0.71 ns / call + * no table: 1.06 ns / call + * f16c: 0.45 ns / call + +- float-to-half: + + * original: 5.2 ns / call + * no exp table + opt: 1.27 ns / call + * f16c: 0.45 ns / call + +**Note:** the timing above depends on the distribution of the +floats in question. + + diff -Nru ilmbase-3.1.9-imath/website/classes/half.rst ilmbase-3.1.10/website/classes/half.rst --- ilmbase-3.1.9-imath/website/classes/half.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/half.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,36 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _half: + +half +#### + +.. code-block:: + + #include + +``half`` is a 16-bit floating point number. See :doc:`float` for an +explanation of the representation. + +See :doc:`half_c` for C-language functions for conversion +between ``half`` and ``float``. Also, see :doc:`half_conversion` +for information about building Imath with support for the F16C SSE +instruction set. + +Example: + +.. literalinclude:: ../examples/half.cpp + :language: c++ + +.. toctree:: + :caption: half + :maxdepth: 1 + + half_class + half_limits + half_c + half_conversion + float + diff -Nru ilmbase-3.1.9-imath/website/classes/half_c.rst ilmbase-3.1.10/website/classes/half_c.rst --- ilmbase-3.1.9-imath/website/classes/half_c.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/half_c.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,21 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +C-language half-float Conversion +################################ + +The ``half.h`` header can be included in pure C code: + +.. literalinclude:: ../examples/half.c + :language: c + +The only C-language operations supported for the ``half`` type are +conversion to and from ``float``. No arithmetic operations are +currently implemented in the C interface. + +.. doxygenfunction:: imath_half_to_float + +.. doxygenfunction:: imath_float_to_half + + diff -Nru ilmbase-3.1.9-imath/website/classes/half_class.rst ilmbase-3.1.10/website/classes/half_class.rst --- ilmbase-3.1.9-imath/website/classes/half_class.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/half_class.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,16 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +The half Class +############## + +.. doxygenclass:: Imath::half + :undoc-members: + :members: + +.. doxygenfunction:: operator<<(std::ostream& os, Imath::half h) + +.. doxygenfunction:: operator>>(std::istream&, Imath::half&) + + diff -Nru ilmbase-3.1.9-imath/website/classes/half_conversion.rst ilmbase-3.1.10/website/classes/half_conversion.rst --- ilmbase-3.1.9-imath/website/classes/half_conversion.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/half_conversion.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,75 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _half-float-conversion-configuration-options: + +Build-time half-float Conversion Configuration Options +###################################################### + +The Imath library supports three options for conversion between 16-bit +half and 32-bit float: + +1. Conversion from half to float via a 16-bit lookup table. Prior to + Imath v3.1, this was the only method supported. + +2. F16C SSE instructions: single-instruction conversion for machine + architectures that support it. When available, this is the fastest + option, by far. + +3. Bit-shift conversion algorithm. + +To use the F16C SSE instruction set on an architecture that supports +it, simply provide the appropriate compiler flags when building an +application that includes ``half.h``. For g++ and clang, +for example: +:: + + $ cmake -DCMAKE_CXX_FLAGS="-m16fc" + +When code including ``half.h`` is compiled with F16C enabled, it will +automatically perform conversions using the instruction set. F16C +compiler flags take precedence over other lookup-table-related Imath +CMake settings. + +On architectures that do not support F16C, you may choose at +compile-time between the bit-shift conversion and lookup table +conversion via the ``IMATH_HALF_USE_LOOKUP_TABLE`` CMake option: +:: + + $ cmake -DIMATH_HALF_USE_LOOKUP_TABLE=OFF + +Note that when building and installing the Imath library itself, the +65,536-entry lookup table symbol will be compiled into the library +even if the ``IMATH_HALF_USE_LOOKUP_TABLE`` setting is false. This +allows applications using that installed Imath library downstream to +choose at compile time which conversion method to use. + +Applications with memory limitations that cannot accomodate the +conversion lookup table can eliminate it from the library by building +Imath with the C preprocessor define ``IMATH_HALF_NO_LOOKUP_TABLE`` +defined. Note that this is a compile-time option, not a CMake setting +(making it possible for application code to choose the desired +behavior). Simply add: +:: + + #define IMATH_HALF_NO_LOOKUP_TABLE + +before including ``half.h``, or define the symbol on the compile +command line. + +Furthermore, an implementation wishing to receive ``FE_OVERFLOW`` and +``FE_UNDERFLOW`` floating point exceptions when converting float to +half by the bit-shift algorithm can define the preprocessor symbol +``IMATH_HALF_ENABLE_FP_EXCEPTIONS`` prior to including ``half.h``: +:: + + #define IMATH_HALF_ENABLE_FP_EXCEPTIONS + +By default, no exceptions are raised on overflow and underflow. + + + + + + diff -Nru ilmbase-3.1.9-imath/website/classes/half_limits.rst ilmbase-3.1.10/website/classes/half_limits.rst --- ilmbase-3.1.9-imath/website/classes/half_limits.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes/half_limits.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,117 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +half Limits +########### + +Constants +--------- + +``HALF_DENORM_MIN`` + Smallest positive denormalized half. + +``HALF_NRM_MIN`` + Smallest positive normalized half. + +``HALF_MIN`` + Smallest positive normalized half. + +``HALF_MAX`` + Largest positive half. + +``HALF_EPSILON`` + Smallest positive e for which half(1.0 + e) != half(1.0) + +``HALF_MANT_DIG`` + Number of digits in mantissa (significand + hidden leading 1) + +``HALF_DIG`` + Number of base 10 digits that can be represented without change: + + floor( (``HALF_MANT_DIG`` - 1) * log10(2) ) => 3.01... -> 3 + +``HALF_DECIMAL_DIG`` + Number of base-10 digits that are necessary to uniquely represent + all distinct values: + + ceil(``HALF_MANT_DIG`` * log10(2) + 1) => 4.31... -> 5 + +``HALF_RADIX`` + Base of the exponent. + +``HALF_DENORM_MIN_EXP`` + Minimum negative integer such that ``HALF_RADIX`` raised to the + power of one less than that integer is a normalized half. + +``HALF_MAX_EXP`` + Maximum positive integer such that ``HALF_RADIX`` raised to the + power of one less than that integer is a normalized half. + +``HALF_DENORM_MIN_10_EXP`` + Minimum positive integer such that 10 raised to that power is a + normalized half. + +``HALF_MAX_10_EXP`` + Maximum positive integer such that 10 raised to that power is a + normalized half. + +``std::numeric_limits`` +----------------------------- + +The ``half`` type provides specializations for +``std::numeric_limits``: + ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::min() `_ | ``HALF_MIN`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::max() `_ | ``HALF_MAX`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::lowest() `_ | ``-HALF_MAX`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::digits `_ | ``HALF_MANT_DIG`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::digits10 `_ | ``HALF_DIG`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::max_digits10 `_ | ``HALF_DECIMAL_DIG`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::is_signed `_ | ``true`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::is_integer `_ | ``false`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::is_exact `_ | ``false`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::radix `_ | ``HALF_RADIX`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::epsilon() `_ | ``HALF_EPSILON`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::round_error() `_ | ``0.5`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::min_exponent `_ | ``HALF_DENORM_MIN_EXP`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::min_exponent10 `_ | ``HALF_DENORM_MIN_10_EXP`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::max_exponent `_ | ``HALF_MAX_EXP`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::max_exponent10 `_ | ``HALF_MAX_10_EXP`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::has_infinity `_ | ``true`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::has_quiet_NaN `_ | ``true`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::has_signaling_NaN `_ | ``true`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::has_denorm `_ | ``std::denorm_present`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::has_denorm_loss `_ | ``false`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::infinity() `_ | ``half::posInf()`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::quiet_NaN() `_ | ``half::qNan()`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::signaling_NaN() `_ | ``half::sNan()`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ +| `std::numeric_limits::denorm_min() `_ | ``HALF_DENORM_MIN`` | ++----------------------------------------------------------------------------------------------------------------------------+----------------------------+ + + diff -Nru ilmbase-3.1.9-imath/website/classes.rst ilmbase-3.1.10/website/classes.rst --- ilmbase-3.1.9-imath/website/classes.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/classes.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,34 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _Imath Classes: + +Imath Classes +############# + +.. toctree:: + :caption: Classes + :maxdepth: 2 + + classes/half + classes/Box + classes/Color3 + classes/Color4 + classes/Euler + classes/Frustum + classes/Interval + classes/Line3 + classes/Matrix22 + classes/Matrix33 + classes/Matrix44 + classes/Plane3 + classes/Quat + classes/Rand32 + classes/Rand48 + classes/Shear6 + classes/Sphere3 + classes/Vec2 + classes/Vec3 + classes/Vec4 + diff -Nru ilmbase-3.1.9-imath/website/concepts.rst ilmbase-3.1.10/website/concepts.rst --- ilmbase-3.1.9-imath/website/concepts.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/concepts.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,143 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _Concepts: + +Concepts +######## + +.. toctree:: + :caption: Concepts + :maxdepth: 0 + +The Imath library emphasizes simplicity, ease of use, correctness and +verifiability, performance, and breadth of adoption. Imath is not +intended to be a comprehensive linear algebra or numerical analysis +package. + +Imath is not a substitute for `Eigen `_! +It's not a full-featured linear algebra package, and it doesn't +represent vectors and matrices of arbitrary dimension. Its greatest +utility is as a geometric data representation, primarily for 2D images +and 3D scenes and coordinate transformations, along with an +accompanying set of utility methods and functions. + +Example +======= + +A basic program: + +.. literalinclude:: examples/intro.cpp + +Matrices Are Row-Major +====================== + +Imath stores matrices in row-major layout, originally inspired by +compatibility with OpenGL matrices. + +A matrix described as: + +.. math:: + \begin{bmatrix} + m_{00} & m_{01} & m_{02} & m_{03} \\ + m_{10} & m_{11} & m_{12} & m_{13} \\ + m_{20} & m_{21} & m_{22} & m_{23} \\ + m_{30} & m_{31} & m_{32} & m_{33} \\ + \end{bmatrix} + +is laid out in memory as: + +.. list-table:: + :widths: 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 + :header-rows: 1 + + * - 0 + - 1 + - 2 + - 3 + - 4 + - 5 + - 6 + - 7 + - 8 + - 9 + - 10 + - 11 + - 12 + - 13 + - 14 + - 15 + * - :math:`m_{00}` + - :math:`m_{01}` + - :math:`m_{02}` + - :math:`m_{03}` + - :math:`m_{10}` + - :math:`m_{11}` + - :math:`m_{12}` + - :math:`m_{13}` + - :math:`m_{20}` + - :math:`m_{21}` + - :math:`m_{22}` + - :math:`m_{23}` + - :math:`m_{30}` + - :math:`m_{31}` + - :math:`m_{32}` + - :math:`m_{33}` + +A matrix representing a homogeneous transform has a right-hand column +of :math:`\begin{bmatrix} 0 & 0 & 0 & 1\end{bmatrix}` and the +translation component across the bottom row. + +As a result, it is best to think of Imath vectors as row-vectors, and +vector-matrix multiplication with the vector on the left and matrix on +the right: + +.. math:: + \begin{bmatrix} v_{0}' & v_{1}' & v_{2}' & 1' \end{bmatrix} + = + \begin{bmatrix} v_{0} & v_{1} & v_{2} & 1 \end{bmatrix} + \begin{bmatrix} m_{00} & m_{01} & m_{02} & 0 \\ + m_{10} & m_{11} & m_{12} & 0 \\ + m_{20} & m_{21} & m_{22} & 0 \\ + m_{30} & m_{31} & m_{32} & 1 + \end{bmatrix} + +This further implies that you should interpret local transformations +as pre-multiplication: + +.. code-block:: + + M44f M; + M.translate (tx, ty, tz); + m.rotate (r, 0, 0); + m.scale (s); + +.. math:: + \begin{bmatrix} + m_{00} & m_{01} & m_{02} & m_{03} \\ + m_{10} & m_{11} & m_{12} & m_{13} \\ + m_{20} & m_{21} & m_{22} & m_{23} \\ + m_{30} & m_{31} & m_{32} & m_{33} \\ + \end{bmatrix} + = + \begin{bmatrix} + s & 0 & 0 & 0 \\ + 0 & s & 0 & 0 \\ + 0 & 0 & s & 0 \\ + 0 & 0 & 0 & 1 \\ + \end{bmatrix} + \begin{bmatrix} + 1 & 0 & 0 & 0 \\ + 0 & \cos(r) & \sin(r) & 0 \\ + 0 & -\sin(r) & \cos(r) & 0 \\ + 0 & 0 & 0 & 1 \\ + \end{bmatrix} + \begin{bmatrix} + 1 & 0 & 0 & 0 \\ + 0 & 1 & 0 & 0 \\ + 0 & 0 & 1 & 0 \\ + tx & ty & tz & 1 \\ + \end{bmatrix} + + diff -Nru ilmbase-3.1.9-imath/website/conf.py ilmbase-3.1.10/website/conf.py --- ilmbase-3.1.9-imath/website/conf.py 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/conf.py 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,309 @@ +#!/usr/bin/env python3 + +# SPDX-License-Identifier: BSD-3-Clause +# Copyright Contributors to the OpenEXR Project. + +# -*- coding: utf-8 -*- +# +# ReadTheDocs-Breathe documentation build configuration file, created by +# sphinx-quickstart on Mon Feb 10 20:03:57 2014. +# +# This file is execfile()d with the current directory set to its +# containing dir. +# +# Note that not all possible configuration values are present in this +# autogenerated file. +# +# All configuration values have a default; values that are commented out +# serve to show the default. + +import sys +import os + +# If extensions (or modules to document with autodoc) are in another directory, +# add these directories to sys.path here. If the directory is relative to the +# documentation root, use os.path.abspath to make it absolute, like shown here. +#sys.path.insert(0, os.path.abspath('.')) + +# hack for readthedocs to cause it to run doxygen first +# https://github.com/rtfd/readthedocs.org/issues/388 + +on_rtd = os.environ.get('READTHEDOCS', None) == 'True' +if on_rtd: + + with open("Doxyfile.in", "r") as file: + filedata = file.read() + + doxygen_output_dir = "_build" + filedata = filedata.replace('@DOXYGEN_INPUT_DIR@', "../src/Imath") + filedata = filedata.replace('@DOXYGEN_OUTPUT_DIR@', "doxygen") + + with open("Doxyfile", "w") as file: + file.write(filedata) + + from subprocess import call + call('doxygen') + +# -- General configuration ------------------------------------------------ + +# If your documentation needs a minimal Sphinx version, state it here. +#needs_sphinx = '1.0' + +# Add any Sphinx extension module names here, as strings. They can be +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom +# ones. +extensions = [ + 'sphinx.ext.autodoc', + 'sphinx.ext.todo', + 'sphinx.ext.viewcode', + 'breathe', +] + +# Breathe extension variables +breathe_projects = { "Imath": "doxygen/xml" } +breathe_default_project = "Imath" + +# Add any paths that contain templates here, relative to this directory. +templates_path = ['_templates'] + +# The suffix of source filenames. +source_suffix = '.rst' + +# The encoding of source files. +#source_encoding = 'utf-8-sig' + +# General information about the project. +project = 'Imath' +copyright = '2021, Contributors to the OpenEXR Project' + +# The version info for the project you're documenting, acts as replacement for +# |version| and |release|, also used in various other places throughout the +# built documents. +# +project_Imath_VERSION = "project(Imath VERSION " +release = None +for l in open ("../CMakeLists.txt"): + if l.startswith (project_Imath_VERSION): + release = l.split (' ')[2] + break +if release == None: + print ("Error in conf.py: can't find Imath VERSION in ../CMakeList.txt") + exit(-1) + +v = release.split('.') +# The short X.Y version. +version = "%s.%s" % (v[0], v[1]) + +# The language for content autogenerated by Sphinx. Refer to documentation +# for a list of supported languages. +#language = None + +# There are two options for replacing |today|: either, you set today to some +# non-false value, then it is used: +#today = '' +# Else, today_fmt is used as the format for a strftime call. +#today_fmt = '%B %d, %Y' + +# List of patterns, relative to source directory, that match files and +# directories to ignore when looking for source files. +exclude_patterns = ['_build'] + +# The reST default role (used for this markup: `text`) to use for all +# documents. +#default_role = None + +# If true, '()' will be appended to :func: etc. cross-reference text. +#add_function_parentheses = True + +# If true, the current module name will be prepended to all description +# unit titles (such as .. function::). +#add_module_names = True + +# If true, sectionauthor and moduleauthor directives will be shown in the +# output. They are ignored by default. +#show_authors = False + +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = 'sphinx' + +# A list of ignored prefixes for module index sorting. +#modindex_common_prefix = [] + +# If true, keep warnings as "system message" paragraphs in the built documents. +#keep_warnings = False + + +# -- Options for HTML output ---------------------------------------------- + +# The theme to use for HTML and HTML Help pages. See the documentation for +# a list of builtin themes. +#html_theme = 'agogo' +#html_theme = 'default' # good +#html_theme = 'nature' # too green +#html_theme = 'bizstyle' # OK +#html_theme = 'sphinxdoc' + +html_theme = "press" +html_theme_options = { + "external_links": [ + ("Github", "https://github.com/AcademySoftwareFoundation/Imath"), + ] +} + +# Theme options are theme-specific and customize the look and feel of a theme +# further. For a list of options available for each theme, see the +# documentation. +#html_theme_options = {} + +# Add any paths that contain custom themes here, relative to this directory. +#html_theme_path = [] + +# The name for this set of Sphinx documents. If None, it defaults to +# " v documentation". +html_title = "Imath Documentation" + +# A shorter title for the navigation bar. Default is the same as html_title. +html_short_title = "Imath" + +# The name of an image file (relative to this directory) to place at the top +# of the sidebar. +html_logo = "images/imath-logo-blue.png" + +# The name of an image file (within the static path) to use as favicon of the +# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 +# pixels large. +html_favicon = "images/imath-fav.ico" + +# Add any paths that contain custom static files (such as style sheets) here, +# relative to this directory. They are copied after the builtin static files, +# so a file named "default.css" will overwrite the builtin "default.css". +#html_static_path = ['_static'] + +# Add any extra paths that contain custom files (such as robots.txt or +# .htaccess) here, relative to this directory. These files are copied +# directly to the root of the documentation. +#html_extra_path = [] + +# If not '', a 'Last updated on:' timestamp is inserted at every page bottom, +# using the given strftime format. +html_last_updated_fmt = '%b %d, %Y' + +# If true, SmartyPants will be used to convert quotes and dashes to +# typographically correct entities. +html_use_smartypants = True + +# Custom sidebar templates, maps document names to template names. +#html_sidebars = {} + +# Additional templates that should be rendered to pages, maps page names to +# template names. +#html_additional_pages = {} + +# If false, no module index is generated. +#html_domain_indices = True + +# If false, no index is generated. +#html_use_index = True + +# If true, the index is split into individual pages for each letter. +#html_split_index = False + +# If true, links to the reST sources are added to the pages. +#html_show_sourcelink = True + +# If true, "Created using Sphinx" is shown in the HTML footer. Default is True. +#html_show_sphinx = True + +# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True. +#html_show_copyright = True + +# If true, an OpenSearch description file will be output, and all pages will +# contain a tag referring to it. The value of this option must be the +# base URL from which the finished HTML is served. +#html_use_opensearch = '' + +# This is the file name suffix for HTML files (e.g. ".xhtml"). +#html_file_suffix = None + +# Output file base name for HTML help builder. +htmlhelp_basename = 'Imath' + + +# -- Options for LaTeX output --------------------------------------------- + +#latex_elements = { +# The paper size ('letterpaper' or 'a4paper'). +#'papersize': 'letterpaper', + +# The font size ('10pt', '11pt' or '12pt'). +#'pointsize': '10pt', + +# Additional stuff for the LaTeX preamble. +#'preamble': '', +#} + +# Grouping the document tree into LaTeX files. List of tuples +# (source start file, target name, title, +# author, documentclass [howto, manual, or own class]). +#latex_documents = [ +# ('index', 'Imath.tex', 'Imath Documentation', +# 'Contributors to the OpenEXR Project', 'manual'), +#] + +# The name of an image file (relative to this directory) to place at the top of +# the title page. +#latex_logo = None + +# For "manual" documents, if this is true, then toplevel headings are parts, +# not chapters. +#latex_use_parts = False + +# If true, show page references after internal links. +#latex_show_pagerefs = False + +# If true, show URL addresses after external links. +#latex_show_urls = False + +# Documents to append as an appendix to all manuals. +#latex_appendices = [] + +# If false, no module index is generated. +#latex_domain_indices = True + + +# -- Options for manual page output --------------------------------------- + +# One entry per manual page. List of tuples +# (source start file, name, description, authors, manual section). +man_pages = [ + ('index', 'imath', 'Imath Documentation', + ['Contributors to the OpenEXR Project'], 1) +] + +# If true, show URL addresses after external links. +#man_show_urls = False + + +# -- Options for Texinfo output ------------------------------------------- + +# Grouping the document tree into Texinfo files. List of tuples +# (source start file, target name, title, author, +# dir menu entry, description, category) +texinfo_documents = [ + ('index', 'Imath', 'Imath Documentation', + 'Contributors to the OpenEXR Project', 'Imath', + '2D and 3D vectors and matrices, half 16-bit floating-point type', + 'Miscellaneous'), +] + +# Documents to append as an appendix to all manuals. +#texinfo_appendices = [] + +# If false, no module index is generated. +#texinfo_domain_indices = True + +# How to display URL addresses: 'footnote', 'no', or 'inline'. +#texinfo_show_urls = 'footnote' + +# If true, do not generate a @detailmenu in the "Top" node's menu. +#texinfo_no_detailmenu = False diff -Nru ilmbase-3.1.9-imath/website/examples/Box.cpp ilmbase-3.1.10/website/examples/Box.cpp --- ilmbase-3.1.9-imath/website/examples/Box.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Box.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,25 @@ +#include + +void +box_example() +{ + Imath::V3f a (0, 0, 0); + Imath::V3f b (1, 1, 1); + Imath::V3f c (2, 9, 2); + + Imath::Box3f box (a); + + assert (box.isEmpty()); + assert (!box.isInfinite()); + assert (!box.hasVolume()); + + box.extendBy (c); + + assert (box.size() == (c-a)); + assert (box.intersects (b)); + assert (box.max[0] > box.min[0]); + assert (box.max[1] > box.min[1]); + assert (box.max[2] > box.min[2]); + assert (box.hasVolume()); + assert (box.majorAxis() == 1); +} diff -Nru ilmbase-3.1.9-imath/website/examples/CMakeLists.txt ilmbase-3.1.10/website/examples/CMakeLists.txt --- ilmbase-3.1.9-imath/website/examples/CMakeLists.txt 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/CMakeLists.txt 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,48 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright Contributors to the OpenEXR Project. + +cmake_minimum_required(VERSION 3.10) + +project(imath-examples) + +find_package(Imath) + +# The introductory example on the main docs page +add_executable(imath-intro intro.cpp) + +# A main() that executes all the example code snippets +add_executable(imath-examples + main.cpp + Color3.cpp + Color4.cpp + Euler.cpp + Frustum.cpp + Interval.cpp + Line3.cpp + Matrix22.cpp + Matrix33.cpp + Matrix44.cpp + Plane3.cpp + Quat.cpp + Shear6.cpp + Sphere3.cpp + Vec2.cpp + Vec3.cpp + Vec4.cpp + half.cpp +) + +target_link_libraries(imath-intro Imath::Imath) +target_link_libraries(imath-examples Imath::Imath) + +set_target_properties(imath-examples PROPERTIES + RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin" +) +set_target_properties(imath-intro PROPERTIES + RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin" +) + +add_test(NAME Imath.imath-intro COMMAND $) +add_test(NAME Imath.imath-examples COMMAND $) + +enable_testing() diff -Nru ilmbase-3.1.9-imath/website/examples/Color3.cpp ilmbase-3.1.10/website/examples/Color3.cpp --- ilmbase-3.1.9-imath/website/examples/Color3.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Color3.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,16 @@ +#include +#include + +void +color3_example() +{ + Imath::C3c r (255, 0, 0); + Imath::C3c g (0, 255, 0); + Imath::C3c b (0, 0, 255); + + Imath::C3c c = r + g + b; + + assert (c.x == 255); + assert (c.x == 255); + assert (c.x == 255); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Color4.cpp ilmbase-3.1.10/website/examples/Color4.cpp --- ilmbase-3.1.9-imath/website/examples/Color4.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Color4.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,17 @@ +#include +#include + +void +color4_example() +{ + Imath::C4f r (1.0f, 0.0f, 0.0f, 1.0f); + Imath::C4f g (0.0f, 1.0f, 0.0f, 1.0f); + Imath::C4f b (0.0f, 0.0f, 1.0f, 1.0f); + + Imath::C4f w = r + g + b; + + assert (w.r == 1.0f); + assert (w.g == 1.0f); + assert (w.b == 1.0f); + assert (w.a == 3.0f); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Euler.cpp ilmbase-3.1.10/website/examples/Euler.cpp --- ilmbase-3.1.9-imath/website/examples/Euler.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Euler.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,25 @@ +#include +#include +#include + +void +euler_example() +{ + int i, j, k; + + Imath::Eulerf xyz (Imath::Eulerf::XYZ); + xyz.angleOrder (i, j, k); + assert (i == 0 && j == 1 && k == 2); + + Imath::Eulerf xzy (Imath::Eulerf::XZY); + xzy.angleOrder (i, j, k); + assert (i == 0 && j == 2 && k == 1); + + Imath::Eulerf e1 (0.0f, 0.0f, 0.1f + 2 * M_PI); + Imath::Eulerf e2 (0.0f, 0.0f, 0.1f); + + e1.makeNear (e2); + Imath::V3f v = e2.toXYZVector(); + assert (v.equalWithAbsError (Imath::V3f (0.0f, 0.0f, 0.1f), 0.00001f)); +} + diff -Nru ilmbase-3.1.9-imath/website/examples/Frustum.cpp ilmbase-3.1.10/website/examples/Frustum.cpp --- ilmbase-3.1.9-imath/website/examples/Frustum.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Frustum.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,22 @@ +#include +#include + +void +frustum_example() +{ + float near = 1.7f; + float far = 567.0f; + float left = -3.5f; + float right = 2.0f; + float top = 0.9f; + float bottom = -1.3f; + + Imath::Frustumf frustum (near, far, left, right, top, bottom, false); + + Imath::M44f m = frustum.projectionMatrix(); + + Imath::V3f p (1.0f, 1.0f, 1.0f); + Imath::V2f s = frustum.projectPointToScreen (p); + + assert (s.equalWithAbsError (Imath::V2f (-0.345455f, -1.36364f), 0.0001f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Interval.cpp ilmbase-3.1.10/website/examples/Interval.cpp --- ilmbase-3.1.9-imath/website/examples/Interval.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Interval.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,19 @@ +#include +#include + +void +interval_example() +{ + Imath::Intervalf v; + + assert (v.isEmpty()); + assert (!v.hasVolume()); + assert (!v.isInfinite()); + + v.extendBy (1.0f); + assert (!v.isEmpty()); + + v.extendBy (2.0f); + assert (v.hasVolume()); + assert (v.intersects (1.5f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Line3.cpp ilmbase-3.1.10/website/examples/Line3.cpp --- ilmbase-3.1.9-imath/website/examples/Line3.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Line3.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,23 @@ +#include +#include + +void +line3_example() +{ + Imath::V3f a (0.0f, 0.0f, 0.0f); + Imath::V3f b (1.0f, 1.0f, 1.0f); + + Imath::Line3f line (a, b); + + assert (line.pos == a); + assert (line.dir == (b-a).normalized()); + + Imath::V3f c (0.5f, 0.5f, 0.5f); + + float f = line.distanceTo (c); + assert (Imath::equalWithAbsError (f, 0.0f, 0.0001f)); + + Imath::V3f p = line (0.5f); // midpoint, i.e. 0.5 units from a along (b-a) + + assert (p.equalWithAbsError (Imath::V3f (0.288675f, 0.288675f, 0.288675f), 0.0001f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Matrix22.cpp ilmbase-3.1.10/website/examples/Matrix22.cpp --- ilmbase-3.1.9-imath/website/examples/Matrix22.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Matrix22.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,27 @@ +#include +#include +#include + +void +matrix22_example() +{ + Imath::M22f M (Imath::UNINITIALIZED); // uninitialized + + M.makeIdentity(); + assert (M[0][0] == 1.0f); + assert (M[0][1] == 0.0f); + + Imath::M22f Minv = M.inverse(); + + Imath::M22f R; + assert (R == Imath::identity22f); + + R.rotate (M_PI/4); + + M = R * M; + + Imath::V2f v2 (1.0f, 0.0f); + Imath::V2f r2 = v2 * M; + + assert (r2.equalWithAbsError (Imath::V2f (0.707107f, 0.707107f), 1e-6f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Matrix33.cpp ilmbase-3.1.10/website/examples/Matrix33.cpp --- ilmbase-3.1.9-imath/website/examples/Matrix33.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Matrix33.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,27 @@ +#include +#include +#include + +void +matrix33_example() +{ + Imath::M33f M (Imath::UNINITIALIZED); // uninitialized + + M.makeIdentity(); + assert (M[0][0] == 1.0f); + assert (M[0][1] == 0.0f); + + Imath::M33f Minv = M.inverse(); + + Imath::M33f R; + assert (R == Imath::identity33f); + + R.rotate (M_PI/4); + + M = R * M; + + Imath::V3f v3 (1.0f, 0.0f, 0.0f); + Imath::V3f r3 = v3 * M; + + assert (r3.equalWithAbsError (Imath::V3f (0.707107f, 0.7071070f, 0.0f), 1e-6f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Matrix44.cpp ilmbase-3.1.10/website/examples/Matrix44.cpp --- ilmbase-3.1.9-imath/website/examples/Matrix44.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Matrix44.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,31 @@ +#include +#include +#include + +void +matrix44_example() +{ + Imath::M44f M (Imath::UNINITIALIZED); // uninitialized + + M.makeIdentity(); + assert (M[0][0] == 1.0f); + assert (M[0][1] == 0.0f); + + Imath::M44f Minv = M.inverse(); + + Imath::M44f R; + assert (R == Imath::identity44f); + + R.rotate (Imath::V3f (0.02f, M_PI/4, 0.0f)); + + M = R * M; + + Imath::V3f v3 (1.0f, 0.0f, 0.0f); + Imath::V4f v4 (1.0f, 0.0f, 0.0f, 1.0f); + + Imath::V3f r3 = v3 * M; + assert (r3.equalWithAbsError (Imath::V3f (0.707107f, 0.0f, -0.7071070f), 1e-6f)); + + Imath::V4f r4 = v4 * M; + assert (r4.equalWithAbsError (Imath::V4f (0.707107f, 0.0f, -0.7071070f, 1.0f), 1e-6f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Plane3.cpp ilmbase-3.1.10/website/examples/Plane3.cpp --- ilmbase-3.1.9-imath/website/examples/Plane3.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Plane3.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,21 @@ +#include +#include + +void +plane3_example() +{ + Imath::V3f a (1.0f, 0.0f, 0.0f); + Imath::V3f b (0.0f, 1.0f, 0.0f); + Imath::V3f c (0.0f, 0.0f, 1.0f); + + Imath::Plane3f p (a, b, c); + + Imath::V3f n (1.0f, 1.0f, 1.0f); + n.normalize(); + + assert (p.normal == n); + + Imath::V3f o (0.0f, 0.0f, 0.0f); + float d = p.distanceTo (o); + assert (Imath::equalWithAbsError (d, -0.57735f, 1e-6f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Quat.cpp ilmbase-3.1.10/website/examples/Quat.cpp --- ilmbase-3.1.9-imath/website/examples/Quat.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Quat.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,12 @@ +#include +#include + +void +quat_example() +{ + Imath::Quatf q (2.0f, 3.0f, 4.0f, 5.0f); + assert (q.r == 2.0f && q.v == Imath::V3f (3.0f, 4.0f, 5.0f)); + + Imath::Quatf r (1.0f, 0.0f, 0.0f, 1.0f); + assert (r.inverse() == Imath::Quatf (0.5f, 0.0f, 0.0f, -0.5f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Shear6.cpp ilmbase-3.1.10/website/examples/Shear6.cpp --- ilmbase-3.1.9-imath/website/examples/Shear6.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Shear6.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,11 @@ +#include +#include + +void +shear6_example() +{ + Imath::Shear6f s (0.330f, 0.710f, 0.010f, 0.999f, -0.531f, -0.012f); + + Imath::M44f M; + M.setShear (s); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Sphere3.cpp ilmbase-3.1.10/website/examples/Sphere3.cpp --- ilmbase-3.1.9-imath/website/examples/Sphere3.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Sphere3.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,21 @@ +#include +#include + +void +sphere3_example() +{ + Imath::V3f center (1.0f, 1.0f, 1.0f); + float radius = 2.0f; + Imath::Sphere3f s (center, radius); + + assert (s.center == center); + assert (s.radius == radius); + + Imath::Line3f line (Imath::V3f (0.0f, 0.0f, 0.0f), + Imath::V3f (1.0f, 1.0f, 1.0f)); + + Imath::V3f v; + assert (s.intersect (line, v)); + + assert (v.equalWithAbsError (Imath::V3f(2.1547f, 2.1547f, 2.1547f), 1e-6f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Vec2.cpp ilmbase-3.1.10/website/examples/Vec2.cpp --- ilmbase-3.1.9-imath/website/examples/Vec2.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Vec2.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,19 @@ +#include +#include + +void +vec2_example() +{ + Imath::V2f a (1.0f, 2.0f); + Imath::V2f b; // b is uninitialized + + b.x = a[0]; + b.y = a[1]; + + assert (a == b); + + assert (a.length() == sqrt (a ^ a)); + + a.normalize(); + assert (Imath::equalWithAbsError (a.length(), 1.0f, 1e-6f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Vec3.cpp ilmbase-3.1.10/website/examples/Vec3.cpp --- ilmbase-3.1.9-imath/website/examples/Vec3.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Vec3.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,20 @@ +#include +#include + +void +vec3_example() +{ + Imath::V3f a (1.0f, 2.0f, 3.0f); + Imath::V3f b; // b is uninitialized + + b.x = a[0]; + b.y = a[1]; + b.z = a[2]; + + assert (a == b); + + assert (a.length() == sqrt (a ^ a)); + + a.normalize(); + assert (Imath::equalWithAbsError (a.length(), 1.0f, 1e-6f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/Vec4.cpp ilmbase-3.1.10/website/examples/Vec4.cpp --- ilmbase-3.1.9-imath/website/examples/Vec4.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/Vec4.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,21 @@ +#include +#include + +void +vec4_example() +{ + Imath::V4f a (1.0f, 2.0f, 3.0f, 4.0f); + Imath::V4f b; // b is uninitialized + + b.x = a[0]; + b.y = a[1]; + b.z = a[2]; + b.w = a[3]; + + assert (a == b); + + assert (a.length() == sqrt (a ^ a)); + + a.normalize(); + assert (Imath::equalWithAbsError (a.length(), 1.0f, 1e-6f)); +} diff -Nru ilmbase-3.1.9-imath/website/examples/gl.cpp ilmbase-3.1.10/website/examples/gl.cpp --- ilmbase-3.1.9-imath/website/examples/gl.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/gl.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,12 @@ +#include + +void +gl_example() +{ + Imath::M44f M; + glPushMatrix (M); + + Imath::V3f v (0.0f, 1.0f, 2.0f); + glVertex (v); +} + diff -Nru ilmbase-3.1.9-imath/website/examples/half.c ilmbase-3.1.10/website/examples/half.c --- ilmbase-3.1.9-imath/website/examples/half.c 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/half.c 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,12 @@ +#include + +void +half_example() +{ + float f = 3.5f; + + half h = imath_float_to_half (f) + + float hh = imath_half_to_float (h) +} + diff -Nru ilmbase-3.1.9-imath/website/examples/half.cpp ilmbase-3.1.10/website/examples/half.cpp --- ilmbase-3.1.9-imath/website/examples/half.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/half.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,13 @@ +#include +#include + +void +half_example() +{ + half a (3.5); + float b (a + sqrt (a)); + a += b; + b += a; + b = a + 7; +} + diff -Nru ilmbase-3.1.9-imath/website/examples/intro.cpp ilmbase-3.1.10/website/examples/intro.cpp --- ilmbase-3.1.9-imath/website/examples/intro.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/intro.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,24 @@ +#include +#include +#include +#include + +int +main() +{ + const Imath::V3f v (3.0f, 4.0f, 5.0f); + + Imath::M44f M; + const Imath::V3f t(1.0f, 2.0f, 3.0f); + M.translate (t); + + Imath::V3f p; + M.multVecMatrix(v, p); + + std::cout << "What's your vector, Victor? " << p << std::endl; + + Imath::V3f vt = v + t; + assert (p.equalWithAbsError(vt, 1e-6f)); + + return 0; +} diff -Nru ilmbase-3.1.9-imath/website/examples/main.cpp ilmbase-3.1.10/website/examples/main.cpp --- ilmbase-3.1.9-imath/website/examples/main.cpp 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/examples/main.cpp 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,50 @@ +// SPDX-License-Identifier: BSD-3-Clause +// Copyright Contributors to the OpenEXR Project. + +#include + +void color3_example(); +void color4_example(); +void euler_example(); +void frustum_example(); +void interval_example(); +void line3_example(); +void matrix22_example(); +void matrix33_example(); +void matrix44_example(); +void plane3_example(); +void quat_example(); +void shear6_example(); +void sphere3_example(); +void vec2_example(); +void vec3_example(); +void vec4_example(); +void half_example(); + +int +main (int argc, char* argv[]) +{ + std::cout << "imath examples..." << std::endl; + + color3_example(); + color4_example(); + euler_example(); + frustum_example(); + interval_example(); + line3_example(); + matrix22_example(); + matrix33_example(); + matrix44_example(); + plane3_example(); + quat_example(); + shear6_example(); + sphere3_example(); + vec2_example(); + vec3_example(); + vec4_example(); + half_example(); + + std::cout << "done." << std::endl; + + return 0; +} diff -Nru ilmbase-3.1.9-imath/website/fixmanpages.sh ilmbase-3.1.10/website/fixmanpages.sh --- ilmbase-3.1.9-imath/website/fixmanpages.sh 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/fixmanpages.sh 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,24 @@ +#!/bin/bash + +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + +# Fix the names of doxygen-generated man page Files: +# * Strip "_ Vec" and "_ T _ _" from "Imath_Box_ Vec2_ T _ _.3" +# * and rename "Imath_*" to "Imath::*" + +if [ -d $1/man/man3 ]; then + + cd $1/man/man3 + echo cd $1/man/man3 + shopt -s nullglob + for file in Imath_*.3; + do + new=`echo $file | sed -e 's/_ T _ _//g' -e 's/_ Vec//g' -e s/_/::/g` + echo /bin/mv "$file" $new + /bin/mv "$file" $new + done +fi + + + diff -Nru ilmbase-3.1.9-imath/website/functions/box.rst ilmbase-3.1.10/website/functions/box.rst --- ilmbase-3.1.9-imath/website/functions/box.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/box.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,26 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _box-functions: + +Box Functions +############# + +Functions that operate on bounding boxes. + +.. code-block:: + + #include + +.. doxygenfunction:: clip + +.. doxygenfunction:: closestPointInBox + +.. doxygenfunction:: transform(const Box>& box, const Matrix44& m) noexcept + +.. doxygenfunction:: affineTransform(const Box>& box, const Matrix44& m) noexcept + +.. doxygenfunction:: findEntryAndExitPoints + +.. doxygenfunction:: intersects(const Box>& b, const Line3& r, Vec3& ip) noexcept diff -Nru ilmbase-3.1.9-imath/website/functions/color.rst ilmbase-3.1.10/website/functions/color.rst --- ilmbase-3.1.9-imath/website/functions/color.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/color.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,32 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _color-functions: + +Color Functions +############### + +Functions that operate on colors. + +.. code-block:: + + #include + +.. doxygenfunction:: hsv2rgb(const Vec3& hsv) noexcept + +.. doxygenfunction:: hsv2rgb(const Color4& hsv) noexcept + +.. doxygenfunction:: rgb2hsv(const Color4 &rgb) noexcept + +.. doxygenfunction:: rgb2hsv(const Vec3 &rgb) noexcept + +.. doxygenfunction:: rgb2packed(const Color4 &c) noexcept + +.. doxygenfunction:: rgb2packed(const Vec3 &c) noexcept + +.. doxygenfunction:: packed2rgb(PackedColor packed, Color4 &out) noexcept + +.. doxygenfunction:: packed2rgb(PackedColor packed, Vec3 &out) noexcept + + diff -Nru ilmbase-3.1.9-imath/website/functions/frame.rst ilmbase-3.1.10/website/functions/frame.rst --- ilmbase-3.1.9-imath/website/functions/frame.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/frame.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,20 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _frame-functions: + +Frame Functions +############### + +Functions to compute coordinate frames. + +.. code-block:: + + #include + +.. doxygenfunction:: firstFrame + +.. doxygenfunction:: nextFrame + +.. doxygenfunction:: lastFrame diff -Nru ilmbase-3.1.9-imath/website/functions/gl.rst ilmbase-3.1.10/website/functions/gl.rst --- ilmbase-3.1.9-imath/website/functions/gl.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/gl.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,53 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _gl-functions: + +GL Functions +############ + +Functions that wrap OpenGL calls to accept Imath vectors and matrices. + +.. code-block:: + + #include + +Example: + +.. literalinclude:: ../examples/gl.cpp + :language: c++ + +.. doxygenfunction:: glVertex(const Imath::V2f &v) + +.. doxygenfunction:: glVertex(const Imath::V3f &v) + +.. doxygenfunction:: glNormal(const Imath::V3f &v) + +.. doxygenfunction:: glColor(const Imath::V3f &v) + +.. doxygenfunction:: glTranslate + +.. doxygenfunction:: glTexCoord + +.. doxygenfunction:: throwBadMatrix + +.. doxygenfunction:: glMultMatrix( const Imath::M44f &m ) + +.. doxygenfunction:: glMultMatrix( const Imath::M44f *m ) + +.. doxygenfunction:: glLoadMatrix(const Imath::M44f &m) + +.. doxygenfunction:: glLoadMatrix(const Imath::M44f *m) + +.. doxygenclass:: Imath::GLPushMatrix + :members: + :undoc-members: + +.. doxygenclass:: Imath::GLPushAttrib + :members: + :undoc-members: + +.. doxygenclass:: Imath::GLBegin + :members: + :undoc-members: diff -Nru ilmbase-3.1.9-imath/website/functions/glu.rst ilmbase-3.1.10/website/functions/glu.rst --- ilmbase-3.1.9-imath/website/functions/glu.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/glu.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,16 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _glu-functions: + +GLU Functions +############# + +Functions that wrap GLU calls to accept Imath vectors. + +.. code-block:: + + #include + +.. doxygenfunction:: gluLookAt(const Imath::V3f& pos, const Imath::V3f& interest, const Imath::V3f& up) diff -Nru ilmbase-3.1.9-imath/website/functions/line.rst ilmbase-3.1.10/website/functions/line.rst --- ilmbase-3.1.9-imath/website/functions/line.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/line.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,22 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _line-functions: + +Line3 Functions +############### + +.. code-block:: + + #include + +Functions that operate on the ``Line3`` object. + +.. doxygenfunction:: closestPoints + +.. doxygenfunction:: intersect(const Line3& line, const Vec3&v0, const Vec3& v1, const Vec3& v2, Vec3& pt, Vec3& barycentric, bool& front) noexcept + +.. doxygenfunction:: closestVertex(const Vec3& v0, const Vec3& v1, const Vec3& v2, const Line3& l) noexcept + +.. doxygenfunction:: rotatePoint diff -Nru ilmbase-3.1.9-imath/website/functions/matrix.rst ilmbase-3.1.10/website/functions/matrix.rst --- ilmbase-3.1.9-imath/website/functions/matrix.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/matrix.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,104 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _matrix-functions: + +Matrix Functions +################ + +.. code-block:: + + #include + +Functions that operate on matrices + +.. doxygenfunction:: extractScaling(const Matrix44& mat, Vec3& scl, bool exc) + +.. doxygenfunction:: sansScaling(const Matrix44& mat, bool exc) + +.. doxygenfunction:: removeScaling(Matrix44& mat, bool exc) + +.. doxygenfunction:: extractScalingAndShear(const Matrix44& mat, Vec3& scl, Vec3& shr, bool exc) + +.. doxygenfunction:: sansScalingAndShear(const Matrix44& mat, bool exc) + +.. doxygenfunction:: sansScalingAndShear(Matrix44& result, const Matrix44& mat, bool exc) + +.. doxygenfunction:: removeScalingAndShear(Matrix44& mat, bool exc) + +.. doxygenfunction:: extractAndRemoveScalingAndShear(Matrix44& mat, Vec3& scl, Vec3& shr, bool exc) + +.. doxygenfunction:: extractEulerXYZ(const Matrix44& mat, Vec3& rot) + +.. doxygenfunction:: extractEulerZYX(const Matrix44& mat, Vec3& rot) + +.. doxygenfunction:: extractQuat(const Matrix44& mat) + +.. doxygenfunction:: extractSHRT(const Matrix44& mat, Vec3& s, Vec3& h, Vec3& r, Vec3& t, bool exc, typename Euler::Order rOrder) + +.. doxygenfunction:: extractSHRT(const Matrix44& mat, Vec3& s, Vec3& h, Vec3& r, Vec3& t, bool exc) + +.. doxygenfunction:: extractSHRT(const Matrix44& mat, Vec3& s, Vec3& h, Euler& r, Vec3& t, bool exc) + +.. doxygenfunction:: checkForZeroScaleInRow(const T& scl, const Vec3& row, bool exc) + +.. doxygenfunction:: outerProduct(const Vec4& a, const Vec4& b) + +.. doxygenfunction:: rotationMatrix(const Vec3& fromDirection, const Vec3& toDirection) + +.. doxygenfunction:: rotationMatrixWithUpDir(const Vec3& fromDir, const Vec3& toDir, const Vec3& upDir) + +.. doxygenfunction:: alignZAxisWithTargetDir(Matrix44& result, Vec3 targetDir, Vec3 upDir) + +.. doxygenfunction:: computeLocalFrame(const Vec3& p, const Vec3& xDir, const Vec3& normal) + +.. doxygenfunction:: addOffset(const Matrix44& inMat, const Vec3& tOffset, const Vec3& rOffset, const Vec3& sOffset, const Vec3& ref) + +.. doxygenfunction:: computeRSMatrix(bool keepRotateA, bool keepScaleA, const Matrix44& A, const Matrix44& B) + +.. doxygenfunction:: extractScaling(const Matrix33& mat, Vec2& scl, bool exc) + +.. doxygenfunction:: sansScaling(const Matrix33& mat, bool exc) + +.. doxygenfunction:: removeScaling(Matrix33& mat, bool exc) + +.. doxygenfunction:: extractScalingAndShear(const Matrix33& mat, Vec2& scl, T& shr, bool exc) + +.. doxygenfunction:: sansScalingAndShear(const Matrix33& mat, bool exc) + +.. doxygenfunction:: removeScalingAndShear(Matrix33& mat, bool exc) + +.. doxygenfunction:: extractAndRemoveScalingAndShear(Matrix33& mat, Vec2& scl, T& shr, bool exc) + +.. doxygenfunction:: extractEuler(const Matrix22& mat, T& rot) + +.. doxygenfunction:: extractEuler(const Matrix33& mat, T& rot) + +.. doxygenfunction:: extractSHRT(const Matrix33& mat, Vec2& s, T& h, T& r, Vec2& t, bool exc) + +.. doxygenfunction:: checkForZeroScaleInRow(const T& scl, const Vec2& row, bool exc) + +.. doxygenfunction:: outerProduct(const Vec3& a, const Vec3& b) + +.. doxygenfunction:: procrustesRotationAndTranslation(const Vec3* A, const Vec3* B, const T* weights, const size_t numPoints, const bool doScaling) + +.. doxygenfunction:: procrustesRotationAndTranslation(const Vec3* A, const Vec3* B, const size_t numPoints, const bool doScaling) + +.. doxygenfunction:: jacobiSVD(const Matrix33& A, Matrix33& U, Vec3& S, Matrix33& V, const T tol, const bool forcePositiveDeterminant) + +.. doxygenfunction:: jacobiSVD(const Matrix44& A, Matrix44& U, Vec4& S, Matrix44& V, const T tol, const bool forcePositiveDeterminant) + +.. doxygenfunction:: jacobiEigenSolver(Matrix33& A, Vec3& S, Matrix33& V, const T tol) + +.. doxygenfunction:: jacobiEigenSolver(Matrix33& A, Vec3& S, Matrix33& V) + +.. doxygenfunction:: jacobiEigenSolver(Matrix44& A, Vec4& S, Matrix44& V, const T tol) + +.. doxygenfunction:: jacobiEigenSolver(Matrix44& A, Vec4& S, Matrix44& V) + +.. doxygenfunction:: maxEigenVector(TM& A, TV& S) + +.. doxygenfunction:: minEigenVector(TM& A, TV& S) + + diff -Nru ilmbase-3.1.9-imath/website/functions/random.rst ilmbase-3.1.10/website/functions/random.rst --- ilmbase-3.1.9-imath/website/functions/random.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/random.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,33 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _random-number-functions: + +Random Numbers +############## + +Functions to compute pseudo-random numbers. + +.. code-block:: + + #include + +.. doxygenfunction:: solidSphereRand + +.. doxygenfunction:: hollowSphereRand + +.. doxygenfunction:: gaussSphereRand + +.. doxygenfunction:: gaussRand + +.. doxygenfunction:: erand48 + +.. doxygenfunction:: drand48 + +.. doxygenfunction:: nrand48 + +.. doxygenfunction:: lrand48 + +.. doxygenfunction:: srand48 + diff -Nru ilmbase-3.1.9-imath/website/functions/roots.rst ilmbase-3.1.10/website/functions/roots.rst --- ilmbase-3.1.9-imath/website/functions/roots.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/roots.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,22 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _roots: + +Roots +##### + +Functions to compute roots of simple equations. + +.. code-block:: + + #include + +.. doxygenfunction:: solveLinear + +.. doxygenfunction:: solveQuadratic + +.. doxygenfunction:: solveNormalizedCubic + +.. doxygenfunction:: solveCubic diff -Nru ilmbase-3.1.9-imath/website/functions/vec.rst ilmbase-3.1.10/website/functions/vec.rst --- ilmbase-3.1.9-imath/website/functions/vec.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions/vec.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,19 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _vector-functions: + +Vector Functions +################ + +.. code-block:: + + #include + +Functions that operate on vectors. + +.. doxygenfunction:: closestVertex(const Vec& v0, const Vec& v1, const Vec& v2, const Vec& p) noexcept + + + diff -Nru ilmbase-3.1.9-imath/website/functions.rst ilmbase-3.1.10/website/functions.rst --- ilmbase-3.1.9-imath/website/functions.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/functions.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,24 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _Imath Functions: + +Imath Functions +############### + +.. toctree:: + :caption: Functions + :maxdepth: 3 + + functions/box + functions/color + functions/frame + functions/gl + functions/glu + functions/line + functions/matrix + functions/random + functions/roots + functions/vec + Binary files /tmp/tmprrmz8hd1/9jqJmQmhRl/ilmbase-3.1.9-imath/website/images/imath-fav.ico and /tmp/tmprrmz8hd1/Ew6aKMySnx/ilmbase-3.1.10/website/images/imath-fav.ico differ Binary files /tmp/tmprrmz8hd1/9jqJmQmhRl/ilmbase-3.1.9-imath/website/images/imath-logo-black.png and /tmp/tmprrmz8hd1/Ew6aKMySnx/ilmbase-3.1.10/website/images/imath-logo-black.png differ Binary files /tmp/tmprrmz8hd1/9jqJmQmhRl/ilmbase-3.1.9-imath/website/images/imath-logo-blue.png and /tmp/tmprrmz8hd1/Ew6aKMySnx/ilmbase-3.1.10/website/images/imath-logo-blue.png differ Binary files /tmp/tmprrmz8hd1/9jqJmQmhRl/ilmbase-3.1.9-imath/website/images/imath-logo-white.png and /tmp/tmprrmz8hd1/Ew6aKMySnx/ilmbase-3.1.10/website/images/imath-logo-white.png differ diff -Nru ilmbase-3.1.9-imath/website/index.rst ilmbase-3.1.10/website/index.rst --- ilmbase-3.1.9-imath/website/index.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/index.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,77 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _Overview: + +Imath +##### + +.. toctree:: + :caption: Imath + :maxdepth: 1 + +Imath is a basic, light-weight, and efficient C++ representation of 2D +and 3D vectors, 2x2, 3x3, and 4x4 matrices, and other simple but useful +mathematical objects, functions, and data types common in computer +graphics applications, including the :doc:`classes/half` 16-bit floating-point +type. + +Imath also includes optional python bindings for all types and +functions, including optimized implementations of vector and matrix +arrays. + +Imath is maintained by the `OpenEXR project `_, a part of the `Academy +Software Foundation `_. + +Community +========= + +* **Ask a question:** + + - Email: `openexr-dev@lists.aswf.io `_ + + - Slack: `academysoftwarefdn#openexr `_ + +* **Attend a meeting:** + + - Technical Steering Committee meetings are open to the + public, fortnightly on Thursdays, 1:30pm Pacific Time. + + - Calendar: https://lists.aswf.io/g/openexr-dev/calendar + +* **Report a bug:** + + - Submit an Issue: https://github.com/AcademySoftwareFoundation/Imath/issues + +* **Report a security vulnerability:** + + - Email security@openexr.com + +* **Contribute a Fix, Feature, or Improvement:** + + - Read the `Contribution Guidelines + `_ + and `Code of Conduct `_ + + - Sign the `Contributor License Agreement + `_ + + - Submit a Pull Request: https://github.com/AcademySoftwareFoundation/Imath/pulls + +Resources +========= + +- Security policy: `SECURITY.md `_ +- Release notes: `CHANGES.md + `_ +- Contributors: `CONTRIBUTORS.md `_ +- Porting Guide: :doc:`PortingGuide` + +Index +===== + +:ref:`genindex` + +.. include:: toc_redirect.rst + diff -Nru ilmbase-3.1.9-imath/website/install.rst ilmbase-3.1.10/website/install.rst --- ilmbase-3.1.9-imath/website/install.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/install.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,329 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _Install: + +Install +======== + +.. toctree:: + :caption: Install + +The Imath library is available for download and installation in +binary form via package managers on many Linux distributions. See +`https://pkgs.org/download/Imath +`_ for a complete list. The common +ones that generally provide current releases include: + +* `Fedora `_ +* `Gentoo `_ +* `Ubuntu `_ + +Beware that some distributions are out of date and only provide +distributions of outdated releases OpenEXR. We recommend against using +OpenEXR v2, and we *strongly* recommend against using OpenEXR v1. + +On macOS, we do not recommend installation via HomeBrew because the +distribution is outdated. + +Please note that ``pip install openexr`` installs the `openexrpython +`_ module, which is not +affiliated with the OpenEXR project or the ASWF. Please direct +questions there. + +Build from Source +----------------- + +Imath builds on Linux, macOS, Microsoft Windows via CMake, and is +cross-compilable on other systems. + +Download the source from the `GitHub releases page +`_ +page, or clone the `repo `_. + +The ``release`` branch of the repo always points to the most advanced +release. + + +Prerequisites +~~~~~~~~~~~~~ + +Make sure these are installed on your system before building Imath: + +* Imath requires CMake version 3.12 or newer +* C++ compiler that supports C++11 + +The instructions that follow describe building Imath with CMake. + +Linux/macOS +~~~~~~~~~~~ + +To build via CMake, you need to first identify three directories: + +1. The source directory, i.e. the top-level directory of the + downloaded source archive or cloned repo, referred to below as ``$srcdir`` +2. A temporary directory to hold the build artifacts, referred to below as + ``$builddir`` +3. A destination directory into which to install the + libraries and headers, referred to below as ``$installdir``. + +To build: + +.. code-block:: + + % cd $builddir + % cmake $srcdir --install-prefix $installdir + % cmake --build $builddir --target install --config Release + +Note that the CMake configuration prefers to apply an out-of-tree +build process, since there may be multiple build configurations +(i.e. debug and release), one per folder, all pointing at once source +tree, hence the ``$builddir`` noted above, referred to in CMake +parlance as the *build directory*. You can place this directory +wherever you like. + +See the CMake Configuration Options section below for the most common +configuration options especially the install directory. Note that with +no arguments, as above, ``make install`` installs the header files in +``/usr/local/include``, the object libraries in ``/usr/local/lib``, and the +executable programs in ``/usr/local/bin``. + +Windows +~~~~~~~ + +Under Windows, if you are using a command line-based setup, such as +cygwin, you can of course follow the above. For Visual Studio, cmake +generators are "multiple configuration", so you don't even have to set +the build type, although you will most likely need to specify the +install location. Install Directory By default, ``make install`` +installs the headers, libraries, and programs into ``/usr/local``, but you +can specify a local install directory to cmake via the +``CMAKE_INSTALL_PREFIX`` variable: + +.. code-block:: + + % cmake .. -DCMAKE_INSTALL_PREFIX=$Imath_install_directory + +Library Names +------------- + +By default the installed libraries follow a pattern for how they are +named. This is done to enable multiple versions of the library to be +installed and targeted by different builds depending on the needs of +the project. A simple example of this would be to have different +versions of the library installed to allow for applications targeting +different VFX Platform years to co-exist. + +If you are building dynamic libraries, once you have configured, built, +and installed the libraries, you should see the following pattern of +symlinks and files in the install lib folder: + +.. code-block:: + + libImath.so -> libImath-3_1.so + libImath-3_1.so -> libImath-3_1.so.30 + libImath-3_1.so.30 -> libImath-3_1.so.30.3.0 + libImath-3_1.so.30.3.0 (the shared object file) + +The ``-3_1`` suffix encodes the major and minor version, which can be +configured via the ``IMATH_LIB_SUFFIX`` CMake setting. The ``30`` +corresponds to the so version, or in ``libtool`` terminology the +``current`` shared object version; the `3` denotes the ``libtool`` +``revision``, and the ``0`` denotes the ``libtool`` ``age``. See the +`libtool +`_ +documentation for more details. + +Porting Applications from OpenEXR v2 to v3 +------------------------------------------ + +See the :doc:`PortingGuide` for details about differences from previous +releases and how to address them. Also refer to the porting guide for +details about changes to Imath. + +Building the Website +-------------------- + +The Imath technical documentation at `https://imath.readthedocs.io +`_ is generated via `Sphinx +`_ with the `Breathe +`_ extension using information +extracted from header comments by `Doxygen `_, +using the `sphinx-press-theme +`_, and is hosted by +`readthedocs `_. The website +source is in `restructured text +`_ +in the ``website`` directory. + +To build the website locally from the source headers and +``.rst`` files, set the CMake option ``BUILD_WEBSITE=ON``. This adds +``website`` CMake target. Generation is off by default. + +Building the website requires that ``sphinx``, ``breathe``, and +``doxygen`` are installed. It further requires the `sphinx-press-theme +`_. Complete dependencies are +described in the `requirements.txt +`_ +file. + +On Debian/Ubuntu Linux: + +.. code-block:: + + % apt-get install doxygen python3-sphinx + % pip3 install breathe + % pip3 install sphinx_press_theme + + % mkdir _build + % cd _build + % cmake .. -DBUILD_WEBSITE=ON + % cmake --build . --target website + +CMake Build-time Configuration Options +-------------------------------------- + +The default CMake configuration options are stored in +``cmake/ImathSetup.cmake``. To see a complete set of option +variables, run: + +.. code-block:: + + % cmake -LAH $imath_source_directory + +You can customize these options three ways: + +1. Modify the ``.cmake`` files in place. +2. Use the UI ``cmake-gui`` or ``ccmake``. +3. Specify them as command-line arguments when you invoke cmake. + +Library Naming Options +~~~~~~~~~~~~~~~~~~~~~~ + +* ``IMATH_LIB_SUFFIX`` + + Append the given string to the end of all the Imath + libraries. Default is ``-_`` version string. Please + see the section on library names + +Imath Dependency +~~~~~~~~~~~~~~~~ + +* ``CMAKE_PREFIX_PATH`` + + The standard CMake path in which to + search for dependencies, Imath in particular. A comma-separated + path. Add the root directory where Imath is installed. + +Namespace Options +~~~~~~~~~~~~~~~~~ + +* ``IMATH_NAMESPACE`` + + Public namespace alias for Imath. Default is ``Imath``. + +* ``IMATH_INTERNAL_NAMESPACE`` + + Real namespace for Imath that will end up in compiled + symbols. Default is ``Imath__``. + +* ``IMATH_NAMESPACE_CUSTOM`` + + Whether the namespace has been customized (so external users know) + +Component Options +~~~~~~~~~~~~~~~~~ + +* ``BUILD_TESTING`` + + Build the testing tree. Default is ``ON``. Note that + this causes the test suite to be compiled, but it is not + executed. To execute the suite, run "make test". + +Additional CMake Options +~~~~~~~~~~~~~~~~~~~~~~~~ + +See the CMake documentation for more information (https://cmake.org/cmake/help/v3.12/). + +* ``CMAKE_BUILD_TYPE`` + + For builds when not using a multi-configuration generator. Available + values: ``Debug``, ``Release``, ``RelWithDebInfo``, ``MinSizeRel`` + +* ``BUILD_SHARED_LIBS`` + + This is the primary control whether to build static libraries or + shared libraries / dlls (side note: technically a convention, hence + not an official ``CMAKE_`` variable, it is defined within cmake and + used everywhere to control this static / shared behavior) + +* ``IMATH_CXX_STANDARD`` + + C++ standard to compile against. This obeys the global + ``CMAKE_CXX_STANDARD`` but doesn’t force the global setting to + enable sub-project inclusion. Default is ``14``. + +* ``CMAKE_CXX_COMPILER`` + + The C++ compiler. + +* ``CMAKE_C_COMPILER`` + + The C compiler. + +* ``CMAKE_INSTALL_RPATH`` + + For non-standard install locations where you don’t want to have to + set ``LD_LIBRARY_PATH`` to use them + +* ``CMAKE_EXPORT_COMPILE_COMMANDS`` + + Enable/Disable output of compile commands during generation. Default + is ``OFF``. + +* ``CMAKE_VERBOSE_MAKEFILE`` + + Echo all compile commands during make. Default is ``OFF``. + +Cross Compiling / Specifying Specific Compilers +----------------------------------------------- + +When trying to either cross-compile for a different platform, or for +tasks such as specifying a compiler set to match the `VFX reference +platform `_, cmake provides the idea of a +toolchain which may be useful instead of having to remember a chain of +configuration options. It also means that platform-specific compiler +names and options are out of the main cmake file, providing better +isolation. + +A toolchain file is simply just a cmake script that sets all the +compiler and related flags and is run very early in the configuration +step to be able to set all the compiler options and such for the +discovery that cmake performs automatically. These options can be set +on the command line still if that is clearer, but a theoretical +toolchain file for compiling for VFX Platform 2015 is provided in the +source tree at ``cmake/Toolchain-Linux-VFX_Platform15.cmake`` which +will hopefully provide a guide how this might work. + +For cross-compiling for additional platforms, there is also an +included sample script in ``cmake/Toolchain-mingw.cmake`` which shows +how cross compiling from Linux for Windows may work. The compiler +names and paths may need to be changed for your environment. + +More documentation: + +* Toolchains: https://cmake.org/cmake/help/v3.12/manual/cmake-toolchains.7.html +* Cross compiling: https://gitlab.kitware.com/cmake/community/wikis/doc/cmake/ + +Ninja +----- + +If you have `Ninja `_ installed, it is faster +than make. You can generate ninja files using cmake when doing the +initial generation: + +.. code-block:: + + % cmake -G “Ninja” .. + diff -Nru ilmbase-3.1.9-imath/website/license.rst ilmbase-3.1.10/website/license.rst --- ilmbase-3.1.9-imath/website/license.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/license.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,33 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. _License: + +License +======= + +.. toctree:: + :caption: License + +Imath is licensed under the BSD-3-Clause license. Contributions to the +library should abide by that license unless otherwised approved by the OpenEXR +TSC and ASWF Governing Board. + +See `LICENSE.md +`__ +on GitHub. + +Copyright (c) Contributors to the OpenEXR Project. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + diff -Nru ilmbase-3.1.9-imath/website/requirements.txt ilmbase-3.1.10/website/requirements.txt --- ilmbase-3.1.9-imath/website/requirements.txt 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/requirements.txt 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,6 @@ +# SPDX-License-Identifier: BSD-3-Clause +# Copyright (c) Contributors to the OpenEXR Project. + +sphinx >= 5.0 +breathe +sphinx-press-theme diff -Nru ilmbase-3.1.9-imath/website/toc_redirect.rst ilmbase-3.1.10/website/toc_redirect.rst --- ilmbase-3.1.9-imath/website/toc_redirect.rst 1970-01-01 00:00:00.000000000 +0000 +++ ilmbase-3.1.10/website/toc_redirect.rst 2024-01-24 22:14:50.000000000 +0000 @@ -0,0 +1,38 @@ +.. + SPDX-License-Identifier: BSD-3-Clause + Copyright Contributors to the OpenEXR Project. + +.. toctree:: + :hidden: + + concepts + +.. toctree:: + :hidden: + + classes + +.. toctree:: + :hidden: + + functions + +.. toctree:: + :hidden: + + install + +.. toctree:: + :hidden: + + license + +.. toctree:: + :hidden: + + about + + + + +