예제 #1
0
        public void SetDiscardable(Int32 x, Int32 y, LED led)
        {
            if (Dims.Discardable(x, y))
            {
                return;
            }

            Data[x, y] = led;
        }
예제 #2
0
        public bool MouseToLEDIndex(Int32 x, Int32 y, ref Point p)
        {
            if (x < m_dotEdge || y < m_dotEdge ||
                x > Size.Width - m_dotEdge || y > Size.Width - m_dotEdge)
            {
                return(false);
            }

            Int32 indexX = (x / m_dotSize);
            Int32 indexY = (y / m_dotSize);

            Dims.Clamp(ref indexX, ref indexY);

            p.X = indexX;
            p.Y = indexY;

            return(true);
        }
예제 #3
0
 public void SetWrap(Int32 x, Int32 y, LED led)
 {
     Dims.Wrap(ref x, ref y);
     Data[x, y] = led;
 }
예제 #4
0
 public void SetClamp(Int32 x, Int32 y, LED led)
 {
     Dims.Clamp(ref x, ref y);
     Data[x, y] = led;
 }