The Molecule class - This class represents a molecule. It consists of atoms and bonds.
More...
#include <Molecule.h>
Inherits SceneObject.
|
| std::vector< Atom > * | atoms |
| | atoms - Contains information of all atoms-> Stores all the atoms in this molecule. More...
|
| |
| QMatrix4x4 | modelMatrix |
| |
The Molecule class - This class represents a molecule. It consists of atoms and bonds.
| Molecule::Molecule |
( |
QMatrix4x4 |
_modelMatrix | ) |
|
| void Molecule::centerMolecule |
( |
QVector3D |
center | ) |
|
centerMolecule - Resets the molecule to the center in world space (0, 0 ,0). This method must be called before initGL. Otherwise the new positions will not be updated on the GPU
- Parameters
-
draw - Draws the corresponding VBO to the screen
- Parameters
-
| type | - enumeration component specifying the type of this draw |
| QVector3D Molecule::findCameraTranslation |
( |
| ) |
|
findCameraTranslation
- Returns
- calculate by which distance the camera needs to be translated along positive Z-axis, so that user can see whole model at once
| QVector3D Molecule::findChainColor |
( |
int |
chainID | ) |
|
findChainColor
- Parameters
-
- Returns
- Finds the corresponding chain color of the atom with the given id
| QVector3D Molecule::findColor |
( |
std::string |
atomName | ) |
|
findColor
- Parameters
-
- Returns
- Finds the corresponging color and radius of the atom name. If not found the function returns a basic 4D vector containing ones (WHITE)
| QVector3D Molecule::findMoleculeCenter |
( |
| ) |
|
findMoleculeCenter
- Returns
- Determines the center of the molecule, e.g. the center of the surrounding bounding sphere
| float Molecule::findRadius |
( |
std::string |
atomName, |
|
|
RadiusEnum |
radiusType |
|
) |
| |
findRadius
- Parameters
-
- Returns
- Return the radius of the atom with the given name and type
| float Molecule::getBoundingSphereRadius |
( |
| ) |
|
getBoundingSphereRadius
- Returns
- Returns the radius of the bounding sphere
| void Molecule::initGL |
( |
QOpenGLShaderProgram * |
mainShader, |
|
|
QOpenGLShaderProgram * |
shadowMapShader, |
|
|
QOpenGLShaderProgram * |
ambientOcclusionMapShader, |
|
|
QOpenGLShaderProgram * |
edgeShader, |
|
|
QOpenGLShaderProgram * |
haloShader |
|
) |
| |
initGL - Initializes the communication with opengl
- Parameters
-
| mainShader | |
| shadowMapShader | |
| ambientOcclusionMapShader | |
| edgeShader | |
| haloShader | |
| std::vector<Atom>* Molecule::atoms |
atoms - Contains information of all atoms-> Stores all the atoms in this molecule.
The documentation for this class was generated from the following files: