Example requests & Code samples for GdPicture.NET.
by Loïc » Sun Apr 19, 2009 2:49 pm
Here a sample to compare two images. This sample uses GdPicture ADR Technology included in GdPicture.NET. More informations at:
http://www.gdpicture.com/solutions/GdPicture-ADR.php- Code: Select all
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim oGdPictureImaging As New GdPicture.GdPictureImaging
Dim Confidence As Double
oGdPictureImaging.SetLicenseNumber("XXX") 'Replace XXX by a demo or commercial license key
Dim ImageID1 As Integer = oGdPictureImaging.CreateGdPictureImageFromFile("") 'Openning image 1
Dim ImageID2 As Integer = oGdPictureImaging.CreateGdPictureImageFromFile("") 'Openning image 2
Dim TemplateID As Integer = oGdPictureImaging.ADRCreateTemplateFromGdPictureImage(ImageID1)
oGdPictureImaging.ReleaseGdPictureImage(ImageID1)
oGdPictureImaging.ADRGetCloserTemplateForGdPictureImage(ImageID2)
oGdPictureImaging.ReleaseGdPictureImage(ImageID2)
Confidence = oGdPictureImaging.ADRGetLastConfidence()
oGdPictureImaging.ADRDeleteTemplate(TemplateID)
MsgBox("The two image are the same at: " & Str(Confidence) & "%")
End Sub
-

Loïc
- Site Admin
-
- Posts: 4230
- Joined: Tue Oct 17, 2006 10:48 pm
- Location: France
-
Return to Example requests & Code samples
Who is online
Users browsing this forum: No registered users and 0 guests