没有找到合适的产品?
联系客服协助选型:023-68661681
提供3000多款全球软件/控件产品
针对软件研发的各个阶段提供专业培训与技术咨询
根据客户需求提供定制化的软件开发服务
全球知名设计软件,显著提升设计质量
打造以经营为中心,实现生产过程透明化管理
帮助企业合理产能分配,提高资源利用率
快速打造数字化生产线,实现全流程追溯
生产过程精准追溯,满足企业合规要求
以六西格玛为理论基础,实现产品质量全数字化管理
通过大屏电子看板,实现车间透明化管理
对设备进行全生命周期管理,提高设备综合利用率
实现设备数据的实时采集与监控
利用数字化技术提升油气勘探的效率和成功率
钻井计划优化、实时监控和风险评估
提供业务洞察与决策支持实现数据驱动决策
原创|使用教程|编辑:郝浩|2013-09-06 09:18:38.000|阅读 577 次
概述:LEADTOOLS v18(即LEADTOOLS Anywhere)将其世界领先的成像技术扩展到了WinRT、iOS、Android、Windows Phone和Linux等平台。本文主要展示LEADTOOLS Anywhere如何在每个平台上面读取条形码。
# 界面/图表报表/文档/IDE等千款热门软控件火热销售中 >>
LEADTOOLS v18(即LEADTOOLS Anywhere)将其世界领先的成像技术扩展到了WinRT、iOS、Android、Windows Phone和Linux等平台。不仅如此,用户还可以在所有流行平台中实现查看、注释和标记、OCR、条形码、PDF、图像格式、压缩和图像处理等功能。
LEADTOOLS在每个开发平台上面都提供了一组非常相似的开发库,这是LEADTOOLS的一个非常明显的优势,让开发者既能够开发原生的应用程序,又不用花费太多的时间进行完全的代码重写。
接下来,我们就一起展示一下LEADTOOLS Anywhere如何在每个平台上面读取条形码。
.NET
System.Drawing.Bitmap bitmap = ... //
// Get a LEADTOOLS RasterImage from the platform image
RasterImage rasterImage = RasterImageConverter.FromImage(bitmap);
// Create a LEADTOOLS Barcode Engine instance
private BarcodeEngine barcodeEngine = new BarcodeEngine();
// Read the first barcode found in the image
BarcodeData barcodeData = barcodeEngine.Reader.ReadBarcode(rasterImage,
LogicalRectangle.Empty, BarcodeSymbology.Unknown);
// For this example, simply output the barcode type, location and data in the console
if (barcodeData != null) {
Console.WriteLine("Symbology:{0}", barcodeData.Symbology);
Console.WriteLine("Location:{0},{1},{2},{3}", barcodeData.Bounds.X,
barcodeData.Bounds.Y, barcodeData.Bounds.Width, barcodeData.Bounds.Height);
Console.WriteLine("Value:{0}", barcodeData.Value);
} else {
Console.WriteLine("No barcodes found");
}

WinRT & Windows Phone
Windows.UI.Xaml.Media.ImageSource imageSource = ... //
// Get a LEADTOOLS RasterImage from the platform image
RasterImage rasterImage = RasterImageConverter.ConvertFromImageSource(
imageSource, ConvertFromImageOptions.None);
// Create a LEADTOOLS Barcode Engine instance
private BarcodeEngine barcodeEngine = new BarcodeEngine();
// Read the first barcode found in the image
BarcodeData barcodeData = barcodeEngine.Reader.ReadBarcode(rasterImage,
LogicalRectangle.Empty, BarcodeSymbology.Unknown);
// For this example, simply output the barcode type, location and data in the console
if (barcodeData != null) {
Console.WriteLine("Symbology:{0}", barcodeData.Symbology);
Console.WriteLine("Location:{0},{1},{2},{3}", barcodeData.Bounds.X,
barcodeData.Bounds.Y, barcodeData.Bounds.Width, barcodeData.Bounds.Height);
Console.WriteLine("Value:{0}", barcodeData.Value);
} else {
Console.WriteLine("No barcodes found");
}

iOS & OS X
UIImage* uiImage = ... //
// Get a LEADTOOLS RasterImage from the platform image
LTRasterImage* rasterImage = [LTRasterImageConverter convertFromImage:uiImage
options:LTConvertFromImageOptions_None error:nil];
// Create a LEADTOOLS Barcode Engine instance
LTBarcodeEngine* barcodeEngine = [LTBarcodeEngine new];
// Read the first barcode found in the image
LTBarcodeData* barcodeData = [barcodeEngine.reader readBarcode:rasterImage
searchBounds:LeadRect_Empty() symbologies:nil symbologiesCount:0 error:nil];
// For this example, simply retrieve the barcode type, location and data
if(barcodeData != nil) {
NSLog(@"Symbology:%u", barcodeData.symbology);
NSLog(@"Location:%u,%u,%u,%u", barcodeData.bounds.x, barcodeData.bounds.y,
barcodeData.bounds.width, barcodeData.bounds.height);
NSLog(@"Value:%@", barcodeData.value);
} else {
NSLog(@"No barcodes found");
}

