# Visualization Library

A lightweight C++ OpenGL middleware for 2D/3D graphics

[Home] [Tutorials] [All Classes] [Grouped Classes]

Public Member Functions | Protected Attributes

# vl::RingExtractor Class Reference

The RingExtractor class traverses a molecule's graph and detects various types of cycles, mainly used for aromatic ring detection. More...

`#include <RingExtractor.hpp>`

List of all members.

## Public Member Functions

| RingExtractor (Molecule *mol)
void | setMolecule (Molecule *mol)
Molecule * | molecule () const
void | run ()
void | bootstrap ()
void | depthFirstVisit (Atom *atom, std::vector< ref< Atom > > &current_path)
void | keepAromaticCycles ()
void | sortCycles ()
void | keepPlanarCycles (float epsilon)
void | removeDoubles ()
void | keepMinimalCycles ()

## Protected Attributes

Molecule * | mMolecule

## Detailed Description

The RingExtractor class traverses a molecule's graph and detects various types of cycles, mainly used for aromatic ring detection.

Definition at line 44 of file RingExtractor.hpp.

## Constructor & Destructor Documentation

vl::RingExtractor::RingExtractor | ( | Molecule * | mol ) | `[inline]`

Definition at line 47 of file RingExtractor.hpp.

## Member Function Documentation

void vl::RingExtractor::setMolecule | ( | Molecule * | mol ) | `[inline]`

Definition at line 49 of file RingExtractor.hpp.

References mMolecule.

Molecule* vl::RingExtractor::molecule | ( | ) | const`[inline]`

Definition at line 51 of file RingExtractor.hpp.

References mMolecule.

Referenced by bootstrap(), depthFirstVisit(), keepAromaticCycles(), keepMinimalCycles(), keepPlanarCycles(), removeDoubles(), run(), and sortCycles().

void vl::RingExtractor::run | ( | ) | `[inline]`

Definition at line 53 of file RingExtractor.hpp.

References bootstrap(), keepAromaticCycles(), keepMinimalCycles(), molecule(), removeDoubles(), and sortCycles().

void vl::RingExtractor::bootstrap | ( | ) | `[inline]`

Definition at line 66 of file RingExtractor.hpp.

References vl::Molecule::atom(), vl::Molecule::atomCount(), vl::Molecule::computeAtomAdjacency(), depthFirstVisit(), molecule(), and vl::Atom::setVisited().

Referenced by run().

void vl::RingExtractor::depthFirstVisit | ( | Atom * | atom,
|  | std::vector< ref< Atom > > & | current_path
| ) |  | `[inline]`

Definition at line 78 of file RingExtractor.hpp.

References vl::Atom::adjacentAtoms(), vl::Molecule::cycles(), molecule(), vl::Atom::setVisited(), and vl::Atom::visited().

Referenced by bootstrap().

void vl::RingExtractor::keepAromaticCycles | ( | ) | `[inline]`

Definition at line 108 of file RingExtractor.hpp.

References vl::Molecule::bond(), vl::Bond::bondType(), vl::BT_Aromatic, vl::Molecule::cycle(), vl::Molecule::cycles(), and molecule().

Referenced by run().

void vl::RingExtractor::sortCycles | ( | ) | `[inline]`

Definition at line 133 of file RingExtractor.hpp.

References vl::Molecule::cycle(), vl::Molecule::cycles(), vl::Atom::isAtomAdjacent(), and molecule().

Referenced by run().

void vl::RingExtractor::keepPlanarCycles | ( | float | epsilon ) | `[inline]`

Definition at line 155 of file RingExtractor.hpp.

References vl::AABB::center(), vl::Atom::coordinates(), vl::cross(), vl::Molecule::cycle(), vl::Molecule::cycles(), vl::dot(), molecule(), vl::Vector3< T_Scalar >::normalize(), and vl::normalize().

void vl::RingExtractor::removeDoubles | ( | ) | `[inline]`

Definition at line 194 of file RingExtractor.hpp.

References vl::Molecule::cycle(), vl::Molecule::cycles(), and molecule().

Referenced by run().

void vl::RingExtractor::keepMinimalCycles | ( | ) | `[inline]`

Definition at line 206 of file RingExtractor.hpp.

References vl::Molecule::atoms(), vl::Molecule::cycles(), and molecule().

Referenced by run().

## Member Data Documentation

Molecule* vl::RingExtractor::mMolecule`[protected]`

Definition at line 245 of file RingExtractor.hpp.

Referenced by molecule(), and setMolecule().

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

- D:/VL/BuildSystem/VL_DISTRO/Visualization_Library_SDK/src/vlMolecule/RingExtractor.hpp

Visualization Library v2011.09.1162 Reference Documentation
Copyright 2005-2011 Michele Bosi. All rights reserved.
Updated on Thu Jan 26 2012 00:44:59.
Permission is granted to use this page to write and publish articles regarding Visualization Library.