SMTK  @SMTK_VERSION@
Simulation Modeling Tool Kit
Classes | Typedefs | Enumerations | Functions | Variables
smtk::model Namespace Reference

Represent geometric and topological models of simulation domains. More...

Classes

class  AddAuxiliaryGeometry
 
class  AddImage
 
class  Arrangement
 Store an arrangement of solid model entities. More...
 
class  ArrangementHelper
 Superclass for session-specific updates to arrangments of entities. More...
 
class  ArrangementReference
 A simple structure that robustly references an arrangement. More...
 
class  AssignColors
 
class  AttributeAssignments
 Store a list of attributes assigned to solid model entities. More...
 
class  AuxiliaryGeometry
 An EntityRef subclass for representing unmodeled geometry to be included in a scene. More...
 
class  AuxiliaryGeometryExtension
 A base class for extensions that provide methods to tessellate or mesh auxiliary geometry entities. More...
 
class  CellEntity
 A entityref subclass with methods specific to cell entities. More...
 
class  Chain
 A entityref subclass with methods specific to vertex-chains. More...
 
class  CloseModel
 
class  CompositeAuxiliaryGeometry
 
class  CreateInstances
 
class  DefaultSession
 A session that does no transcription. More...
 
class  Delete
 Delete an entity from a model resource. More...
 
class  DivideInstance
 
class  Edge
 A entityref subclass that provides methods specific to 1-d edge cells. More...
 
class  EdgeUse
 A entityref subclass that provides methods specific to 1-d edge cells. More...
 
class  Entity
 A solid model entity, defined by a type and relations to other entities. More...
 
class  EntityGroupOperation
 Create, desctory or modify a model entity group. More...
 
class  EntityIterator
 
class  EntityRef
 A lightweight entityref pointing to a model entity's resource. More...
 
class  EntityRefArrangementOps
 A class to help obtain entityrefs from arrangement information. More...
 
class  ExportEdgesToVTK
 
class  ExportModelJSON
 
class  Face
 A entityref subclass that provides methods specific to 2-d face cells. More...
 
class  FaceUse
 A entityref subclass that provides methods specific to 0-d vertex cells. More...
 
struct  FilterAction
 Actions on the state in response to encountered grammar. More...
 
struct  FilterAction< float_property_name >
 
struct  FilterAction< float_property_value >
 
struct  FilterAction< int_property_name >
 
struct  FilterAction< int_property_value >
 
struct  FilterAction< name_property_regex_value >
 
struct  FilterAction< name_property_value >
 
struct  FilterAction< string_property_name >
 
struct  FilterAction< string_property_regex_value >
 
struct  FilterAction< string_property_value >
 
struct  FilterGrammar
 The filter grammar is a composition of the grammar for each property type. More...
 
struct  grammar_for
 With the differences between the property types factored out into the above traits class, we can now construct a general description for the grammar for each property type. More...
 
class  GridInfo
 
class  Group
 A entityref subclass that provides methods specific to entity use records. More...
 
class  GroupAuxiliaryGeometry
 
class  Instance
 A entityref subclass that provides methods specific to entity use records. More...
 
struct  LimitingClause
 ! More...
 
class  Loop
 A entityref subclass with methods specific to edge-loops. More...
 
class  MergeInstances
 
class  Model
 A entityref subclass that provides methods specific to models. More...
 
class  PointLocatorExtension
 A base class for extensions that provide point-locators for finding nearest points on tessellations of model entities. More...
 
struct  property_traits
 We use a traits class to describe analogous features between the different property types. More...
 
struct  property_traits< float_property >
 
struct  property_traits< int_property >
 
struct  property_traits< string_property >
 
class  Registrar
 
class  Resource
 Store information about solid models. More...
 
struct  SelectionFootprint
 Identify model components highlighted to display a selection. More...
 
class  Session
 A base class for bridging modelers into SMTK. More...
 
class  SessionIO
 A base class for delegating session I/O. More...
 
class  SessionIOJSON
 A base class for delegating session I/O to/from JSON. More...
 
class  SessionRef
 A entityref subclass that provides methods specific to entity use records. More...
 
class  SetInstancePrototype
 
class  Shell
 A entityref subclass with methods specific to face-shells. More...
 
class  ShellEntity
 A entityref subclass with methods specific to shell entities. More...
 
class  TerrainExtraction
 
class  Tessellation
 Store geometric information related to model entities. More...
 
struct  URLDisposition
 
class  UseEntity
 A entityref subclass that provides methods specific to entity-use records. More...
 
class  Vertex
 A entityref subclass that provides methods specific to 0-d vertex cells. More...
 
class  VertexUse
 A entityref subclass that provides methods specific to 0-d vertex cells. More...
 
class  Volume
 A entityref subclass that provides methods specific to 3-d volume cells. More...
 
class  VolumeUse
 A entityref subclass that provides methods specific to 0-d vertex cells. More...
 

Typedefs

typedef std::vector< smtk::model::ArrangementReferenceArrangementReferences
 An array of ArrangementReference objects used, for instance, to enumerate inverse relations. More...
 
typedef std::vector< smtk::model::ArrangementArrangements
 A vector of Arrangements is associated to each Manager entity. More...
 
typedef std::vector< smtk::model::AuxiliaryGeometryAuxiliaryGeometries
 
typedef std::vector< smtk::model::SessionRefSessionRefs
 
typedef std::vector< smtk::model::CellEntityCells
 
typedef std::set< smtk::model::CellEntityCellSet
 
typedef std::vector< smtk::model::ChainChains
 
typedef std::set< smtk::model::EntityRefEntityRefs
 
typedef std::vector< smtk::model::EntityRefEntityRefArray
 
typedef std::vector< smtk::model::EdgeEdges
 
typedef std::set< smtk::model::EdgeEdgeSet
 
typedef std::vector< smtk::model::EdgeUseEdgeUses
 
typedef std::vector< smtk::model::FaceFaces
 
typedef std::set< smtk::model::FaceFaceSet
 
typedef std::vector< smtk::model::FaceUseFaceUses
 
typedef std::vector< smtk::model::InstanceInstances
 
typedef std::set< smtk::model::InstanceInstanceSet
 
