VTK  9.5.20250625
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
vtkOverlappingAMRMetaData Class Reference

Meta data that describes the structure of an overlapping AMR data set. More...

#include <vtkOverlappingAMRMetaData.h>

Inheritance diagram for vtkOverlappingAMRMetaData:
[legend]
Collaboration diagram for vtkOverlappingAMRMetaData:
[legend]

Public Types

typedef vtkAMRMetaData Superclass
 

Public Member Functions

virtual vtkTypeBool IsA (const char *type)
 Return 1 if this class is the same type of (or a subclass of) the named class.
 
vtkOverlappingAMRMetaDataNewInstance () const
 
void PrintSelf (ostream &os, vtkIndent indent) override
 Print members.
 
bool operator== (const vtkOverlappingAMRMetaData &other) const
 
void Initialize (int numLevels, const int *blocksPerLevel) override
 Initialize the meta information numLevels is the number of levels blocksPerLevel[i] is the number of blocks at level i.
 
const double * GetBounds ()
 Returns the bounds of the entire domain as a 6 sized array.
 
void GetBounds (unsigned int level, unsigned int id, double *bb)
 Returns the bounding box of a given box.
 
bool GetOrigin (unsigned int level, unsigned int id, double *origin)
 Recover the origin of the grid at (level,id).
 
void GetSpacing (unsigned int level, double spacing[3])
 Return the spacing at the given fiven.
 
bool HasSpacing (unsigned int level)
 Return if a specific level has spacing.
 
bool GetCoarsenedAMRBox (unsigned int level, unsigned int id, vtkAMRBox &box) const
 return the amr box coarsened to the previous level
 
void GenerateRefinementRatio ()
 This method computes the refinement ratio at each level.
 
