# Envision 2.0

February 28, 2024 - SHA: 35e51d55

Envision 2.0 is a major release which means it contains breaking changes. The main focus this release have been:

- Updating to newer compilers
- Upgrading dependencies to increase performance and reduce vulnerabilities
- Removing deprecated code
- Strengthen core implementation to make the components more robust
- Ensuring that the public interfaces remain clean and consistent
- Improved automated testing

All this to ensure that we are better equipped to continue to provide the best CAE Visualization toolkit in the marked!

Updated Supported Platforms

Envision now supports the following platforms:

Supported platforms | Operating system | Compiler
--- | --- | ---
Windows | Windows 10 | MSVC 2019 (142 toolset)
Linux | Ubuntu 20.04 (glibc 2.31) | gcc 9.4

Envision for Web Envision for Desktop

## New Features

### CAE-1257 C++17 Standard

Envision is now built using the C++ 17 standard.

### CAE-1245 Node.js version upgrade

We now support Node.js runtime version 18.
https://nodejs.org/

### CAE-1231 Add scalar result filtering to Web

Scalar results can now be filtered on Web with `cee.ug.ScalarSettings.setFilteringRange()`. Results outside of this range will not be drawn. Feature already exists on Desktop.

### CAE-1291 Update to version 1.9.1 of CEETRON Access

Our file interfaces now uses version 1.9.1 of CEETRON Access (CeetronSAM_1.9.1_945b810c)

### CAE-1294 Updated to TBB 2021.11

Updated to version 2021.11 of oneAPI Threading Building Blocks (oneTBB).
https://github.com/oneapi-src/oneTBB

### CAE-1245 Improved in-editor navigation of api documentation

Inline comments now use JSdoc @link references to other symbols in the declaration file, enabling quick navigation in modern editors.

## Breaking Changes

### CAE-1254 Handling of default camera config for UG and CUG

New functionality:

- Added new abstract method `Model.getDefaultCameraConfig()` that lets a model report a default camera configuration. Currently implemented by the `RemoteModel` and `ConstantRemoteModel` models.
- Added new methods `Camera.applyCameraConfig()` and `Camera.resetCamera()`.

Changes:

- The signature of the `ug.OpenModelCallback` function, utilized in `ug.RemoteModel.openModel()` has changed. A new parameter, info of type `ug.OpenModelInfo`, has been added to be able to communicate camera configurations from the server through the `serverCameraConfig` property.
- The logic for setting up a default camera in a `View` when the camera has not already been modified has changed. This logic will now try and use the default camera config of the contained models if any exist. Note that this will only happen if the camera has not yet been modified. The new function `Camera.resetCamera()` can be used to reset a view to its initial state.
- Instances of `ug.RemoteModel` will no longer reset/update the camera of the views it which they are contained. For views where the camera has not been modified, the view will try and derive a default camera setup by calling the `ug.RemoteModel.getDefaultCameraConfig()` function on the contained models. For most use-cases we recommend that you explicitly configure the view’s camera before streaming of the model starts instead. This would normally be done in the `ug.OpenModelCallback` function, either by utilizing `ug.RemoteModel.getDefaultCameraConfig()` or any camera config received through `ug.OpenModelInfo.serverCameraConfig`.
- The signature of the `ug.RemoteModel.applyVTFxCase()` has changed. The `applyCameraSettings` parameter has been removed. It is no longer possible to have the model automatically apply the camera settings to the associated views. This must now be done in the callback function.

### CAE-1249 Refactor and consolidate bounding boxes

The overall change going forward is that when `Model.getBoundingBox()` is called without any parameters it will return the current bounding box of the model. This bounding box includes only the parts/objects that are currently visible in the model.

To get the full (ignoring part visibility) bounding box of the model, `Model.getBoundingBox()` can be called with the optional `ModelBoundingBoxOptions.includeHiddenParts` parameter set to true. Note that at the moment `RemoteModel` and `ConstantRemoteModel` does not support `ModelBoundingBoxOptions`.

