毕业论文

打赏
当前位置: 毕业论文 > 计算机论文 >

基于DirectX技术的3D游戏Demo设计与实现

时间:2020-07-07 19:55来源:毕业论文
实现了天空盒子、水面倒影(折射、反射)、截投体(摄像机视锥)优化模块、地图场景优化模块、射线相交碰撞检测模块、Python脚本语言调用、输入管理模块和粒子系统,在室内场景

摘要:3D游戏就是三维游戏,3D中的D是Dimension(维)的缩写。本程序为使用DirectX技术实现的3D游戏Demo版,C++编写,采用Win32架构消息循环机制,可以在WindowsXP及以上系统流畅运行,无任何BUG。本程序使用了多种编程技术,如多线程技术和动态脚本技术,在渲染方面,使用了HLSL(高级着色语言)shader技术。本程序使用的设计模式有工厂模式和单件模式,有效地保证了资源和类的管理,保证了程序的质量。52103

本游戏主要实现了天空盒子、水面倒影(折射、反射)、截投体(摄像机视锥)优化模块、地图场景优化模块、射线相交碰撞检测模块、Python脚本语言调用、输入管理模块和粒子系统,在室内场景优化(BSP)方面做了一些尝试,但是没有成功,还需要进一步的研究

毕业论文关键字:3D游戏,Win32,多线程,HLSL,脚本。

Abstract:The full name of 3D-Game is "3 Dimensions Game", the "D" refers to Dimensions. This program is a 3D game demo compiled by DirectX and C++ ,message cycle mechanism of Win32.It can run well on the system Windows XP and higher without any bug. This program is compiled by several technologies,such as multi-thread and dynamic scripts. The shader of rendering is HLSL(High Level Shader Language).The design pattern of it includes factory and singleton, it can ensure the management of  resources and classes, and the quality of the program further.

This game has completed the Sky-Box, the Refraction and Reflaction of Water, the Frustum optimization, the Terrain optimization, the Ray-Cast Monitor, the Particles and call Python script. I have attempted to accomplish the BSP(Binary Space Partitioning),but it failed, and I think I should pay more effort on it. 

Key words: 3 Dimension Game, Win32, multi-thread,HLSL,script. 

目录

1 背景 5

1.1 电脑游戏及3D游戏发展史 5

1.2 3D游戏的几种实现技术 6

1.3 DirectX简介 7

2 游戏Demo设计 8

2.1 程序流程图 8

2.2 功能与构成 9

2.3 数据流图 9

2.4 程序开发与运行环境 10

3 关键技术与代码 10

3.1 多线程技术 10

3.2 截投体、四叉树LOD地图优化 13

3.3 碰撞检测 16

3.4 节点绑定与更新 18

3.5 渲染到纹理(RTT)技术 19

3.6 水面反射与折射 19

3.7 公告板(BillBoard) 21

3.8 昵称显示与透明处理 23

3.9 高级着色器语言HLSL 25

3.10 Python脚本调用 26

4 测试 30

4.1 游戏测试结果 30

4.2测试结果分析 30

1 背景

1.1 电脑游戏及3D游戏发展史

20世纪60年代,电子计算机进入了美国大学校园,那是一个编程高手崭露头角的年代。1962年的时候,一位叫斯蒂夫·拉塞尔的大学生编写了世界上第一款电脑游戏——《宇宙战争》(Space War),这个游戏在当时相当有名,是在PDP-1型电子计算机上编写的(美国DEC公司生产)[1]。 基于DirectX技术的3D游戏Demo设计与实现:http://www.youerw.com/jisuanji/lunwen_55926.html

------分隔线----------------------------
推荐内容