Loading...
Searching...
No Matches
Changelog for SDK 2021 (v.2.0.0)

This release includes major changes in the SDK, various new features, and fixes of known and reported issues.

Below is the list of the changes in SAMSON SDK per library and per class.

One of the major changes visible to users is the introduction of Presentations and Animations. This includes new node types: SBAnimation, SBPresentation. Other new node types: SBPseudoBond, SBHydrogenBondGroup, SBHydrogenBond.

Core library group

Class

SBClass

New types

SBProxy

New functions that can be used via class proxies: SBProxy::getShortcut, SBProxy::getToolTip, SBProxy::getPublicName, SBProxy::getIconFileName, SBProxy::getMinimumUserPlan

Container

Performance and other various improvements in the following classes: SBCContainerBuffer (SBBuffer), SBCContainerHashMap (SBHashMap), SBCContainerIndexer (SBIndexer), SBCContainerList (SBList), SBCContainerVector (SBVector)

A new class describing the user plan: SBCContainerUserPlan (SBUserPlan)

Signal

Internal performance improvements of the signal management.

DataModel library group

Color library

Small changes in SBDColorPalette base and child classes: virtual and static functions.

DataGraph library

A new class: SBNodeSelector. This class describes and implements selectors that might be used accross SAMSON and in SAMSON Extensions. It is used, for example, in visual presets.

SBNode

Major changes that might affect other classes that are based on SBNode :

Functions SBDDataGraphNode::getNodes(SBNodeIndexer& nodeIndexer, const SBNodePredicate& selectionPredicate, const SBNodePredicate& visitPredicate, bool includeDependencies) and SBDDataGraphNode::countNodes(const SBNodePredicate& selectionPredicate, const SBNodePredicate& visitPredicate, bool includeDependencies) are now const. If you have implemented a class based on the SBNode class and overridden one of those functions, you need to add the const specifier.

New functions that might need to be implemented by a class based on SBNode :

  • SBDDataGraphNode::canHaveDescendantType(SBDDataGraphNode::Type). It returns whether this node can have a node with given type as a descendant.
  • new versions of the above mentioned functions that improve performance for special but very frequent cases when getting just nodes of a single node type (with no other predicates): SBDDataGraphNode::getNodes(SBNodeIndexer& nodeIndexer, SBDDataGraphNode::Type nodeType, bool selectedNodesOnly, const SBNodePredicate& visitPredicate, bool includeDependencies), SBDDataGraphNode::countNodes(SBNodeIndexer& nodeIndexer, SBDDataGraphNode::Type nodeType, bool selectedNodesOnly, const SBNodePredicate& visitPredicate, bool includeDependencies). So if you used a functions
    SBNodeIndexer nodeIndexer;
    node->getNodes(nodeIndexer, SBNode::IsType(SBNode::Atom));
    This node predicate compares the node type with a given type.
    Definition: SBDDataGraphNode.hpp:512
    @ Atom
    Atom.
    Definition: SBDDataGraphNode.hpp:67
    This class describes a node indexer.
    Definition: SBDDataGraphNodeIndexer.hpp:21
    void getNodes(SBDDataGraphNodeIndexer &nodeIndexer, const SBNodePredicate &selectionPredicate=SBNodePredicateTrue(), const SBNodePredicate &visitPredicate=SBNodePredicateTrue(), bool includeDependencies=false) const
    Collects nodes into nodeIndexer, based on a selectionPredicate and a visitPredicate,...
    Definition: SBDDataGraphNodeIndexer.cpp:31
    Now, you can use the new functions that improve performance when using a single SBNode::IsType predicate as follows:
    SBNodeIndexer nodeIndexer;
    node->getNodes(nodeIndexer, SBNode::Atom);

These changes affect the following classes:

New node types: SBNode::Animation, SBNode::Presentation, SBNode::PseudoBond, SBNode::HydrogenBondGroup, SBNode::HydrogenBond.

Now nodes in the data graph can be locked to prevent operations with them, e.g. when performing a simulation. New functions: SBNode::isLocked, SBNode::getLockedFlag, SBNode::setLockedFlag, and associated predicates SBDDataGraphNode::IsLocked, SBDDataGraphNode::GetLockedFlag

Now nodes can have transparency/opacity and inherited transparency. There is a set of associated functions, e.g.: SBNode::getTransparency, SBNode::setTransparency, SBNode::getInheritedTransparency.

A new rendering pass for nodes: SBNode::RenderingPass::Setup.

SBBaseEvent

New events: SBBaseEvent::LockedFlagChanged, SBBaseEvent::TransparencyChanged

SBNodeIndexer