typedef std::vector< smtk::model::LoopLoops
 
typedef std::vector< smtk::model::ModelModels
 
typedef std::vector< smtk::model::ShellShells
 
typedef std::vector< smtk::model::ShellEntityShellEntities
 
typedef std::vector< smtk::model::UseEntityUseEntities
 
typedef std::vector< smtk::model::VertexVertices
 
typedef std::set< smtk::model::VertexVertexSet
 
typedef std::vector< smtk::model::VertexUseVertexUses
 
typedef std::vector< smtk::model::VolumeVolumes
 
typedef std::vector< smtk::model::VolumeUseVolumeUses
 
typedef smtk::shared_ptr< smtk::model::SessionSessionPtr
 
typedef smtk::weak_ptr< smtk::model::SessionWeakSessionPtr
 
typedef std::map< smtk::common::UUID, smtk::shared_ptr< smtk::model::Session > > UUIDsToSessions
 
typedef smtk::shared_ptr< smtk::model::DefaultSessionDefaultSessionPtr
 
typedef smtk::shared_ptr< smtk::model::SessionIOSessionIOPtr
 
typedef smtk::shared_ptr< smtk::model::SessionIOJSONSessionIOJSONPtr
 
typedef smtk::shared_ptr< smtk::model::ResourceResourcePtr
 
typedef smtk::weak_ptr< smtk::model::ResourceWeakResourcePtr
 
typedef smtk::shared_ptr< smtk::model::EntityEntityPtr
 
typedef smtk::weak_ptr< smtk::model::EntityWeakEntityPtr
 
typedef std::vector< smtk::model::EntityPtrEntityArray
 
typedef smtk::shared_ptr< smtk::model::ArrangementArrangementPtr
 
typedef smtk::weak_ptr< smtk::model::ArrangementWeakArrangementPtr
 
typedef smtk::shared_ptr< smtk::model::TessellationTessellationPtr
 
typedef smtk::weak_ptr< smtk::model::TessellationWeakTessellationPtr
 
typedef smtk::shared_ptr< smtk::model::GridInfoGridInfoPtr
 
typedef std::map< ArrangementKind, ArrangementsKindsToArrangements
 A map holding Arrangements of different ArrangementKinds.
 
typedef std::map< smtk::common::UUID, KindsToArrangementsUUIDsToArrangements
 Each Manager entity's UUID is mapped to a vector of Arrangment instances.
 
typedef std::map< smtk::common::UUID, KindsToArrangements >::iterator UUIDWithArrangementDictionary
 An iterator referencing a (UUID,KindsToArrangements)-tuple.
 
typedef std::map< ArrangementKind, Arrangements >::iterator ArrangementKindWithArrangements
 An iterator referencing an (ArrangementKind,Arrangements)-tuple.
 
typedef std::map< smtk::common::UUID, AttributeAssignmentsUUIDsToAttributeAssignments
 Each Manager entity's UUID is mapped to a set of assigned attribute IDs.
 
typedef std::map< smtk::common::UUID, AttributeAssignments >::iterator UUIDWithAttributeAssignments
 An iterator referencing a (UUID,AttributeAssignments)-tuple.
 
typedef std::vector< CellEntityCellEntities
 
typedef std::pair< smtk::common::UUID, EntityUUIDEntityPair
 An abbreviation for the record type used by maps of Entity records.
 
typedef std::vector< GroupGroups
 
typedef unsigned int BitFlags
 The integer type used to hold bit values describing an entity's type.
 
typedef std::pair< ResourceEventChangeType, ResourceEventRelationTypeResourceEventType
 A notification of a model resource event. More...
 
typedef int(* ConditionCallback) (ResourceEventType, const smtk::model::EntityRef &, void *)
 Callbacks for changes in the condition of an entity. WARNING: Likely to change in future releases.
 
typedef std::pair< ConditionCallback, void * > ConditionObserver
 An observer of an entity-condition-change (i.e., addition, update or removal) event.
 
typedef std::pair< ResourceEventType, ConditionObserverConditionTrigger
 A trigger entry for an event-observer pair.
 
typedef int(* OneToOneCallback) (ResourceEventType, const smtk::model::EntityRef &, const smtk::model::EntityRef &, void *)
 Callbacks for one-to-one relationships between entities. WARNING: Likely to change in future releases.
 
typedef std::pair< OneToOneCallback, void * > OneToOneObserver
 An observer of a one-to-one relationship-event.
 
typedef std::pair< ResourceEventType, OneToOneObserverOneToOneTrigger
 A trigger entry for an event-observer pair.
 
typedef int(* OneToManyCallback) (ResourceEventType, const smtk::model::EntityRef &, const smtk::model::EntityRefArray &, void *)
 Callbacks for one-to-many relationships between entities. WARNING: Likely to change in future releases.
 
typedef std::pair< OneToManyCallback, void * > OneToManyObserver
 An observer of a one-to-many relationship-event.
 
typedef std::pair< ResourceEventType, OneToManyObserverOneToManyTrigger
 A trigger entry for an event-observer pair.
 
typedef double Float
 
typedef std::vector< Float > FloatList
 
typedef std::map< std::string, FloatList > FloatData
 
typedef std::map< smtk::common::UUID, FloatData > UUIDsToFloatData
 
typedef UUIDsToFloatData::iterator UUIDWithFloatProperties
 
typedef FloatData::iterator PropertyNameWithFloats
 
typedef FloatData::const_iterator PropertyNameWithConstFloats
 
typedef std::vector< InstanceInstanceEntities
 
typedef long Integer
 
typedef std::vector< long > IntegerList
 
typedef std::map< std::string, IntegerList > IntegerData
 
typedef std::map< smtk::common::UUID, IntegerData > UUIDsToIntegerData
 
typedef UUIDsToIntegerData::iterator UUIDWithIntegerProperties
 
typedef IntegerData::iterator PropertyNameWithIntegers
 
typedef IntegerData::const_iterator PropertyNameWithConstIntegers
 
typedef std::map< smtk::common::UUID, EntityPtrUUIDsToEntities
 Store information mapping IDs to Entity records. This is the primary storage for SMTK models.
 
