裁缝大师 1.1 - Asim Abbasi






1.29/5 (5投票s)
2007年2月25日
1分钟阅读

30219

193
Visual Basic 项目。该软件随后按顺序生成坐标,并将其发送到微控制器。
引言
该软件使用 Visual Basic 5 创建。它被设计用于与微控制器接口,以切割金属板。用户可以输入软件模式,指定要切割板的图案,格式为 jpg、gif、bmp 或 wmf 文件。该软件随后按顺序生成坐标,并将其发送到微控制器。您还可以保存生成的坐标以供以后使用。主要例程如下。完整的代码(项目)位于 zip 文件中。
Private Sub Command3_Click()
For ptx = 0 To Picture1.ScaleWidth
For pty = 0 To Picture1.ScaleHeight
DoEvents
If Picture1.Point(ptx, pty) = RGB(0, 0, 0) Then
GoTo PointPrinter
End If
下一篇
下一篇
Exit Sub
PointDirector
DoEvents
color = Picture1.Point(ptx, pty)
If color = &H0& Then
GoTo PointPrinter
Else
ptx = ptx + 1
color = Picture1.Point(ptx, pty)
If color = &H0& Then
GoTo PointPrinter
Else
pty = pty + 1
color = Picture1.Point(ptx, pty)
If color = &H0& Then
GoTo PointPrinter
Else
ptx = ptx - 1
color = Picture1.Point(ptx, pty)
If color = &H0& Then
GoTo PointPrinter
Else
ptx = ptx - 1
color = Picture1.Point(ptx, pty)
If color = &H0& Then
GoTo PointPrinter
Else
pty = pty - 1
color = Picture1.Point(ptx, pty)
If color = &H0& Then
GoTo PointPrinter
Else
pty = pty - 1
color = Picture1.Point(ptx, pty)
If color = &H0& Then
GoTo PointPrinter
Else
ptx = ptx + 1
GoTo PointPrinter
End If
End If
End If
End If
End If
End If
End If
Exit Sub
PointPrinter
color = Picture1.Point(ptx, pty)
If color = &H0& Then
On Error GoTo Outmem
Text1.SelText = Str(ptx) + "," + Str(pty) + " "
Picture1.PSet (ptx, pty), RGB(242, 243, 52)
End If
GoTo PointDirector
Exit Sub
Outmem
MsgBox Err.Description, vbCritical, "错误编号" + Str(Err.Number)
Text1.Text = ""
Exit Sub