SBNodeIndexer now has copy and move assignment operators.

Document library

New classes: SBAnimation, SBPresentation.

SBDocument

New functions:

SBFolder

Changes due to changes in SBNode, see changes in SBNode.

New functions: SBFolder::getAnimationList, SBFolder::getPresentationList

SBDocumentEvent

New document events:

Quantity library

SBDQuantityType

New constructors, add serialization.

Type library

New classes: SBCubicPolynomial, SBEasingCurve.

New copy and move constructors and operators for some existing types.

SBDTypeColor

Changes in serialization. New default colors used in the interface, e.g. colors of axes.

SBVector3

New functions:

SBSpatialTransform

A new function: SBSpatialTransform::fromAlignment that returns the best possible transform between the two given position vectors.

Visualization library

A new library that introduces the following classes that describe visual presets: SBVisualPreset, SBVisualPresetGroup.

Facade library group

New functions:

Changes in functions:

GUI library group

DataGraph library

New functions:

Editor library

A new rendering pass for editors: SBGEditor::RenderingPass::Setup.

A new function: SBGEditor::isSelectionDependent - returns true when the node's context menu actions depend on the current selection

Window library

New functions:

  • SBGWindowDialog::informUser(const QString& dialogTitle, const QString& labelText, const QString& text, bool monospaceFont), SAMSON::informUser(QWidget*)
  • SBGWindowDialog::askUser(const QString& dialogTitle, const QString& labelText, const QString& text, bool monospaceFont, QDialogButtonBox* buttonBox)
  • SBGWindowDialog::getColorSchemeFromUser

Modeling library group

Changes accross various classes of this library due to changes in SBNode, see changes in SBNode.

StructuralModel library

New classes: SBPseudoBond, SBHydrogenBondGroup, SBHydrogenBond

SBStructuralEvent

New events associated with new structural node types.

SBStructuralModel

New utility functions:

SBStructuralModelGrid

Performance improvements: changes from SBIndexer to SBVector when storing neighbor vectors.

Changed functions:

  • getNeighbors
  • getNeighborVector

New functions:

  • SBMStructuralModelGrid::areNeighbors(unsigned int i, unsigned int j), SBMStructuralModelGrid::areNeighbors(SBStructuralParticle*, SBStructuralParticle*)

SBAtom

New functions:

New predicates associated with the new functions:

  • SBAtom::GetNumberOfBondedAtoms, SBAtom::GetNumberOfBondedHeavyAtoms, SBAtom::GetNumberOfBondedCarbons, SBAtom::GetNumberOfBondedHydrogens, SBAtom::GetNumberOfBondedOxygens, SBAtom::GetNumberOfBondedNitrogens, SBAtom::GetNumberOfBondedSulfurs
  • SBAtom::IsPlanar

SBBackbone

New functions for nucleic acid topology:

SBStructuralGroup

New functions:

SBResidue

Changed function names:

New functions for nucleic acid geometry:

New predicates associated with dissociation constants (pKa1, pKa2, pI):

  • SBResidue::HasDissociationConstant, SBResidue::GetDissociationConstant1, SBResidue::GetDissociationConstant2, SBResidue::GetIsoelectricPointPH

VisualModel library

New class: SBTexture

SBMesh

Changed functions: SBMesh::getSurfaceIndexer

SBSurface

New functions using SBTexture: SBSurface::getDiffuseTexture, SBSurface::setDiffuseTexture

Simulation library group

Changes due to changes in SBNode, see changes in SBNode.

NeighborSearch library

Performance improvements: changes from SBIndexer to SBVector when storing neighbor vectors.

SBNeighborSearchParticleSystem

Changed functions:

  • SBSNeighborSearchParticleSystem::getNeighborVector
  • getNeighbors

New functions:

  • SBSNeighborSearchParticleSystem::areNeighbors(unsigned int, unsigned int), SSBNeighborSearchParticleSystem::areNeighbors(SBStructuralParticle*, SBStructuralParticle*)

SBNeighborSearchParticleSystemPBC

Changed functions:

  • SBSNeighborSearchParticleSystemPBC::getNeighborVector
  • getNeighbors

SBNeighborSearchParticleSystemGrid

Changed functions:

  • getNeighbors

New functions:

  • SBSNeighborSearchParticleSystemGrid::areNeighbors(unsigned int, unsigned int), SBSNeighborSearchParticleSystemGrid::areNeighbors(SBStructuralParticle*, SBStructuralParticle*)

SBNeighborSearchParticleSystemGridPBC

Changed functions:

  • getNeighbors

SBPositionGrid

Changed functions:

New functions: