畫點(diǎn):
創(chuàng)新互聯(lián)專注于忠縣企業(yè)網(wǎng)站建設(shè),響應(yīng)式網(wǎng)站建設(shè),商城網(wǎng)站建設(shè)。忠縣網(wǎng)站建設(shè)公司,為忠縣等地區(qū)提供建站服務(wù)。全流程按需制作網(wǎng)站,專業(yè)設(shè)計(jì),全程項(xiàng)目跟蹤,創(chuàng)新互聯(lián)專業(yè)和態(tài)度為您提供的服務(wù)
在PictureBox的Paint事件里面:
dim myGraphics=e.Graphics
Dim myPointArray As Point() = {New Point(0, 0), New Point(50, 30), New Point(30, 60)}
myGraphics.DrawPolygon(myPen, myPointArray)
畫圓:
Dim g As Graphics
g = PictureBox1.CreateGraphics
g.FillEllipse(Brushes.Red, x, y, 10, 10)
Call Pset(x,y,RGB(Red,Green,Blue))
x,y是坐標(biāo)
RGB是顏色
可以隨時(shí)調(diào)用!!!
哦,對(duì)不起,沒看清。
我沒用過VB.Net,代碼是沒辦法給你了
但我有辦法:
用API函數(shù)SetPixel,SetPixelv(后者快一點(diǎn))
語法參見
畫點(diǎn):
在PictureBox的Paint事件里面:
dim myGraphics=e.Graphics
Dim myPointArray As Point() = {New Point(0, 0), New Point(50, 30), New Point(30, 60)}
myGraphics.DrawPolygon(myPen, myPointArray)
畫圓:
Dim g As Graphics
g = PictureBox1.CreateGraphics
g.FillEllipse(Brushes.Red, x, y, 10, 10)