using IronQr;
using IronSoftware.Drawing;
using System;
using System.Collections.Generic;
// Open the asset to read a QR Code from
var inputBmp = AnyBitmap.FromFile("IMAGE_TO_READ.png");
// Load the asset into QrImageInput
QrImageInput imageInput = new QrImageInput(inputBmp);
// Create a QR Reader object
QrReader reader = new QrReader();
// Read the Input an get all embedded QR Codes
IEnumerable<QrResult> results = reader.Read(imageInput);
// Use and Store the information as required
foreach (QrResult result in results)
{
// String value of the QR Code
Console.WriteLine(result.Value);
// URI value of the QR Code
Console.WriteLine(result.Url);
// Coordinates of the QR Code
foreach (IronSoftware.Drawing.PointF point in result.Points)
{
Console.WriteLine($"{point.X}, {point.Y}");
}
}
Imports IronQr
Imports IronSoftware.Drawing
Imports System
Imports System.Collections.Generic
' Open the asset to read a QR Code from
Private inputBmp = AnyBitmap.FromFile("IMAGE_TO_READ.png")
' Load the asset into QrImageInput
Private imageInput As New QrImageInput(inputBmp)
' Create a QR Reader object
Private reader As New QrReader()
' Read the Input an get all embedded QR Codes
Private results As IEnumerable(Of QrResult) = reader.Read(imageInput)
' Use and Store the information as required
For Each result As QrResult In results
' String value of the QR Code
Console.WriteLine(result.Value)
' URI value of the QR Code
Console.WriteLine(result.Url)
' Coordinates of the QR Code
For Each point As IronSoftware.Drawing.PointF In result.Points
Console.WriteLine($"{point.X}, {point.Y}")
Next point
Next result
Install-Package IronQR
读取高级二维码
我们致力于提供最先进的二维码阅读体验,这体现在我们集成了最先进的机器学习技术 (ML) 模型。通过采用尖端的 ML 技术,我们将 QR 码读取提升到了一个新的水平。我们先进的 ML 模型使您的应用程序能够以无与伦比的准确性和效率解码 QR 码,即使在具有挑战性的场景中也是如此。无论您是从图像、视频还是实时摄像机馈送中读取 QR 码,我们的 ML 解决方案都能确保您快速可靠地获取所需信息。这一创新不仅简化了数据提取,还增强了安全性,因为它可以区分合法 QR 码和潜在威胁。有了我们的 ML 模型,您可以相信您的二维码读取能力处于技术前沿,为您的用户提供无缝、可靠的体验。