File tree Expand file tree Collapse file tree 1 file changed +1
-3
lines changed
src/ImageSharp/Processing/Processors/Quantization Expand file tree Collapse file tree 1 file changed +1
-3
lines changed Original file line number Diff line number Diff line change 11// Copyright (c) Six Labors.
22// Licensed under the Six Labors Split License.
33
4- using System . Diagnostics ;
54using SixLabors . ImageSharp . Memory ;
65using SixLabors . ImageSharp . PixelFormats ;
76
@@ -84,10 +83,10 @@ public IEnumerable<Buffer2DRegion<TPixel>> EnumeratePixelRegions<TPixel>(Image<T
8483
8584 int denom = ( int ) ratio . Denominator ;
8685 int num = ( int ) ratio . Numerator ;
86+ DebugGuard . MustBeGreaterThan ( denom , 0 , "Denominator must be greater than zero." ) ;
8787
8888 for ( int pos = 0 ; pos < totalNumberOfRows ; pos ++ )
8989 {
90- DebugGuard . MustBeGreaterThan ( denom , 0 , "Denominator must be greater than zero." ) ;
9190 int subPos = ( int ) ( ( uint ) pos % ( uint ) denom ) ;
9291 if ( subPos < num )
9392 {
@@ -136,7 +135,6 @@ public IEnumerable<Buffer2DRegion<TPixel>> EnumeratePixelRegions<TPixel>(ImageFr
136135
137136 int denom = ( int ) ratio . Denominator ;
138137 int num = ( int ) ratio . Numerator ;
139-
140138 DebugGuard . MustBeGreaterThan ( denom , 0 , "Denominator must be greater than zero." ) ;
141139
142140 for ( int pos = 0 ; pos < totalNumberOfRows ; pos ++ )
You can’t perform that action at this time.
0 commit comments