extract: add option to treat width and height as "maximum" rather than absolute values
Open
Nobody has claimed this yet.
enhancement
- Dominant language
- JavaScript
- Stars
- 32.7k
- Forks
- 1.4k
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 5
Description
If we try to extract more pixels than has an image - we will get "extract_area: bad extract area"
Can we ignore exception and extract an actual pixels? I don't want calculate if image.width < etc.. i suppose it should be in a core. May be additional option?
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
Start by tracing the extract entry point to libvips's extract_area failure and checking how width and height are currently passed. Done means an explicit option treats those dimensions as maximums, returns the available pixels when they exceed the image, and avoids the bad extract area error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, nodejs
- Domain
- backend, computer-graphics
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100