Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Part/PartDesign: make BodyBase more functional #175

Closed
wants to merge 1 commit into from

Conversation

DeepSOIC
Copy link
Contributor

@DeepSOIC DeepSOIC commented May 22, 2016

This is a first step to introducing Bodies to Part workbench (and consequently, to Draft, Lattice, and whatever workbench related to Part::Features)

Offloaded some functionality that might be common to all kinds of
potential Body features to BodyBase. Includes:

  • ViewProvider for BodyBase, supporting "Tip" and "Through" display
    modes, as well as updating size of origin features, and double-click
    activation
  • addObject, removeObject, removeModelFromDocument, Origin creation and
    deletion, etc.
  • execute (merely returns shape of Tip feature)

Moved a couple of PartDesign::Body specific methods and properties from
BodyBase to Body:

  • property BaseFeature
  • isAfter method
  • getFullModel method implementation

From now on, one can drop a Part::BodyBase object, and that object is functional. The management of it doesn't exist in Part Workbench, but Part-o-magic will make it tick =)

Offloaded some functionality that might be common to all kinds of
potential Body features to BodyBase. Includes:
* ViewProvider for BodyBase, supporting "Tip" and "Through" display
modes, as well as updating size of origin features, and double-click
activation
* addObject, removeObject, removeModelFromDocument, Origin creation and
deletion, etc.
* execute (merely returns shape of Tip feature)

Moved a couple of PartDesign::Body specific methods and properties from
BodyBase to Body:
* property BaseFeature
* isAfter method
* getFullModel method implementation
@wwmayer
Copy link
Contributor

wwmayer commented May 23, 2016

Needs more discussion: see http://forum.freecadweb.org/viewtopic.php?f=17&t=15861

@DeepSOIC
Copy link
Contributor Author

Waiting for ickby's rework. Pull request withdrawn. See http://forum.freecadweb.org/viewtopic.php?f=10&t=15869&p=125976#p125976

@DeepSOIC DeepSOIC closed this May 23, 2016
mosfet80 added a commit to mosfet80/FreeCAD that referenced this pull request Sep 11, 2023
## 3.1.0 - (in progress)

### Added