bool HasRefinementRatio ()
 Returns whether refinement ratio has been set (either by calling GenerateRefinementRatio() or by calling SetRefinementRatio()
 
void SetRefinementRatio (unsigned int level, int ratio)
 Set the refinement ratio at a level.
 
int GetRefinementRatio (unsigned int level) const
 Returns the refinement of a given level.
 
void SetSpacing (unsigned int level, const double *h)
 Set the spacing at a given level.
 
bool HasChildrenInformation ()
 Return whether parent child information has been generated.
 
unsigned int * GetParents (unsigned int level, unsigned int index, unsigned int &numParents)
 Return a pointer to Parents of a block.
 
unsigned int * GetChildren (unsigned int level, unsigned int index, unsigned int &numChildren)
 Return a pointer to Children of a block.
 
void PrintParentChildInfo (unsigned int level, unsigned int index)
 Prints the parents and children of a requested block (Debug Routine)
 
void GenerateParentChildInformation ()
 Generate the parent/child relationships - needed to be called before GetParents or GetChildren can be used!
 
bool CheckValidity ()
 Checks whether the meta data is internally consistent.
 
bool FindCell (double q[3], unsigned int level, unsigned int index, int &cellIdx)
 Given a point q, find whether q is bounded by the data set at (level,index).
 
bool FindGrid (double q[3], int level, unsigned int &gridId)
 find the grid that contains the point q at the specified level
 
bool FindGrid (double q[3], unsigned int &level, unsigned int &gridId)
 Given a point q, find the highest level grid that contains it.
 
std::vector< std::vector< unsigned int > > & GetChildrenAtLevel (unsigned int i)
 Get children at a specific level.
 
void DeepCopy (vtkOverlappingAMRMetaData *other)
 Copy internal fields from other into this.
 
virtual void DeepCopy (vtkAMRMetaData *other)
 Copy internal fields from other into this.
 
void GetOrigin (double origin[3])
 Get the AMR dataset origin as a 3 sized array The origin is essentially the minimum of all the grids.
 
double * GetOrigin ()
 Get the AMR dataset origin as a 3 sized array The origin is essentially the minimum of all the grids.
 
void SetOrigin (const double *origin)
 Get the AMR dataset origin as a 3 sized array The origin is essentially the minimum of all the grids.
 
void SetAMRBox (unsigned int level, unsigned int id, const vtkAMRBox &box)
 Methods to set and get the AMR box at a given position.
 
const vtkAMRBoxGetAMRBox (unsigned int level, unsigned int id) const
 Methods to set and get the AMR box at a given position.
 
int GetAMRBlockSourceIndex (int index)
 Get/Set the SourceIndex of a block.
 
void SetAMRBlockSourceIndex (int index, int sourceId)
 Get/Set the SourceIndex of a block.
 
- Public Member Functions inherited from vtkObject
 vtkBaseTypeMacro (vtkObject, vtkObjectBase)
 
virtual void DebugOn ()
 Turn debugging output on.
 
virtual void DebugOff ()
 Turn debugging output off.
 
bool GetDebug ()
 Get the value of the debug flag.
 
void SetDebug (bool debugFlag)
 Set the value of the debug flag.
 
virtual void Modified ()
 Update the modification time for this object.
 
virtual vtkMTimeType GetMTime ()
 Return this object's modified time.
 
void PrintSelf (ostream &os, vtkIndent indent) override
 Methods invoked by print to print information about the object including superclasses.
 
void RemoveObserver (unsigned long tag)
 
void RemoveObservers (unsigned long event)
 
void RemoveObservers (const char *event)
 
void RemoveAllObservers ()
 
vtkTypeBool HasObserver (unsigned long event)
 
vtkTypeBool HasObserver (const char *event)
 
vtkTypeBool InvokeEvent (unsigned long event)
 
vtkTypeBool InvokeEvent (const char *event)
 
std::string GetObjectDescription () const override
 The object description printed in messages and PrintSelf output.
 
unsigned long AddObserver (unsigned long event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
unsigned long AddObserver (const char *event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
vtkCommandGetCommand (unsigned long tag)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
void RemoveObserver (vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
void RemoveObservers (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
void RemoveObservers (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
vtkTypeBool HasObserver (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
vtkTypeBool HasObserver (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object.
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events.
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events.
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, bool(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Allow user to set the AbortFlagOn() with the return value of the callback method.
 
vtkTypeBool InvokeEvent (unsigned long event, void *callData)
 This method invokes an event and return whether the event was aborted or not.
 
vtkTypeBool InvokeEvent (const char *event, void *callData)
 This method invokes an event and return whether the event was aborted or not.
 
virtual void SetObjectName (const std::string &objectName)
 Set/get the name of this object for reporting purposes.
 
virtual std::string GetObjectName () const
 Set/get the name of this object for reporting purposes.
 
- Public Member Functions inherited from vtkObjectBase
const char * GetClassName () const
 Return the class name as a string.
 
virtual std::string GetObjectDescription () const
 The object description printed in messages and PrintSelf output.
 
virtual vtkTypeBool IsA (const char *name)
 Return 1 if this class is the same type of (or a subclass of) the named class.
 
virtual vtkIdType GetNumberOfGenerationsFromBase (const char *name)
 Given the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class).
 
virtual void Delete ()
 Delete a VTK object.
 
virtual void FastDelete ()
 Delete a reference to this object.
 
void InitializeObjectBase ()
 
void Print (ostream &os)
 Print an object to an ostream.
 
void Register (vtkObjectBase *o)
 Increase the reference count (mark as used by another object).
 
virtual void UnRegister (vtkObjectBase *o)
 Decrease the reference count (release by another object).
 
int GetReferenceCount ()
 Return the current reference count of this object.
 
void SetReferenceCount (int)
 Sets the reference count.
 
bool GetIsInMemkind () const
 A local state flag that remembers whether this object lives in the normal or extended memory space.
 
virtual void PrintHeader (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses.
 
virtual void PrintTrailer (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses.
 
virtual bool UsesGarbageCollector () const
 Indicate whether the class uses vtkGarbageCollector or not.
 

Static Public Member Functions

static vtkOverlappingAMRMetaDataNew ()
 
static vtkTypeBool IsTypeOf (const char *type)
 
static vtkOverlappingAMRMetaDataSafeDownCast (vtkObjectBase *o)
 
- Static Public Member Functions inherited from vtkObject
static vtkObjectNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
 
static void BreakOnError ()
 This method is called when vtkErrorMacro executes.
 
static void SetGlobalWarningDisplay (vtkTypeBool val)
 This is a global flag that controls whether any debug, warning or error messages are displayed.
 
static void GlobalWarningDisplayOn ()
 This is a global flag that controls whether any debug, warning or error messages are displayed.
 
static void GlobalWarningDisplayOff ()
 This is a global flag that controls whether any debug, warning or error messages are displayed.
 
static vtkTypeBool GetGlobalWarningDisplay ()
 This is a global flag that controls whether any debug, warning or error messages are displayed.
 
- Static Public Member Functions inherited from vtkObjectBase
static vtkTypeBool IsTypeOf (const char *name)
 Return 1 if this class type is the same type of (or a subclass of) the named class.
 
static vtkIdType GetNumberOfGenerationsFromBaseType (const char *name)
 Given a the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class).
 
static vtkObjectBaseNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
 
static void SetMemkindDirectory (const char *directoryname)
 The name of a directory, ideally mounted -o dax, to memory map an extended memory space within.
 
static bool GetUsingMemkind ()
 A global state flag that controls whether vtkObjects are constructed in the usual way (the default) or within the extended memory space.
 

Protected Member Functions

virtual vtkObjectBaseNewInstanceInternal () const
 
 vtkOverlappingAMRMetaData ()
 
 ~vtkOverlappingAMRMetaData () override
 
- Protected Member Functions inherited from vtkObject
 vtkObject ()
 
 ~vtkObject () override
 
void RegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void UnRegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=nullptr)
 These methods allow a command to exclusively grab all events.
 
void InternalReleaseFocus ()
 These methods allow a command to exclusively grab all events.
 
- Protected Member Functions inherited from vtkObjectBase
 vtkObjectBase ()
 
virtual ~vtkObjectBase ()
 
virtual void RegisterInternal (vtkObjectBase *, vtkTypeBool check)
 
virtual void UnRegisterInternal (vtkObjectBase *, vtkTypeBool check)
 
virtual void ReportReferences (vtkGarbageCollector *)
 
virtual void ObjectFinalize ()
 
 vtkObjectBase (const vtkObjectBase &)
 
void operator= (const vtkObjectBase &)
 

Additional Inherited Members

- Static Protected Member Functions inherited from vtkObjectBase
static vtkMallocingFunction GetCurrentMallocFunction ()
 
static vtkReallocingFunction GetCurrentReallocFunction ()
 
static vtkFreeingFunction GetCurrentFreeFunction ()
 
static vtkFreeingFunction GetAlternateFreeFunction ()
 
- Protected Attributes inherited from vtkObject
bool Debug
 
vtkTimeStamp MTime
 
vtkSubjectHelper * SubjectHelper
 
std::string ObjectName
 
- Protected Attributes inherited from vtkObjectBase
std::atomic< int32_t > ReferenceCount
 
vtkWeakPointerBase ** WeakPointers
 

Detailed Description

Meta data that describes the structure of an overlapping AMR data set.

vtkAMRInformation encapsulates the following meta information for a generic AMR data set

See also
vtkUniformGridAMR, vtkOverlappingAMR, vtkAMRBox, vtkOverlappingAMRMetaData, vtkNonOverlappingAMR

Definition at line 28 of file vtkOverlappingAMRMetaData.h.

Member Typedef Documentation

◆ Superclass

Definition at line 32 of file vtkOverlappingAMRMetaData.h.

Constructor & Destructor Documentation

◆ vtkOverlappingAMRMetaData()

vtkOverlappingAMRMetaData::vtkOverlappingAMRMetaData ( )
protected

◆ ~vtkOverlappingAMRMetaData()

vtkOverlappingAMRMetaData::~vtkOverlappingAMRMetaData ( )
overrideprotected

Member Function Documentation

◆ New()

static vtkOverlappingAMRMetaData * vtkOverlappingAMRMetaData::New ( )
static

◆ IsTypeOf()

static vtkTypeBool vtkOverlappingAMRMetaData::IsTypeOf ( const char *  type)
static

◆ IsA()

virtual vtkTypeBool vtkOverlappingAMRMetaData::IsA ( const char *  name)
virtual

Return 1 if this class is the same type of (or a subclass of) the named class.

Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkAMRMetaData.

Reimplemented in vtkAMRInformation.

◆ SafeDownCast()

static vtkOverlappingAMRMetaData * vtkOverlappingAMRMetaData::SafeDownCast ( vtkObjectBase o)
static

◆ NewInstanceInternal()

virtual vtkObjectBase * vtkOverlappingAMRMetaData::NewInstanceInternal ( ) const
protectedvirtual

Reimplemented from vtkAMRMetaData.

Reimplemented in vtkAMRInformation.

◆ NewInstance()

vtkOverlappingAMRMetaData * vtkOverlappingAMRMetaData::NewInstance ( ) const

◆ PrintSelf()

void vtkOverlappingAMRMetaData::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
overridevirtual

Print members.

Reimplemented from vtkAMRMetaData.

◆ operator==()

bool vtkOverlappingAMRMetaData::operator== ( const vtkOverlappingAMRMetaData other) const

◆ Initialize()

void vtkOverlappingAMRMetaData::Initialize ( int  numLevels,
const int *  blocksPerLevel 
)
overridevirtual

Initialize the meta information numLevels is the number of levels blocksPerLevel[i] is the number of blocks at level i.

Reimplemented from vtkAMRMetaData.

◆ GetOrigin() [1/3]

void vtkOverlappingAMRMetaData::GetOrigin ( double  origin[3])

Get the AMR dataset origin as a 3 sized array The origin is essentially the minimum of all the grids.

◆ GetOrigin() [2/3]

double * vtkOverlappingAMRMetaData::GetOrigin ( )

Get the AMR dataset origin as a 3 sized array The origin is essentially the minimum of all the grids.

◆ SetOrigin()

void vtkOverlappingAMRMetaData::SetOrigin ( const double *  origin)

Get the AMR dataset origin as a 3 sized array The origin is essentially the minimum of all the grids.

◆ GetBounds() [1/2]

const double * vtkOverlappingAMRMetaData::GetBounds ( )

Returns the bounds of the entire domain as a 6 sized array.

◆ GetBounds() [2/2]

void vtkOverlappingAMRMetaData::GetBounds ( unsigned int  level,
unsigned int  id,
double *  bb 
)

Returns the bounding box of a given box.

◆ GetOrigin() [3/3]

bool vtkOverlappingAMRMetaData::GetOrigin ( unsigned int  level,
unsigned int  id,
double *  origin 
)

Recover the origin of the grid at (level,id).

Return true if sucessful, false otherwise.

◆ GetSpacing()

void vtkOverlappingAMRMetaData::GetSpacing ( unsigned int  level,
double  spacing[3] 
)

Return the spacing at the given fiven.

◆ HasSpacing()

bool vtkOverlappingAMRMetaData::HasSpacing ( unsigned int  level)

Return if a specific level has spacing.

◆ SetAMRBox()

void vtkOverlappingAMRMetaData::SetAMRBox ( unsigned int  level,
unsigned int  id,
const vtkAMRBox box 
)

Methods to set and get the AMR box at a given position.

◆ GetAMRBox()

const vtkAMRBox & vtkOverlappingAMRMetaData::GetAMRBox ( unsigned int  level,
unsigned int  id 
) const

Methods to set and get the AMR box at a given position.

◆ GetCoarsenedAMRBox()

bool vtkOverlappingAMRMetaData::GetCoarsenedAMRBox ( unsigned int  level,
unsigned int  id,
vtkAMRBox box 
) const

return the amr box coarsened to the previous level

◆ GetAMRBlockSourceIndex()

int vtkOverlappingAMRMetaData::GetAMRBlockSourceIndex ( int  index)

Get/Set the SourceIndex of a block.

Typically, this is a file-type specific index that can be used by a reader to load a particular file block

◆ SetAMRBlockSourceIndex()

void vtkOverlappingAMRMetaData::SetAMRBlockSourceIndex ( int  index,
int  sourceId 
)

Get/Set the SourceIndex of a block.

Typically, this is a file-type specific index that can be used by a reader to load a particular file block

◆ GenerateRefinementRatio()

void vtkOverlappingAMRMetaData::GenerateRefinementRatio ( )

This method computes the refinement ratio at each level.

At each level, l, the refinement ratio r_l is computed by r_l = D_{l} / D_{l+1}, where D_{l+1} and D_{l} are the grid spacings at the next and current level respectively. .SECTION Assumptions 1) Within each level, the refinement ratios are the same for all blocks. 2) The refinement ratio is uniform along each dimension of the block.

◆ HasRefinementRatio()

bool vtkOverlappingAMRMetaData::HasRefinementRatio ( )

Returns whether refinement ratio has been set (either by calling GenerateRefinementRatio() or by calling SetRefinementRatio()

◆ SetRefinementRatio()

void vtkOverlappingAMRMetaData::SetRefinementRatio ( unsigned int  level,
int  ratio 
)

Set the refinement ratio at a level.

This method should be called for all levels, if called at all.

◆ GetRefinementRatio()

int vtkOverlappingAMRMetaData::GetRefinementRatio ( unsigned int  level) const

Returns the refinement of a given level.

◆ SetSpacing()

void vtkOverlappingAMRMetaData::SetSpacing ( unsigned int  level,
const double *  h 
)

Set the spacing at a given level.

◆ HasChildrenInformation()

bool vtkOverlappingAMRMetaData::HasChildrenInformation ( )

Return whether parent child information has been generated.

◆ GetParents()

unsigned int * vtkOverlappingAMRMetaData::GetParents ( unsigned int  level,
unsigned int  index,
unsigned int &  numParents 
)

Return a pointer to Parents of a block.

The first entry is the number of parents the block has followed by its parent ids in level-1. If none exits it returns nullptr.

◆ GetChildren()

unsigned int * vtkOverlappingAMRMetaData::GetChildren ( unsigned int  level,
unsigned int  index,
unsigned int &  numChildren 
)

Return a pointer to Children of a block.

The first entry is the number of children the block has followed by its children ids in level+1. If none exits it returns nullptr.

◆ PrintParentChildInfo()

void vtkOverlappingAMRMetaData::PrintParentChildInfo ( unsigned int  level,
unsigned int  index 
)

Prints the parents and children of a requested block (Debug Routine)

◆ GenerateParentChildInformation()

void vtkOverlappingAMRMetaData::GenerateParentChildInformation ( )

Generate the parent/child relationships - needed to be called before GetParents or GetChildren can be used!

◆ CheckValidity()

bool vtkOverlappingAMRMetaData::CheckValidity ( )

Checks whether the meta data is internally consistent.

◆ FindCell()

bool vtkOverlappingAMRMetaData::FindCell ( double  q[3],
unsigned int  level,
unsigned int  index,
int &  cellIdx 
)

Given a point q, find whether q is bounded by the data set at (level,index).

If it is, set cellIdx to the cell index and return true; otherwise return false

◆ FindGrid() [1/2]

bool vtkOverlappingAMRMetaData::FindGrid ( double  q[3],
int  level,
unsigned int &  gridId 
)

find the grid that contains the point q at the specified level

◆ FindGrid() [2/2]

bool vtkOverlappingAMRMetaData::FindGrid ( double  q[3],
unsigned int &  level,
unsigned int &  gridId 
)

Given a point q, find the highest level grid that contains it.

◆ GetChildrenAtLevel()

std::vector< std::vector< unsigned int > > & vtkOverlappingAMRMetaData::GetChildrenAtLevel ( unsigned int  i)
inline

Get children at a specific level.

Definition at line 190 of file vtkOverlappingAMRMetaData.h.

◆ DeepCopy() [1/2]

void vtkOverlappingAMRMetaData::DeepCopy ( vtkOverlappingAMRMetaData other)

Copy internal fields from other into this.

◆ DeepCopy() [2/2]

virtual void vtkAMRMetaData::DeepCopy ( vtkAMRMetaData other)
virtual

Copy internal fields from other into this.

Reimplemented from vtkAMRMetaData.


The documentation for this class was generated from the following file: