VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkAtom.h 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00023 #ifndef __vtkAtom_h 00024 #define __vtkAtom_h 00025 00026 #include "vtkObject.h" // For macros, defines, etc 00027 00028 class vtkMolecule; 00029 class vtkVector3d; 00030 class vtkVector3f; 00031 00032 class VTK_FILTERING_EXPORT vtkAtom 00033 { 00034 public: 00035 ~vtkAtom(); 00036 00037 void PrintSelf(ostream &os, vtkIndent indent); 00038 00040 vtkIdType GetId() const; 00041 00043 vtkMolecule * GetMolecule(); 00044 00046 00047 unsigned short GetAtomicNumber() const; 00048 void SetAtomicNumber(unsigned short atomicNum); 00050 00052 00053 void GetPosition(float pos[3]) const; 00054 void GetPosition(double pos[3]) const; 00055 void SetPosition(const float pos[3]); 00056 void SetPosition(float x, float y, float z); 00057 vtkVector3f GetPosition() const; 00058 void SetPosition(const vtkVector3f &pos); 00060 00061 protected: 00062 friend class vtkMolecule; 00063 00064 vtkAtom(vtkMolecule *parent, vtkIdType id); 00065 00066 vtkMolecule *Molecule; 00067 vtkIdType Id; 00068 }; 00069 00070 inline vtkIdType vtkAtom::GetId() const 00071 { 00072 return this->Id; 00073 } 00074 00075 inline vtkMolecule * vtkAtom::GetMolecule() 00076 { 00077 return this->Molecule; 00078 } 00079 00080 #endif