- {cmake} New option `E57_RELEASE_LTO` controls whether link-time optimization is on for release builds. It defaults to `ON`. ([FreeCAD#254](asmaloney/libE57Format#254))

  CMake forces "thin" LTO (see [this issue](https://gitlab.kitware.com/cmake/cmake/-/issues/23136)) which is a problem if compiling statically for distribution (e.g. in a package manager). Generally you will only want to turn this off for distributing static release builds.

### Changed

- {cmake} Remove `E57_VISIBILITY_HIDDEN` option. ([FreeCAD#259](asmaloney/libE57Format#259))

  I cannot get extern templates to work across all of gcc, clang, apple clang, and MSVC when using "hidden" visibility with shared libraries.

### Fixed

- Fix clang warnings about implicit conversions in _SourceDestBufferImpl.cpp_. Apple's clang doesn't warn about these, but it looks like the official clang releases do. ([FreeCAD#257](asmaloney/libE57Format#257)) (Thanks Martin!)

## [3.0.2](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.2) - 2023-07-22

### Fixed

- Fix `E57_VERBOSE` build. ([FreeCAD#251](asmaloney/libE57Format#251)) (Thanks Jia!)
- {standard conformance} Fix invalid range exception in FloatNode implementation. ([FreeCAD#250](asmaloney/libE57Format#250))
- Fix reading of index packets. ([FreeCAD#249](asmaloney/libE57Format#249))
- Fix several places where we should be checking for MSVC, not WIN32. ([FreeCAD#248](asmaloney/libE57Format#248))
- Fix "unnecessary semicolons" warnings which prevented building with GCC <= 10. ([FreeCAD#241](asmaloney/libE57Format#241)) (Thanks Andre!)

## [3.0.1](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.1) - 2023-03-15

### Added

- {ci} Added an MSVC 32-bit build. ([FreeCAD#235](asmaloney/libE57Format#235))

### Fixed

- {cmake} Turn off inter-procedural optimization in debug builds. Link-time optimization can make debugging more difficult. ([FreeCAD#240](asmaloney/libE57Format#240))
- {cmake} Don't force a debug postfix if `CMAKE_DEBUG_POSTFIX` is defined.([FreeCAD#239](asmaloney/libE57Format#239))
- {cmake} Don't force install locations. This prevents overriding them using `CMAKE_INSTALL_BINDIR` & `CMAKE_INSTALL_LIBDIR`.([FreeCAD#237](asmaloney/libE57Format#237))
- Fix warnings which prevented building on 32-bit systems. ([FreeCAD#233](asmaloney/libE57Format#233), [FreeCAD#234](asmaloney/libE57Format#234))

## [3.0.0](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.0) - 2023-02-23

There have been _many_ changes around the `Simple API` in this release to fix some problems, avoid potential errors, and simplify the use of the API. Where possible these changes are marked as `deprecated` to be removed later. The compiler will produce warnings for these indicating what needs to change. Other changes could not be marked deprecated but will break the API, requiring code changes. The notable ones are marked with 🚧 below.

### Added

- Add address (ASan) and undefined behaviour (UBSan) sanitizers. These are controlled by `E57FORMAT_SANITIZE_ALL`, `E57FORMAT_SANITIZE_ADDRESS` and `E57FORMAT_SANITIZE_ADDRESS`. They are not included when building with MSVC.
- Add new `E57Version.h` header for more convenient access to version information. ([FreeCAD#197](asmaloney/libE57Format#197)).
- Add `ImageFile::extensionsLookupPrefix()` overload for more concise user code. ([FreeCAD#161](asmaloney/libE57Format#161))
- Added a constructor & destructor for **E57SimpleData**'s `Data3DPointsData_t`. This will create all the required buffers based on an `e57::Data3D` struct and handle their cleanup. See the `SimpleWriter` tests for examples. ([FreeCAD#149](asmaloney/libE57Format#149))

  > **Note:** I strongly recommend these new constructors be used to simplify your code and help prevent errors.

- A new **E57SimpleReader** constructor takes a `ReaderOptions` struct which allows setting the checksum policy.
  ```cpp
  Reader( const ustring &filePath, const ReaderOptions &options );
  ```
- {test} Added testing using [GoogleTest](https://github.com/google/googletest). For details, please see [test/README.md](test/README.md) ([FreeCAD#121](asmaloney/libE57Format#121))
- Added `E57Exception::errorStr()` to get the error string directly. ([FreeCAD#128](asmaloney/libE57Format#128))
- {cmake} Use [ccache](https://ccache.dev/) if available. ([FreeCAD#129](asmaloney/libE57Format#129))
- {ci} Added a CI check for proper clang-formatted code. ([FreeCAD#125](asmaloney/libE57Format#125))

### Changed

- Now requires a **[C++14](https://en.cppreference.com/w/cpp/14)** compatible compiler.
- Now requires **[CMake](https://cmake.org/) >= 3.15**. ([FreeCAD#205](asmaloney/libE57Format#205))
- 🚧 **DEBUG** and **VERBOSE** macros were changed to simplify and clarify:
  - New `E57_ENABLE_DIAGNOSTIC_OUTPUT` controls the inclusion of the code for the `dump()` functions on nodes. I don't see any real reason to turn this off, but I left the capability in for compatibility.
  - New `E57_VALIDATION_LEVEL=N` replaces `E57_DEBUG` (N=1) and `E57_MAX_DEBUG` (N=2).
  - `E57_MAX_VERBOSE` was consolidated with `E57_VERBOSE` since they were essentially the same.
- When building itself, warnings are now treated as errors. ([FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#211](asmaloney/libE57Format#211))
- Clean up global const and enum names to use the `e57` namespace and avoid repetition. ([FreeCAD#176](asmaloney/libE57Format#176))
  - i.e. instead of `e57::E57_STRUCTURE`, we now use `e57::TypeStructure`
- {format} Update clang-format rules for clang-format 15. ([FreeCAD#168](asmaloney/libE57Format#168), [FreeCAD#179](asmaloney/libE57Format#179))
- Change default checksum policies to an enum. ([FreeCAD#166](asmaloney/libE57Format#166))
  Old | New
  --|--
  CHECKSUM_POLICY_NONE | ChecksumPolicy::None
  CHECKSUM_POLICY_SPARSE | ChecksumPolicy::Sparse
  CHECKSUM_POLICY_HALF | ChecksumPolicy::Half
  CHECKSUM_POLICY_ALL | ChecksumPolicy::All
- Avoid implicit conversion in constructors. ([FreeCAD#135](asmaloney/libE57Format#135))
- Update [CRCpp](https://github.com/d-bahr/CRCpp) to 1.2. ([FreeCAD#130](asmaloney/libE57Format#130))
- **E57Exception** changes ([FreeCAD#118](asmaloney/libE57Format#118)):
  - mark methods as `noexcept`
  - use `private` instead of `protected`
- Rename **E57Simple**'s `Data3DPointsData` and `Data3DPointsData_d` structs to `Data3DPointsFloat` and `Data3DPointsDouble` respectively. ([FreeCAD#180](asmaloney/libE57Format#180))
- 🚧 **E57Simple:** Specifying the node type for cartesian & spherical points, time stamp, and intensity is now explicit using new fields (`pointRangeNodeType`, `angleNodeType`, `timeNodeType`, and `intensityNodeType`) and a new enum (`NumericalNodeType`). ([FreeCAD#178](asmaloney/libE57Format#178))
  - For examples, please see _test/src/testSimpleWriter.cpp_.
- Simplify the **E57SimpleWriter** API with `WriteImage2DData()` for images and `WriteData3DData()` for 3D data. This reduces code, hides complexity, and avoids potential errors. ([FreeCAD#171](asmaloney/libE57Format#171))
  - As part of this simplification, `WriteData3DData()` will now fill in any missing min/max values for cartesian & spherical points, intensity, and time stamps by looking at the data.([FreeCAD#175](asmaloney/libE57Format#175))
- 🚧 **E57Simple:** Intensity now uses `double` instead of `float`. ([FreeCAD#178](asmaloney/libE57Format#178))
- 🚧 **E57Simple:** Colours now use `uint16_t` instead of `uint8_t`. ([FreeCAD#167](asmaloney/libE57Format#167))
- 🚧 Change **E57SimpleData**'s Data3D field name from `pointsSize` to `pointCount`. ([FreeCAD#164](asmaloney/libE57Format#164))
- 🚧 Min/max fields in **E57SimpleData**'s Data3D's point fields were a mix of floats and doubles. Since the fields are doubles, set them all to doubles and use the new `Data3DPointsData_t` constructor to set them properly for floats. ([FreeCAD#153](asmaloney/libE57Format#153))
  > **Note:** If you were previously relying on these to be floats and are not using the new `Data3DPointsData_t` constructor, you will need to set these.
- 🚧 Renamed the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's fields in **E57SimpleData**'s `PointStandardizedFieldsAvailable` to be in line with existing code. ([FreeCAD#149](asmaloney/libE57Format#149))
  - `normalX` renamed to `normalXField`
  - `normalY` renamed to `normalYField`
  - `normalZ` renamed to `normalZField`

### Deprecated

- `e57::Utilities::getVersions()`. ([FreeCAD#197](asmaloney/libE57Format#197))
- `e57::Data3DPointsData` and `e57::Data3DPointsData_d` types. ([FreeCAD#180](asmaloney/libE57Format#180))
- Many global const and enum names. The compiler will produce warnings including the replacement symbols (note that enumerators will not produce warnings on C++14, but they will on C++17). ([FreeCAD#176](asmaloney/libE57Format#176))
- `e57::Writer::NewImage2D`and `e57::Writer::SetUpData3DPointsData`. ([FreeCAD#171](asmaloney/libE57Format#171))
- Old default checksum policies (`CHECKSUM_POLICY_NONE`, `CHECKSUM_POLICY_SPARSE`, `CHECKSUM_POLICY_HALF`, and `CHECKSUM_POLICY_ALL`). ([FreeCAD#166](asmaloney/libE57Format#166))
- The old `e57::Reader` constructor taking only `filePath`. ([FreeCAD#139](asmaloney/libE57Format#139))
- The old `e57::Writer` constructor taking only `filePath`. ([FreeCAD#117](asmaloney/libE57Format#117))

### Fixed

- Fix several potential divide-by-zero cases. ([FreeCAD#224](asmaloney/libE57Format#224))
- {ci} Now builds shared library versions as well. ([FreeCAD#219](asmaloney/libE57Format#219))
- {win} Fixes shared library build warnings. ([FreeCAD#215](asmaloney/libE57Format#215), [FreeCAD#216](asmaloney/libE57Format#216), [FreeCAD#217](asmaloney/libE57Format#217))
- Fix the code which shortens floating point numbers when converted to strings. The impact of it being incorrect was negligible since it's just the floating point representation in the XML portion of the file. ([FreeCAD#214](asmaloney/libE57Format#214))
- Turned on a lot of compiler warnings and fixed them. ([FreeCAD#201](asmaloney/libE57Format#201), [FreeCAD#202](asmaloney/libE57Format#202), [FreeCAD#203](asmaloney/libE57Format#203), [FreeCAD#204](asmaloney/libE57Format#204), [FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#207](asmaloney/libE57Format#207), [FreeCAD#209](asmaloney/libE57Format#209))
- Fix writing floating point numbers when `std::locale::global` is set. ([FreeCAD#174](asmaloney/libE57Format#174))
- E57XmlParser: Parse doubles in a locale-independent way. ([FreeCAD#173](asmaloney/libE57Format#173)) (Thanks Hugal31!)
- E57SimpleReader: Ensure scaled integer fields are set as best we can when reading. ([FreeCAD#158](asmaloney/libE57Format#158))
- Fix the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's URI in **E57SimpleWriter**. ([FreeCAD#143](asmaloney/libE57Format#143))
- {win} Fix conversion warning when compiling with debug on. ([FreeCAD#124](asmaloney/libE57Format#124))
- Add errno detail to `E57_ERROR_OPEN_FAILED` exception. ([FreeCAD#119](asmaloney/libE57Format#119), [FreeCAD#120](asmaloney/libE57Format#120))

## [2.3.0](https://github.com/asmaloney/libE57Format/releases/tag/v2.3.0) - 2022-10-04

### Added

- {cmake} Added `E57_VISIBILITY_HIDDEN` option to control [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html). Defaults to `ON`. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- Added BSD support. ([FreeCAD#99](asmaloney/libE57Format#99)) (Thanks Christophe!)

### Changed

- Updated &amp; reorganized the [online API docs](https://asmaloney.github.io/libE57Format-docs/) and changed to a [cleaner theme](https://github.com/jothepro/doxygen-awesome-css).
- Change file creation to use _0666_ permissions on [POSIX](https://en.wikipedia.org/wiki/POSIX) systems. ([FreeCAD#105](asmaloney/libE57Format#105)) (Thanks Nigel!)
- {cmake} [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html) is now set and `ON` by default. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- A new **E57SimpleWriter** constructor takes a `WriterOptions` struct which allows setting the file's GUID.
  ```cpp
  Writer( const ustring &filePath, const WriterOptions &options );
  ```
  The old constructor taking only `coordinateMetadata` is deprecated and will be removed in the future. ([FreeCAD#96](asmaloney/libE57Format#96)) (Thanks Nigel!)
- Change `E57_DEBUG`, `E57_MAX_DEBUG`, `E57_VERBOSE`, `E57_MAX_VERBOSE`, `E57_WRITE_CRAZY_PACKET_MODE` from **#defines** to cmake options. ([FreeCAD#80](asmaloney/libE57Format#80)) (Thanks Nigel!)

### Fixed

- Fix **E57SimpleWriter**'s writing of invalid quaternions. It now defaults to the identity quaternion. ([FreeCAD#108](asmaloney/libE57Format#108)) (Thanks Nigel!)
- Fix **E57SimpleReader** to handle missing `images2D` and `isAtomicClockReferenced` nodes. ([FreeCAD#90](asmaloney/libE57Format#90)) (Thanks Olli!)
- Fix **BitpackIntegerDecoder** sometimes reading past end of input buffer. ([FreeCAD#87](asmaloney/libE57Format#87)) (Thanks Nigel!)
- Fix compilation when some debug options are set. ([FreeCAD#81](asmaloney/libE57Format#81), [FreeCAD#82](asmaloney/libE57Format#82), [FreeCAD#84](asmaloney/libE57Format#84)) (Thanks Nigel!)
- Fix compilation with [musl libc](https://musl.libc.org/) ([FreeCAD#70](asmaloney/libE57Format#70)) (Thanks Dimitri!)
- Add missing include for [GCC 11](https://gcc.gnu.org/gcc-11/porting_to.html#header-dep-changes) ([FreeCAD#68](asmaloney/libE57Format#68)) (Thanks bartoszek!)

**Note:** The next release will be 3.0 and will require a [C++14](https://en.cppreference.com/w/cpp/14) compiler.
mosfet80 added a commit to mosfet80/FreeCAD that referenced this pull request Sep 11, 2023
## 3.1.0 - (in progress)

### Added

- {cmake} New option `E57_RELEASE_LTO` controls whether link-time optimization is on for release builds. It defaults to `ON`. ([FreeCAD#254](asmaloney/libE57Format#254))

  CMake forces "thin" LTO (see [this issue](https://gitlab.kitware.com/cmake/cmake/-/issues/23136)) which is a problem if compiling statically for distribution (e.g. in a package manager). Generally you will only want to turn this off for distributing static release builds.

### Changed

- {cmake} Remove `E57_VISIBILITY_HIDDEN` option. ([FreeCAD#259](asmaloney/libE57Format#259))

  I cannot get extern templates to work across all of gcc, clang, apple clang, and MSVC when using "hidden" visibility with shared libraries.

### Fixed

- Fix clang warnings about implicit conversions in _SourceDestBufferImpl.cpp_. Apple's clang doesn't warn about these, but it looks like the official clang releases do. ([FreeCAD#257](asmaloney/libE57Format#257)) (Thanks Martin!)

## [3.0.2](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.2) - 2023-07-22

### Fixed

- Fix `E57_VERBOSE` build. ([FreeCAD#251](asmaloney/libE57Format#251)) (Thanks Jia!)
- {standard conformance} Fix invalid range exception in FloatNode implementation. ([FreeCAD#250](asmaloney/libE57Format#250))
- Fix reading of index packets. ([FreeCAD#249](asmaloney/libE57Format#249))
- Fix several places where we should be checking for MSVC, not WIN32. ([FreeCAD#248](asmaloney/libE57Format#248))
- Fix "unnecessary semicolons" warnings which prevented building with GCC <= 10. ([FreeCAD#241](asmaloney/libE57Format#241)) (Thanks Andre!)

## [3.0.1](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.1) - 2023-03-15

### Added

- {ci} Added an MSVC 32-bit build. ([FreeCAD#235](asmaloney/libE57Format#235))

### Fixed

- {cmake} Turn off inter-procedural optimization in debug builds. Link-time optimization can make debugging more difficult. ([FreeCAD#240](asmaloney/libE57Format#240))
- {cmake} Don't force a debug postfix if `CMAKE_DEBUG_POSTFIX` is defined.([FreeCAD#239](asmaloney/libE57Format#239))
- {cmake} Don't force install locations. This prevents overriding them using `CMAKE_INSTALL_BINDIR` & `CMAKE_INSTALL_LIBDIR`.([FreeCAD#237](asmaloney/libE57Format#237))
- Fix warnings which prevented building on 32-bit systems. ([FreeCAD#233](asmaloney/libE57Format#233), [FreeCAD#234](asmaloney/libE57Format#234))

## [3.0.0](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.0) - 2023-02-23

There have been _many_ changes around the `Simple API` in this release to fix some problems, avoid potential errors, and simplify the use of the API. Where possible these changes are marked as `deprecated` to be removed later. The compiler will produce warnings for these indicating what needs to change. Other changes could not be marked deprecated but will break the API, requiring code changes. The notable ones are marked with 🚧 below.

### Added

- Add address (ASan) and undefined behaviour (UBSan) sanitizers. These are controlled by `E57FORMAT_SANITIZE_ALL`, `E57FORMAT_SANITIZE_ADDRESS` and `E57FORMAT_SANITIZE_ADDRESS`. They are not included when building with MSVC.
- Add new `E57Version.h` header for more convenient access to version information. ([FreeCAD#197](asmaloney/libE57Format#197)).
- Add `ImageFile::extensionsLookupPrefix()` overload for more concise user code. ([FreeCAD#161](asmaloney/libE57Format#161))
- Added a constructor & destructor for **E57SimpleData**'s `Data3DPointsData_t`. This will create all the required buffers based on an `e57::Data3D` struct and handle their cleanup. See the `SimpleWriter` tests for examples. ([FreeCAD#149](asmaloney/libE57Format#149))

  > **Note:** I strongly recommend these new constructors be used to simplify your code and help prevent errors.

- A new **E57SimpleReader** constructor takes a `ReaderOptions` struct which allows setting the checksum policy.
  ```cpp
  Reader( const ustring &filePath, const ReaderOptions &options );
  ```
- {test} Added testing using [GoogleTest](https://github.com/google/googletest). For details, please see [test/README.md](test/README.md) ([FreeCAD#121](asmaloney/libE57Format#121))
- Added `E57Exception::errorStr()` to get the error string directly. ([FreeCAD#128](asmaloney/libE57Format#128))
- {cmake} Use [ccache](https://ccache.dev/) if available. ([FreeCAD#129](asmaloney/libE57Format#129))
- {ci} Added a CI check for proper clang-formatted code. ([FreeCAD#125](asmaloney/libE57Format#125))

### Changed

- Now requires a **[C++14](https://en.cppreference.com/w/cpp/14)** compatible compiler.
- Now requires **[CMake](https://cmake.org/) >= 3.15**. ([FreeCAD#205](asmaloney/libE57Format#205))
- 🚧 **DEBUG** and **VERBOSE** macros were changed to simplify and clarify:
  - New `E57_ENABLE_DIAGNOSTIC_OUTPUT` controls the inclusion of the code for the `dump()` functions on nodes. I don't see any real reason to turn this off, but I left the capability in for compatibility.
  - New `E57_VALIDATION_LEVEL=N` replaces `E57_DEBUG` (N=1) and `E57_MAX_DEBUG` (N=2).
  - `E57_MAX_VERBOSE` was consolidated with `E57_VERBOSE` since they were essentially the same.
- When building itself, warnings are now treated as errors. ([FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#211](asmaloney/libE57Format#211))
- Clean up global const and enum names to use the `e57` namespace and avoid repetition. ([FreeCAD#176](asmaloney/libE57Format#176))
  - i.e. instead of `e57::E57_STRUCTURE`, we now use `e57::TypeStructure`
- {format} Update clang-format rules for clang-format 15. ([FreeCAD#168](asmaloney/libE57Format#168), [FreeCAD#179](asmaloney/libE57Format#179))
- Change default checksum policies to an enum. ([FreeCAD#166](asmaloney/libE57Format#166))
  Old | New
  --|--
  CHECKSUM_POLICY_NONE | ChecksumPolicy::None
  CHECKSUM_POLICY_SPARSE | ChecksumPolicy::Sparse
  CHECKSUM_POLICY_HALF | ChecksumPolicy::Half
  CHECKSUM_POLICY_ALL | ChecksumPolicy::All
- Avoid implicit conversion in constructors. ([FreeCAD#135](asmaloney/libE57Format#135))
- Update [CRCpp](https://github.com/d-bahr/CRCpp) to 1.2. ([FreeCAD#130](asmaloney/libE57Format#130))
- **E57Exception** changes ([FreeCAD#118](asmaloney/libE57Format#118)):
  - mark methods as `noexcept`
  - use `private` instead of `protected`
- Rename **E57Simple**'s `Data3DPointsData` and `Data3DPointsData_d` structs to `Data3DPointsFloat` and `Data3DPointsDouble` respectively. ([FreeCAD#180](asmaloney/libE57Format#180))
- 🚧 **E57Simple:** Specifying the node type for cartesian & spherical points, time stamp, and intensity is now explicit using new fields (`pointRangeNodeType`, `angleNodeType`, `timeNodeType`, and `intensityNodeType`) and a new enum (`NumericalNodeType`). ([FreeCAD#178](asmaloney/libE57Format#178))
  - For examples, please see _test/src/testSimpleWriter.cpp_.
- Simplify the **E57SimpleWriter** API with `WriteImage2DData()` for images and `WriteData3DData()` for 3D data. This reduces code, hides complexity, and avoids potential errors. ([FreeCAD#171](asmaloney/libE57Format#171))
  - As part of this simplification, `WriteData3DData()` will now fill in any missing min/max values for cartesian & spherical points, intensity, and time stamps by looking at the data.([FreeCAD#175](asmaloney/libE57Format#175))
- 🚧 **E57Simple:** Intensity now uses `double` instead of `float`. ([FreeCAD#178](asmaloney/libE57Format#178))
- 🚧 **E57Simple:** Colours now use `uint16_t` instead of `uint8_t`. ([FreeCAD#167](asmaloney/libE57Format#167))
- 🚧 Change **E57SimpleData**'s Data3D field name from `pointsSize` to `pointCount`. ([FreeCAD#164](asmaloney/libE57Format#164))
- 🚧 Min/max fields in **E57SimpleData**'s Data3D's point fields were a mix of floats and doubles. Since the fields are doubles, set them all to doubles and use the new `Data3DPointsData_t` constructor to set them properly for floats. ([FreeCAD#153](asmaloney/libE57Format#153))
  > **Note:** If you were previously relying on these to be floats and are not using the new `Data3DPointsData_t` constructor, you will need to set these.
- 🚧 Renamed the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's fields in **E57SimpleData**'s `PointStandardizedFieldsAvailable` to be in line with existing code. ([FreeCAD#149](asmaloney/libE57Format#149))
  - `normalX` renamed to `normalXField`
  - `normalY` renamed to `normalYField`
  - `normalZ` renamed to `normalZField`

### Deprecated

- `e57::Utilities::getVersions()`. ([FreeCAD#197](asmaloney/libE57Format#197))
- `e57::Data3DPointsData` and `e57::Data3DPointsData_d` types. ([FreeCAD#180](asmaloney/libE57Format#180))
- Many global const and enum names. The compiler will produce warnings including the replacement symbols (note that enumerators will not produce warnings on C++14, but they will on C++17). ([FreeCAD#176](asmaloney/libE57Format#176))
- `e57::Writer::NewImage2D`and `e57::Writer::SetUpData3DPointsData`. ([FreeCAD#171](asmaloney/libE57Format#171))
- Old default checksum policies (`CHECKSUM_POLICY_NONE`, `CHECKSUM_POLICY_SPARSE`, `CHECKSUM_POLICY_HALF`, and `CHECKSUM_POLICY_ALL`). ([FreeCAD#166](asmaloney/libE57Format#166))
- The old `e57::Reader` constructor taking only `filePath`. ([FreeCAD#139](asmaloney/libE57Format#139))
- The old `e57::Writer` constructor taking only `filePath`. ([FreeCAD#117](asmaloney/libE57Format#117))

### Fixed

- Fix several potential divide-by-zero cases. ([FreeCAD#224](asmaloney/libE57Format#224))
- {ci} Now builds shared library versions as well. ([FreeCAD#219](asmaloney/libE57Format#219))
- {win} Fixes shared library build warnings. ([FreeCAD#215](asmaloney/libE57Format#215), [FreeCAD#216](asmaloney/libE57Format#216), [FreeCAD#217](asmaloney/libE57Format#217))
- Fix the code which shortens floating point numbers when converted to strings. The impact of it being incorrect was negligible since it's just the floating point representation in the XML portion of the file. ([FreeCAD#214](asmaloney/libE57Format#214))
- Turned on a lot of compiler warnings and fixed them. ([FreeCAD#201](asmaloney/libE57Format#201), [FreeCAD#202](asmaloney/libE57Format#202), [FreeCAD#203](asmaloney/libE57Format#203), [FreeCAD#204](asmaloney/libE57Format#204), [FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#207](asmaloney/libE57Format#207), [FreeCAD#209](asmaloney/libE57Format#209))
- Fix writing floating point numbers when `std::locale::global` is set. ([FreeCAD#174](asmaloney/libE57Format#174))
- E57XmlParser: Parse doubles in a locale-independent way. ([FreeCAD#173](asmaloney/libE57Format#173)) (Thanks Hugal31!)
- E57SimpleReader: Ensure scaled integer fields are set as best we can when reading. ([FreeCAD#158](asmaloney/libE57Format#158))
- Fix the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's URI in **E57SimpleWriter**. ([FreeCAD#143](asmaloney/libE57Format#143))
- {win} Fix conversion warning when compiling with debug on. ([FreeCAD#124](asmaloney/libE57Format#124))
- Add errno detail to `E57_ERROR_OPEN_FAILED` exception. ([FreeCAD#119](asmaloney/libE57Format#119), [FreeCAD#120](asmaloney/libE57Format#120))

## [2.3.0](https://github.com/asmaloney/libE57Format/releases/tag/v2.3.0) - 2022-10-04

### Added

- {cmake} Added `E57_VISIBILITY_HIDDEN` option to control [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html). Defaults to `ON`. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- Added BSD support. ([FreeCAD#99](asmaloney/libE57Format#99)) (Thanks Christophe!)

### Changed

- Updated &amp; reorganized the [online API docs](https://asmaloney.github.io/libE57Format-docs/) and changed to a [cleaner theme](https://github.com/jothepro/doxygen-awesome-css).
- Change file creation to use _0666_ permissions on [POSIX](https://en.wikipedia.org/wiki/POSIX) systems. ([FreeCAD#105](asmaloney/libE57Format#105)) (Thanks Nigel!)
- {cmake} [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html) is now set and `ON` by default. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- A new **E57SimpleWriter** constructor takes a `WriterOptions` struct which allows setting the file's GUID.
  ```cpp
  Writer( const ustring &filePath, const WriterOptions &options );
  ```
  The old constructor taking only `coordinateMetadata` is deprecated and will be removed in the future. ([FreeCAD#96](asmaloney/libE57Format#96)) (Thanks Nigel!)
- Change `E57_DEBUG`, `E57_MAX_DEBUG`, `E57_VERBOSE`, `E57_MAX_VERBOSE`, `E57_WRITE_CRAZY_PACKET_MODE` from **#defines** to cmake options. ([FreeCAD#80](asmaloney/libE57Format#80)) (Thanks Nigel!)

### Fixed

- Fix **E57SimpleWriter**'s writing of invalid quaternions. It now defaults to the identity quaternion. ([FreeCAD#108](asmaloney/libE57Format#108)) (Thanks Nigel!)
- Fix **E57SimpleReader** to handle missing `images2D` and `isAtomicClockReferenced` nodes. ([FreeCAD#90](asmaloney/libE57Format#90)) (Thanks Olli!)
- Fix **BitpackIntegerDecoder** sometimes reading past end of input buffer. ([FreeCAD#87](asmaloney/libE57Format#87)) (Thanks Nigel!)
- Fix compilation when some debug options are set. ([FreeCAD#81](asmaloney/libE57Format#81), [FreeCAD#82](asmaloney/libE57Format#82), [FreeCAD#84](asmaloney/libE57Format#84)) (Thanks Nigel!)
- Fix compilation with [musl libc](https://musl.libc.org/) ([FreeCAD#70](asmaloney/libE57Format#70)) (Thanks Dimitri!)
- Add missing include for [GCC 11](https://gcc.gnu.org/gcc-11/porting_to.html#header-dep-changes) ([FreeCAD#68](asmaloney/libE57Format#68)) (Thanks bartoszek!)

**Note:** The next release will be 3.0 and will require a [C++14](https://en.cppreference.com/w/cpp/14) compiler.

updated libe57Format from v2.2.1 to 3.1

### Added

- {cmake} New option `E57_RELEASE_LTO` controls whether link-time optimization is on for release builds. It defaults to `ON`. ([FreeCAD#254](asmaloney/libE57Format#254))

  CMake forces "thin" LTO (see [this issue](https://gitlab.kitware.com/cmake/cmake/-/issues/23136)) which is a problem if compiling statically for distribution (e.g. in a package manager). Generally you will only want to turn this off for distributing static release builds.

### Changed

- {cmake} Remove `E57_VISIBILITY_HIDDEN` option. ([FreeCAD#259](asmaloney/libE57Format#259))

  I cannot get extern templates to work across all of gcc, clang, apple clang, and MSVC when using "hidden" visibility with shared libraries.

### Fixed

- Fix clang warnings about implicit conversions in _SourceDestBufferImpl.cpp_. Apple's clang doesn't warn about these, but it looks like the official clang releases do. ([FreeCAD#257](asmaloney/libE57Format#257)) (Thanks Martin!)

## [3.0.2](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.2) - 2023-07-22

### Fixed

- Fix `E57_VERBOSE` build. ([FreeCAD#251](asmaloney/libE57Format#251)) (Thanks Jia!)
- {standard conformance} Fix invalid range exception in FloatNode implementation. ([FreeCAD#250](asmaloney/libE57Format#250))
- Fix reading of index packets. ([FreeCAD#249](asmaloney/libE57Format#249))
- Fix several places where we should be checking for MSVC, not WIN32. ([FreeCAD#248](asmaloney/libE57Format#248))
- Fix "unnecessary semicolons" warnings which prevented building with GCC <= 10. ([FreeCAD#241](asmaloney/libE57Format#241)) (Thanks Andre!)

## [3.0.1](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.1) - 2023-03-15

### Added

- {ci} Added an MSVC 32-bit build. ([FreeCAD#235](asmaloney/libE57Format#235))

### Fixed

- {cmake} Turn off inter-procedural optimization in debug builds. Link-time optimization can make debugging more difficult. ([FreeCAD#240](asmaloney/libE57Format#240))
- {cmake} Don't force a debug postfix if `CMAKE_DEBUG_POSTFIX` is defined.([FreeCAD#239](asmaloney/libE57Format#239))
- {cmake} Don't force install locations. This prevents overriding them using `CMAKE_INSTALL_BINDIR` & `CMAKE_INSTALL_LIBDIR`.([FreeCAD#237](asmaloney/libE57Format#237))
- Fix warnings which prevented building on 32-bit systems. ([FreeCAD#233](asmaloney/libE57Format#233), [FreeCAD#234](asmaloney/libE57Format#234))

## [3.0.0](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.0) - 2023-02-23

There have been _many_ changes around the `Simple API` in this release to fix some problems, avoid potential errors, and simplify the use of the API. Where possible these changes are marked as `deprecated` to be removed later. The compiler will produce warnings for these indicating what needs to change. Other changes could not be marked deprecated but will break the API, requiring code changes. The notable ones are marked with 🚧 below.

### Added

- Add address (ASan) and undefined behaviour (UBSan) sanitizers. These are controlled by `E57FORMAT_SANITIZE_ALL`, `E57FORMAT_SANITIZE_ADDRESS` and `E57FORMAT_SANITIZE_ADDRESS`. They are not included when building with MSVC.
- Add new `E57Version.h` header for more convenient access to version information. ([FreeCAD#197](asmaloney/libE57Format#197)).
- Add `ImageFile::extensionsLookupPrefix()` overload for more concise user code. ([FreeCAD#161](asmaloney/libE57Format#161))
- Added a constructor & destructor for **E57SimpleData**'s `Data3DPointsData_t`. This will create all the required buffers based on an `e57::Data3D` struct and handle their cleanup. See the `SimpleWriter` tests for examples. ([FreeCAD#149](asmaloney/libE57Format#149))

  > **Note:** I strongly recommend these new constructors be used to simplify your code and help prevent errors.

- A new **E57SimpleReader** constructor takes a `ReaderOptions` struct which allows setting the checksum policy.
  ```cpp
  Reader( const ustring &filePath, const ReaderOptions &options );
  ```
- {test} Added testing using [GoogleTest](https://github.com/google/googletest). For details, please see [test/README.md](test/README.md) ([FreeCAD#121](asmaloney/libE57Format#121))
- Added `E57Exception::errorStr()` to get the error string directly. ([FreeCAD#128](asmaloney/libE57Format#128))
- {cmake} Use [ccache](https://ccache.dev/) if available. ([FreeCAD#129](asmaloney/libE57Format#129))
- {ci} Added a CI check for proper clang-formatted code. ([FreeCAD#125](asmaloney/libE57Format#125))

### Changed

- Now requires a **[C++14](https://en.cppreference.com/w/cpp/14)** compatible compiler.
- Now requires **[CMake](https://cmake.org/) >= 3.15**. ([FreeCAD#205](asmaloney/libE57Format#205))
- 🚧 **DEBUG** and **VERBOSE** macros were changed to simplify and clarify:
  - New `E57_ENABLE_DIAGNOSTIC_OUTPUT` controls the inclusion of the code for the `dump()` functions on nodes. I don't see any real reason to turn this off, but I left the capability in for compatibility.
  - New `E57_VALIDATION_LEVEL=N` replaces `E57_DEBUG` (N=1) and `E57_MAX_DEBUG` (N=2).
  - `E57_MAX_VERBOSE` was consolidated with `E57_VERBOSE` since they were essentially the same.
- When building itself, warnings are now treated as errors. ([FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#211](asmaloney/libE57Format#211))
- Clean up global const and enum names to use the `e57` namespace and avoid repetition. ([FreeCAD#176](asmaloney/libE57Format#176))
  - i.e. instead of `e57::E57_STRUCTURE`, we now use `e57::TypeStructure`
- {format} Update clang-format rules for clang-format 15. ([FreeCAD#168](asmaloney/libE57Format#168), [FreeCAD#179](asmaloney/libE57Format#179))
- Change default checksum policies to an enum. ([FreeCAD#166](asmaloney/libE57Format#166))
  Old | New
  --|--
  CHECKSUM_POLICY_NONE | ChecksumPolicy::None
  CHECKSUM_POLICY_SPARSE | ChecksumPolicy::Sparse
  CHECKSUM_POLICY_HALF | ChecksumPolicy::Half
  CHECKSUM_POLICY_ALL | ChecksumPolicy::All
- Avoid implicit conversion in constructors. ([FreeCAD#135](asmaloney/libE57Format#135))
- Update [CRCpp](https://github.com/d-bahr/CRCpp) to 1.2. ([FreeCAD#130](asmaloney/libE57Format#130))
- **E57Exception** changes ([FreeCAD#118](asmaloney/libE57Format#118)):
  - mark methods as `noexcept`
  - use `private` instead of `protected`
- Rename **E57Simple**'s `Data3DPointsData` and `Data3DPointsData_d` structs to `Data3DPointsFloat` and `Data3DPointsDouble` respectively. ([FreeCAD#180](asmaloney/libE57Format#180))
- 🚧 **E57Simple:** Specifying the node type for cartesian & spherical points, time stamp, and intensity is now explicit using new fields (`pointRangeNodeType`, `angleNodeType`, `timeNodeType`, and `intensityNodeType`) and a new enum (`NumericalNodeType`). ([FreeCAD#178](asmaloney/libE57Format#178))
  - For examples, please see _test/src/testSimpleWriter.cpp_.
- Simplify the **E57SimpleWriter** API with `WriteImage2DData()` for images and `WriteData3DData()` for 3D data. This reduces code, hides complexity, and avoids potential errors. ([FreeCAD#171](asmaloney/libE57Format#171))
  - As part of this simplification, `WriteData3DData()` will now fill in any missing min/max values for cartesian & spherical points, intensity, and time stamps by looking at the data.([FreeCAD#175](asmaloney/libE57Format#175))
- 🚧 **E57Simple:** Intensity now uses `double` instead of `float`. ([FreeCAD#178](asmaloney/libE57Format#178))
- 🚧 **E57Simple:** Colours now use `uint16_t` instead of `uint8_t`. ([FreeCAD#167](asmaloney/libE57Format#167))
- 🚧 Change **E57SimpleData**'s Data3D field name from `pointsSize` to `pointCount`. ([FreeCAD#164](asmaloney/libE57Format#164))
- 🚧 Min/max fields in **E57SimpleData**'s Data3D's point fields were a mix of floats and doubles. Since the fields are doubles, set them all to doubles and use the new `Data3DPointsData_t` constructor to set them properly for floats. ([FreeCAD#153](asmaloney/libE57Format#153))
  > **Note:** If you were previously relying on these to be floats and are not using the new `Data3DPointsData_t` constructor, you will need to set these.
- 🚧 Renamed the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's fields in **E57SimpleData**'s `PointStandardizedFieldsAvailable` to be in line with existing code. ([FreeCAD#149](asmaloney/libE57Format#149))
  - `normalX` renamed to `normalXField`
  - `normalY` renamed to `normalYField`
  - `normalZ` renamed to `normalZField`

### Deprecated

- `e57::Utilities::getVersions()`. ([FreeCAD#197](asmaloney/libE57Format#197))
- `e57::Data3DPointsData` and `e57::Data3DPointsData_d` types. ([FreeCAD#180](asmaloney/libE57Format#180))
- Many global const and enum names. The compiler will produce warnings including the replacement symbols (note that enumerators will not produce warnings on C++14, but they will on C++17). ([FreeCAD#176](asmaloney/libE57Format#176))
- `e57::Writer::NewImage2D`and `e57::Writer::SetUpData3DPointsData`. ([FreeCAD#171](asmaloney/libE57Format#171))
- Old default checksum policies (`CHECKSUM_POLICY_NONE`, `CHECKSUM_POLICY_SPARSE`, `CHECKSUM_POLICY_HALF`, and `CHECKSUM_POLICY_ALL`). ([FreeCAD#166](asmaloney/libE57Format#166))
- The old `e57::Reader` constructor taking only `filePath`. ([FreeCAD#139](asmaloney/libE57Format#139))
- The old `e57::Writer` constructor taking only `filePath`. ([FreeCAD#117](asmaloney/libE57Format#117))

### Fixed

- Fix several potential divide-by-zero cases. ([FreeCAD#224](asmaloney/libE57Format#224))
- {ci} Now builds shared library versions as well. ([FreeCAD#219](asmaloney/libE57Format#219))
- {win} Fixes shared library build warnings. ([FreeCAD#215](asmaloney/libE57Format#215), [FreeCAD#216](asmaloney/libE57Format#216), [FreeCAD#217](asmaloney/libE57Format#217))
- Fix the code which shortens floating point numbers when converted to strings. The impact of it being incorrect was negligible since it's just the floating point representation in the XML portion of the file. ([FreeCAD#214](asmaloney/libE57Format#214))
- Turned on a lot of compiler warnings and fixed them. ([FreeCAD#201](asmaloney/libE57Format#201), [FreeCAD#202](asmaloney/libE57Format#202), [FreeCAD#203](asmaloney/libE57Format#203), [FreeCAD#204](asmaloney/libE57Format#204), [FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#207](asmaloney/libE57Format#207), [FreeCAD#209](asmaloney/libE57Format#209))
- Fix writing floating point numbers when `std::locale::global` is set. ([FreeCAD#174](asmaloney/libE57Format#174))
- E57XmlParser: Parse doubles in a locale-independent way. ([FreeCAD#173](asmaloney/libE57Format#173)) (Thanks Hugal31!)
- E57SimpleReader: Ensure scaled integer fields are set as best we can when reading. ([FreeCAD#158](asmaloney/libE57Format#158))
- Fix the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's URI in **E57SimpleWriter**. ([FreeCAD#143](asmaloney/libE57Format#143))
- {win} Fix conversion warning when compiling with debug on. ([FreeCAD#124](asmaloney/libE57Format#124))
- Add errno detail to `E57_ERROR_OPEN_FAILED` exception. ([FreeCAD#119](asmaloney/libE57Format#119), [FreeCAD#120](asmaloney/libE57Format#120))

## [2.3.0](https://github.com/asmaloney/libE57Format/releases/tag/v2.3.0) - 2022-10-04

### Added

- {cmake} Added `E57_VISIBILITY_HIDDEN` option to control [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html). Defaults to `ON`. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- Added BSD support. ([FreeCAD#99](asmaloney/libE57Format#99)) (Thanks Christophe!)

### Changed

- Updated &amp; reorganized the [online API docs](https://asmaloney.github.io/libE57Format-docs/) and changed to a [cleaner theme](https://github.com/jothepro/doxygen-awesome-css).
- Change file creation to use _0666_ permissions on [POSIX](https://en.wikipedia.org/wiki/POSIX) systems. ([FreeCAD#105](asmaloney/libE57Format#105)) (Thanks Nigel!)
- {cmake} [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html) is now set and `ON` by default. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- A new **E57SimpleWriter** constructor takes a `WriterOptions` struct which allows setting the file's GUID.
  ```cpp
  Writer( const ustring &filePath, const WriterOptions &options );
  ```
  The old constructor taking only `coordinateMetadata` is deprecated and will be removed in the future. ([FreeCAD#96](asmaloney/libE57Format#96)) (Thanks Nigel!)
- Change `E57_DEBUG`, `E57_MAX_DEBUG`, `E57_VERBOSE`, `E57_MAX_VERBOSE`, `E57_WRITE_CRAZY_PACKET_MODE` from **#defines** to cmake options. ([FreeCAD#80](asmaloney/libE57Format#80)) (Thanks Nigel!)

### Fixed

- Fix **E57SimpleWriter**'s writing of invalid quaternions. It now defaults to the identity quaternion. ([FreeCAD#108](asmaloney/libE57Format#108)) (Thanks Nigel!)
- Fix **E57SimpleReader** to handle missing `images2D` and `isAtomicClockReferenced` nodes. ([FreeCAD#90](asmaloney/libE57Format#90)) (Thanks Olli!)
- Fix **BitpackIntegerDecoder** sometimes reading past end of input buffer. ([FreeCAD#87](asmaloney/libE57Format#87)) (Thanks Nigel!)
- Fix compilation when some debug options are set. ([FreeCAD#81](asmaloney/libE57Format#81), [FreeCAD#82](asmaloney/libE57Format#82), [FreeCAD#84](asmaloney/libE57Format#84)) (Thanks Nigel!)
- Fix compilation with [musl libc](https://musl.libc.org/) ([FreeCAD#70](asmaloney/libE57Format#70)) (Thanks Dimitri!)
- Add missing include for [GCC 11](https://gcc.gnu.org/gcc-11/porting_to.html#header-dep-changes) ([FreeCAD#68](asmaloney/libE57Format#68)) (Thanks bartoszek!)

**Note:** The next release will be 3.0 and will require a [C++14](https://en.cppreference.com/w/cpp/14) compiler.
mosfet80 added a commit to mosfet80/FreeCAD that referenced this pull request Sep 11, 2023
## 3.1.0 - (in progress)

### Added

- {cmake} New option `E57_RELEASE_LTO` controls whether link-time optimization is on for release builds. It defaults to `ON`. ([FreeCAD#254](asmaloney/libE57Format#254))

  CMake forces "thin" LTO (see [this issue](https://gitlab.kitware.com/cmake/cmake/-/issues/23136)) which is a problem if compiling statically for distribution (e.g. in a package manager). Generally you will only want to turn this off for distributing static release builds.

### Changed

- {cmake} Remove `E57_VISIBILITY_HIDDEN` option. ([FreeCAD#259](asmaloney/libE57Format#259))

  I cannot get extern templates to work across all of gcc, clang, apple clang, and MSVC when using "hidden" visibility with shared libraries.

### Fixed

- Fix clang warnings about implicit conversions in _SourceDestBufferImpl.cpp_. Apple's clang doesn't warn about these, but it looks like the official clang releases do. ([FreeCAD#257](asmaloney/libE57Format#257)) (Thanks Martin!)

## [3.0.2](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.2) - 2023-07-22

### Fixed

- Fix `E57_VERBOSE` build. ([FreeCAD#251](asmaloney/libE57Format#251)) (Thanks Jia!)
- {standard conformance} Fix invalid range exception in FloatNode implementation. ([FreeCAD#250](asmaloney/libE57Format#250))
- Fix reading of index packets. ([FreeCAD#249](asmaloney/libE57Format#249))
- Fix several places where we should be checking for MSVC, not WIN32. ([FreeCAD#248](asmaloney/libE57Format#248))
- Fix "unnecessary semicolons" warnings which prevented building with GCC <= 10. ([FreeCAD#241](asmaloney/libE57Format#241)) (Thanks Andre!)

## [3.0.1](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.1) - 2023-03-15

### Added

- {ci} Added an MSVC 32-bit build. ([FreeCAD#235](asmaloney/libE57Format#235))

### Fixed

- {cmake} Turn off inter-procedural optimization in debug builds. Link-time optimization can make debugging more difficult. ([FreeCAD#240](asmaloney/libE57Format#240))
- {cmake} Don't force a debug postfix if `CMAKE_DEBUG_POSTFIX` is defined.([FreeCAD#239](asmaloney/libE57Format#239))
- {cmake} Don't force install locations. This prevents overriding them using `CMAKE_INSTALL_BINDIR` & `CMAKE_INSTALL_LIBDIR`.([FreeCAD#237](asmaloney/libE57Format#237))
- Fix warnings which prevented building on 32-bit systems. ([FreeCAD#233](asmaloney/libE57Format#233), [FreeCAD#234](asmaloney/libE57Format#234))

## [3.0.0](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.0) - 2023-02-23

There have been _many_ changes around the `Simple API` in this release to fix some problems, avoid potential errors, and simplify the use of the API. Where possible these changes are marked as `deprecated` to be removed later. The compiler will produce warnings for these indicating what needs to change. Other changes could not be marked deprecated but will break the API, requiring code changes. The notable ones are marked with 🚧 below.

### Added

- Add address (ASan) and undefined behaviour (UBSan) sanitizers. These are controlled by `E57FORMAT_SANITIZE_ALL`, `E57FORMAT_SANITIZE_ADDRESS` and `E57FORMAT_SANITIZE_ADDRESS`. They are not included when building with MSVC.
- Add new `E57Version.h` header for more convenient access to version information. ([FreeCAD#197](asmaloney/libE57Format#197)).
- Add `ImageFile::extensionsLookupPrefix()` overload for more concise user code. ([FreeCAD#161](asmaloney/libE57Format#161))
- Added a constructor & destructor for **E57SimpleData**'s `Data3DPointsData_t`. This will create all the required buffers based on an `e57::Data3D` struct and handle their cleanup. See the `SimpleWriter` tests for examples. ([FreeCAD#149](asmaloney/libE57Format#149))

  > **Note:** I strongly recommend these new constructors be used to simplify your code and help prevent errors.

- A new **E57SimpleReader** constructor takes a `ReaderOptions` struct which allows setting the checksum policy.
  ```cpp
  Reader( const ustring &filePath, const ReaderOptions &options );
  ```
- {test} Added testing using [GoogleTest](https://github.com/google/googletest). For details, please see [test/README.md](test/README.md) ([FreeCAD#121](asmaloney/libE57Format#121))
- Added `E57Exception::errorStr()` to get the error string directly. ([FreeCAD#128](asmaloney/libE57Format#128))
- {cmake} Use [ccache](https://ccache.dev/) if available. ([FreeCAD#129](asmaloney/libE57Format#129))
- {ci} Added a CI check for proper clang-formatted code. ([FreeCAD#125](asmaloney/libE57Format#125))

### Changed

- Now requires a **[C++14](https://en.cppreference.com/w/cpp/14)** compatible compiler.
- Now requires **[CMake](https://cmake.org/) >= 3.15**. ([FreeCAD#205](asmaloney/libE57Format#205))
- 🚧 **DEBUG** and **VERBOSE** macros were changed to simplify and clarify:
  - New `E57_ENABLE_DIAGNOSTIC_OUTPUT` controls the inclusion of the code for the `dump()` functions on nodes. I don't see any real reason to turn this off, but I left the capability in for compatibility.
  - New `E57_VALIDATION_LEVEL=N` replaces `E57_DEBUG` (N=1) and `E57_MAX_DEBUG` (N=2).
  - `E57_MAX_VERBOSE` was consolidated with `E57_VERBOSE` since they were essentially the same.
- When building itself, warnings are now treated as errors. ([FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#211](asmaloney/libE57Format#211))
- Clean up global const and enum names to use the `e57` namespace and avoid repetition. ([FreeCAD#176](asmaloney/libE57Format#176))
  - i.e. instead of `e57::E57_STRUCTURE`, we now use `e57::TypeStructure`
- {format} Update clang-format rules for clang-format 15. ([FreeCAD#168](asmaloney/libE57Format#168), [FreeCAD#179](asmaloney/libE57Format#179))
- Change default checksum policies to an enum. ([FreeCAD#166](asmaloney/libE57Format#166))
  Old | New
  --|--
  CHECKSUM_POLICY_NONE | ChecksumPolicy::None
  CHECKSUM_POLICY_SPARSE | ChecksumPolicy::Sparse
  CHECKSUM_POLICY_HALF | ChecksumPolicy::Half
  CHECKSUM_POLICY_ALL | ChecksumPolicy::All
- Avoid implicit conversion in constructors. ([FreeCAD#135](asmaloney/libE57Format#135))
- Update [CRCpp](https://github.com/d-bahr/CRCpp) to 1.2. ([FreeCAD#130](asmaloney/libE57Format#130))
- **E57Exception** changes ([FreeCAD#118](asmaloney/libE57Format#118)):
  - mark methods as `noexcept`
  - use `private` instead of `protected`
- Rename **E57Simple**'s `Data3DPointsData` and `Data3DPointsData_d` structs to `Data3DPointsFloat` and `Data3DPointsDouble` respectively. ([FreeCAD#180](asmaloney/libE57Format#180))
- 🚧 **E57Simple:** Specifying the node type for cartesian & spherical points, time stamp, and intensity is now explicit using new fields (`pointRangeNodeType`, `angleNodeType`, `timeNodeType`, and `intensityNodeType`) and a new enum (`NumericalNodeType`). ([FreeCAD#178](asmaloney/libE57Format#178))
  - For examples, please see _test/src/testSimpleWriter.cpp_.
- Simplify the **E57SimpleWriter** API with `WriteImage2DData()` for images and `WriteData3DData()` for 3D data. This reduces code, hides complexity, and avoids potential errors. ([FreeCAD#171](asmaloney/libE57Format#171))
  - As part of this simplification, `WriteData3DData()` will now fill in any missing min/max values for cartesian & spherical points, intensity, and time stamps by looking at the data.([FreeCAD#175](asmaloney/libE57Format#175))
- 🚧 **E57Simple:** Intensity now uses `double` instead of `float`. ([FreeCAD#178](asmaloney/libE57Format#178))
- 🚧 **E57Simple:** Colours now use `uint16_t` instead of `uint8_t`. ([FreeCAD#167](asmaloney/libE57Format#167))
- 🚧 Change **E57SimpleData**'s Data3D field name from `pointsSize` to `pointCount`. ([FreeCAD#164](asmaloney/libE57Format#164))
- 🚧 Min/max fields in **E57SimpleData**'s Data3D's point fields were a mix of floats and doubles. Since the fields are doubles, set them all to doubles and use the new `Data3DPointsData_t` constructor to set them properly for floats. ([FreeCAD#153](asmaloney/libE57Format#153))
  > **Note:** If you were previously relying on these to be floats and are not using the new `Data3DPointsData_t` constructor, you will need to set these.
- 🚧 Renamed the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's fields in **E57SimpleData**'s `PointStandardizedFieldsAvailable` to be in line with existing code. ([FreeCAD#149](asmaloney/libE57Format#149))
  - `normalX` renamed to `normalXField`
  - `normalY` renamed to `normalYField`
  - `normalZ` renamed to `normalZField`

### Deprecated

- `e57::Utilities::getVersions()`. ([FreeCAD#197](asmaloney/libE57Format#197))
- `e57::Data3DPointsData` and `e57::Data3DPointsData_d` types. ([FreeCAD#180](asmaloney/libE57Format#180))
- Many global const and enum names. The compiler will produce warnings including the replacement symbols (note that enumerators will not produce warnings on C++14, but they will on C++17). ([FreeCAD#176](asmaloney/libE57Format#176))
- `e57::Writer::NewImage2D`and `e57::Writer::SetUpData3DPointsData`. ([FreeCAD#171](asmaloney/libE57Format#171))
- Old default checksum policies (`CHECKSUM_POLICY_NONE`, `CHECKSUM_POLICY_SPARSE`, `CHECKSUM_POLICY_HALF`, and `CHECKSUM_POLICY_ALL`). ([FreeCAD#166](asmaloney/libE57Format#166))
- The old `e57::Reader` constructor taking only `filePath`. ([FreeCAD#139](asmaloney/libE57Format#139))
- The old `e57::Writer` constructor taking only `filePath`. ([FreeCAD#117](asmaloney/libE57Format#117))

### Fixed

- Fix several potential divide-by-zero cases. ([FreeCAD#224](asmaloney/libE57Format#224))
- {ci} Now builds shared library versions as well. ([FreeCAD#219](asmaloney/libE57Format#219))
- {win} Fixes shared library build warnings. ([FreeCAD#215](asmaloney/libE57Format#215), [FreeCAD#216](asmaloney/libE57Format#216), [FreeCAD#217](asmaloney/libE57Format#217))
- Fix the code which shortens floating point numbers when converted to strings. The impact of it being incorrect was negligible since it's just the floating point representation in the XML portion of the file. ([FreeCAD#214](asmaloney/libE57Format#214))
- Turned on a lot of compiler warnings and fixed them. ([FreeCAD#201](asmaloney/libE57Format#201), [FreeCAD#202](asmaloney/libE57Format#202), [FreeCAD#203](asmaloney/libE57Format#203), [FreeCAD#204](asmaloney/libE57Format#204), [FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#207](asmaloney/libE57Format#207), [FreeCAD#209](asmaloney/libE57Format#209))
- Fix writing floating point numbers when `std::locale::global` is set. ([FreeCAD#174](asmaloney/libE57Format#174))
- E57XmlParser: Parse doubles in a locale-independent way. ([FreeCAD#173](asmaloney/libE57Format#173)) (Thanks Hugal31!)
- E57SimpleReader: Ensure scaled integer fields are set as best we can when reading. ([FreeCAD#158](asmaloney/libE57Format#158))
- Fix the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's URI in **E57SimpleWriter**. ([FreeCAD#143](asmaloney/libE57Format#143))
- {win} Fix conversion warning when compiling with debug on. ([FreeCAD#124](asmaloney/libE57Format#124))
- Add errno detail to `E57_ERROR_OPEN_FAILED` exception. ([FreeCAD#119](asmaloney/libE57Format#119), [FreeCAD#120](asmaloney/libE57Format#120))

## [2.3.0](https://github.com/asmaloney/libE57Format/releases/tag/v2.3.0) - 2022-10-04

### Added

- {cmake} Added `E57_VISIBILITY_HIDDEN` option to control [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html). Defaults to `ON`. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- Added BSD support. ([FreeCAD#99](asmaloney/libE57Format#99)) (Thanks Christophe!)

### Changed

- Updated &amp; reorganized the [online API docs](https://asmaloney.github.io/libE57Format-docs/) and changed to a [cleaner theme](https://github.com/jothepro/doxygen-awesome-css).
- Change file creation to use _0666_ permissions on [POSIX](https://en.wikipedia.org/wiki/POSIX) systems. ([FreeCAD#105](asmaloney/libE57Format#105)) (Thanks Nigel!)
- {cmake} [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html) is now set and `ON` by default. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- A new **E57SimpleWriter** constructor takes a `WriterOptions` struct which allows setting the file's GUID.
  ```cpp
  Writer( const ustring &filePath, const WriterOptions &options );
  ```
  The old constructor taking only `coordinateMetadata` is deprecated and will be removed in the future. ([FreeCAD#96](asmaloney/libE57Format#96)) (Thanks Nigel!)
- Change `E57_DEBUG`, `E57_MAX_DEBUG`, `E57_VERBOSE`, `E57_MAX_VERBOSE`, `E57_WRITE_CRAZY_PACKET_MODE` from **#defines** to cmake options. ([FreeCAD#80](asmaloney/libE57Format#80)) (Thanks Nigel!)

### Fixed

- Fix **E57SimpleWriter**'s writing of invalid quaternions. It now defaults to the identity quaternion. ([FreeCAD#108](asmaloney/libE57Format#108)) (Thanks Nigel!)
- Fix **E57SimpleReader** to handle missing `images2D` and `isAtomicClockReferenced` nodes. ([FreeCAD#90](asmaloney/libE57Format#90)) (Thanks Olli!)
- Fix **BitpackIntegerDecoder** sometimes reading past end of input buffer. ([FreeCAD#87](asmaloney/libE57Format#87)) (Thanks Nigel!)
- Fix compilation when some debug options are set. ([FreeCAD#81](asmaloney/libE57Format#81), [FreeCAD#82](asmaloney/libE57Format#82), [FreeCAD#84](asmaloney/libE57Format#84)) (Thanks Nigel!)
- Fix compilation with [musl libc](https://musl.libc.org/) ([FreeCAD#70](asmaloney/libE57Format#70)) (Thanks Dimitri!)
- Add missing include for [GCC 11](https://gcc.gnu.org/gcc-11/porting_to.html#header-dep-changes) ([FreeCAD#68](asmaloney/libE57Format#68)) (Thanks bartoszek!)

**Note:** The next release will be 3.0 and will require a [C++14](https://en.cppreference.com/w/cpp/14) compiler.

updated libe57Format from v2.2.1 to 3.1

### Added

- {cmake} New option `E57_RELEASE_LTO` controls whether link-time optimization is on for release builds. It defaults to `ON`. ([FreeCAD#254](asmaloney/libE57Format#254))

  CMake forces "thin" LTO (see [this issue](https://gitlab.kitware.com/cmake/cmake/-/issues/23136)) which is a problem if compiling statically for distribution (e.g. in a package manager). Generally you will only want to turn this off for distributing static release builds.

### Changed

- {cmake} Remove `E57_VISIBILITY_HIDDEN` option. ([FreeCAD#259](asmaloney/libE57Format#259))

  I cannot get extern templates to work across all of gcc, clang, apple clang, and MSVC when using "hidden" visibility with shared libraries.

### Fixed

- Fix clang warnings about implicit conversions in _SourceDestBufferImpl.cpp_. Apple's clang doesn't warn about these, but it looks like the official clang releases do. ([FreeCAD#257](asmaloney/libE57Format#257)) (Thanks Martin!)

## [3.0.2](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.2) - 2023-07-22

### Fixed

- Fix `E57_VERBOSE` build. ([FreeCAD#251](asmaloney/libE57Format#251)) (Thanks Jia!)
- {standard conformance} Fix invalid range exception in FloatNode implementation. ([FreeCAD#250](asmaloney/libE57Format#250))
- Fix reading of index packets. ([FreeCAD#249](asmaloney/libE57Format#249))
- Fix several places where we should be checking for MSVC, not WIN32. ([FreeCAD#248](asmaloney/libE57Format#248))
- Fix "unnecessary semicolons" warnings which prevented building with GCC <= 10. ([FreeCAD#241](asmaloney/libE57Format#241)) (Thanks Andre!)

## [3.0.1](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.1) - 2023-03-15

### Added

- {ci} Added an MSVC 32-bit build. ([FreeCAD#235](asmaloney/libE57Format#235))

### Fixed

- {cmake} Turn off inter-procedural optimization in debug builds. Link-time optimization can make debugging more difficult. ([FreeCAD#240](asmaloney/libE57Format#240))
- {cmake} Don't force a debug postfix if `CMAKE_DEBUG_POSTFIX` is defined.([FreeCAD#239](asmaloney/libE57Format#239))
- {cmake} Don't force install locations. This prevents overriding them using `CMAKE_INSTALL_BINDIR` & `CMAKE_INSTALL_LIBDIR`.([FreeCAD#237](asmaloney/libE57Format#237))
- Fix warnings which prevented building on 32-bit systems. ([FreeCAD#233](asmaloney/libE57Format#233), [FreeCAD#234](asmaloney/libE57Format#234))

## [3.0.0](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.0) - 2023-02-23

There have been _many_ changes around the `Simple API` in this release to fix some problems, avoid potential errors, and simplify the use of the API. Where possible these changes are marked as `deprecated` to be removed later. The compiler will produce warnings for these indicating what needs to change. Other changes could not be marked deprecated but will break the API, requiring code changes. The notable ones are marked with 🚧 below.

### Added

- Add address (ASan) and undefined behaviour (UBSan) sanitizers. These are controlled by `E57FORMAT_SANITIZE_ALL`, `E57FORMAT_SANITIZE_ADDRESS` and `E57FORMAT_SANITIZE_ADDRESS`. They are not included when building with MSVC.
- Add new `E57Version.h` header for more convenient access to version information. ([FreeCAD#197](asmaloney/libE57Format#197)).
- Add `ImageFile::extensionsLookupPrefix()` overload for more concise user code. ([FreeCAD#161](asmaloney/libE57Format#161))
- Added a constructor & destructor for **E57SimpleData**'s `Data3DPointsData_t`. This will create all the required buffers based on an `e57::Data3D` struct and handle their cleanup. See the `SimpleWriter` tests for examples. ([FreeCAD#149](asmaloney/libE57Format#149))

  > **Note:** I strongly recommend these new constructors be used to simplify your code and help prevent errors.

- A new **E57SimpleReader** constructor takes a `ReaderOptions` struct which allows setting the checksum policy.
  ```cpp
  Reader( const ustring &filePath, const ReaderOptions &options );
  ```
- {test} Added testing using [GoogleTest](https://github.com/google/googletest). For details, please see [test/README.md](test/README.md) ([FreeCAD#121](asmaloney/libE57Format#121))
- Added `E57Exception::errorStr()` to get the error string directly. ([FreeCAD#128](asmaloney/libE57Format#128))
- {cmake} Use [ccache](https://ccache.dev/) if available. ([FreeCAD#129](asmaloney/libE57Format#129))
- {ci} Added a CI check for proper clang-formatted code. ([FreeCAD#125](asmaloney/libE57Format#125))

### Changed

- Now requires a **[C++14](https://en.cppreference.com/w/cpp/14)** compatible compiler.
- Now requires **[CMake](https://cmake.org/) >= 3.15**. ([FreeCAD#205](asmaloney/libE57Format#205))
- 🚧 **DEBUG** and **VERBOSE** macros were changed to simplify and clarify:
  - New `E57_ENABLE_DIAGNOSTIC_OUTPUT` controls the inclusion of the code for the `dump()` functions on nodes. I don't see any real reason to turn this off, but I left the capability in for compatibility.
  - New `E57_VALIDATION_LEVEL=N` replaces `E57_DEBUG` (N=1) and `E57_MAX_DEBUG` (N=2).
  - `E57_MAX_VERBOSE` was consolidated with `E57_VERBOSE` since they were essentially the same.
- When building itself, warnings are now treated as errors. ([FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#211](asmaloney/libE57Format#211))
- Clean up global const and enum names to use the `e57` namespace and avoid repetition. ([FreeCAD#176](asmaloney/libE57Format#176))
  - i.e. instead of `e57::E57_STRUCTURE`, we now use `e57::TypeStructure`
- {format} Update clang-format rules for clang-format 15. ([FreeCAD#168](asmaloney/libE57Format#168), [FreeCAD#179](asmaloney/libE57Format#179))
- Change default checksum policies to an enum. ([FreeCAD#166](asmaloney/libE57Format#166))
  Old | New
  --|--
  CHECKSUM_POLICY_NONE | ChecksumPolicy::None
  CHECKSUM_POLICY_SPARSE | ChecksumPolicy::Sparse
  CHECKSUM_POLICY_HALF | ChecksumPolicy::Half
  CHECKSUM_POLICY_ALL | ChecksumPolicy::All
- Avoid implicit conversion in constructors. ([FreeCAD#135](asmaloney/libE57Format#135))
- Update [CRCpp](https://github.com/d-bahr/CRCpp) to 1.2. ([FreeCAD#130](asmaloney/libE57Format#130))
- **E57Exception** changes ([FreeCAD#118](asmaloney/libE57Format#118)):
  - mark methods as `noexcept`
  - use `private` instead of `protected`
- Rename **E57Simple**'s `Data3DPointsData` and `Data3DPointsData_d` structs to `Data3DPointsFloat` and `Data3DPointsDouble` respectively. ([FreeCAD#180](asmaloney/libE57Format#180))
- 🚧 **E57Simple:** Specifying the node type for cartesian & spherical points, time stamp, and intensity is now explicit using new fields (`pointRangeNodeType`, `angleNodeType`, `timeNodeType`, and `intensityNodeType`) and a new enum (`NumericalNodeType`). ([FreeCAD#178](asmaloney/libE57Format#178))
  - For examples, please see _test/src/testSimpleWriter.cpp_.
- Simplify the **E57SimpleWriter** API with `WriteImage2DData()` for images and `WriteData3DData()` for 3D data. This reduces code, hides complexity, and avoids potential errors. ([FreeCAD#171](asmaloney/libE57Format#171))
  - As part of this simplification, `WriteData3DData()` will now fill in any missing min/max values for cartesian & spherical points, intensity, and time stamps by looking at the data.([FreeCAD#175](asmaloney/libE57Format#175))
- 🚧 **E57Simple:** Intensity now uses `double` instead of `float`. ([FreeCAD#178](asmaloney/libE57Format#178))
- 🚧 **E57Simple:** Colours now use `uint16_t` instead of `uint8_t`. ([FreeCAD#167](asmaloney/libE57Format#167))
- 🚧 Change **E57SimpleData**'s Data3D field name from `pointsSize` to `pointCount`. ([FreeCAD#164](asmaloney/libE57Format#164))
- 🚧 Min/max fields in **E57SimpleData**'s Data3D's point fields were a mix of floats and doubles. Since the fields are doubles, set them all to doubles and use the new `Data3DPointsData_t` constructor to set them properly for floats. ([FreeCAD#153](asmaloney/libE57Format#153))
  > **Note:** If you were previously relying on these to be floats and are not using the new `Data3DPointsData_t` constructor, you will need to set these.
- 🚧 Renamed the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's fields in **E57SimpleData**'s `PointStandardizedFieldsAvailable` to be in line with existing code. ([FreeCAD#149](asmaloney/libE57Format#149))
  - `normalX` renamed to `normalXField`
  - `normalY` renamed to `normalYField`
  - `normalZ` renamed to `normalZField`

### Deprecated

- `e57::Utilities::getVersions()`. ([FreeCAD#197](asmaloney/libE57Format#197))
- `e57::Data3DPointsData` and `e57::Data3DPointsData_d` types. ([FreeCAD#180](asmaloney/libE57Format#180))
- Many global const and enum names. The compiler will produce warnings including the replacement symbols (note that enumerators will not produce warnings on C++14, but they will on C++17). ([FreeCAD#176](asmaloney/libE57Format#176))
- `e57::Writer::NewImage2D`and `e57::Writer::SetUpData3DPointsData`. ([FreeCAD#171](asmaloney/libE57Format#171))
- Old default checksum policies (`CHECKSUM_POLICY_NONE`, `CHECKSUM_POLICY_SPARSE`, `CHECKSUM_POLICY_HALF`, and `CHECKSUM_POLICY_ALL`). ([FreeCAD#166](asmaloney/libE57Format#166))
- The old `e57::Reader` constructor taking only `filePath`. ([FreeCAD#139](asmaloney/libE57Format#139))
- The old `e57::Writer` constructor taking only `filePath`. ([FreeCAD#117](asmaloney/libE57Format#117))

### Fixed

- Fix several potential divide-by-zero cases. ([FreeCAD#224](asmaloney/libE57Format#224))
- {ci} Now builds shared library versions as well. ([FreeCAD#219](asmaloney/libE57Format#219))
- {win} Fixes shared library build warnings. ([FreeCAD#215](asmaloney/libE57Format#215), [FreeCAD#216](asmaloney/libE57Format#216), [FreeCAD#217](asmaloney/libE57Format#217))
- Fix the code which shortens floating point numbers when converted to strings. The impact of it being incorrect was negligible since it's just the floating point representation in the XML portion of the file. ([FreeCAD#214](asmaloney/libE57Format#214))
- Turned on a lot of compiler warnings and fixed them. ([FreeCAD#201](asmaloney/libE57Format#201), [FreeCAD#202](asmaloney/libE57Format#202), [FreeCAD#203](asmaloney/libE57Format#203), [FreeCAD#204](asmaloney/libE57Format#204), [FreeCAD#205](asmaloney/libE57Format#205), [FreeCAD#207](asmaloney/libE57Format#207), [FreeCAD#209](asmaloney/libE57Format#209))
- Fix writing floating point numbers when `std::locale::global` is set. ([FreeCAD#174](asmaloney/libE57Format#174))
- E57XmlParser: Parse doubles in a locale-independent way. ([FreeCAD#173](asmaloney/libE57Format#173)) (Thanks Hugal31!)
- E57SimpleReader: Ensure scaled integer fields are set as best we can when reading. ([FreeCAD#158](asmaloney/libE57Format#158))
- Fix the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's URI in **E57SimpleWriter**. ([FreeCAD#143](asmaloney/libE57Format#143))
- {win} Fix conversion warning when compiling with debug on. ([FreeCAD#124](asmaloney/libE57Format#124))
- Add errno detail to `E57_ERROR_OPEN_FAILED` exception. ([FreeCAD#119](asmaloney/libE57Format#119), [FreeCAD#120](asmaloney/libE57Format#120))

## [2.3.0](https://github.com/asmaloney/libE57Format/releases/tag/v2.3.0) - 2022-10-04

### Added

- {cmake} Added `E57_VISIBILITY_HIDDEN` option to control [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html). Defaults to `ON`. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- Added BSD support. ([FreeCAD#99](asmaloney/libE57Format#99)) (Thanks Christophe!)

### Changed

- Updated &amp; reorganized the [online API docs](https://asmaloney.github.io/libE57Format-docs/) and changed to a [cleaner theme](https://github.com/jothepro/doxygen-awesome-css).
- Change file creation to use _0666_ permissions on [POSIX](https://en.wikipedia.org/wiki/POSIX) systems. ([FreeCAD#105](asmaloney/libE57Format#105)) (Thanks Nigel!)
- {cmake} [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html) is now set and `ON` by default. ([FreeCAD#104](asmaloney/libE57Format#104)) (Thanks Nigel!)
- A new **E57SimpleWriter** constructor takes a `WriterOptions` struct which allows setting the file's GUID.
  ```cpp
  Writer( const ustring &filePath, const WriterOptions &options );
  ```
  The old constructor taking only `coordinateMetadata` is deprecated and will be removed in the future. ([FreeCAD#96](asmaloney/libE57Format#96)) (Thanks Nigel!)
- Change `E57_DEBUG`, `E57_MAX_DEBUG`, `E57_VERBOSE`, `E57_MAX_VERBOSE`, `E57_WRITE_CRAZY_PACKET_MODE` from **#defines** to cmake options. ([FreeCAD#80](asmaloney/libE57Format#80)) (Thanks Nigel!)

### Fixed

- Fix **E57SimpleWriter**'s writing of invalid quaternions. It now defaults to the identity quaternion. ([FreeCAD#108](asmaloney/libE57Format#108)) (Thanks Nigel!)
- Fix **E57SimpleReader** to handle missing `images2D` and `isAtomicClockReferenced` nodes. ([FreeCAD#90](asmaloney/libE57Format#90)) (Thanks Olli!)
- Fix **BitpackIntegerDecoder** sometimes reading past end of input buffer. ([FreeCAD#87](asmaloney/libE57Format#87)) (Thanks Nigel!)
- Fix compilation when some debug options are set. ([FreeCAD#81](asmaloney/libE57Format#81), [FreeCAD#82](asmaloney/libE57Format#82), [FreeCAD#84](asmaloney/libE57Format#84)) (Thanks Nigel!)
- Fix compilation with [musl libc](https://musl.libc.org/) ([FreeCAD#70](asmaloney/libE57Format#70)) (Thanks Dimitri!)
- Add missing include for [GCC 11](https://gcc.gnu.org/gcc-11/porting_to.html#header-dep-changes) ([FreeCAD#68](asmaloney/libE57Format#68)) (Thanks bartoszek!)

**Note:** The next release will be 3.0 and will require a [C++14](https://en.cppreference.com/w/cpp/14) compiler.
ebffe5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants