101 const std::function<
bool()> &cancelled = {},
102 int maximumVertices = 50000,
int maximumFeatures = 500);
The Qt-facing MeshKit API (meshkit::core_qt, meshkit::model_qt, meshkit::io_qt): mesh value types and...
ConstraintPreview makeConstraintPreview(const QVector< SimplificationFeature > &original, const ConstraintSimplificationResult &candidate, const std::function< bool()> &cancelled={}, int maximumVertices=50000, int maximumFeatures=500)
Build bounded display data comparing source features with a simplification candidate.
Definition constraintpreview.cpp:9
Display data for one feature of a constraint-simplification preview.
Definition constraintpreview.h:9
quint64 removedCount
SimplificationChange::removed of the feature.
Definition constraintpreview.h:30
bool displayReduced
original, proposed or removed holds fewer points than the full data.
Definition constraintpreview.h:47
double areaChange
SimplificationChange::areaChange (squared XY units).
Definition constraintpreview.h:37
QVector< QPointF > original
Original XY vertices; when longer than the per-path display budget, evenly subsampled by index,...
Definition constraintpreview.h:23
quint64 verticesBefore
Full original vertex count, including a repeated closing vertex.
Definition constraintpreview.h:30
QVector< QPointF > proposed
Candidate XY vertices, subsampled the same way.
Definition constraintpreview.h:23
QString label
Source label, or id when the label is empty.
Definition constraintpreview.h:14
QString id
SimplificationFeature::id of the source feature.
Definition constraintpreview.h:14
bool rolledBack
SimplificationChange::rolledBack of the feature.
Definition constraintpreview.h:47
double maxDeviation
SimplificationChange::maxDeviation (XY units).
Definition constraintpreview.h:37
QVector< QPointF > removed
A sample of the original vertices the candidate removed, for markers; at most 100 per feature within ...
Definition constraintpreview.h:23
bool closed
The source is a ring: its closed flag is set or its first and last vertices are exactly equal.
Definition constraintpreview.h:47
double maxZDeviation
SimplificationChange::maxZDeviation (elevation units).
Definition constraintpreview.h:37
quint64 verticesAfter
Full candidate vertex count.
Definition constraintpreview.h:30
bool budgetRetained
SimplificationChange::budgetRetained of the feature.
Definition constraintpreview.h:47
Bounded display summary of a simplification candidate, built by makeConstraintPreview().
Definition constraintpreview.h:54
QVector< ConstraintPreviewFeature > features
Displayed features: changed ones (vertices removed, rolled back or budget-retained) first in input or...
Definition constraintpreview.h:57
quint64 verticesAfter
Candidate vertex count over all features.
Definition constraintpreview.h:67
bool displayReduced
Some features, vertices or removed-vertex markers are not displayed.
Definition constraintpreview.h:72
quint64 verticesBefore
Original vertex count over all features.
Definition constraintpreview.h:67
quint64 featuresTotal
Number of source features.
Definition constraintpreview.h:67
QString horizontalUnit
XY unit label for display; left empty by makeConstraintPreview().
Definition constraintpreview.h:77
quint64 removedTotal
Sum of SimplificationChange::removed over all features.
Definition constraintpreview.h:67
QString verticalUnit
Elevation unit label for display; left empty by makeConstraintPreview().
Definition constraintpreview.h:77
bool cancelled
Building stopped on cancellation; the other fields are partial.
Definition constraintpreview.h:72
QRectF bounds
XY extent of all original vertices; a default QRectF when there are none.
Definition constraintpreview.h:58
Output of simplifyConstraints(); features and changes are parallel to the input.
Definition constraintsimplifier.h:186