Mapbox line-pattern distorts the image
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 12.4k
- Forks
- 2.4k
- PR merge metrics
- No merged PRs in 30d
Description
I am applying **line-pattern** property to a Line but the result is distorted.
The image width is a factor of two (32 or 64px) and I am using a fixed width for the line (I am not trying to scale it with the zoom - which is much worse btw)
paint: {
'line-pattern':fillPatternName,
'line-width': 32,
},
**Example:**
Here is the pattern: https://imgur.com/a/uJqkkTj
And this is the actual result: https://imgur.com/a/4sj1jgv
As you can see it will create an angle in the pattern and also the repeat is inconsistent as it will start repeating the pattern without finishing the previous pattern draw (overlaping).
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.
Research direction
No source file or test is named. Reproduce the reported case with the provided 32/64px pattern and fixed line-width of 32, then trace the line-pattern rendering path; done means the pattern has no angle distortion and repeats without overlapping or truncating the previous repeat.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, typescript
- Domain
- computer-graphics, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 32/100