@@ -306,7 +306,7 @@ private void ReadRle<TPixel>(BmpCompression compression, Buffer2D<TPixel> pixels
306306 int newY = Invert ( y , height , inverted ) ;
307307 int rowStartIdx = y * width ;
308308 Span < byte > bufferRow = bufferSpan . Slice ( rowStartIdx , width ) ;
309- Span < TPixel > pixelRow = pixels . GetRowSpan ( newY ) ;
309+ Span < TPixel > pixelRow = pixels . DangerousGetRowSpan ( newY ) ;
310310
311311 bool rowHasUndefinedPixels = rowsWithUndefinedPixelsSpan [ y ] ;
312312 if ( rowHasUndefinedPixels )
@@ -377,7 +377,7 @@ private void ReadRle24<TPixel>(Buffer2D<TPixel> pixels, int width, int height, b
377377 for ( int y = 0 ; y < height ; y ++ )
378378 {
379379 int newY = Invert ( y , height , inverted ) ;
380- Span < TPixel > pixelRow = pixels . GetRowSpan ( newY ) ;
380+ Span < TPixel > pixelRow = pixels . DangerousGetRowSpan ( newY ) ;
381381 bool rowHasUndefinedPixels = rowsWithUndefinedPixelsSpan [ y ] ;
382382 if ( rowHasUndefinedPixels )
383383 {
@@ -826,7 +826,7 @@ private void ReadRgbPalette<TPixel>(Buffer2D<TPixel> pixels, byte[] colors, int
826826 int newY = Invert ( y , height , inverted ) ;
827827 this . stream . Read ( rowSpan ) ;
828828 int offset = 0 ;
829- Span < TPixel > pixelRow = pixels . GetRowSpan ( newY ) ;
829+ Span < TPixel > pixelRow = pixels . DangerousGetRowSpan ( newY ) ;
830830
831831 for ( int x = 0 ; x < arrayWidth ; x ++ )
832832 {
@@ -878,7 +878,7 @@ private void ReadRgb16<TPixel>(Buffer2D<TPixel> pixels, int width, int height, b
878878 {
879879 this . stream . Read ( bufferSpan ) ;
880880 int newY = Invert ( y , height , inverted ) ;
881- Span < TPixel > pixelRow = pixels . GetRowSpan ( newY ) ;
881+ Span < TPixel > pixelRow = pixels . DangerousGetRowSpan ( newY ) ;
882882
883883 int offset = 0 ;
884884 for ( int x = 0 ; x < width ; x ++ )
@@ -933,7 +933,7 @@ private void ReadRgb24<TPixel>(Buffer2D<TPixel> pixels, int width, int height, b
933933 {
934934 this . stream . Read ( rowSpan ) ;
935935 int newY = Invert ( y , height , inverted ) ;
936- Span < TPixel > pixelSpan = pixels . GetRowSpan ( newY ) ;
936+ Span < TPixel > pixelSpan = pixels . DangerousGetRowSpan ( newY ) ;
937937 PixelOperations < TPixel > . Instance . FromBgr24Bytes (
938938 this . Configuration ,
939939 rowSpan ,
@@ -961,7 +961,7 @@ private void ReadRgb32Fast<TPixel>(Buffer2D<TPixel> pixels, int width, int heigh
961961 {
962962 this . stream . Read ( rowSpan ) ;
963963 int newY = Invert ( y , height , inverted ) ;
964- Span < TPixel > pixelSpan = pixels . GetRowSpan ( newY ) ;
964+ Span < TPixel > pixelSpan = pixels . DangerousGetRowSpan ( newY ) ;
965965 PixelOperations < TPixel > . Instance . FromBgra32Bytes (
966966 this . Configuration ,
967967 rowSpan ,
@@ -1031,7 +1031,7 @@ private void ReadRgb32Slow<TPixel>(Buffer2D<TPixel> pixels, int width, int heigh
10311031 this . stream . Read ( rowSpan ) ;
10321032
10331033 int newY = Invert ( y , height , inverted ) ;
1034- Span < TPixel > pixelSpan = pixels . GetRowSpan ( newY ) ;
1034+ Span < TPixel > pixelSpan = pixels . DangerousGetRowSpan ( newY ) ;
10351035
10361036 PixelOperations < TPixel > . Instance . FromBgra32Bytes (
10371037 this . Configuration ,
@@ -1054,7 +1054,7 @@ private void ReadRgb32Slow<TPixel>(Buffer2D<TPixel> pixels, int width, int heigh
10541054 width ) ;
10551055
10561056 int newY = Invert ( y , height , inverted ) ;
1057- Span < TPixel > pixelSpan = pixels . GetRowSpan ( newY ) ;
1057+ Span < TPixel > pixelSpan = pixels . DangerousGetRowSpan ( newY ) ;
10581058
10591059 for ( int x = 0 ; x < width ; x ++ )
10601060 {
@@ -1109,7 +1109,7 @@ private void ReadRgb32BitFields<TPixel>(Buffer2D<TPixel> pixels, int width, int
11091109 {
11101110 this . stream . Read ( bufferSpan ) ;
11111111 int newY = Invert ( y , height , inverted ) ;
1112- Span < TPixel > pixelRow = pixels . GetRowSpan ( newY ) ;
1112+ Span < TPixel > pixelRow = pixels . DangerousGetRowSpan ( newY ) ;
11131113
11141114 int offset = 0 ;
11151115 for ( int x = 0 ; x < width ; x ++ )
0 commit comments