计算机应用 ›› 2005, Vol. 25 ›› Issue (01): 202-205.DOI: 10.3724/SP.J.1087.2005.0202

• 典型应用 • 上一篇    下一篇

OpenGL在自然对象真实感图形生成中的应用

 秦忠宝1,2,石怀宇3,何卫平1,房亚东1,赵锋1,4   

  1. 1.西北工业大学现代设计与集成制造教育部重点实验室; 2,成都飞机工业公司职业技术学院; 3.第二炮兵工程学院基础部; 4.西安建筑科技大学理学院
  • 发布日期:2005-01-01 出版日期:2005-01-01
  • 基金资助:

    国家"十五"科技攻关计划重大项目(2001BA201A05);;国家自然科学基金资助项目(69973037)

Methods of building the realistic graphics of natural objects with fractal feature using OpenGL

QIN Zhong-bao12,SHI Huai-yu3, HE Wei-ping1, FANG Ya-dong1, ZHAO Feng1, 4   

  1. 1.Ministry of Education of China, Northwest Polytechnic University; 2. The second Artilyry Engineering Colloge; 3. Technological Institute, Chengdu Aeroplane Corporation; 4. College of Science, Xi’an University of Architecture & Technology,
  • Online:2005-01-01 Published:2005-01-01

摘要: 针对自然对象不规则的几何形状,介绍了分形几何在其数据建模方面的优势和基本思想,并以山脉地形为中心阐述了以fBm方法为基础的几何数据模型生成算法。探讨了OpenGL在以山脉地形为代表的自然对象真实感图形生成过程中的基本用法。对于在分形几何对象图形渲染过程中,OpenGL默认的法矢量计算函数无法正常运行的问题,引入了行之有效的求取算法。最后通过计算机模拟实验对整个过程算法过程予以验证。

关键词: 分形, fBm, 山脉地形, OpenGL, 真实感图形

Abstract: The advantages of fractal geometry in representing natural objects with scrambling features and building their geometric models were introduced and the methods of producing the geometric data models of the natural objects based on fBm with mountain were exemplified. Then, how OpenGL was applied to display and render the realistic graphics of the mountain terrain was investigated. Because of the fractal features of the mountain terrains, the default function of OpenGL that could be used to compute the normals of the surfaces of the fractal models was ineffective. Thus, an effective method to remedy the flaw above was suggested. In the end, in order to prove the validity of the methods above, a prototype program was developed and a few vivid graphics produced by the program were displayed.

Key words: fractal geometry, fBm, mountain terrain, OpenGL, realistic graphics

中图分类号: