:tocdepth: 2

############
Envision 1.0
############

September 28, 2022 - SHA: 39e4a5d5

Note: Envision 1.0 requires a new license and a new way to provide that license to the toolkit. Please see the 
license section below.


------------------------------------------------

*************
New Features
*************

CAE-850 Added support for Python 3.7-3.10 in one unified distribution
=====================================================================

Envision Desktop now supports Python 3.7-3.10. In the distribution archive, there is a Python folder that 
contains what used to be Ceetron Python Modules [CPM].

Note that we have changed the python folder from ``cee`` to ``cee_envision`` to prepare for distribution on PyPI. So all old 
scripts using CPM needs to be updated to reflect this change.


CAE-774 [Web] Add support for dynamic symmetric arrows for vectors
==================================================================

Added support for drawing symmetric vector arrows which direction (inward or outward) is controlled by the sign of a 
user defined scalar result. This could be used to show if a stress result is compression or tension. 

Added a new vector type (``DYNAMIC_SYMMETRIC_ARROW``) and ``VectorSettings.setVectorTypeDynamicSymmetricArrow(scalarId: number)`` 
to specify this new visualization. 


.. note::
    The property ``VectorSettings.vectorType`` now is a read-only property and the set property is deprecated. 
    It will still work, but will be removed in future versions. So please use the new ``setVectorTypeArrow()``, 
    ``setVectorTypeSymmetricArrow()`` and ``setVectorTypeReverseSymmetricArrow()`` functions in ``VectorSettings`` to 
    change the vector type.


CAE-698 [Web] Client-side element picking
=========================================

Added support for client side picking of visible triangles within a region (rectangle) or along a path (set of points). 
This is a fast way to find all visible triangles within a region. You can then use the output of this to highlight the 
triangles, or to query the server to get which elements these triangles represent. 

Added ``RemoteModelElementPicker`` which can be produced by ``RemoteModel.createElementPicker(view: View)``. Use the 
``getVisibleElementsInRectangle`` or ``getVisibleElementsAtPoints`` methods to perform the query. Note that a new 
``RemoteModelElementPicker`` must be created if you change the state of the ``RemoteModel``. See documentation for more 
info.


CAE-827 [Web] Add interfaceName to cee.ug.SimulationInfo
========================================================

Added the name of the interface/reader/data provider that is currently in use for the RemoteModel in 
``cee.ug.SimulationInfo.interfaceName``


CAE-760 [Web] Create new markup part for lines
==============================================

Added new Markup Part ``cee.mrk.PartLines``. This is a part that can show lines in a MarkupModel. Added 
``cee.utils.PathGenerator`` which is a helper class to generate vertices for a path that can then be shown with the 
PartLines markup part.


CAE-740 Support for polyhedrons in Envision VTFx component
==========================================================

Polyhedrons are now fully supported in the VTFx export component. Added ``cee::vtfx::ElementBlock::addPolyhedronElements()`` 
for adding polyhedron elements to a VTFx block.


CAE-794 Add result unit information to VTFx export and Envision Desktop
=======================================================================

Added ``cee::ug::ResultInfo::setUnit()`` and ``unit()`` to Envision Desktop. This is already present in Envision Web. 

Added ``cee::vtfx::ResultBlock::setUnit()`` and ``unit()`` to Envision VTFx component.


CAE-836 Add robustness for empty DataPartVector/DataPartScalar
==============================================================

Envision now handles parts with no result a bit more robust, as it is now allowed to have part objects with no 
results and not only ``nullptr`` in the part array.



------------------------------------------------

*******
Changes
*******

Rename Ceetron Cloud Components (C3) to CEETRON Envision for Web
================================================================

The product Ceetron Cloud Components (C3) has been renamed to CEETRON Envision for Web. The product is almost identical 
and has the same features, with the change of the license system being the most notable change (see below). There are 
also some changes to the organization of the distribution archive, where the servers are now grouped into the server 
folder, and the CeeCloudServer is now in the ``server/ugServer`` folder.

The product documentation is now also part of the Tech Soft 3D documentation system and can be found 
here: https://docs.techsoft3d.com/hoops/latest/envision-web/index.html 

