Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

RecolorBrush - Limit access to target dimensions - #350

#350
Merged
JimBobSquarePants merged 2 commits into
mainSixLabors/ImageSharp.Drawing:mainfrom
js/issue-348SixLabors/ImageSharp.Drawing:js/issue-348Copy head branch name to clipboard
Jan 8, 2025
Merged

RecolorBrush - Limit access to target dimensions#350
JimBobSquarePants merged 2 commits into
mainSixLabors/ImageSharp.Drawing:mainfrom
js/issue-348SixLabors/ImageSharp.Drawing:js/issue-348Copy head branch name to clipboard

Conversation

@JimBobSquarePants

@JimBobSquarePants JimBobSquarePants commented Jan 8, 2025

Copy link
Copy Markdown
Member

Prerequisites

  • I have written a descriptive pull-request title
  • I have verified that there are no overlapping pull-requests open
  • I have verified that I am following matches the existing coding patterns and practice as demonstrated in the repository. These follow strict Stylecop rules 👮.
  • I have provided test coverage for my change (where applicable)

Description

RecolorBrush didn't take transforms into consideration. I've not added an explicit test but here's the output from the samples project. Fixes #348

wrapped

@JimBobSquarePants JimBobSquarePants added the bug Something isn't working label Jan 8, 2025

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 1 out of 2 changed files in this pull request and generated 1 comment.

Files not reviewed (1)
  • ImageSharp.Drawing.sln: Language not supported

Span<float> amounts = this.blenderBuffers.AmountSpan[..scanline.Length];
Span<TPixel> overlays = this.blenderBuffers.OverlaySpan[..scanline.Length];

int width = this.Target.Width;

Copilot AI Jan 8, 2025

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The variable 'width' is declared but not used. It should be removed to avoid confusion.

Suggested change
int width = this.Target.Width;
// int width = this.Target.Width;

Copilot uses AI. Check for mistakes.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nearly correct. It's best to delete than comment out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

error demo:Sample-DrawWaterMarkOnImage-LongText

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.