|
|
@ -5,13 +5,13 @@ |
|
|
|
open DeathSocket |
|
|
|
open DeathSocket |
|
|
|
|
|
|
|
|
|
|
|
let createHorizontalLines width height rows = |
|
|
|
let createHorizontalLines width height rows = |
|
|
|
let interval = width / rows |
|
|
|
let interval = height / rows |
|
|
|
[| for point in 1 .. (rows - 1) -> |
|
|
|
[| for point in 1 .. (rows - 1) -> |
|
|
|
[|Point (0, (interval * point)) |
|
|
|
[|Point (0, (interval * point)) |
|
|
|
Point (height, (interval * point) )|]|] |
|
|
|
Point (width, (interval * point) )|]|] |
|
|
|
|
|
|
|
|
|
|
|
let createVerticalLines height columns = |
|
|
|
let createVerticalLines width height columns = |
|
|
|
let interval = height / columns |
|
|
|
let interval = width / columns |
|
|
|
[| for point in 1 .. (columns - 1) -> |
|
|
|
[| for point in 1 .. (columns - 1) -> |
|
|
|
[| Point ((interval * point), 0) |
|
|
|
[| Point ((interval * point), 0) |
|
|
|
Point ((interval * point), height)|]|] |
|
|
|
Point ((interval * point), height)|]|] |
|
|
@ -22,7 +22,7 @@ |
|
|
|
let pen = new Pen (spec.colour, width = spec.penWidth) |
|
|
|
let pen = new Pen (spec.colour, width = spec.penWidth) |
|
|
|
let horizontalLines = |
|
|
|
let horizontalLines = |
|
|
|
createHorizontalLines (img.Size.Width) (img.Size.Height) (spec.columns) |
|
|
|
createHorizontalLines (img.Size.Width) (img.Size.Height) (spec.columns) |
|
|
|
let verticalLines = createVerticalLines (img.Size.Height) (spec.columns) |
|
|
|
let verticalLines = createVerticalLines (img.Size.Width) (img.Size.Height) (spec.columns) |
|
|
|
for line in horizontalLines do graphics.DrawLines (pen, line) |
|
|
|
for line in horizontalLines do graphics.DrawLines (pen, line) |
|
|
|
for line in verticalLines do graphics.DrawLines (pen, line) |
|
|
|
for line in verticalLines do graphics.DrawLines (pen, line) |
|
|
|
img.Save (spec.savePath, ImageFormat.Png) |
|
|
|
img.Save (spec.savePath, ImageFormat.Png) |
|
|
|