- let next = pointToCheck.Pop()
- pointChecked.Add(next) |> ignore
- for ny in -1 .. 1 do
- for nx in -1 .. 1 do
- if ny <> 0 && nx <> 0
- then
- let p = Point(next.X + nx, next.Y + ny)
- if p.X >= 0 && p.X < w && p.Y >= 0 && p.Y < h && data.[p.Y, p.X, 0] > 0uy && not (pointChecked.Contains p)
- then
- pointToCheck.Push(p)
+ let next = pointToCheck.Pop ()
+ pointChecked.Add next |> ignore
+ for ny = -1 to 1 do
+ for nx = -1 to 1 do
+ if ny <> 0 && nx <> 0 then
+ let p = Point (next.X + nx, next.Y + ny)
+ if p.X >= 0 && p.X < w && p.Y >= 0 && p.Y < h && data.[p.Y, p.X, 0] > 0uy && not (pointChecked.Contains p) then
+ pointToCheck.Push p