typedef UUIDsToEntities::iterator UUIDWithEntityPtr
 An abbreviation for an iterator into primary model storage.
 
typedef UUIDsToEntities::const_iterator UUIDWithConstEntityPtr
 
typedef unsigned long SessionInfoBits
 Bit-vector combinations of SessionInformation values for requesting information to transcribe.
 
typedef std::map< smtk::model::EntityRef, SessionInfoBitsDanglingEntities
 
typedef std::string String
 Use std::string for holding string values.
 
typedef std::vector< StringStringList
 Use vectors of String objects for holding string properties on model entities.
 
typedef std::map< std::string, StringListStringData
 A dictionary of property names mapped to their values (string vectors)
 
typedef std::map< smtk::common::UUID, StringDataUUIDsToStringData
 A dictionary of model entities mapped to all the string properties defined on them.
 
typedef UUIDsToStringData::iterator UUIDWithStringProperties
 A convenient typedef that describes how an iterator to model-entity string properties is used.
 
typedef StringData::iterator PropertyNameWithStrings
 A convenient typedef that describes how the iterator to one string property is used.
 
typedef StringData::const_iterator PropertyNameWithConstStrings
 A convenient typedef that describes how the const_iterator to one string property is used.
 
typedef std::map< smtk::common::UUID, TessellationUUIDsToTessellations
 
typedef std::map< smtk::common::UUID, Tessellation >::iterator UUIDWithTessellation
 
typedef std::vector< std::pair< double, const smtk::attribute::Attribute *const > > Weights
 Weights are a vector of distances and associated attributes. More...
 

Enumerations

enum  Orientation { NEGATIVE = -1, POSITIVE = +1, UNDEFINED = 0 }
 Constants that describe a cell-use's orientation relative to its parent cell. More...
 
enum  ArrangementKind {
  INCLUDES, HAS_CELL, HAS_SHELL, HAS_USE,
  EMBEDDED_IN, SUBSET_OF, SUPERSET_OF, INSTANCE_OF,
  INSTANCED_BY, KINDS_OF_ARRANGEMENTS
}
 Specification of how a cell's relations are arranged. More...
 
enum  IteratorStyle { ITERATE_BARE = 0, ITERATE_CHILDREN = 1, ITERATE_MODELS }
 Indicate what records should be visited. More...
 
enum  Exclusions { Nothing = 0, Rendering = (1 << 1), ViewPresentation = (1 << 2), Everything = (1 << 3) - 1 }
 Indicate an entity is excluded from which parts in smtk. More...
 
enum  EntityTypeBits : BitFlags {
  DIMENSION_0 = 0x00000001, DIMENSION_1 = 0x00000002, DIMENSION_2 = 0x00000004, DIMENSION_3 = 0x00000008,
  DIMENSION_4 = 0x00000010, CELL_ENTITY = 0x00000100, USE_ENTITY = 0x00000200, SHELL_ENTITY = 0x00000400,
  GROUP_ENTITY = 0x00000800, MODEL_ENTITY = 0x00001000, INSTANCE_ENTITY = 0x00002000, SESSION = 0x00004000,
  AUX_GEOM_ENTITY = 0x00008000, CONCEPT_ENTITY = 0x00010000, SURFACE_ENTITY = 0x00020000, COVER = 0x00100000,
  PARTITION = 0x00200000, OPEN = 0x00400000, CLOSED = 0x00800000, MODEL_BOUNDARY = 0x01000000,
  MODEL_DOMAIN = 0x02000000, HOMOGENOUS_GROUP = 0x04000000, NO_SUBGROUPS = 0x08000000, ANY_DIMENSION = 0x000000ff,
  ENTITY_MASK = 0x0001ff00, ANY_ENTITY = 0x0001ffff, VERTEX = 0x00000101, EDGE = 0x00000102,
  FACE = 0x00000104, VOLUME = 0x00000108, CELL_0D = 0x00000101, CELL_1D = 0x00000102,
  CELL_2D = 0x00000104, CELL_3D = 0x00000108, ANY_CELL = 0x000001ff, VERTEX_USE = 0x00000201,
  EDGE_USE = 0x00000202, FACE_USE = 0x00000204, VOLUME_USE = 0x00000208, USE_0D = 0x00000201,
  USE_1D = 0x00000202, USE_2D = 0x00000204, USE_3D = 0x00000208, ANY_USE = 0x000002ff,
  CHAIN = 0x00000403, LOOP = 0x00000406, SHELL = 0x0000040c, SHELL_0D = 0x00000403,
  SHELL_1D = 0x00000406, SHELL_2D = 0x0000040c, ANY_SHELL = 0x000004ff, GROUP_0D = 0x00000801,
  GROUP_1D = 0x00000802, GROUP_2D = 0x00000804, GROUP_3D = 0x00000808, ANY_GROUP = 0x000008ff,
  BOUNDARY_GROUP = 0x01600800, DOMAIN_GROUP = 0x02600800, GROUP_CONSTRAINT_MASK = 0x0ff00000, HALF_OPEN = 0x00c00000,
  HALF_CLOSED = 0x00c00000, NOTHING = 0x00000000, INVALID = 0xffffffff
}
 Different types of entities the model can hold and their inherent properties. More...
 
enum  ModelGeometryStyle { DISCRETE, PARAMETRIC }
 Enumerate how model domains are represented. More...
 
enum  ResourceEventChangeType { ADD_EVENT, MOD_EVENT, DEL_EVENT, ANY_EVENT }
 Enumerate the types of changes a model resource undergoes. More...
 
enum  ResourceEventRelationType {
  ENTITY_ENTRY, TESSELLATION_ENTRY, ENTITY_HAS_PROPERTY, ENTITY_HAS_ATTRIBUTE,
  SESSION_INCLUDES_MODEL, MODEL_INCLUDES_FREE_CELL, MODEL_INCLUDES_FREE_USE, MODEL_INCLUDES_FREE_SHELL,
  MODEL_INCLUDES_FREE_AUX_GEOM, MODEL_INCLUDES_MODEL, MODEL_INCLUDES_GROUP, CELL_INCLUDES_CELL,
  CELL_HAS_USE, SHELL_HAS_USE, SHELL_INCLUDES_SHELL, GROUP_SUPERSET_OF_ENTITY,
  MODEL_SUPERSET_OF_MODEL, MODEL_SUPERSET_OF_GROUP, SESSION_SUPERSET_OF_MODEL, AUX_GEOM_INCLUDES_AUX_GEOM,
  INSTANCE_OF_ENTITY, INVALID_RELATIONSHIP
}
 Enumerate the types of relationships which may cause model resource events. More...
 
