Incorrect results of model.combine
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- typescript
- Domain
- computer-graphics
Research direction
Start by running the supplied model.combineSubtraction example and inspect the model.combine and exporter.toSVG entry points. Compare the subtraction result with the SVG output to determine where the stray polygon lines remain. Done means subtracting the polygon from the circle produces no visible lines outside the resulting shape.
Written by the indexing model from the issue text.
Description
Hello,
I came across a problem with a strange behaviour of model.combine. I have a circle and a polygon made of lines, and when I try to subtract the polygon from a circle, then a couple of lines stay visible outside of the result shape.
var circle = {
type: 'circle',
origin: [-122, -154],
radius: 402.7,
units: 'cm'
};
var modelCircle = { paths: { myCircle: circle } };
var line1 = {
type: 'line',
origin: [-500, -399],
end: [-499, 201]
};
var line2 = {
type: 'line',
origin: [-499, 201] ,
end: [-670, -136]
};
var line3 = {
type: 'line',
origin: [-670, -136] ,
end: [-500, -399]
};
var modelLinien = { paths: { myLine1: line1, myLine2: line2, myLine3: line3 } };
rootModel = m.model.combineSubtraction(modelCircle, modelLinien);
// same result
rootModel2 = m.model.combine(
modelCircle,
modelLinien,
false,
true,
true,
false
);
var svg = m.exporter.toSVG(rootModel);
document.write(svg);

- Dominant language
- TypeScript
- Stars
- 2k
- Forks
- 302
- Avg merge
- 21h 28m
- Merged PRs (30d)
- 5
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/maker.js
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
-
Difficulty 4/5 3-5 days Newbie friendliness 42/100
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
-
Difficulty 3/5 1-2 days Newbie friendliness 42/100
All issues in microsoft/maker.js
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
bug clawsweeper:linked-pr-open clawsweeper:needs-live-repro clawsweeper:no-new-fix-pr impact:message-loss issue-rating: 🐚 platinum hermit P2 regression
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
fullcalendar/fullcalendar#8106 ·