コード例 #1
0
 static bool FindY(RasterizedLine.PixelIterator iter, int y, out int x0)
 {
     RasterizedLine.Pixel p;
     while (iter.Next(out p))
     {
         if (p.y == y)
         {
             x0 = p.x;
             return(true);
         }
     }
     x0 = 0;
     return(false);
 }
コード例 #2
0
            static void CacheYOnChanged(RasterizedLine.PixelIterator iter, Array <RasterizedLine.Pixel> list)
            {
                RasterizedLine.Pixel p;
                int y = int.MaxValue;

                while (iter.Next(out p))
                {
                    if (y != p.y)
                    {
                        list.Push(p);
                        y = p.y;
                    }
                }
            }
コード例 #3
0
 static bool NextY(RasterizedLine.PixelIterator iter, int y, out int x0, out int y0)
 {
     RasterizedLine.Pixel p;
     while (iter.Next(out p))
     {
         if (y != p.y)
         {
             x0 = p.x;
             y0 = p.y;
             return(true);
         }
     }
     x0 = 0;
     y0 = 0;
     return(false);
 }