当前位置:文档之家› 图像识别技术和图像处理技术

图像识别技术和图像处理技术

摘要本文对图形图像处理系统的发展现状和所采用的主要技术进行了详细分析,确定了相应的结构和主要功能,以及实际开发中所采取的技术。

系统在Windows XP平台下实现,本课题是采用Visual C++作为编程工具,采用面向对象的程序设计技术实现一个图形绘制和图像处理的应用软件。

主要工作分为三类,包括基本图形绘制与编辑、简单的图像处理、图像格式的转换。

图形方面主要是设计图形基类,以及继承图形基类的具体图形类。

通过对独立功能的封装,可以为今后需要的图形图像的应用奠定基础。

系统的优点有:充分体现了面向对象的设计思想,充分运用了C++的特性,比如封装、多态、继承。

程序结构清晰,可读性好,程序中做了充分的注释。

图形绘制部分避免了传统的switch case的繁琐结构。

容易扩充和移植。

最后,对系统进行测试表明,系统功能达到了预期的要求,界面友好,操作简便,运行也较稳定,是一个完成基本功能的图形图像系统。

总体上,本文介绍了系统开发设计的全过程和设计过程中部分代码,也对系统测试的过程进行简单描述,同时对系统中采用的关键技术也作了一些必要的说明,对图像变换的基本原理,图像处理的基本原理和各种图像格式做了详细的阐述。

关键词:图形;图像;多态;继承AbstractThis article has carried on the detailed analysis about graph image processing system development and using of the key technology,identify the corresponding structure and central function, as well as the system adopts technology in the actual development. The system realizes under the Windows XP platform, the topic use Visual C++ as a programming tool, use object-oriented programming techniques to achieve a graphic and image processing software. Major work is divided into three categories, basic drawing and editing graphics, simple image processing, and image format conversion. The graph aspect is designs the graph base class , as well as inherits the graph bas e class’s specific graph class. Through independent function's encapsulation, for the future’s needs of the graphic images lays the foundation. The system merit has: the object-oriented design’s thought application of the c++ properties, for example encapsulation, pol ymorphism, and inheritance. Program’s structure is clear, good readability, codes has the full annotation in the program. The graph plan’s part has avoided complicated structure of the traditional switch case. Easy expansion and transplantation.Finally, system’s testing shows, s ystem’s functions achieve the expected demand, friendly interface, and the operation is simple, also a much stable operation, it has basic functions of the graphic image system.As a whole, this paper describes the system design process and part of the process of designing code, also carries on the simple description to the system test process, meanwhile it made some necessary explanations about key technology in the system, it made the detailed description to image transform of the basic principle, the image processing basic principle and various image formats.Keyword: graph; image; polymorphism; inheritance目录摘要 (I)Abstract (II)第1章引言 (1)1.1 课题的研究目的和意义 (1)1.2 国内外发展现状 (1)1.3 研究方法与手段 (2)1.3.1 运行环境 (2)1.3.2 开发环境 (2)第2章图形图像处理系统相关技术综述 (3)2.1 图形设计基础 (3)2.1.1 Visual C++技术概要 (3)2.1.2 图形设备接口GDI (3)2.1.3 设备环境DC (3)2.1.4 CDC类的派生类的功能及其之间的区别 (4)2.1.5 与绘图相关的GDI对象类 (5)2.1.6 坐标变换和映射模式 (6)2.2 图像设计基础 (7)2.2.1 数字图像的基本概念 (7)2.2.2 调色板 (8)2.2.3 调色板的概念 (9)第3章图形图像处理系统的总体设计 (10)3.1 需求分析 (10)3.2 图形图像处理系统目标设计 (10)3.3 图形图像处理系统功能描述 (10)3.4 界面设计 (12)3.4.1 主界面设计 (12)3.4.2菜单设计 (14)3.4.3 工具栏设计 (14)3.4.4 属性框设计 (15)第4章图形图像处理系统图像部分设计 (16)4.1 与设备无关位图(DIB) (16)4.1.1 DIB位图的结构 (16)4.1.2 定义DIB处理函数集 (18)4.1.3 CDib类的设计目标 (20)4.2 图像变换 (20)4.2.1 图像变换的理论基础 (20)4.2.2 旋转 (21)4.2.3 镜像 (22)4.3 图像处理的基本方法 (22)4.4 图像格式 (25)4.4.1 PCX格式 (25)5.4.2 GIF格式 (26)4.4.3 JPEG (28)第5章图形图像处理系统图形部分设计 (29)5.1 图形类的设计 (29)5.1.1 图形系统的层次结构 (29)5.1.3 类层次性的特点 (29)5.1.4 图形系统类层次的设计原则 (30)5.1.5 基类CEntity (30)5.1.6 命令基类CCommand (31)5.2 派生类设计 (32)5.2.1 派生类Cline (32)5.2.2 派生类Cline的具体实现 (32)5.2.3 创建直线命令类CCreateLine (33)5.3 位置类Position (33)5.3.1 构造位置类的原因 (34)5.3.2 位置类Position的实现 (34)5.4 图元拾取 (35)5.4.1 直线的拾取 (36)5.4.2 矩形的拾取 (37)5.4.3 圆的拾取 (37)5.4.4 图元拾取的准确度和可靠性 (37)5.5 图元的编辑 (37)5.5.1 图元编辑函数 (38)5.5.2 实现图元的交互编辑 (39)5.6 序列化和反序列化 (40)5.7系统测试 (41)第6章结论 (43)参考文献 (44)致谢 (45)第1章引言1.1 课题的研究目的和意义本课题的目的是采用Visual C++作为编程工具,实现基本图形元素如直线、圆、椭圆等的绘制,对图形元素的基本操作如填充、擦除等,也包括对常用图像格式的处理,如图像的显示、图像格式的转换等[1]。