Android
android.graphics.Bitmap bitmap = ... //
// Get a LEADTOOLS RasterImage from the platform image
RasterImage rasterImage = RasterImageConverter.convertFromBitmap(
bitmap, ConvertFromImageOptions.NONE);
// Create a LEADTOOLS Barcode Engine instance
private BarcodeEngine barcodeEngine = new BarcodeEngine();
// Read the first barcode found in the image
BarcodeData barcodeData = barcodeEngine.getReader().readBarcode(
rasterImage, LeadRect.getEmpty(), BarcodeSymbology.UNKNOWN);
// For this example, simply output the barcode type, location and data in the console
if (barcodeData != null) {
Log.i("LEADTOOLS.BarcodeDemo", String.format("Symbology:%s", barcodeData.getSymbology()));
Log.i("LEADTOOLS.BarcodeDemo", String.format("Location:%1$s,%2$s,%3$s,%4$s",
barcodeData.getBounds().getX(), barcodeData.getBounds().getY(),
barcodeData.getBounds().getWidth(), barcodeData.getBounds().getHeight()));
Log.i("LEADTOOLS.BarcodeDemo", String.format("Value:%s", barcodeData.getValue()));
} else {
Log.i("LEADTOOLS.BarcodeDemo", "No barcodes found");
}

本站文章除注明转载外,均为本站原创或翻译。欢迎任何形式的转载,但请务必注明出处、不得修改原文相关链接,如果存在内容上的异议请邮件反馈至chenjj@ke049m.cn
文章转载自:慧都控件网

LEADTOOLS Document Imaging Suite SDK是LEADTOOLS SDK中各种特点的精选组合,这套强大的工具利用了LEAD行业领先的图像处理技术来智能地识别文档的特征,而根据文档的特征可以识别扫描的或传真的任何类型的表格图像。


LEADTOOLS Medical Imaging是一款医疗成像控件,包含了一些精心挑选的、经过优化的特性,可以满足医疗成像应用程序开发的特殊需要。
在使用Parasoft C/C++test执行BugDetective数据流分析时,可能会遇到用户自定义的资源API,那在这种情况下,若要判断是否存在资源问题,如资源泄露等,则需要手动配置测试配置。
大型SaaS系统的自动化测试常常受制于界面变化快、结构复杂、加载机制多变等因素。从元素识别到脚本管理,SmartBear TestComplete帮助Salesforce建了可靠的自动化测试体系。
BarTender 标签管理系统,正是帮助企业轻松实现 GS1 标准化标签设计、编码生成与信息联动的强大工具。
Parasoft C/C++test 是一款功能强大的 C/C++ 软件测试工具,集成了静态代码分析、单元测试、集成测试和覆盖率分析等功能,单元测试作为其关键功能之一,为了适配多样化的目标部署环境,C/C++test 设计了灵活的测试结果收集机制。通过Socket通讯方式来收集单元测试结果,从而扩展其测试覆盖范围与应用场景。
相关产品
20多年的老牌图像处理控件,支持TWAIN扫描、200多种图像效果、150多种图像格式…
LEADTOOLS Document Suite Developer ToolkitLEADTOOLS Document Imaging Suite SDK是LEADTOOLS SDK中各种特点的精选组合,这套强大的工具利用了LEAD行业领先的图像处理技术来智能地识别文档的特征,而根据文档的特征可以识别扫描的或传真的任何类型的表格图像。
LEADTOOLS Document Imaging Developer Toolkit多语言的文档图像处理控件,支持光符识别处理、条形码扫描识别等。
LEADTOOLS Medical Developer ToolkitLEADTOOLS Medical Imaging是一款医疗成像控件,包含了一些精心挑选的、经过优化的特性,可以满足医疗成像应用程序开发的特殊需要。
LEADTOOLS Medical Imaging Suite Developer ToolkitLEADTOOLS Medical Imaging Suite帮您开发功能强大的PACS和医学成像应用程序
最新文章 MORE
半岛外围网上直营相关的文章 MORE
服务电话
重庆/ 023-68661681
华东/ 13452821722
华南/ 18100878085
华北/ 17347785263
客户支持
技术支持咨询服务
服务热线:400-700-1020
邮箱:sales@ke049m.cn
关注我们
地址 : 重庆市九龙坡区火炬大道69号6幢
半岛外围网上直营