2 writes to Scan0
System.Drawing.Common.Tests (2)
System\Drawing\BitmapTests.cs (1)
1214
data.
Scan0
= IntPtr.Zero;
System\Drawing\Imaging\BitmapDataTests.cs (1)
67
Scan0
= new IntPtr(value)
81 references to Scan0
PresentationFramework-SystemDrawing (1)
SystemDrawingExtension.cs (1)
184
bmData.
Scan0
,
System.Drawing.Common.Tests (70)
DrawingTest.cs (1)
19
new ReadOnlySpan<byte>((void*)data.
Scan0
, data.Stride * data.Height),
mono\System.Drawing.Imaging\BmpCodecTests.cs (1)
253
byte* scan = (byte*)data.
Scan0
;
mono\System.Drawing.Imaging\GifCodecTests.cs (1)
120
byte* scan = (byte*)data.
Scan0
;
mono\System.Drawing.Imaging\IconCodecTests.cs (5)
142
byte* scan = (byte*)data.
Scan0
;
338
byte* scan = (byte*)data.
Scan0
;
556
byte* scan = (byte*)data.
Scan0
;
760
byte* scan = (byte*)data.
Scan0
;
1535
byte* scan = (byte*)data.
Scan0
;
mono\System.Drawing.Imaging\JpegCodecTests.cs (2)
122
byte* scan = (byte*)data.
Scan0
;
238
byte* scan = (byte*)data.
Scan0
;
mono\System.Drawing.Imaging\PngCodecTests.cs (3)
156
byte* scan = (byte*)data.
Scan0
;
308
byte* scan = (byte*)data.
Scan0
;
480
byte* scan = (byte*)data.
Scan0
;
mono\System.Drawing.Imaging\TiffCodecTests.cs (1)
130
byte* scan = (byte*)data.
Scan0
;
mono\System.Drawing\BitmapTests.cs (26)
78
Assert.NotEqual(nint.Zero, bd.
Scan0
);
98
Assert.False(nint.Zero.Equals(data.
Scan0
));
220
Marshal.Copy(bd.
Scan0
, data, 0, size);
418
nint src_ptr = (nint)(y * data.Stride + data.
Scan0
.ToInt64());
509
long pos = bd.
Scan0
.ToInt64();
683
pixel_value = Marshal.ReadByte(data.
Scan0
, 0);
684
pixel_value |= Marshal.ReadByte(data.
Scan0
, 1) << 8;
685
pixel_value |= Marshal.ReadByte(data.
Scan0
, 2) << 16;
686
pixel_value |= Marshal.ReadByte(data.
Scan0
, 3) << 24;
694
Marshal.WriteByte(data.
Scan0
, 0, blue.B);
695
Marshal.WriteByte(data.
Scan0
, 1, blue.G);
696
Marshal.WriteByte(data.
Scan0
, 2, blue.R);
697
Marshal.WriteByte(data.
Scan0
, 3, blue.A);
713
Marshal.WriteByte(data.
Scan0
, 0, blue.B);
714
Marshal.WriteByte(data.
Scan0
, 1, blue.G);
715
Marshal.WriteByte(data.
Scan0
, 2, blue.R);
716
Marshal.WriteByte(data.
Scan0
, 3, blue.A);
736
byte b = Marshal.ReadByte(data.
Scan0
, 0);
737
byte g = Marshal.ReadByte(data.
Scan0
, 1);
738
byte r = Marshal.ReadByte(data.
Scan0
, 2);
742
Marshal.WriteByte(data.
Scan0
, 0, blue.B);
743
Marshal.WriteByte(data.
Scan0
, 1, blue.G);
744
Marshal.WriteByte(data.
Scan0
, 2, blue.R);
757
Marshal.WriteByte(data.
Scan0
, 0, blue.B);
758
Marshal.WriteByte(data.
Scan0
, 1, blue.G);
759
Marshal.WriteByte(data.
Scan0
, 2, blue.R);
System\Drawing\BitmapTests.cs (26)
1117
Assert.Equal(IntPtr.Zero, bitmapData.
Scan0
);
1138
Assert.Equal(IntPtr.Zero, bitmapData.
Scan0
);
1167
Assert.Equal(IntPtr.Zero, bitmapData.
Scan0
);
1179
Assert.Equal(IntPtr.Zero, bitmapData.
Scan0
);
1352
Marshal.Copy(bitmapData.
Scan0
, data, 0, size);
1477
int pixelValue = Marshal.ReadByte(data.
Scan0
, 0);
1478
pixelValue |= Marshal.ReadByte(data.
Scan0
, 1) << 8;
1479
pixelValue |= Marshal.ReadByte(data.
Scan0
, 2) << 16;
1480
pixelValue |= Marshal.ReadByte(data.
Scan0
, 3) << 24;
1488
Marshal.WriteByte(data.
Scan0
, 0, blue.B);
1489
Marshal.WriteByte(data.
Scan0
, 1, blue.G);
1490
Marshal.WriteByte(data.
Scan0
, 2, blue.R);
1491
Marshal.WriteByte(data.
Scan0
, 3, blue.A);
1507
Marshal.WriteByte(data.
Scan0
, 0, blue.B);
1508
Marshal.WriteByte(data.
Scan0
, 1, blue.G);
1509
Marshal.WriteByte(data.
Scan0
, 2, blue.R);
1510
Marshal.WriteByte(data.
Scan0
, 3, blue.A);
1530
byte b = Marshal.ReadByte(data.
Scan0
, 0);
1531
byte g = Marshal.ReadByte(data.
Scan0
, 1);
1532
byte r = Marshal.ReadByte(data.
Scan0
, 2);
1535
Marshal.WriteByte(data.
Scan0
, 0, blue.B);
1536
Marshal.WriteByte(data.
Scan0
, 1, blue.G);
1537
Marshal.WriteByte(data.
Scan0
, 2, blue.R);
1550
Marshal.WriteByte(data.
Scan0
, 0, blue.B);
1551
Marshal.WriteByte(data.
Scan0
, 1, blue.G);
1552
Marshal.WriteByte(data.
Scan0
, 2, blue.R);
System\Drawing\GraphicsTests.cs (2)
2906
ReadOnlySpan<byte> bytes = new((byte*)data.
Scan0
, data.Stride * data.Height);
2920
ReadOnlySpan<byte> bytes = new((byte*)data.
Scan0
, data.Stride * data.Height);
System\Drawing\Imaging\BitmapDataTests.cs (2)
15
Assert.Equal(IntPtr.Zero, bd.
Scan0
);
69
Assert.Equal(new IntPtr(value), bd.
Scan0
);
System.Windows.Forms (5)
System\Windows\Forms\Controls\ImageList\ImageList.cs (3)
562
IntPtr srcPtr = sourceData.
Scan0
+ offsetSrc;
563
IntPtr destPtr = targetData.
Scan0
+ offsetDest;
583
byte* candidate = ((byte*)bmpData.
Scan0
.ToPointer()) + offsetRow + j;
System\Windows\Forms\Rendering\ControlPaint.cs (2)
272
Debug.Assert(data.
Scan0
!= 0, "BitmapData.Scan0 is null; check marshalling");
274
ReadOnlySpan<ARGB> colors = new((ARGB*)data.
Scan0
, width * height);
System.Windows.Forms.Design (1)
System\Windows\Forms\Design\DesignerUtils.cs (1)
676
int* pPixels = (int*)data.
Scan0
;
System.Windows.Forms.Tests (2)
System\Windows\Forms\DataObject_BitmapBinderTests.cs (2)
73
ReadOnlySpan<byte> originalBytes = new((byte*)originalData.
Scan0
, originalData.Stride * originalData.Height);
74
ReadOnlySpan<byte> deserializedBytes = new((byte*)deserializedData.
Scan0
, deserializedData.Stride * deserializedData.Height);
System.Windows.Forms.UI.IntegrationTests (2)
Infra\ScreenRecordService.cs (2)
274
previousImageData = new ReadOnlySpan<uint>((void*)lockedBitmaps[previousFrameBufferIndex].data.
Scan0
, totalLockedPixels);
275
currentImageData = new ReadOnlySpan<uint>((void*)lockedBitmaps[currentFrameBufferIndex].data.
Scan0
, totalLockedPixels);