应该说,目前已有种类繁多的图形图像处理专用软件工具,如AutoCAD、和PhotoShop等,利用这些图形图像处理软件可以实现同样的功能。

即便如此,研究这些图形图像处理技术仍具有一定使用价值。

首先,利用一个设计良好的简单的小图形处理程序可以用于教学演示的目的,展示基本的图形图像处理技术和面向对象技术在这一领域的应用效果。

其次,在很多应用中需要提供自己的图形图像处理功能,例如,在一个正在连接网络的任务中可能就希望显示一幅示意性的动画,此时,不能依赖一个图形软件来实现。

因此,通过对独立功能的封装,可以为今后需要的图形图像的应用奠定基础[2]。

此外,借助Visual C++语言这种典型的面向对象编程环境,能够充分挖掘硬件的潜能,得到性能优良的程序代码。

1.2 国内外发展现状图形与图像处理是计算机最早应用的领域之一,从简单的图形显示到复杂的图像分析、模式识别,使得图形与图像处理技术不断走向成熟,也涌现出了大量的软件。

例如,ACDSee、PhotoShop、CorelDraw等,这些软件提供了一般显示、特殊显示、特技处理等大量复杂的功能。

图形处理技术得益于图形学的发展,而从目的上可以将图像处理技术分为两类,分别是图像识别技术和图像处理技术。

针对图像处理技术,可以是旋转、亮度、对比度、饱和度、RGB调节、调节图像尺寸等属性方面的处理技术和添加文字、图像增强、弱化、水印、特效、镂空等处理方法。

甚至为了达到更精微的处理效果,这些软件还使用了图层。

随着网络和多媒体技术的发展和应用,体现在应用软件中的是一些更具有1“现代感”的应用,例如,支持各种常用图形、RAW原始图片、Flash动画的快速浏览、编辑、保存、导入、导出,甚至还可以提供一些趣味涂鸦、字符素描之类的应用,以体现人的个性[3]。

相关主题