Logo Search packages:      
Sourcecode: inkscape version File versions

std::vector< double > Geom::roots ( SBasis const &  s  ) 

Find all t s.t s(t) = 0

Parameters:
a sbasis function
Returns:
vector of zeros (roots)

Definition at line 366 of file sbasis-roots.cpp.

References sbasis_to_bezier().

                                          {
    switch(s.size()) {
        case 0:
            return std::vector<double>();
        case 1:
            return roots1(s);
        default:
        {
            Bezier bz;
            sbasis_to_bezier(bz, s);
            return bz.roots();
        }
    }
}


Generated by  Doxygen 1.6.0   Back to index