' Draw a Hilbert curve.
Private Sub Hilbert(ByVal depth As Integer, ByVal dx As _
Single, ByVal dy As Single)
If depth > 1 Then Hilbert depth - 1, dy, dx
picCanvas.Line -Step(dx, dy)
If depth > 1 Then Hilbert depth - 1, dx, dy
picCanvas.Line -Step(dy, dx)
If depth > 1 Then Hilbert depth - 1, dx, dy
picCanvas.Line -Step(-dx, -dy)
If depth > 1 Then Hilbert depth - 1, -dy, -dx
If m_Refresh Then picCanvas.Refresh
End Sub
|