Here's the doxygen docs. I'll check it in once I've checked the HTML. Note that I've changed the method to return a bool (this method will be new in 2.3).
/** * Convert a molecule's Tetrahedral Stereo objects to a series of hash or * wedge bonds. Note that the molecule itself is not modified; the result * is returned in the maps @param updown and @param from, which indicate * the origin and direction of each hash or wedge bond. * * When converting, the following guidelines are followed when trying to * find the best candidate bond to set up/down for each tetrahedral stereo * object: * 1. **Should not already be set** * 2. Should not be connected to a 2nd tet center * (this is acceptable in theory, as the wedge is only at one end but * it may cause confusion and thus we avoid it) * 3. Preferably is not in a cycle * 4. Preferably is a terminal H * * If no bond can be found that matches all of these rules (and there is * a slim possibility of this at the moment) then an error message is logged * and the function returns false. * * @param mol The molecule. * @param updown A map of OBStereo::BondDirection for each hash/wedge bond * @param from A map of OBStereo::Ref indicate the origin of each hash/wedge bond * * @since version 2.3 */ OBAPI bool TetStereoTo0D(OBMol &mol, std::map<OBBond*, enum OBStereo::BondDirection> &updown, std::map<OBBond*, OBStereo::Ref> &from); This function is called from inchiformat and mdlformat. - Noel On 23 August 2010 18:11, Noel O'Boyle <baoille...@gmail.com> wrote: > On 23 August 2010 15:43, Chris Morley <c.mor...@gaseq.co.uk> wrote: >> I'm trying to get wedge and hash bonds displayed in SVGFormat, >> starting with a 0D molecule. (Note the new SMILES input.) >> >> This doesn't: >> obabel -:b...@h](F)I --gen2D -O out.svg >> >> This does: >> obabel -:b...@h](F)I -omol --gen2D -xw | obabel -imol -O out.svg >> >> This doesn't: >> obabel -:b...@h](F)I -omol --gen2D | obabel -imol -O out.svg >> >> So presumably calling TetStereoTo0D() does the job and it really >> should be called in --gen2D. There is a lack of documentation "(HASSLE >> NOEL ABOUT THIS!!)" and I don't understand where the parameter >> std::map<OBBond*, OBStereo::Ref> &from should come from. >> >> Can anybody help? > > Consider me hassled. I'll write these docs in the next few minutes > once I figure it out. > >> I also guess we could talk about why it is necessary for >> >> obabel -:b...@h](F)I -omol | obabel -imol -osmi >> >> to drop the stereo information. > > Discussed at > http://baoilleach.blogspot.com/2010/02/how-to-store-stereochemistry-in-mol.html. > I don't think it's neccessary to drop the stereo but the spec says to > do it. I added the "s" option to MDL to enable the atom stereo parity > to be optionally retained. Hopefully this works for you. > >> Chris >> >> >> ------------------------------------------------------------------------------ >> This SF.net email is sponsored by >> >> Make an app they can't live without >> Enter the BlackBerry Developer Challenge >> http://p.sf.net/sfu/RIM-dev2dev >> _______________________________________________ >> OpenBabel-Devel mailing list >> OpenBabel-Devel@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/openbabel-devel >> > ------------------------------------------------------------------------------ Sell apps to millions through the Intel(R) Atom(Tm) Developer Program Be part of this innovative community and reach millions of netbook users worldwide. Take advantage of special opportunities to increase revenue and speed time-to-market. Join now, and jumpstart your future. http://p.sf.net/sfu/intel-atom-d2d _______________________________________________ OpenBabel-Devel mailing list OpenBabel-Devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbabel-devel