94 #include "vtkCommonDataModelModule.h"
103 VTK_ABI_NAMESPACE_BEGIN
141 return this->AppendAtom(atomicNumber, pos[0], pos[1], pos[2]);
146 return this->AppendAtom(atomicNumber, pos[0], pos[1], pos[2]);
169 return this->AppendBond(atom1.
Id, atom2.
Id,
order);
201 this->SetAtomPosition(atomId, pos[0], pos[1], pos[2]);
404 return this->
Initialize(atomPositions,
nullptr, atomData);
439 vtkSetStringMacro(AtomicNumberArrayName);
440 vtkGetStringMacro(AtomicNumberArrayName);
447 vtkSetStringMacro(BondOrdersArrayName);
448 vtkGetStringMacro(BondOrdersArrayName);
505 VTK_ABI_NAMESPACE_END
Provides access to and storage of chemical electronic data.
convenience proxy for vtkMolecule
convenience proxy for vtkMolecule
abstract superclass for arrays of numeric data
general representation of visualization data
represent and manipulate attribute data in a dataset
Base class for graph data types.
virtual vtkDataSetAttributes * GetEdgeData()
Get the vertex or edge data.
void Initialize() override
Initialize to an empty graph.
virtual vtkDataSetAttributes * GetVertexData()
Get the vertex or edge data.
vtkIdType GetEdgeId(vtkIdType a, vtkIdType b)
Returns the Id of the edge between vertex a and vertex b.
dynamic, self-adjusting array of vtkIdType
a simple class to control print indentation
represent and manipulate 3x3 transformation matrices
class describing a molecule
vtkAbstractElectronicData * ElectronicData
void GetAtomPosition(vtkIdType atomId, float pos[3])
Get the position of the atom with the specified id.
vtkAtom AppendAtom()
Add new atom with atomic number 0 (dummy atom) at origin.
vtkVector3f GetAtomPosition(vtkIdType atomId)
Get the position of the atom with the specified id.
vtkIdTypeArray * GetBondList()
The graph superclass does not provide fast random access to the edge (bond) data.
void SetLattice(vtkMatrix3x3 *matrix)
The unit cell vectors.
vtkDataSetAttributes * GetAtomData()
Return the VertexData of the underlying graph.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int Initialize(vtkPoints *atomPositions, vtkDataArray *atomicNumberArray, vtkDataSetAttributes *atomData)
Initialize a molecule with an atom per input point.
vtkBond AppendBond(const vtkAtom &atom1, const vtkAtom &atom2, unsigned short order=1)
Add a bond between the specified atoms, optionally setting the bond order (default: 1).
void SetBondOrder(vtkIdType bondId, unsigned short order)
Get/Set the bond order of the bond with the specified id.
vtkAtom AppendAtom(unsigned short atomicNumber, double x, double y, double z)
Add new atom with the specified atomic number and position.
vtkAtom GetAtom(vtkIdType atomId)
Return a vtkAtom that refers to the atom with the specified id.
virtual void DeepCopyStructure(vtkMolecule *m)
Deep copies the atoms and bonds from m into this.
void GetLattice(vtkVector3d &a, vtkVector3d &b, vtkVector3d &c, vtkVector3d &origin)
Get the unit cell lattice vectors, and optionally, the origin.
void Initialize() override
Initialize to an empty graph.
void ClearLattice()
Remove any unit cell lattice information from the molecule.
vtkUnsignedCharArray * GetAtomGhostArray()
Get the array that defines the ghost type of each atom.
virtual void ShallowCopyAttributes(vtkMolecule *m)
Shallow copies attributes (i.e.
void SetAtomAtomicNumber(vtkIdType atomId, unsigned short atomicNum)
Set the atomic number of the atom with the specified id.
virtual void ShallowCopyStructure(vtkMolecule *m)
Shallow copies the atoms and bonds from m into this.
void GetAtomPosition(vtkIdType atomId, double pos[3])
Get the position of the atom with the specified id.
unsigned long GetActualMemorySize() override
Return the actual size of the data in kibibytes (1024 bytes).
double GetBondLength(vtkIdType bondId)
Get the bond length of the bond with the specified id.
vtkSmartPointer< vtkMatrix3x3 > Lattice
virtual void DeepCopyAttributes(vtkMolecule *m)
Deep copies attributes (i.e.
static bool GetPlaneFromBond(const vtkBond &bond, const vtkVector3f &normal, vtkPlane *plane)
Obtain the plane that passes through the indicated bond with the given normal.
int Initialize(vtkPoints *atomPositions, vtkDataSetAttributes *atomData)
Overloads Initialize method.
void ShallowCopy(vtkDataObject *obj) override
Shallow copies the data object into this molecule.
vtkPoints * GetAtomicPositionArray()
Access the raw arrays used in this vtkMolecule instance.
void SetBondListDirty()
The graph superclass does not provide fast random access to the edge (bond) data.
vtkIdType GetBondId(vtkIdType a, vtkIdType b)
Return the edge id from the underlying graph.
vtkUnsignedShortArray * GetAtomicNumberArray()
Access the raw arrays used in this vtkMolecule instance.
vtkUnsignedCharArray * AtomGhostArray
void GetLattice(vtkVector3d &a, vtkVector3d &b, vtkVector3d &c)
Get the unit cell lattice vectors, and optionally, the origin.
vtkUnsignedCharArray * BondGhostArray
void SetAtomPosition(vtkIdType atomId, double x, double y, double z)
Set the position of the atom with the specified id.
void UpdateBondList()
The graph superclass does not provide fast random access to the edge (bond) data.
virtual void CopyAttributesInternal(vtkMolecule *m, bool deep)
Copy everything but bonds and atoms.
void DeepCopy(vtkDataObject *obj) override
Deep copies the data object into this molecule.
int GetDataObjectType() override
Return what type of dataset this is.
static bool GetPlaneFromBond(const vtkAtom &atom1, const vtkAtom &atom2, const vtkVector3f &normal, vtkPlane *plane)
Obtain the plane that passes through the indicated bond with the given normal.
void AllocateAtomGhostArray()
Allocate ghost array for atoms.
void SetAtomPosition(vtkIdType atomId, const vtkVector3f &pos)
Set the position of the atom with the specified id.
virtual void SetElectronicData(vtkAbstractElectronicData *)
Set/Get the AbstractElectronicData-subclassed object for this molecule.
unsigned short GetAtomAtomicNumber(vtkIdType atomId)
Return the atomic number of the atom with the specified id.
vtkIdType GetNumberOfBonds()
Return the number of bonds in the molecule.
char * BondOrdersArrayName
bool HasLattice()
Return true if a unit cell lattice is defined.
vtkBond AppendBond(vtkIdType atom1, vtkIdType atom2, unsigned short order=1)
Add a bond between the specified atoms, optionally setting the bond order (default: 1).
void SetLattice(const vtkVector3d &a, const vtkVector3d &b, const vtkVector3d &c)
The unit cell vectors.
unsigned short GetBondOrder(vtkIdType bondId)
Get/Set the bond order of the bond with the specified id.
vtkAtom AppendAtom(unsigned short atomicNumber, const vtkVector3f &pos)
Add new atom with the specified atomic number and position.
bool BondListIsDirty
The graph superclass does not provide fast random access to the edge (bond) data.
vtkBond GetBond(vtkIdType bondId)
Return a vtkAtom that refers to the bond with the specified id.
static vtkMolecule * GetData(vtkInformationVector *v, int i=0)
Retrieve a molecule from an information vector.
int Initialize(vtkMolecule *molecule)
Use input molecule points, atomic number and atomic data to initialize the new molecule.
char * AtomicNumberArrayName
void AllocateBondGhostArray()
Allocate ghost array for bonds.
vtkUnsignedShortArray * GetBondOrdersArray()
Access the raw arrays used in this vtkMolecule instance.
virtual void CopyStructureInternal(vtkMolecule *m, bool deep)
Copy bonds and atoms.
static vtkMolecule * New()
static vtkMolecule * GetData(vtkInformation *info)
Retrieve a molecule from an information vector.
vtkUnsignedCharArray * GetBondGhostArray()
Get the array that defines the ghost type of each bond.
void SetAtomPosition(vtkIdType atomId, double pos[3])
Set the position of the atom with the specified id.
vtkIdType GetNumberOfAtoms()
Return the number of atoms in the molecule.
vtkVector3d LatticeOrigin
bool CheckedShallowCopy(vtkGraph *g) override
Performs the same operation as ShallowCopy(), but instead of reporting an error for an incompatible g...
bool CheckedDeepCopy(vtkGraph *g) override
Performs the same operation as DeepCopy(), but instead of reporting an error for an incompatible grap...
vtkDataSetAttributes * GetBondData()
Return the EdgeData of the underlying graph.
vtkMatrix3x3 * GetLattice()
Get the unit cell lattice vectors.
vtkAtom AppendAtom(unsigned short atomicNumber, double pos[3])
Add new atom with the specified atomic number and position.
perform various plane computations
represent and manipulate 3D points
dynamic, self-adjusting array of unsigned char
dynamic, self-adjusting array of unsigned short