The same logic applies to `View.getBoundingBox()` which also accepts an optional `ModelBoundingBoxOptions` parameter. Consequently, `View.getBoundingBoxVisibleParts()` has been removed.

Breaking changes

- `View.getBoundingBox()` now returns the bounding box of visible parts/objects by default. If you want to get the “full” bounding box that includes hidden items, you can achieve this by setting the optional `ModelBoundingBoxOptions.includeHiddenParts` flag to true. Note that this is not fully supported by all models.
- Removed the `View.getBoundingBoxVisibleParts()` method. Getting the bounding box for the visible parts is now the default behavior of `View.getBoundingBox()`

API removed/renamed/changes features
| Class/function | Replacement
--- | --- | ---
CAE-1260 | `cee.ug.RemoteModel.appendModel()` | If multiple models are desired, create and open another `RemoteModel`
CAE-934 | `cee::vis::Overlay` `::setDisableModelItems(bool)` | Use `cee::vis::disableModelItems(bool)` instead
CAE-934 | `cee::vis::Overlay` `::disableModelItems()` | Use `cee::vis::Overlay::isModelItemsDisabled()` instead
CAE-924 | `cee::ug::PartSettings` `::elementSetFilteringEnabled()` | Use `cee::ug::PartSettings::isElementSetFilteringDisabled()` instead. NOTE! The logic is now inverted!
    bool isDisabled = !ps->elementSetFilteringEnabled();    \\ OLD
    bool isDisabled = ps->isElementSetFilteringDisabled();  \\ NEW
CAE-924 | `cee::ug::PartSettings` `::setElementSetFilteringEnabled(bool)` | Use `cee::ug::PartSettings::disableElementSetFiltering()` instead. NOTE! The logic is now inverted!
    bool disable = true;
    ps->setElementSetFilteringEnabled(!disable);  \\ OLD
    ps->disableElementSetFiltering(disable);      \\ NEW
