Beispiel #1
0
    private void DrawDot(IntVector2 position)
    {
        RectInt rect = DrawingUtils.CalculateFillRect(position, _textureSize, brushSize);

        bool[] mask = DrawingUtils.CreateDotMask(rect);
        ModifyTexture(mask, rect);
    }
Beispiel #2
0
    private void DrawLine(IntVector2 p1, IntVector2 p2)
    {
        RectInt rect = DrawingUtils.CalculateFillRect(p1, p2, _textureSize, brushSize);

        bool[] mask = DrawingUtils.CreateLineMask(p1, p2, rect, _textureSize, brushSize);

        ModifyTexture(mask, rect);
    }