enum  SessionInformation {
  SESSION_ENTITY_TYPE = 0x00000001, SESSION_ENTITY_RELATIONS = 0x00000002, SESSION_ARRANGEMENTS = 0x00000004, SESSION_TESSELLATION = 0x00000008,
  SESSION_FLOAT_PROPERTIES = 0x00000010, SESSION_STRING_PROPERTIES = 0x00000020, SESSION_INTEGER_PROPERTIES = 0x00000040, SESSION_ATTRIBUTE_ASSOCIATIONS = 0x00000080,
  SESSION_USER_DEFINED_PROPERTIES, SESSION_NOTHING = 0x00000000, SESSION_ENTITY_RECORD = 0x00000003, SESSION_ENTITY_ARRANGED,
  SESSION_PROPERTIES = 0x00000070, SESSION_EVERYTHING = 0x000000ff, SESSION_EXHAUSTIVE
}
 Bit flags describing types of information sessiond to Resource. More...
 
enum  TessellationCellType {
  TESS_VERTEX = 0x0200, TESS_TRIANGLE = 0x0000, TESS_QUAD = 0x0001, TESS_POLYVERTEX,
  TESS_POLYLINE, TESS_POLYGON, TESS_TRIANGLE_STRIP, TESS_INVALID_CELL = 0x4000,
  TESS_VARYING_VERT_CELL, TESS_CELLTYPE_MASK = 0x7e01, TESS_FACE_MATERIAL, TESS_FACE_UV,
  TESS_FACE_VERTEX_UV, TESS_FACE_NORMAL, TESS_FACE_VERTEX_NORMAL, TESS_FACE_COLOR,
  TESS_FACE_VERTEX_COLOR, TESS_PROPERTY_MASK = 0x00fe
}
 Cell type information bit-vector constants. More...
 
enum  ModificationResolution {
  OVERWRITE, IGNORE, ABORT, MOVE,
  ASK
}
 

Functions

void collectVertices (EntityRef &model, vtkPoints *pts, std::map< EntityRef, vtkIdType > &pointMap)
 
void insertEdges (EntityRef &model, vtkPolyData *pdt, vtkPoints *pts, std::map< EntityRef, vtkIdType > &pointMap)
 
ArrangementKind ArrangementKindFromName (const std::string &name)
 
std::string NameForArrangementKind (ArrangementKind k)
 
ArrangementKind ArrangementKindFromAbbreviation (const std::string &abbr)
 
std::string AbbreviationForArrangementKind (ArrangementKind k)
 
ArrangementKind Dual (EntityTypeBits entType, ArrangementKind k)
 
template<EntityTypeBits B>
bool hasBit (BitFlags val)
 
BitFlags keywordToBitFlags (const std::string &keyword)
 
Entity::QueryFunctor limitedQueryFunctor (smtk::model::BitFlags bitFlags, LimitingClause &limitClause)
 
std::ostream & operator<< (std::ostream &os, const EntityRef &c)
 
std::size_t entityrefHash (const EntityRef &c)
 
bool isCellEntity (BitFlags entityFlags)
 
bool doesMaskAllowCellEntities (BitFlags entityFlags)
 
bool isVertex (BitFlags entityFlags)
 
bool doesMaskAllowVertexEntities (BitFlags entityFlags)
 
bool isEdge (BitFlags entityFlags)
 
bool doesMaskAllowEdgeEntities (BitFlags entityFlags)
 
bool isFace (BitFlags entityFlags)
 
bool doesMaskAllowFaceEntities (BitFlags entityFlags)
 
bool isVolume (BitFlags entityFlags)
 
bool doesMaskAllowVolumeEntities (BitFlags entityFlags)
 
bool isUseEntity (BitFlags entityFlags)
 
bool isVertexUse (BitFlags entityFlags)
 
bool isEdgeUse (BitFlags entityFlags)
 
bool isFaceUse (BitFlags entityFlags)
 
bool isVolumeUse (BitFlags entityFlags)
 
bool isShellEntity (BitFlags entityFlags)
 
bool isChain (BitFlags entityFlags)
 
bool isLoop (BitFlags entityFlags)
 
bool isShell (BitFlags entityFlags)
 
bool isGroup (BitFlags entityFlags)
 
bool isModel (BitFlags entityFlags)
 
bool doesMaskAllowModelEntities (BitFlags entityFlags)
 
bool isInstance (BitFlags entityFlags)
 
bool isAuxiliaryGeometry (BitFlags entityFlags)
 
bool isConcept (BitFlags entityFlags)
 
bool isSessionRef (BitFlags entityFlags)
 
std::string ModelGeometryStyleName (ModelGeometryStyle s)
 Given a ModelGeometryStyle, return a short string description.
 
ModelGeometryStyle NamedModelGeometryStyle (const std::string &s)
 Given a string name, return the matching ModelGeometryStyle.
 
std::vector< WeightscomputeWeights (const std::vector< double > &samplePoints, const smtk::attribute::DefinitionPtr &definition)
 Compute weights for a each sample point in <samplePoints> according to geometry associated with <definition>.
 
std::vector< double > inverseDistanceWeighting (const std::vector< Weights > &weightsForPoints, const std::string &itemName, const double &power)
 Use inverse distance weighting to interpolate values held by the double item named <itemName>.
 

Variables

const char * ArrangementKindName [KINDS_OF_ARRANGEMENTS+1]
 
const char * ArrangementKindAbbr [KINDS_OF_ARRANGEMENTS+1]
 

Detailed Description

Represent geometric and topological models of simulation domains.

