-
-
Notifications
You must be signed in to change notification settings - Fork 851
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handle case when Foreground image overhangs bottom of background image during DrawImage Call (3.1 target) #2610
Conversation
9cced1a
to
ec55081
Compare
Thanks for fixing this. We'll need to PR this against release/v3.1.x here also as well as update the ImageBrush to allow negative offsetting since it does the same thing. |
👍 i'll rebaseline the PRs against the 3.1 branch this weekend. Regarding |
Thanks, appreciate it. See here for what I mean with the ImageBrush. It does the same reset of the position when given negative location. That’s why I exposed the rectangle constructor. |
src/ImageSharp/Processing/Processors/Drawing/DrawImageProcessor{TPixelBg,TPixelFg}.cs
Outdated
Show resolved
Hide resolved
src/ImageSharp/Processing/Processors/Drawing/DrawImageProcessor{TPixelBg,TPixelFg}.cs
Outdated
Show resolved
Hide resolved
managed to reduce it to a single pair of clamping operations to solve the ArgumentOutOfRange exception. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work here!
Prerequisites
Description
Prevents the
ArgumentOutOfRangeException
when the area of interest of the foreground image will be drawn past the edge of the bounds of the background image.fixes #2603
related to #2609
Targeting 3.1 release branch