.. note::
    The demo site running the docker versions of Envision Web can now be found on: https://envision.ceetron.com  
    (previously http://c3.ceetron.com).


Rename Ceetron Desktop Components to CEETRON Envision for Desktop
=================================================================

The product Ceetron Desktop Components (CDC) has been renamed to CEETRON Envision for Desktop. The product is almost 
identical and has the same features, with the change of the license system being the most notable change. (see below). 
Ceetron Python Modules [CPM] is now a part of the Envision Desktop distribution and no longer a separate product. See 
CAE-850 below for more info.

The product documentation is now also part of the Tech Soft 3D documentation system and can be found 
here: https://docs.techsoft3d.com/hoops/latest/envision-desktop/index.html. 


New unified documentation for all CEETRON products (including Envision Desktop and Web)
=======================================================================================

We have a new look and feel for the entire CAE product line at Tech Soft 3D. This is using the same system as for the 
new HOOPS documentation.

The main entry point is  https://docs.techsoft3d.com/hoops/index.html. Here you can find an overview of 
the entire CEETRON product line and browse or search for documentation for any of the products.


New unified HOOPS license system in Envision (Web and Desktop)
==============================================================

Envision (Web and Desktop) now uses the unified HOOPS license. The same license can be used across all CEETRON and 
HOOPS products, given that the license has the needed features enabled. This license key is a long string and it 
replaces the two keys (KeyA and KeyB) that were used in C3 and CDC.

For **CEETRON Envision Web**, the license can be specified with the ``ugServer.setLicenseCode(myCode)``. You can also 
copy your hoops_license.h (downloaded from the Developer Zone) into the same folder as the server code. For more help, 
please see the documentation here: https://docs.techsoft3d.com/hoops/latest/envision-web/license.html. 

For **CEETRON Envision Desktop**, you need to provide the string to ``cee::CoreComponent::initialize()``. One way to do 
this is to use hoops_license.h (downloaded from the Developer Zone) as shown below: 

.. code-block:: cpp

    #include "hoops_license.h"
    ...
    // Initialize the parts of Envision Desktop that we'll use.
    g_componentInstance = cee::CoreComponent::initialize(HOOPS_LICENSE);

For more information, please see the documentation:
https://docs.techsoft3d.com/hoops/latest/envision-desktop/topics/general/license-system.html.


Changes to versioning
=====================

Envision Desktop and Web will follow the same version numbers and starts at 1.0. We will strictly follow 
Semantic Versioning (`Semantic Versioning 2.0.0 <https://semver.org/>`_ ).

For Envision Desktop there have been some changes to the ``CeeCore/Version.h`` file with its macros:

====================    ============================
Old Define              New Define
====================    ============================
CEE_VERSION             CEE_VERSION_NUMERIC
CEE_MAJOR_VERSION       CEE_VERSION_MAJOR
CEE_MINOR_VERSION       CEE_VERSION_MINOR
CEE_PATCH_VERSION       CEE_VERSION_PATCH
CEE_SPECIAL_BUILD       CEE_VERSION_PRE_RELEASE
====================    ============================

.. note::
    The ``CEE_VERSION_STRING`` is now: ``“MAJOR.MINOR.PATCH"`` (for pre-releases: ``“MAJOR.MINOR.PATCH-PRE_RELEASE"``). 
    Examples: ``1.2.3`` or ``1.4.0-RC1``

The is a new method in CoreComponent to get the full version with the build SHA:

``CoreComponent::versionStringWithBuildSha()`` Returns full version number. Examples: ``1.2.1+e73b7a84`` or ``1.2.0-rc1+e73b7a84``.

There is now a ``VersionInfo.json`` file in the root folder of both Desktop and Web distributions detailing the version 
info of the distribution:

**Web**

::

    {
        "productName": "Ceetron Envision Web",
        "major": 1,
        "minor": 0,
        "patch": 0,
        "preRelease": "",
        "buildSha": "39e4a5d5",
        "version": "1.0.0",
        "versionWithBuildSha": "1.0.0+39e4a5d5",
        "cugDataFormatVersion": 2
    }
 

**Desktop**

