Inkscape
Vector Graphics Editor
|
Basic mathematical objects such as intervals and points. More...
Classes | |
class | Geom::Angle |
Wrapper for angular values. More... | |
class | Geom::AngleInterval |
Directed angular interval. More... | |
class | Geom::GenericInterval< C > |
A range of numbers which is never empty. More... | |
class | Geom::GenericOptInterval< C > |
A range of numbers that can be empty. More... | |
class | Geom::GenericRect< C > |
Axis aligned, non-empty, generic rectangle. More... | |
class | Geom::GenericOptRect< C > |
Axis-aligned generic rectangle that can be empty. More... | |
class | Geom::IntPoint |
Two-dimensional point with integer coordinates. More... | |
class | Geom::Interval |
Range of real numbers that is never empty. More... | |
class | Geom::OptInterval |
Range of real numbers that can be empty. More... | |
class | Geom::Ray |
Straight ray from a specific point to infinity. More... | |
class | Geom::Rect |
Axis aligned, non-empty rectangle. More... | |
class | Geom::OptRect |
Axis-aligned rectangle that can be empty. More... | |
class | Geom::Line |
Infinite line on a plane. More... | |
class | Geom::Point |
Two-dimensional point that doubles as a vector. More... | |
Typedefs | |
using | Geom::Coord = double |
Floating point type used to store coordinates. | |
using | Geom::IntCoord = int |
Type used for integral coordinates. | |
using | Geom::IntInterval = GenericInterval< IntCoord > |
Range of integers that is never empty. | |
using | Geom::OptIntInterval = GenericOptInterval< IntCoord > |
Range of integers that can be empty. | |
Enumerations | |
enum | Geom::Dim2 { Geom::X = 0 , Geom::Y = 1 } |
2D axis enumeration (X or Y). More... | |
Functions | |
constexpr Dim2 | Geom::other_dimension (Dim2 d) |
Get the other (perpendicular) dimension. | |
constexpr Coord | Geom::infinity () |
Get a value representing infinity. | |
bool | Geom::are_near (Coord a, Coord b, double eps=EPSILON) |
Nearness predicate for values. | |
constexpr Coord | Geom::lerp (Coord t, Coord a, Coord b) |
Numerically stable linear interpolation. | |
Variables | |
constexpr Coord | Geom::EPSILON = 1e-6 |
Default "acceptably small" value. | |
Basic mathematical objects such as intervals and points.
2Geom has several basic geometrical objects: points, lines, intervals, angles, and others. Most of those objects can be treated as sets of points or numbers satisfying some equation or as functions.
typedef double Geom::Coord |
typedef int Geom::IntCoord |
typedef GenericInterval< IntCoord > Geom::IntInterval |
typedef GenericOptInterval< IntCoord > Geom::OptIntInterval |
enum Geom::Dim2 |
|
constexpr |
Get a value representing infinity.
Definition at line 88 of file coord.h.
Referenced by Inkscape::DrawingShape::_pickItem(), BlurKnotHolderEntity::_pos(), Inkscape::CanvasItemGridXY::_render(), Inkscape::CanvasItemCatchall::_update(), Inkscape::CanvasItemGridXY::_update(), Inkscape::CanvasItemGridTiles::_update(), Inkscape::CanvasItemGridAxonom::_update(), Inkscape::CanvasItemGuideLine::_update(), Inkscape::LivePathEffect::LPEOffset::addKnotHolderEntities(), Proj::Pt2::affine(), Geom::PathVector::allNearestTimes(), Geom::at_infinity(), box3d_snap(), Inkscape::CanvasItemBpath::closest_distance_to(), Inkscape::CanvasItemCurve::closest_distance_to(), SnapManager::constrainedSnap(), Inkscape::do_offset(), Inkscape::do_offset(), Inkscape::LivePathEffect::LPEOffset::doAfterEffect(), Inkscape::LivePathEffect::LPEMeasureSegments::doBeforeEffect(), Inkscape::LivePathEffect::LPESlice::doBeforeEffect(), Inkscape::LivePathEffect::LPEFillBetweenMany::doEffect(), Inkscape::LivePathEffect::LPEOffset::doEffect_path(), GrDrag::dropColor(), Inkscape::LivePathEffect::LPEEmbroderyStitchOrdering::OrderingPoint::FindNearest2(), SnapManager::freeSnap(), SPBox3D::get_center_screen(), SPBox3D::get_corner_screen(), Inkscape::LivePathEffect::LPEOffset::get_default_point(), Proj::TransfMat3x4::get_infinite_angle(), Inkscape::LivePathEffect::get_nearest_point(), Box3D::VanishingPoint::get_pos(), get_scale_transform_for_uniform_stroke(), get_scale_transform_for_variable_stroke(), get_visual_bbox(), Inkscape::SnappedPoint::getDistanceToAlignTarget(), Inkscape::SnappedPoint::getSnapped(), gr_knot_moved_handler(), Inkscape::UI::PathManipulator::insertNodeAtExtremum(), Geom::BezierCurveN< degree >::intersect(), Geom::Ellipse::intersect(), Inkscape::SnappedCurve::intersect(), Inkscape::SnappedLine::intersect(), Inkscape::SnappedCurve::intersect(), Inkscape::SnappedLineSegment::intersect(), Geom::intersection_point(), Inkscape::SnappedPoint::isOtherSnapBetter(), Inkscape::LivePathEffect::FilletChamferKnotHolderEntity::knot_get(), Inkscape::LivePathEffect::PowerStrokePointArrayParamKnotHolderEntity::knot_get(), FilterKnotHolderEntity::knot_get(), Inkscape::LivePathEffect::PowerStrokePointArrayParam::knot_get(), Inkscape::LivePathEffect::LPECurveStitch::LPECurveStitch(), Inkscape::LivePathEffect::LPEOffset::LPEOffset(), Inkscape::Colors::Space::OkLch::max_chroma(), Geom::monotonic_smash_intersect(), SnapManager::multipleConstrainedSnaps(), SnapManager::multipleOfGridPitch(), Geom::nearest_time(), Geom::PathVector::nearestTime(), Proj::Pt2::operator[](), Proj::Pt3::operator[](), Inkscape::LivePathEffect::LPEEmbroderyStitchOrdering::OrderingClosest(), pathv_matrix_point_bbox_wind_distance(), Inkscape::UI::Tools::PencilTool::powerStrokeInterpolate(), Inkscape::UI::Tools::MeasureTool::readMeasurePoint(), Inkscape::LivePathEffect::ArrayParam< StorageType >::readsvg(), Geom::xAx::set(), Geom::xAx::set(), Inkscape::UI::Toolbar::Box3DToolbar::set_button_and_adjustment(), Inkscape::LivePathEffect::LPESimplify::setVersioningData(), smash_intersect(), Inkscape::PureTransform::snap(), Inkscape::SnappedCurve::SnappedCurve(), Inkscape::SnappedCurve::SnappedCurve(), Inkscape::SnappedLine::SnappedLine(), Inkscape::SnappedLine::SnappedLine(), Inkscape::SnappedLineSegment::SnappedLineSegment(), Inkscape::SnappedLineSegment::SnappedLineSegment(), Inkscape::LivePathEffect::LPEOffset::sp_get_offset(), Inkscape::PureScale::storeTransform(), Inkscape::PureStretchConstrained::storeTransform(), Inkscape::PureSkewConstrained::storeTransform(), Inkscape::PureRotateConstrained::storeTransform(), stroke_average_width(), TEST(), and Inkscape::LivePathEffect::LPEKnot::updateSwitcher().
Numerically stable linear interpolation.
Definition at line 97 of file coord.h.
Referenced by Inkscape::UI::Widget::OKWheel::_discColor(), Inkscape::UI::Tools::PencilTool::_sketchInterpolate(), Inkscape::UI::Tools::CalligraphicTool::apply(), Geom::below_x_monotonic_polyline(), Inkscape::UI::Tools::CalligraphicTool::brush(), Geom::casteljau_subdivision(), cubic_length_subdividing(), Geom::PathInterval::inside(), Geom::Circle::intersect(), Geom::detail::bezier_clipping::left_portion(), Inkscape::UI::Widget::lerp(), Geom::Line::pointAt(), Inkscape::Colors::Space::render_hue_scale(), Inkscape::Colors::Space::render_lightness_scale(), Geom::detail::bezier_clipping::right_portion(), Geom::split(), Geom::subdivide(), Inkscape::UI::PathManipulator::subdivideSegment(), TEST(), TEST(), TEST(), Geom::Interval::valueAt(), Geom::Linear::valueAt(), Geom::Line::valueAt(), Geom::LinearOf< T >::valueAt(), Geom::BezierCurveN< degree >::winding(), and wrap_linear().
Get the other (perpendicular) dimension.
Definition at line 52 of file coord.h.
Referenced by Geom::Line::clip(), Geom::Path::extrema(), and Geom::Line::rotationToAxis().
|
constexpr |
Default "acceptably small" value.
Definition at line 84 of file coord.h.
Referenced by Inkscape::UI::ControlPointSelection::_pointDragged(), SPItem::adjust_stroke(), Inkscape::UI::Widget::apply_profile(), SPViewBox::apply_viewbox(), Inkscape::UI::Dialog::Transformation::applyPageSkew(), Geom::bezier_expand_to_image(), Geom::bezier_expand_to_image(), Geom::Interpolate::CentripetalCatmullRomInterpolator::calc_bezier(), Geom::Piecewise< T >::compose(), Inkscape::Extension::Internal::compute_final_page_dimensions(), SPGuide::createSPGuide(), cubic_bbox(), distribute_intersection_times(), Inkscape::LivePathEffect::LPEMirrorSymmetry::doEffect_path(), Inkscape::LivePathEffect::findShadowedTime(), get_scale_transform_for_uniform_stroke(), get_scale_transform_for_variable_stroke(), Geom::Ellipse::intersect(), Geom::Curve::intersectSelf(), item_find_paths(), SPGuide::moveto(), Inkscape::UI::Widget::RegisteredScalarUnit::on_value_changed(), Inkscape::Extension::Internal::PdfBuilder::TextContext::render_text(), Geom::sbasis_to_cubic_bezier(), SPGuide::set(), SPGenericEllipse::set_shape(), sort_and_clean_intersection_times(), sp_svg_read_pathv(), Inkscape::LivePathEffect::LPECopyRotate::split(), and Inkscape::LivePathEffect::LPESlice::splititem().