The Manager class holds records defining one or more geometric- and/or topological-domain decompositions; it maps smtk::common::UUID values to Entity, Arrangement, and Tessellation instances. However, most developers will use the EntityRef classes (Vertex, Edge, Face, Volume, VertexUse, EdgeUse, FaceUse, VolumeUse, Chain, Loop, Shell, Group, Model, and Instance) to access this information. EntityRef is a base class for traversing records in Manager and provides some capability for modifying the model. Attributes may be defined on any record in storage by virtue of the fact that all records in storage are named by their UUID.

If built with VTK, several classes beginning with "vtk" are available for rendering and interacting with model entities which have tessellation information.

If built with Qt, the QEntityItemModel, QEntityItemDelegate, and QEntityItemEditor classes may be used to display model information as exposed by a hierarchy of DescriptivePhrase instances.

Typedef Documentation

◆ ArrangementPtr

◆ ArrangementReferences

An array of ArrangementReference objects used, for instance, to enumerate inverse relations.

See also
smtk::model::ArrangementReference

◆ Arrangements

typedef std::vector< Arrangement > smtk::model::Arrangements

A vector of Arrangements is associated to each Manager entity.

See also
smtk::model::Arrangement

◆ AuxiliaryGeometries

◆ Cells

◆ CellSet

◆ Chains

typedef std::vector< Chain > smtk::model::Chains

◆ DefaultSessionPtr

◆ Edges

typedef std::vector< Edge > smtk::model::Edges

◆ EdgeSet

◆ EdgeUses

typedef std::vector< EdgeUse > smtk::model::EdgeUses

◆ EntityArray

◆ EntityPtr

typedef std::shared_ptr< Entity > smtk::model::EntityPtr

◆ EntityRefArray

typedef std::vector< EntityRef > smtk::model::EntityRefArray

◆ EntityRefs

typedef std::set< EntityRef > smtk::model::EntityRefs

◆ Faces

typedef std::vector< Face > smtk::model::Faces

◆ FaceSet

◆ FaceUses

typedef std::vector< FaceUse > smtk::model::FaceUses

◆ GridInfoPtr

◆ Instances

◆ InstanceSet

◆ Loops

typedef std::vector< Loop > smtk::model::Loops

◆ Models

typedef std::vector< Model > smtk::model::Models

◆ ResourceEventType

A notification of a model resource event.

All events have both a change type and a relationship type.

◆ ResourcePtr

See also
smtk::model::EntityPhrase
smtk::model::EntityListPhrase
smtk::model::MeshPhrase
smtk::model::MeshListPhrase
smtk::model::PropertyValuePhrase
smtk::model::PropertyListPhrase
smtk::model::SimpleModelSubphrases
smtk::model::SubphraseGenerator
smtk::model::Resource

◆ SessionIOJSONPtr

◆ SessionIOPtr

◆ SessionPtr

typedef smtk::shared_ptr<smtk::model::Session> smtk::model::SessionPtr

◆ SessionRefs

typedef std::vector< SessionRef > smtk::model::SessionRefs

◆ ShellEntities

typedef std::vector< ShellEntity > smtk::model::ShellEntities

◆ Shells

typedef std::vector< Shell > smtk::model::Shells

◆ TessellationPtr

◆ UseEntities

typedef std::vector< UseEntity > smtk::model::UseEntities

◆ UUIDsToSessions

typedef std::map< smtk::common::UUID, smtk::shared_ptr< Session > > smtk::model::UUIDsToSessions

◆ VertexSet

◆ VertexUses

typedef std::vector< VertexUse > smtk::model::VertexUses

◆ Vertices

typedef std::vector< Vertex > smtk::model::Vertices

◆ Volumes

typedef std::vector< Volume > smtk::model::Volumes

◆ VolumeUses

typedef std::vector< VolumeUse > smtk::model::VolumeUses

◆ WeakArrangementPtr

◆ WeakEntityPtr

typedef std::weak_ptr< Entity > smtk::model::WeakEntityPtr

◆ WeakResourcePtr

◆ WeakSessionPtr

◆ WeakTessellationPtr

◆ Weights

typedef std::vector<std::pair<double, const smtk::attribute::Attribute* const> > smtk::model::Weights

Weights are a vector of distances and associated attributes.

The distances are unnormalized and have whatever units the coordinates have.

Enumeration Type Documentation

◆ ArrangementKind

Specification of how a cell's relations are arranged.

Enumerator
INCLUDES 

How another cell is contained in the interior of this cell.

HAS_CELL 

How a use or shell is related to its cell.

HAS_SHELL 

How this cell is bounded by cells of lower dimension or how a use participates in a shell.

HAS_USE 

How this cell's shells are combined into a single orientation for use by bordant cells.

EMBEDDED_IN 

How this cell is embedded in the interior of a cell of higher dimension.

SUBSET_OF 

This entity is a subset of the related entity.

SUPERSET_OF 

This entity is a superset of the related entity.

INSTANCE_OF 

This entity is an instance of the related entity.

INSTANCED_BY 

This entity has an instance (duplicate) that is the related entity.

KINDS_OF_ARRANGEMENTS 

The number of different kinds of arrangement relationships enumerated here.

◆ EntityTypeBits

Different types of entities the model can hold and their inherent properties.

This enum is used to specify entity types as well as masks for various operations on entities (e.g., determining suitability for group membership).

Entity types are stored as bit vectors (of type smtk::model::BitFlags) whose bits are values from this enumeration.

The lower 5 bits are reserved for entity dimensionality (DIMENSION_0 through DIMENSION_4). These do not refer to specific dimensions but rather indicate the number of dimensions required to parameterize the point locus of the entity. Shell entities have 2 dimension bits set: the dimension of their boundary and the dimension of the space they enclose. Groups use these bits to constrain membership. Instances need not have any of these bits set. All other entities should have exactly one of these bits set. (For models, this bit indicates the maximum parametric dimension of any entity contained in the model.)

The next 8 bits are reserved for entity types (currently only 6 are used). Every entity should have exactly one of these bits set, except group entities which may use the other bits to indicate constraints on membership.

The next 8 bits identify immutable properties of entities. COVER and PARTITION may be applied to group entities to indicate that they must form a (not necessarily disjoint) cover or (precisely disjoint) partition of the point-locus their top-level member describes. The COVER and PARTITION bits are mutually exclusive. A group with the COVER bit set may have subgroups that overlap. The union of the subgroups is the space covered. A group with the PARTITION bit set must have subgroups that do not overlap. The union of the subgroups is the space partitioned.

