| The rapid development of information technology makes the computer industryno longer exist as a symbolic tool, and it is hoped that the computer can presentgraphics and draw graphics. So computer graphics appears. With the widelyapplication of graphic technology, the study of computer graphic algorithm has beenmore and more important.Most graphics algorithms are fully cast to the CPU previously. It is inevitablymake the CPU load heavy and image generation slow. So we need to use the imageacceleration technology. The technique often makes use of hardware or firmwarecomputing integer to alleviate the burden on the CPU. The curve drawing is a basiccontent of computer graphics, and the most basic needs of curve drawing is thestraight line, as well as the basic technology of polygon drawing scanning is thetriangle.In this issue, the study of straight line and triangle scan algorithm has beenfocused on. The algorithm on hardware to run as fastest and most accurately aspossible calculates the coordinates and the color of the point on straight line andtriangles.Realization of the subject needs introducing and analyzing a variety ofstraight-line scan algorithm, such as Digital Differential Analyzer (DDA), themidpoint painting method and Bresenham algorithm. The optimal Bresenhamalgorithm is selected and then achieved, as well as color dealt with. At the same time,the two modes have been finished: smooth and flat.About the study on polygons, the polygon scan conversion algorithm is introducedand analyzed, and simplified into triangular algorithms. By programming the rows,the triangle scan conversion algorithm has been completed. In the processing of color,the two modes of smooth and flat use.Finally, the corresponding algorithm in the Mesa source code will be analyzedand compared with the algorithm used.To study the issue and achieve its application, the programming language C++with OPENGLhas been adopted to develop the software. |