《计算机图形学》课程教学资源(PPT课件讲稿)Chapter 4 Graphics Output Primitives(Part II)

COIS712/ECOM7087CO1S800 Computer Graphics -Principles Systems Advanced Computer Graphics and Multimedia Advanced Computer Graphics and virtual simulation Chapter 4 Graphics Output Primitives (PartIl
COIS712/ECOM708/COIS800 Computer Graphics – Principles & Systems Advanced Computer Graphics and Multimedia Advanced Computer Graphics and Virtual Simulation Chapter 4 Graphics Output Primitives (Part II)

Outline Open gl Curve Functions fill-Area primitives ° Polygon FillAreas Open gl Polygon Fill-area Functions o Pixel Array Primitives ● Character primitiⅤes Open gL functions ° OpenGL Display lists
Outline OpenGL Curve Functions Fill-Area Primitives Polygon FillAreas OpenGL Polygon Fill-area Functions Pixel Array Primitives Character Primitives OpenGL functions OpenGL Display Lists 2

Chapter 4 Graphics Output Primitives(Part D) OpengL Curve Functions Fill-Area Primitives and Polygon FillAreas
Chapter 4 Graphics Output Primitives (Part II) OpenGL Curve Functions Fill-Area Primitives and Polygon FillAreas 3

OpenGL Curve Functions GLu(OpengL Utility) functions BD Quadrics(Spheres, Cylinders) Rational B-Splines(circles, ellipse, Bezier curve) (有理B樣條) gluSphere/ glu cylinder/ gluDisk NURBS(non-uniform rational B-splines) GLuT (Open gL Utility Toolkit)functions BD QuadricsSpheres, Cones etc. glutSolidSphere/glut Wire Sphere glutSolid Cone, glut SolidTorus Approximate a simple curve using a polyline o The more line sections, the smoother appearance of the curve. Write your own curve-generation algorithms Camputer Graphics with Open GL, Third Edition, by Donald Hearn and M. Pauline Baker ISBN0-13-0-15390-7o 2004 Pearson Education, Inc, Upper Saddle River, NJ. All rights reserve
OpenGL Curve Functions GLU (OpenGL Utility) functions: 3D Quadrics (Spheres,Cylinders) Rational B-Splines (circles, ellipse, Beziercurve) (有理B樣條) NURBS (non-uniform rational B-splines) GLUT (OpenGL UtilityToolkit) functions: 3D Quadrics (Spheres, Cones etc.) Approximate a simple curve using a polyline The more line sections, the smootherappearance of the curve. Write your own curve-generation algorithms (By Mark Kilgard) gluSphere/gluCylinder/gluDisk… 4 glutSolidSphere/glutWireSphere, glutSolidCone, glutSolidTorus,…

Fill-Area Primitives ●Fill( Filled)Area An area filled with some solid color or pattern To describe the surfaces of solid objects Most graphics library routines don t support arbitrary fill shapes A fill area is required to be specified as a polygon A set of polygon facets can approximate a curved surface(a polygon mesh), which can be called as SurfaceTessellation
Fill-Area Primitives Fill (Filled)Area An area filled with some solid color orpattern To describe the surfaces of solid objects Most graphics library routines don’t support arbitrary fill shapes. A fill area is required to be specified as a polygon. A set of polygon facets can approximate a curved surface (a polygon mesh),which can be called as SurfaceTessellation. 5

Polygon Fill Areas Polygon a plane figure specified by a set of three or more vertices. thatare connected in sequence by straight-line segments(edges) The interior angle is the angle inside the polygon boundary that Here refer only to those without is formed by two adjacent edges crossing edges: simple(standard) DORgon Polygon classifications 180° All interior angles are less than or equal to 180 degrees Concave Polygon(凹) A convex polygon(a)and a concave on Otherwise
Polygon Fill Areas A convex polygon (a) and a concave polygon (b) The interior angle is the angle inside the polygon boundary that is formed by two adjacent edges. Polygon A plane figure specified by a set of three or more vertices, thatare connected in sequence by straight-line segments (edges). Here refer only to those without crossing edges: simple (standard) polygon Polygon Classifications Convex Polygon (凸) All interior angles are less thanor equal to 180odegrees Concave Polygon (凹) Otherwise 6

Polygon Fill Areas Implementation consideration Some graphics packages including OpenGL, only support convex polygon for the fill algorithms. Generate a line segment For degenerate(退化) polygogerlapping edges. or edges with o. leng A set of vertices that are collinear(or that have repeated vertex positions To identify these cases, graphics systems usually leave these to the ● For concave polygons Implementation of fill algorithms and other graphics routines aremore complicated for concave polygons olit a concave polygon into a set of convex polygons
Polygon Fill Areas Implementation consideration Some graphics packages including OpenGL, only support convex polygon for the fillalgorithms. For degenerate (退化)polygons -- A set of vertices that are collinear (or that have repeated vertexpositions) --To identify these cases, graphics systems usually leave these to the programmer For concave polygons -- Implementation of fill algorithms and other graphics routines aremore complicated for concave polygons --To split a concave polygon into a set of convex polygons Generate a line segment Overlapping edges, or edges with 0 length 7

Identifying Concave Polygons Characteristics e At least one interior angle >1800 >180° Extension of some edges intersect other o Line segment of some pair of interior points intersects the be Doundary Mathematically The cross products of adjacent edges Convex: the same sign (E1XE2)>0 Concave: some are positive and (E2×E3)2>0 (E3×E4)20 (next slide for the detail) (E3×E)2>0 (E6×E1)2>0
Identifying ConcavePolygons Characteristics At least one interior angle>180o ; Extension of some edges intersect other; Line segment of some pair of interior points intersects the boundary. Mathematically The cross products of adjacent edges Convex: the same sign Concave: some are positive and some are negative (next slide for the detail ) 8

Splitting Concave Polygons a concave polygon with six edges Edge vectors for this polygon E1=(100)E2=( E E E3=(1,-10)E4=(030 E3=(3.00)E=(0-30) E2 E The cross product for two adjacent E dge vectors 0 E1XE2=(001)!E2×E3=(0,0,-2) Splitting a concave polygon using E E4=E4×E3=(009) the vector method (03)E5×E。E6×E1=(00.3) Determinant form i j k Spl(t, the polygon along the line of ax b= det al a2 a3 vector E2. The two new polygons b, b2 b3 9)ia2ba+jab1+ka1b2-iaab2-jay b,. are both convex
E2E3 = (0,0,−2) E4 E5 = (0,0,9) E6E1= (0,0,3) E1 E2 = (0,0,1) E3 E4 = (0,0,3) E5 E6 Split the =(0,0,9) polygon along the line of vector E2 .The two new polygons A concave polygon with six edges. Edge vectors for this polygon: E1 = (1,0,0) E2 = (1,1,0) E3 = (1,−1,0) E4 = (0,3,0) E5 = (− 3,0,0) E6 = (0,−3,0) The cross product for two adjacent edge vectors: Splitting ConcavePolygons Splitting a concave polygon using the vectormethod Determinant form are both convex. 9

Inside-Outside Tests ● Inside- Outside test rea-filling algorithms and other graphics processes often need to identify interior regions of objects For simple object, it is a straightforward process For complex objects, graphics packages normally use either 1.Odd-Even(a f-5)rule(Odd-Parity rule or Even-Oddrule) 2. Non-zero winding(環繞) number rule
Inside-Outside Tests Inside-Outside test ▪ Area-filling algorithms and other graphics processes often need to identify interior regions of objects. ▪ For simple object, it is a straightforward process. ▪ For complex objects, graphics packages normally use either: 1. Odd-Even (奇偶) rule (Odd-Parity rule or Even-Odd rule) 2. Non-zero winding (環繞) number rule 10
按次数下载不扣除下载券;
注册用户24小时内重复下载只扣除一次;
顺序:VIP每日次数-->可用次数-->下载券;
- 亚马逊云计算AWS(Amazon Web Service)、Cloud Computing——Cassandra.ppt
- 上海交通大学:《通信网络》课程PPT教学课件(讲稿)Communication Networks - ANALYSIS OF 10G EEE PROTOCOL.pptx
- 上海交通大学:《Multicore Architecture and Parallel Computing》课程教学资源(PPT课件讲稿)Lecture 7 CUDA.ppt
- 上海交通大学:云安全(PPT讲稿)Cloud Security.pptx
- 局域网的硬件设备和操作系统(PPT讲稿).ppt
- 大数据分析(PPT讲稿)大数据引领我们走向数据智能化时代.ppt
- 淮阴工学院:《数据库原理》课程教学资源(PPT课件讲稿)第3章 关系数据库的基本理论.ppt
- 《Java面向对象程序设计》课程教学资源(PPT课件讲稿)第三章 Java面向对象编程.pptx
- 《Java面向对象程序设计》课程教学资源(PPT课件讲稿)第六章 Java输入输出流与文件操作.pptx
- 《Java面向对象程序设计》课程教学课件(PPT讲稿)流程控制语句.pptx
- 《Java面向对象程序设计》课程教学课件(PPT讲稿)AWT和Swing组件.pptx
- 江苏海洋大学(淮海工学院):《Java面向对象程序设计》课程教学资源(PPT课件讲稿)第4章 Java图形用户界面设计.pptx
- 江苏海洋大学(淮海工学院):《Java面向对象程序设计》课程教学资源(PPT课件讲稿)第2章 Java语言基础.pptx
- 《Java面向对象程序设计》课程教学资源(PPT课件讲稿)第四章 Java图形用户界面设计 4.2 AWT和Swing组件.pptx
- 《高级语言程序设计 Advanced Programming》课程教学资源(PPT课件讲稿)第8章 指针.ppt
- 《C语言程序设计》课程教学资源(PPT课件讲稿)第5章 循环结构程序设计.ppt
- 广西外国语学院:《计算机网络》课程教学资源(PPT课件讲稿)第8章 DNS.ppt
- 深圳大学:《图片处理基础》课程教学课件(PPT讲稿)Poisson Image Editing.pptx
- 《PhotoshopCS2基础教程与上机指导》课程教学资源(PPT课件讲稿)第20章 Web图像与动画设计.ppt
- 广西医科大学:《计算机网络 Computer Networking》课程教学资源(PPT课件讲稿)Chapter 17 NETWORK MANAGEMENT.pptx
- 北京理工大学:《软件工程基础》课程教学资源(PPT课件讲稿)需求工程(主讲:刘驰).ppt
- 上海交通大学:Scheduling Algorithms in Heterogeneous Computing Systems.pptx
- 上海交通大学:《程序设计》课程教学资源(PPT课件讲稿)第5章 批量数据处理——数组.ppt
- 上海交通大学:《现代操作系统》课程教学资源(PPT课件讲稿)Chapter 02 进程与线程 Process and Thread.pps
- 《数据库基础与应用》课程PPT教学课件(Access案例教程)第9章 数据库语言SQL.pptx
- 《数据库基础与应用》课程PPT教学课件(Access案例教程)第8章 宏.pptx
- 《数据库基础与Access应用》课程教学资源(PPT课件)第12章 应用实例.pptx
- 《数字图像处理基础》课程教学资源(教学大纲.pdf
- 长安大学:《微机原理》课程教学资源(PPT课件讲稿)第7章 汇编语言程序设计.pptx
- 西安交通大学:《微型计算机接口技术》课程教学资源(PPT课件讲稿)第二章 微型处理器与单片机.ppt
- 中国铁道出版社:《局域网技术与组网工程》课程教学资源(PPT课件讲稿)第7章 网络系统集成与网络维护.ppt
- 《计算机应用基础》课程教学资源(PPT课件讲稿)第3章 Word 2007文字处理.ppt
- 《微机原理》课程教学资源(PPT课件)第六章 微型计算机的输入/输出.ppt
- 《单片机原理及应用》课程教学资源(PPT课件)第8章 AT89S51单片机外部存储器的扩展.ppt
- 《网页设计与制作》课程教学资源(PPT课件讲稿)第七章 模板与库的应用.ppt
- 《网页设计与制作》课程教学资源(PPT课件讲稿)第四章 设计页面布局.ppt
- 《微机原理》课程教学资源(PPT课件)第2章 微处理器与总线.ppt
- 山东大学:《微机原理及单片机接口技术》课程教学资源(PPT课件讲稿)第四章 指令系统及汇编语言程序设计 4.5 各类指令详解.ppt
- 多媒体图像处理技术(PPT课件讲稿,共六章).ppt
- 山东大学:《人机交互技术》课程教学资源(PPT课件讲稿)第9章 可用性分析与评估.ppt