GemaMesh
The GeMA Mesh Plugin
Public Types | Public Member Functions | Public Attributes | Private Member Functions | List of all members
GmpMeshData< Vector > Struct Template Referenceabstract

Auxiliar structure used to share data between GmpXxxMeshBase and GmpMeshLoader. More...

#include <gmpMeshData.h>

Inheritance diagram for GmpMeshData< Vector >:
Inheritance graph
[legend]
Collaboration diagram for GmpMeshData< Vector >:
Collaboration graph
[legend]

Public Types

template<typename U >
using VectorType = Vector< U >
 A type identifying which vector type we are using.
 

Public Member Functions

 GmpMeshData (GmMesh *mesh)
 Constructor. The unused mesh parameter is a helper to the Surface Mesh code.
 
virtual ~GmpMeshData ()
 Virtual destructor.
 
virtual bool setCoordinateDimension (int ncoord)
 
virtual void clear (GmMesh *mesh)
 Removes all mesh nodes + removes all values from node based value sets, preserving object state so that future node addition can be made.
 
virtual void releaseMemory ()
 Releases all the memory DIRECTLY owned by the object.
 
virtual int addFirstNodes (GmMesh *mesh, int numAddedNodes, int numGhostNodes, QList< GmValueInfo * > infoList=QList< GmValueInfo * >())=0
 
virtual int addNewNodes (GmMesh *mesh, int numAddedNodes)=0
 
virtual int numNodes () const =0
 
int addFirstGhostNodes (GmMesh *mesh, int numAddedNodes, QList< GmValueInfo * > infoList)
 
int addNewGhostNodes (GmMesh *mesh, int numAddedNodes)
 
bool ghostEnabled ()
 
void setGhostEnabled (bool state)
 
int numGhostNodes () const
 
virtual size_t nodeSetsMemory () const
 Returns the approximate memory used for storing mesh node sets.
 
void setGhostCoordinatesData (int nodeIndex, int coordId, double coordVal)
 Updates a ghost node cooridnate.
 
bool addNodeValueSets (GmMesh *mesh, QList< GmValueInfo * > infoList, int numAddedNodes, int numGhostNodes, bool ghost)
 Adds new value sets to the mesh as specified by infoList. The ownership of the list metadata is transferred to the mesh. The gven number of nodes is used to initialize the set sizes. If ghost is false, expects that the affected nodes on the list includes only geometry or both entries. If ghost is true, the list should include ghost and both entries, with the later ones not added to the mesh. In this case, numAddedNodes should be zero.
 
bool resizeValueSets (const QList< GmValueSet * > &valueSets, int numAddedNodes)
 Resizes the given set of value sets adding the specified number of nodes. Either all the sets are resized (and the function returns true), or none are (and the function returns false). Can cope with NULL values in the list. Expects the non-NULL value sets to have the same size.
 
virtual bool addStateGeometryData (GmStateDump *state, int groupId)
 Adds to the state dump an item storing node set nodes followed by an item storing node coordinates.
 
virtual bool fillDumpControlMapData (GmMesh *mesh, QVariantMap *map, const GmLogCategory &logger)
 Stores the mesh data control info on the stored map.
 
virtual bool dumpControlMapDataLoaded (GmMesh *mesh, QVariantMap *map, const GmLogCategory &logger)
 Loads the map data into the object + adjusts vector sizes if necessary.
 

Public Attributes

GmValueInfo_coordInfo
 Information about node coordinates.
 
bool _ghostEnabled
 Are ghost nodes enabled for this mesh?
 
int _numGhostNodes
 The number of mesh ghost nodes.
 
Vector< double > _ghostCoordinates
 Coordinate vector for ghost nodes. Size = _coordInfo->size() * _numGhostNodes. Values stored by node.
 
QMap< QString, GmNodeSet * > _nodeSets
 A map with the definition of each node set associated with the mesh. Map entries are instances of the GmpGemaNodeSet class.
 
GmStateDump_state
 

Private Member Functions

void releaseGhostNodes ()
 Removes the memory associated with ghost nodes.
 

Detailed Description

template<template< class > class Vector>
struct GmpMeshData< Vector >

Auxiliar structure used to share data between GmpXxxMeshBase and GmpMeshLoader.

The template parameter defines the kind of vector object used to store per node data. It can be either GmSingleVector or GmDualVector

Member Data Documentation

◆ _state

template<template< class > class Vector>
GmStateDump* GmpMeshData< Vector >::_state

brief Ugly way of letting the mesh data do some adjustments to the state dump after loading the control data & before loading the other state items. Its value is setted by the mesh loader prior to loading the mesh data from a dump file on the mesh initilization and cleared immediately after.


The documentation for this struct was generated from the following files: