Skip to content

Commit b23707a

Browse files
committed
Use MemoryMarshal.GetReference for rgbStart
1 parent 96edc48 commit b23707a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ImageSharp/Formats/Jpeg/Components/Encoder/RgbForwardConverter{TPixel}.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ public void Convert(int x, int y, ref RowOctet<TPixel> currentRows)
9999

100100
private static void CopyToBlock(Span<Rgb24> rgbSpan, ref Block8x8F redBlock, ref Block8x8F greenBlock, ref Block8x8F blueBlock)
101101
{
102-
ref Rgb24 rgbStart = ref rgbSpan[0];
102+
ref Rgb24 rgbStart = ref MemoryMarshal.GetReference(rgbSpan);
103103

104104
for (int i = 0; i < Block8x8F.Size; i++)
105105
{

0 commit comments

Comments
 (0)