北京印刷学院学报
北京印刷學院學報
북경인쇄학원학보
Journal of Beijing Institute of Graphic Communication
2014年
4期
52~54
,共null页
计算机图形学 编程 VB 绘图 算法 图像
計算機圖形學 編程 VB 繪圖 算法 圖像
계산궤도형학 편정 VB 회도 산법 도상
computer graphics ; VB ; algorithm ; programming ;image ; GUI
计算机图形学教学的编程实践主要使用TC绘图函数,不适用于Windows系统。Windows系统常用的具有图形功能的MFC学习掌握比较困难。VB既具有良好的Windows界面,又易于学习。分析了VB的画点方法,以画直线算法为例,设计了使用文本框输入坐标数据的界面,并给出了样例程序模板;该模板可以改编用于各种手工输入坐标的直线或曲线算法。研究了通过鼠标输入坐标的方法,改进了相应的程序模板;讨论了将绘图结果保存成图像文件的方法及其应用。结果表明,VB能够很好地改进图形学编程实践教学。
計算機圖形學教學的編程實踐主要使用TC繪圖函數,不適用于Windows繫統。Windows繫統常用的具有圖形功能的MFC學習掌握比較睏難。VB既具有良好的Windows界麵,又易于學習。分析瞭VB的畫點方法,以畫直線算法為例,設計瞭使用文本框輸入坐標數據的界麵,併給齣瞭樣例程序模闆;該模闆可以改編用于各種手工輸入坐標的直線或麯線算法。研究瞭通過鼠標輸入坐標的方法,改進瞭相應的程序模闆;討論瞭將繪圖結果保存成圖像文件的方法及其應用。結果錶明,VB能夠很好地改進圖形學編程實踐教學。
계산궤도형학교학적편정실천주요사용TC회도함수,불괄용우Windows계통。Windows계통상용적구유도형공능적MFC학습장악비교곤난。VB기구유량호적Windows계면,우역우학습。분석료VB적화점방법,이화직선산법위례,설계료사용문본광수입좌표수거적계면,병급출료양례정서모판;해모판가이개편용우각충수공수입좌표적직선혹곡선산법。연구료통과서표수입좌표적방법,개진료상응적정서모판;토론료장회도결과보존성도상문건적방법급기응용。결과표명,VB능구흔호지개진도형학편정실천교학。
Computer graphics programming practice mainly uses TC drawing function which is unsuitable for Windows system. On the other hand, MFC, Windows system's own drawing tool is more difficult to master. VB can be a very good balance, because it is not only has the good Windows interface, but also easy to learn. Firstly, we study the method of how to draw a pixel in VB by an example of drawing the straight line. We design an interface in which the coordinate data can be input by TextBox, and give the program templates which the students can adapt as the sample for line and curve algorithm with manually inputting the coordinates. Secondly, the illustration of the solution that coordinates are input by mouse, and improve the corresponding program template. Finally, the drawing result after the algorithm runs is saved as an image file and it's application are discussed. The results show that VB can well improve the graphics programming practice teaching.