The OPEN and CLOSED bits indicate that the point-set of the designated aentities should be considered as OPEN (not containing its closure) or CLOSED (containing its closure). This is largely intended for marking groups to indicate that, for example, if a FaceEntity is in a CLOSED group then its bounding edges and vertices should also be considered members of the group. However, it may be used in the future to accommodate modeling kernels that represent point locii differently than SMTK by marking topological entities themselves (rather than groups).

The MODEL_DOMAIN and MODEL_BOUNDARY bits are intended to be set on groups to constrain their membership to items to the dimensionality of the model to which the group belongs.

The HOMOGENOUS_GROUP bit indicates that a group should contain entities of the same type.

Finally, because groups may have entity-type bits (e.g. CELL_ENTITY) other than GROUP_ENTITY set in order to constrain membership, this bit can be used to indicate whether or not the group may contain other groups.

Besides these bits, there are many enumerants that combine bits into meaningful specifications for entities: VERTEX (CELL_0D), EDGE (CELL_1D), FACE (CELL_2D), VOLUME (CELL_3D), VERTEX_USE (USE_0D), EDGE_USE (USE_1D), FACE_USE (USE_2D), USE_3D, CHAIN (SHELL_0D), LOOP (SHELL_0D), SHELL (SHELL_2D), GROUP_0D, GROUP_1D, GROUP_2D, GROUP_3D, BOUNDARY_GROUP, and DOMAIN_GROUP.

There are also enumerants meant to be used as masks to separate out bits into functional groups: ANY_DIMENSION, ENTITY_MASK, ANY_ENTITY, ANY_GROUP, ANY_SHELL, ANY_CELL, ANY_USE, and GROUP_CONSTRAINT_MASK.

Finally, the INVALID enumerant indicates that an entity does not exist or should be considered ill-posed.

Enumerator
DIMENSION_0 

The entity may include 0-dimensional components.

DIMENSION_1 

The entity may include 1-dimensional components.

DIMENSION_2 

The entity may include 2-dimensional components.

DIMENSION_3 

The entity may include 3-dimensional components.

DIMENSION_4 

The entity may include 4-dimensional components (where time is one dimension)

CELL_ENTITY 

A bit indicating the entity is a cell.

USE_ENTITY 

A bit indicating the entity is a shell (a GroupingEntity in CGM parlance)

SHELL_ENTITY 

A bit indicating the entity is a use (a SenseEntity in CGM parlance)

GROUP_ENTITY 

A bit indicating a group; UUIDs may only occur 0 or 1 times. A separate flag describes constraints on group members.

MODEL_ENTITY 

A bit indicating a (sub)model.

INSTANCE_ENTITY 

A bit indicating an instance of model.

SESSION 

A bit indicating a session.

AUX_GEOM_ENTITY 

A bit indicating auxiliary geometry (scene, preview, or construction) entity.

CONCEPT_ENTITY 

A bit indicating the entity is a conceptual entity (a class of objects that are abstract)

SURFACE_ENTITY 

An algebraically-modeled geometric point locus.

COVER 

The entity must have a relation indicating which cover(s) it participates in.

PARTITION 

The entity must have a relation indicating which partition(s) it participates in.

OPEN 

A bit indicating that the entity should be regarded as an open set (esp. groups)

CLOSED 

A bit indicating that the entity should be regarded as a closed set (esp. groups)

MODEL_BOUNDARY 

The entity is part of a boundary (esp. partition groups, indicating boundary conditions)

MODEL_DOMAIN 

The entity is part of the model domain (esp. groups)

HOMOGENOUS_GROUP 

The group must contain entities of the same type (except that subgroups are allowed).

NO_SUBGROUPS 

The group is not allowed to contain other groups if this flag is set.

ANY_DIMENSION 

Mask to extract the dimensionality of an entity.

ENTITY_MASK 

Mask to extract the type of an entity. Exactly one bit should be set for any valid entity.

ANY_ENTITY 

Mask to extract the type and dimension of an entity.

VERTEX 

A cell of dimension 0 (i.e., a vertex)

EDGE 

A cell of dimension 1 (i.e., an edge)

FACE 

A cell of dimension 2 (i.e., a face)

VOLUME 

A cell of dimension 3 (i.e., a volume)

CELL_0D 

A cell of dimension 0 (i.e., a vertex)

CELL_1D 

A cell of dimension 1 (i.e., an edge)

CELL_2D 

A cell of dimension 2 (i.e., a face)

CELL_3D 

A cell of dimension 3 (i.e., a volume)

ANY_CELL 

A cell of any dimension.

VERTEX_USE 

A cell-use of dimension 0 (i.e., a vertex use)

EDGE_USE 

A cell-use of dimension 1 (i.e., an edge use)

FACE_USE 

A cell-use of dimension 2 (i.e., a face use)

VOLUME_USE 

A cell-use of dimension 3 (i.e., a volume use)

USE_0D 

A cell-use of dimension 0 (i.e., a vertex use)

USE_1D 

A cell-use of dimension 1 (i.e., an edge use)

USE_2D 

A cell-use of dimension 2 (i.e., a face use)

USE_3D 

A cell-use of dimension 3 (i.e., a volume use)

ANY_USE 

A cell-use of any dimension.

CHAIN 

A shell of dimension 0+1 (i.e., a vertex chain)

LOOP 

A shell of dimension 1+2 (i.e., an edge loop)

SHELL 

A shell of dimension 2+3 (i.e., a face shell)

SHELL_0D 

A shell of dimension 0+1 (i.e., a vertex chain)

SHELL_1D 

A shell of dimension 1+2 (i.e., an edge lop)

SHELL_2D 

A shell of dimension 2+3 (i.e., a face shell)

ANY_SHELL 

A shell of any dimension.

GROUP_0D 

A group of cells of dimension 0 (which may include other groups of dimension 0)

GROUP_1D 

A group of cells of dimension 1 (which may include other groups of dimension 1)

GROUP_2D 

A group of cells of dimension 2 (which may include other groups of dimension 2)

GROUP_3D 

