Ignore:
Timestamp:
May 25, 2016, 7:13:57 AM (9 years ago)
Author:
Frederik Heber <heber@…>
Children:
81557e
Parents:
3b6956
git-author:
Frederik Heber <heber@…> (05/10/16 18:33:50)
git-committer:
Frederik Heber <heber@…> (05/25/16 07:13:57)
Message:

Revert "Trimmed down SphericalPointDistribution to what is needed at the moment."

This reverts commit 0241c59e7f10c73f87336715af0aadac2b2d4db1.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Actions/AtomAction/SaturateAction.cpp

    r3b6956 rd468b5  
    7777        "ChangeElementAction::performCall() - mol is still NULL." );
    7878
    79     // add the hydrogens
    80     const Vector AtomsPosition = _atom->getPosition();
    81     double typical_distance = _atom->getType()->getHBondDistance(0);
    82     if (typical_distance == -1.)
    83       typical_distance = 1.;
    84     SphericalPointDistribution PointSphere(typical_distance);
    85     PointSphere.initSelf(_atom->getType()->getNoValenceOrbitals());
    86     for (SphericalPointDistribution::Polygon_t::const_iterator iter = PointSphere.points.begin();
    87         iter != PointSphere.points.end(); ++iter) {
    88       // for every Vector add a point relative to atom's position
    89       atom * hydrogenAtom = World::getInstance().createAtom();
    90       hydrogenAtom->setType(hydrogen);
    91       hydrogenAtom->setPosition(AtomsPosition + *iter);
    92       mol->AddAtom(hydrogenAtom);
    93       // add bond
    94       _atom->addBond(WorldTime::getTime(), hydrogenAtom);
    95       // mark down for undo state
    96       addedHydrogens.push_back(AtomicInfo(*(hydrogenAtom)));
    97     }
     79//    // add the hydrogens
     80//    const Vector AtomsPosition = _atom->getPosition();
     81//    double typical_distance = _atom->getType()->getHBondDistance(0);
     82//    if (typical_distance == -1.)
     83//      typical_distance = 1.;
     84//    SphericalPointDistribution PointSphere(typical_distance);
     85//    PointSphere.initSelf(_atom->getType()->getNoValenceOrbitals());
     86//    for (SphericalPointDistribution::Polygon_t::const_iterator iter = PointSphere.points.begin();
     87//        iter != PointSphere.points.end(); ++iter) {
     88//      // for every Vector add a point relative to atom's position
     89//      atom * hydrogenAtom = World::getInstance().createAtom();
     90//      hydrogenAtom->setType(hydrogen);
     91//      hydrogenAtom->setPosition(AtomsPosition + *iter);
     92//      mol->AddAtom(hydrogenAtom);
     93//      // add bond
     94//      _atom->addBond(WorldTime::getTime(), hydrogenAtom);
     95//      // mark down for undo state
     96//      addedHydrogens.push_back(AtomicInfo(*(hydrogenAtom)));
     97//    }
    9898  }
    9999
Note: See TracChangeset for help on using the changeset viewer.