tuxing2 = PictureBox3.Image
tuxing.Width.Equals(200)
tuxing.Height.Equals(200)
Dim i As Integer ' x轴坐标
Dim j As Integer ' y轴坐标
Dim col_1 As Long ' Picture1像素值
Dim col_2 As Long ' Picture2像素值
Dim r, g, b As Short
For i = 0 To PictureBox3.Size.Width - 1
For j = 0 To PictureBox3.Size.Height - 1
color1 = tuxing.GetPixel(i, j)
color2 = tuxing1.GetPixel(i, j)
r = color1.R
g = color1.G
b = color1.B
col_1 = r + g + b
If col_1 = 3 * 255 Then
tuxing2.SetPixel(i, j, color2) ' (.PSet(i, j), col_2)
Else
tuxing2.SetPixel(i, j, color1)
End If
Next j
PictureBox3.Refresh()
Next i