A group of cells of dimension 3 (which may include other groups of dimension 3)

ANY_GROUP 

A group of cells of any dimension (which may include other groups of any dimension)

BOUNDARY_GROUP 

A boundary condition group (no dimension specified)

DOMAIN_GROUP 

A model domain group (no dimension specified)

GROUP_CONSTRAINT_MASK 

Must a group be homogenous, have no subgroups, be a partition or cover, be open/closed (i.e., include its closure, or be composed only of model bdy/domain entities?

HALF_OPEN 

A bit indicating that the entity should be regarded as half-open (or half-closed)

HALF_CLOSED 

A bit indicating that the entity should be regarded as half-open (or half-closed)

NOTHING 

A convenience to avoid explicit type conversion.

INVALID 

The entity is invalid.

◆ Exclusions

Indicate an entity is excluded from which parts in smtk.

Enumerator
Nothing 

This entity is excluded from nothing.

Rendering 

This entity's tessellation will not be in model renderings(but may be used as a prototype for Instances).

ViewPresentation 

This entity will never be presented to users.

Everything 

All of the exclusions above apply (except Nothing).

◆ IteratorStyle

Indicate what records should be visited.

Enumerator
ITERATE_BARE 

Visit only the specified entities and no others.

ITERATE_CHILDREN 

Visit the specified entities and their children.

ITERATE_MODELS 

Visit all entities with an owning model that also owns any of the specified entities. Also visits the owning session, but not all of the owning session's models.

◆ ModelGeometryStyle

Enumerate how model domains are represented.

Currently a model may be listed as PARAMETRIC or DISCRETE.

PARAMETRIC models have cells that are assumed to have a parameter-space domain mapped to world coordinates by a smooth curve or surface, usually described with a single piecewise-continuous spline per entity. Their display tessellations are not required to be conformal (water-tight) and generally aren't.

DISCRETE models are piecewise linear cell complexes with no explicit parameter-space (although these are easy to generate) whose geometry is exactly represented by the display tessellation, which is required to be conformal. Each entity has 1 or more geometric primitives that, taken together, specify the point locus of the entity is world coordinates.

Other (non-solid) model types such as point clouds may be supported eventually; do not treat this enumeration as a boolean value.

Enumerator
DISCRETE 

Cells are discretized as a polygonal/polyhedral piecewise linear complex (PLC) with a supporting tessellation that are usually composed of multiple primitive geometric shapes like triangles or tetrahedra.

PARAMETRIC 

Cells are defined by a map from parametric coordinates to world coordinates, usually as analytic splines.

◆ ModificationResolution

Enumerator
OVERWRITE 

Favor the in-memory contents over the file/URL.

IGNORE 

Favor the file/URL contents over what's in memory.

ABORT 

Cancel the operation.

MOVE 

Write a new file (to a different location) and modify references to the URL to match.

ASK 

Ask the user what to do.

◆ Orientation

Constants that describe a cell-use's orientation relative to its parent cell.

These only have semantic meaning for edges and faces.

Note that SMTK makes a distinction between the orientation of a cell-use and the sense of a cell-use. The orientation indicates whether the surface normal or curve direction opposes or matches the cell's. The sense is used to indicate the context in which the use occurs (e.g., an edge may participate in multiple face loops, and will have a separate edge-use for each loop).

Also, note that unlike some solid modelers, SMTK composes k-shells out of cell-uses. This means that each k-shell is used exactly once because it may not have a NEGATIVE orientation relative to its cell-uses. If it did, it would be composed with oppositely-oriented cell-uses.

Enumerator
NEGATIVE 

The entity is oriented opposite to the underlying geometry.

POSITIVE 

The entity is codirectional with the underlying geometry.

UNDEFINED 

The relative orientation is unknown or unknowable.

◆ ResourceEventChangeType

Enumerate the types of changes a model resource undergoes.

The change type serves as a modifier to the relationship. Not all relationships support all of the modifiers. Specifically, ENTITY_ENTRY is never paired with MODIFIED_EVENT because there are many other signals that deal with entity modifications in a more fine-grained sense (e.g., GROUP_SUPERSET_OF_ENTITY is one way in which an smtk::model::Entity record can be modified).

Events that affect arrangements but do not otherwise affect a model resource are typically reported with ADD_EVENT notifications generated before addition and DEL_EVENT notifications after removal. The rationale is that (1) observers should have direct access to the most difficult-to-infer configuration while the event type specifies enough information to infer the simpler configuration and (2) observers may wish to perform other operations after removal to maintain the consistency of Resource.

Events that add new smtk::model::Entity, smtk::model::Tessellation, smtk::model::FloatData, smtk::model::StringData, or smtk::model::IntegerData are typically reported with ADD_EVENT notifications generated after addition and DEL_EVENT notifications before removal. The rationale is that observers should have a chance to access the objects being affected (after they are added or before they are removed).

See also
ResourceEventRelationType
Enumerator
ADD_EVENT 

The event is a relationship being added.

MOD_EVENT 

The event is a relationship being modified.

DEL_EVENT 

The event is a relationship being removed.

ANY_EVENT 

All change types (used when calling Resource::observe).

◆ ResourceEventRelationType

Enumerate the types of relationships which may cause model resource events.

This enumerates relationships that may be observed changing, along with the ResourceEventChangeType.

For events involving multiple entities, the name of the relationship specifies the order in which arguments to the callback appear. For example: MODEL_INCLUDES_FREE_CELL will always invoke callbacks with the model followed by the free cell. Likewise CELL_INCLUDES_CELL will always provide the higher-dimensional parent cell before the lower-dimensional, embedded child cell.

See also
ResourceEventChangeType
Enumerator
ENTITY_ENTRY 

An entity entry has been added to (ADD_EVENT) or removed from (DEL_EVENT) the resource.

TESSELLATION_ENTRY 

An entity is being provided or stripped of a tessellation in the resource.

ENTITY_HAS_PROPERTY 

The entity has a property entry being added, modified, or removed.

ENTITY_HAS_ATTRIBUTE 

The entity is being associated/disassociated to/from an attribute.

SESSION_INCLUDES_MODEL 

The entity is a session with a child model being added or removed.

MODEL_INCLUDES_FREE_CELL 

The entity is a model with a free cell.

MODEL_INCLUDES_FREE_USE 

The entity is a model with a free use (not really sensical?).

MODEL_INCLUDES_FREE_SHELL 

The entity is a model with a free shell (not really sensical?).

MODEL_INCLUDES_FREE_AUX_GEOM 

The entity is a model with a free (top-level) auxiliary geometry.

MODEL_INCLUDES_MODEL 

The entity is a model that has child model(s), i.e., an assembly.

MODEL_INCLUDES_GROUP 

The entity is a model that has child group(s).

CELL_INCLUDES_CELL 

The entity is a cell that includes a lower-dimensional cell.

CELL_HAS_USE 

The entity is a cell with a sense that is in use as a boundary.

SHELL_HAS_USE 

The entity is a shell composed of multiple lower-dimensional uses.

SHELL_INCLUDES_SHELL 

The entity is a shell that includes another shell (e.g., a void)

GROUP_SUPERSET_OF_ENTITY 

The entity is a group whose membership is being modified.

MODEL_SUPERSET_OF_MODEL 

The entity is a model whose set of child models is being modified.

MODEL_SUPERSET_OF_GROUP 

The entity is a model whose set of child groups is being modified.

SESSION_SUPERSET_OF_MODEL 

The entity is a session whose set of child models is being modified.

AUX_GEOM_INCLUDES_AUX_GEOM 

The entity is one auxiliary geometry being nested inside another.

INSTANCE_OF_ENTITY 

The entity is an instance being inserted, removed, or modified (retargeting what it instances).

INVALID_RELATIONSHIP 

The event is invalid. Used internally. This must be the last enum.

◆ SessionInformation

Bit flags describing types of information sessiond to Resource.

Session classes should provide individual translation for each piece of information, but are allowed to transcribe additional information when it is efficient or necessary to do so. For example, it does not make sense for an Entity record's relations to be populated but not the bit-flag describing its type. Thus, requesting SESSION_ENTITY_RELATIONS usually also results in SESSION_ENTITY_TYPE being transcribed.

Enumerator
SESSION_ENTITY_TYPE 

Transcribe the Entity type.

SESSION_ENTITY_RELATIONS 

Transcribe the Entity relationship vector.

SESSION_ARRANGEMENTS 

Arrangement information for the relationships.

SESSION_TESSELLATION 

Points and triangles used to render an entity.

SESSION_FLOAT_PROPERTIES 

Floating-point properties.

SESSION_STRING_PROPERTIES 

String properties.

SESSION_INTEGER_PROPERTIES 

Integer properties.

SESSION_ATTRIBUTE_ASSOCIATIONS 

Attribute associations.

SESSION_USER_DEFINED_PROPERTIES 

Remove user-defined as well as machine-generated properties.

                                         This bit is not used during transcription; it is only
                                         significant when erasing entities. Usually, it is not
                                         specified so that properties such as user-assigned
                                         names, colors, and visibility are preserved.
SESSION_NOTHING 

Transcribe nothing.

SESSION_ENTITY_RECORD 

Transcribe both entity type and relations.

SESSION_ENTITY_ARRANGED 

Transcribe the entity record and all arrangement information.

SESSION_PROPERTIES 

Transcribe all properties.

SESSION_EVERYTHING 

Transcribe all information about the entity.

SESSION_EXHAUSTIVE 

Erase all information about the entity, including user-specified.

◆ TessellationCellType

Cell type information bit-vector constants.

This enum holds specific bit-vector combinations used by a subset of entries in a Tessellation instance's connectivity array; the first connectivity entry of each cell in the connectivity array uses these values and indicate how to interpret the rest of the connectivity entries for the cell.

Many of these correspond to Three.js bit values. See https://github.com/mrdoob/three.js/wiki/JSON-Model-format-3 for more information.

Enumerator
TESS_VERTEX 

Cell is a single vertex.

TESS_TRIANGLE 

Cell is a triangle (3 vertices, part of Three.JS).

TESS_QUAD 

Cell is a quadrilateral (4 vertices, part of Three.JS).

TESS_POLYVERTEX 

Cell is a polyvertex, with the number of vertices in the following connectivity entry.

TESS_POLYLINE 

Cell is a polyline, with the number of vertices in the following connectivity entry.

TESS_POLYGON 

Cell is a polygon, with the number of vertices in the following connectivity entry.

TESS_TRIANGLE_STRIP 

Cell is a triangle strip, with the number of vertices in the following connectivity entry.

TESS_INVALID_CELL 

Something went wrong; an invalid cell.

TESS_VARYING_VERT_CELL 

All cell types that have a varying number of vertices (and store it after cell type).

TESS_CELLTYPE_MASK 

The union of all cell type bits.

TESS_FACE_MATERIAL 

Cell has a material ID immediately following the list of vertices (part of Three.js).

TESS_FACE_UV 

Cell has an offset into the UV coordinate storage following material ID (part of Three.js).

TESS_FACE_VERTEX_UV 

Cell has N offsets into the UV coordinate storage following face UV (part of Three.js).

TESS_FACE_NORMAL 

Cell has an offset into the normal-vector storage following vertex UVs (part of Three.js).

TESS_FACE_VERTEX_NORMAL 

Cell has N offsets into the normal-vector storage following face normal (part of Three.js).

TESS_FACE_COLOR 

Cell has an offset into the color storage following vertex normals (part of Three.js).

TESS_FACE_VERTEX_COLOR 

Cell has N offsets into the color storage following face color (part of Three.js).

TESS_PROPERTY_MASK 

All properties that can be stored with a cell.

Variable Documentation

◆ ArrangementKindAbbr

const char* smtk::model::ArrangementKindAbbr[KINDS_OF_ARRANGEMENTS+1]
Initial value:
= {
"i",
"c",
"s",
"u",
"e",
"b",
"r",
"p",
"x",
"?"
}

◆ ArrangementKindName

const char* smtk::model::ArrangementKindName[KINDS_OF_ARRANGEMENTS+1]
Initial value:
= {
"inclusion",
"cell",
"shell",
"use",
"embedding",
"subset",
"superset",
"instantiates",
"instance",
"invalid"
}