VTK  9.7.20261104
vtkUnstructuredGridSideMap::IdColumn Struct Reference

#include <vtkUnstructuredGridSideMap.h>

Detailed Description

One column of the structure, kept in the narrowest integer type its values fit in and read through a raw pointer.

The columns hold small numbers – a local side index is single digits, and ids on any mesh short of two billion sides fit in 32 bits – so storing them all as vtkIdType wastes most of the structure. The type is chosen once when the column is packed and the pointer resolved then, so reading stays a load and a widening rather than a virtual call, which matters because these are read at random, one value at a time, on the O(1) paths.

Definition at line 305 of file vtkUnstructuredGridSideMap.h.

Collaboration diagram for vtkUnstructuredGridSideMap::IdColumn:
[legend]

Public Member Functions

vtkIdType operator[] (vtkIdType i) const
bool Empty () const
vtkIdType GetNumberOfValues () const
unsigned long GetActualMemorySize () const
void Clear ()
void Bind ()
void Pack (const std::vector< vtkIdType > &values)
void Adopt (vtkDataArray *array)

Public Attributes

vtkSmartPointer< vtkDataArray > Array
const unsigned char * Tiny = nullptr
const vtkTypeInt32 * Narrow = nullptr
const vtkTypeInt64 * Wide = nullptr

Member Function Documentation

◆ operator[]()

vtkIdType vtkUnstructuredGridSideMap::IdColumn::operator[] ( vtkIdType i) const
inline

Definition at line 312 of file vtkUnstructuredGridSideMap.h.

◆ Empty()

bool vtkUnstructuredGridSideMap::IdColumn::Empty ( ) const
inline

Definition at line 325 of file vtkUnstructuredGridSideMap.h.

◆ GetNumberOfValues()

vtkIdType vtkUnstructuredGridSideMap::IdColumn::GetNumberOfValues ( ) const

◆ GetActualMemorySize()

unsigned long vtkUnstructuredGridSideMap::IdColumn::GetActualMemorySize ( ) const

◆ Clear()

void vtkUnstructuredGridSideMap::IdColumn::Clear ( )

◆ Bind()

void vtkUnstructuredGridSideMap::IdColumn::Bind ( )

◆ Pack()

void vtkUnstructuredGridSideMap::IdColumn::Pack ( const std::vector< vtkIdType > & values)

◆ Adopt()

void vtkUnstructuredGridSideMap::IdColumn::Adopt ( vtkDataArray * array)

Member Data Documentation

◆ Array

vtkSmartPointer<vtkDataArray> vtkUnstructuredGridSideMap::IdColumn::Array

Definition at line 307 of file vtkUnstructuredGridSideMap.h.

◆ Tiny

const unsigned char* vtkUnstructuredGridSideMap::IdColumn::Tiny = nullptr

Definition at line 308 of file vtkUnstructuredGridSideMap.h.

◆ Narrow

const vtkTypeInt32* vtkUnstructuredGridSideMap::IdColumn::Narrow = nullptr

Definition at line 309 of file vtkUnstructuredGridSideMap.h.

◆ Wide

const vtkTypeInt64* vtkUnstructuredGridSideMap::IdColumn::Wide = nullptr

Definition at line 310 of file vtkUnstructuredGridSideMap.h.


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