:: 

    {
        "productName": "Ceetron Envision Desktop",
        "major": 1,
        "minor": 0,
        "patch": 0,
        "preRelease": "",
        "buildSha": "39e4a5d5",
        "version": "1.0.0",
        "versionWithBuildSha": "1.0.0+39e4a5d5",
        "dataProviderFramework": "7.0",
        "resultCalculatorFramework": "4.0"
    }


Changes to environment variables
================================

Most environment variables have changed from C3_* to CEW_*. 

================================    ================================
Old environment variable name       New environment variable name
================================    ================================
C3_UG_PORT                          CEW_UG_PORT
C3_UG_USE_HTTPS                     CEW_UG_USE_HTTPS
C3_UG_MODEL_PATH                    CEW_UG_MODEL_PATH
C3_UG_ENABLE_REST_API_UPLOAD        CEW_UG_ENABLE_REST_API_UPLOAD
C3_UG_ENABLE_REST_API_QUERY         CEW_UG_ENABLE_REST_API_QUERY
C3_UG_ENABLE_CORS                   CEW_UG_ENABLE_CORS
C3_UG_DATA_PROVIDER_FOLDER          CEW_UG_DATA_PROVIDER_FOLDER
C3_UG_RESULT_CALCULATOR_FOLDER      CEW_UG_RESULT_CALCULATOR_FOLDER
C3_UG_ADD_ON_FULL_FILENAME          CEW_UG_ADD_ON_FULL_FILENAME
C3_UG_DISABLE_IMPORT_CAE            CEW_UG_DISABLE_IMPORT_CAE
C3_UG_LOG_CONSOLE_OUTPUT_TYPE       CEW_UG_LOG_CONSOLE_OUTPUT_TYPE
C3_UG_LOG_FILE_OUTPUT_TYPE          CEW_UG_LOG_FILE_OUTPUT_TYPE
C3_UG_LOG_FILENAME                  CEW_UG_LOG_FILENAME
C3_UG_LOG_LEVEL                     CEW_UG_LOG_LEVEL

C3_CUGS_PORT                        CEW_CUGS_PORT
C3_CUGS_FILE_DS_PATH                CEW_CUGS_FILE_DS_PATH
C3_CUGS_LOG_CONSOLE_OUTPUT_TYPE     CEW_CUGS_LOG_CONSOLE_OUTPUT_TYPE
C3_CUGS_LOG_FILE_OUTPUT_TYPE        CEW_CUGS_LOG_FILE_OUTPUT_TYPE
C3_CUGS_LOG_FILENAME                CEW_CUGS_LOG_FILENAME
C3_CUGS_LOG_LEVEL                   CEW_CUGS_LOG_LEVEL

C3_GS_PORT                          CEW_GS_PORT
C3_GS_USE_HTTPS                     CEW_GS_USE_HTTPS
C3_GS_REDIS_DS_HOST                 CEW_GS_REDIS_DS_HOST
C3_GS_FILE_DS_PATH                  CEW_GS_FILE_DS_PATH
C3_GS_LOCAL_FILE_SOURCE_PATH        CEW_GS_LOCAL_FILE_SOURCE_PATH
================================    ================================


------------------------------------------------

***********
Fixed Bugs
***********

CAE-831 Missing vector filtering "skip by" when mapped to iso/cut
=================================================================

Specifying a skip-by for drawing of vectors did not work as expected for isosurfaces, isovolumes and cutting planes.


CAE-826 Query of results from VTFx files which reference result values by ID did not work
=========================================================================================

Querying results from a model backed by a VTFx file did not work as expected if the result values were referenced by 
ID (not the recommended way to reference result values).


CAE-811 [Web] ug.QueryNodeInfo returned -1 for node id if displacements were enabled
====================================================================================

If a model were using displacements, the result returned from ``QueryNodeInfo`` would not contain the correct node ids.


CAE-801 [Web] VTFx properties did not apply info on visible sets and how to show them properly
==============================================================================================

Loading VTFx models with properties did not apply proper settings for visible sets.


CAE-762 Wrong visualization of mirrored parts on a cutting plane
================================================================

Cutting planes for mirrored parts did not render correctly.