CAE-1274 | `cee::vis::Font::createTrueTypeFont()` | Helper function is removed. Use the `cee::vis::TrueTypeFont` class instead.
CAE-891 | `cee.geo.PartSettings.EyeLift` `cee.ug.PartSettings.EyeLift` `cee.mrk.EyeLift` | Use the base `cee.EyeLift` enum instead.
CAE-1273 | `cee::ug::DataSourceDirectory` `::setScalarResultInfo()` `::setVectorResultInfo()` `::setDisplacementResultInfo()` `::setSymmetricTensorResultInfo()` | Instead, use `cee::ug::DataSourceDirectory::setResultInfo()` with the correct result type enum. (`cee::ug::SCALAR`, `cee::ug::VECTOR`, `cee::ug::DISPLACEMENT` or `cee::ug::SYMMETRIC_TENSOR`.)
CAE-1273 | `cee::ug::DataSourceDirectory` `::removeAllScalarResultInfos()` `::removeAllVectorResultInfos()` `::removeAllDisplacementResultInfos()` `::removeAllSymmetricTensorResultInfos()` | Instead, use `cee::ug::DataSourceDirectory::removeAllResultInfos()` with the correct result type enum. (`cee::ug::SCALAR`, `cee::ug::VECTOR`, `cee::ug::DISPLACEMENT` or `cee::ug::SYMMETRIC_TENSOR`.)
CAE-1260 | `cee.mrk.LabelAppearance.anchorPointColor` | Use `mrk.LabelAttachmentAppearance.anchorPointColor` instead.
CAE-1260 | `cee.mrk.LabelAppearance.anchorPointSize` | Use `mrk.LabelAttachmentAppearance.anchorPointSize` instead.
CAE-1260 | `cee.mrk.PartImageLabel` `.attachmentLineLength` | Use `mrk.LabelAttachmentAppearance.lineLength` instead.
CAE-1260 | `cee.mrk.PartImageLabel` `.attachmentPointVisible` | Use `mrk.LabelAttachmentAppearance.anchorPointSize` instead.
CAE-1260 | `cee.mrk.PartLabels.attachmentLineLength` | Use `mrk.LabelAttachmentAppearance.lineLength` instead.
CAE-1260 | `cee.ug.QueryNodeInfo.executeQuery` | Use `ug.QueryNodeInfo.executeQueryByIds` instead.
CAE-1260 | `cee.ug.VectorSettings.vectorType` | Instead, use methods `setVectorTypeArrow`, `setVectorTypeSymmetricArrow`, `setVectorTypeDynamicSymmetricArrow` or `setVectorTypeReverseSymmetricArrow`.
CAE-1260 | `cee.Viewer.rayFromMouseCoordinate` | Use `cee.Viewer.rayFromCssCoordinate` instead, using `MouseEvent.offsetX/offsetY`.
CAE-1260 | `cee.View.backgroundColor` | Use `cee.View.background.setSingleColor` or `cee.View.background.topColor` instead.
CAE-1300 | `cee::ug::DataSource` `::defaultDispacementResultId()` | Use `cee::ug::DataSource::defaultDisplacementResultId()` instead.
CAE-1258 | `cee::rep::Snapshot` `::fieldValues()` `::setFieldValues()` | Refactored `cee::rep::Snapshot` and `cee::rep::FieldValuesGenerator` (into `FieldValueSet`). In `cee::rep::Snapshot`, replaced member functions `fieldValues()` and `setFieldValues()` with `fieldValueSet()` and `setFieldValueSet()`. The new `cee::rep::FieldValueSet` class replaces the existing static helper class `cee::rep::FieldValuesGenerator`. Instances of `FieldValueSet` can be constructed and initialized from a `cee::ug::UnstructGridModel` model, and the resulting instance can be passed directly to a `Snapshot` instance using the `setFieldValueSet()` member function.
CAE-1258 | `cee::ImageResources::allImageResources()` | Use `cee::ImageResources::allResourceNames()` and `cee::ImageResources::imageResource()` instead.
CAE-1258 | `cee::ug::Situation` `::setAllUserData()` `::allUserData()` | Use new `cee::ug::Situation::allUserDataKeys()` in conjunction with `cee::ug::Situation::userData()` instead.
CAE-1258 | `cee::ug::Situation` `::elementSets()` `::elementSetInfos()` | Use new non-array versions `cee::ug::Situation::elementSet()` and `cee::ug::Situation::elementSetInfo()` instead.
CAE-1258 | `cee::ug::Situation` `::addElementSet()` `::addElementSetInfo()` | In `cee::ug::Situation`, refactored `addElementSet()` to take both an element set and element set info. Removed the `addElementSetInfo()` member function.
CAE-1258 | `cee::geo::GeometryModel` `::regionIntersect()` `::polygonIntersect()` | Refactored `cee::geo::GeometryModel::regionIntersect()` and `cee::geo::GeometryModel::polygonIntersect()` to use new `cee::geo::PartCollection` class for returning results.
CAE-1298 | `cee.ug.RemoteModelTrianglePicker` `cee.ug.RemoteModelPickHelper` `cee.ug.RemoteModelHighlightHelper` | Remove unnecessary and confusing “RemoteModel” prefix to some of the worker/utility classes in UG/RemoteModel. Renamed utility class `ug.RemoteModelTrianglePicker` to `ug.TrianglePicker` Renamed utility class `ug.RemoteModelPickHelper` to `ug.PickHelper` Renamed utility class `ug.RemoteModelHighlightHelper` to `ug.HighlightHelper`
CAE-1314 | `cee::ug::UnstructGrid::DataSourceCae` `::vdmVersion()` | Renamed to `DataSourceCae::accessVersion()`

Conversation saved
HOOPSY BETA

### Hello! I'm HOOPSY

Your multilingual generative AI assistant for documentation. Ask me anything about HOOPS Envision for Web in your own language, or choose a sample question below to start a conversation:

What is HOOPS Envision for Web?
What are the latest release notes for HOOPS Envision for Web?
How do I start evaluating HOOPS Envision for Web?
How do I write my first sample application?
How can I get assistance?

HOOPSY may store conversations according to OpenAI's policy. Responses may not always be accurate.

HOOPSY is thinking...