Constructor
new AtomImage(model, index, ijk)
Name | Type | Description |
---|---|---|
model | Model | The model from which the image is from |
index | int | Index of the atom in the model |
ijk | Array | Indices of the cell in which the image is located |
Members
(readonly) aura :AuraMesh
Aura used to highlight this atom image
- AuraMesh
baseRadius :float
Starting radius of the atom
- float
(readonly) bondedAtoms :Array.<AtomImage>
All atoms bonded to this atom
- Array.<AtomImage>
(readonly) bonds :Array.<BondImage>
All bonds connected to this atom
- Array.<BondImage>
(readonly) bondsFrom :Array.<BondImage>
Bonds from this atom
- Array.<BondImage>
(readonly) bondsTo :Array.<BondImage>
Bonds to this atom
- Array.<BondImage>
color :int
Color of the atom
- int
(readonly) cpkColor :int
Hex integer code of the conventional CPK color used for this element (altered in case of non-standard isotopes)
- int
(readonly) crystLabel :String
Crystal site label of this atom
- String
(readonly) element :String
Symbol of this atom's element
- String
(readonly) elementData :Object
Periodic table information for this atom's element
- Object
(readonly) fxyz :Array.<float>
Fractional coordinates of this atom image
- Array.<float>
(readonly) fxyz0 :Array.<float>
Fractional coordinates of this atom's original
- Array.<float>
highlighted :bool
Whether the atom is highlighted
- bool
(readonly) id :String
String ID of the image
- String
(readonly) ijk :Array.<int>
Cell indices of this atom image
- Array.<int>
(readonly) imgIndex :int
Index of this image
- int
(readonly) index :int
Index of the atom
- int
isotope :int
Atomic mass of this atom's isotope
- int
(readonly) isotopeData :Object
Information for this atom's isotope
- Object
isotopeGlobal :int
Atomic mass of the global isotope set as default for this atom's species
- int
(readonly) mesh :AtomMesh
Mesh corresponding to this atom image
- AtomMesh
(readonly) model :Model
Model this atom belongs to
- Model
(readonly) moleculeIndex :int
Index of the molecule this atom belongs to
- int
(readonly) number :int
Atomic number of element
- int
opacity :float
Opacity of the atom
- float
radius :float
Final radius of the atom (starting radius * scale)
- float
(readonly) renderer :Renderer
Renderer used by this atom
- Renderer
scale :float
Scale of the atom
- float
(readonly) speciesIndex :int
Index of the species of this atom
- int
(readonly) vdwRadius :float
Van dew Waals radius for this element
- float
visible :bool
Whether the atom is visible
- bool
(readonly) xyz :Array.<float>
Position of this atom image
- Array.<float>
(readonly) xyz0 :Array.<float>
Position of this atom's original
- Array.<float>
Methods
addEllipsoid(data, name, parameters)
Add an ellipsoid to the atom.
Name | Type | Description |
---|---|---|
data | TensorData | | The data to base the ellipsoid on. Can be: - a TensorData object; - an Object with 'eigenvalues' and 'eigenvectors' members - an Array of the form [eigenvalues, eigenvectors] |
name | String | Name of the ellipsoid |
parameters | Object | Additional options to pass (see EllipsoidMesh) |
addLabel(text, name, parameters)
Add a text label to the atom.
Name | Type | Description |
---|---|---|
text | String | Content of the label |
name | String | Name to use to refer to the label (necessary to overwrite/erase later) |
parameters | Object | Dictionary of other options (e.g. font family, text color, etc. See TextSprite) |
ellipsoidProperty(name, property, value)
Retrieve or set an ellipsoid's properties
Name | Type | Default | Description |
---|---|---|---|
name | String | Name of the ellipsoid | |
property | String | Property to set | |
value | ? | null | Value to set. If omitted, returns the current value instead. |
getArrayValue(name) → {*}
Get the value for one array for this image
Name | Type | Description |
---|---|---|
name | String | Name of the array |
Value of the array for this atom
- Type:
- *
labelProperty(name, property, value)
Retrieve or set a label's properties
Name | Type | Default | Description |
---|---|---|---|
name | String | Name of the label | |
property | String | Property to set | |
value | ? | null | Value to set. If omitted, returns the current value instead. |
removeEllipsoid(name)
Remove the ellipsoid with a given name
Name | Type | Description |
---|---|---|
name | String | Name of the ellipsoid |
removeLabel(name)
Remove the label of a given name
Name | Type | Description |
---|---|---|
name | String | Name of the label |