HTML5Game Engine Implementation Based on IOS Platform

Author
GuoSong
Advisor
ZhangJiaChen
School
Jilin University
Major
Computer Software and Theory
Classification
TP311.52 Software Development
Degree
Master's thesis
Year
2013
Downloads
132
Citations
0

Request the full text

Abstract

HTML5is the next-generation HTML. Recently, the high-speed development oftechnology associated with HTML5leads to increasing number of webpage applicationsbased on this particular technique. Modern browsers all provide technical support for HTML5.Similar circumstances appear in the environment of smart phones as Safari on Apple iOS andbuilt-in browser on Android platform both accepts HTML5. All these progresses bringpositive opportunities to mobile application developers. In traditional mobile applicationdeveloping, Objective-C language is necessary on iOS as well as Java on Android platformdue to which the cross-platform application developing got held back. Unlike to Objective-Cor Java, mobile applications based on HTML5using JavaScript are allowed to run on mobilebrowsers of different platforms. Therefore HTML5technology is getting more and moreacknowledgement among mobile application developers.Currently however, mobile phone browsers are technically far away from satisfaction forHTML5mobile applications requirements which is critical especially in rendering efficiencyof heavy gaming programs. Essentially, all rendering calculations rely on CPU without GPUhardware acceleration. Thus, this article comes up a fresh way, which adopts a localizedHTML5solution with original mobile browsers abandoned, to accomplish a HTML5gameengine based on iOS platform. The engine support hardware acceleration and generousHTML5functions. The author participated in the project design and develop as the engine smajor researcher.The main purposes of the article are as follows:1. The article gives the game engine s integrated architecture. Substantially the engineis a localized browser according to HTML5standard aiming at heavy gameprograms developing. So the game closely related functions are strengthened andmeantime performance as browser is partially sacrificed.2. Built-in JavaScript engine analysis. The engine is created with Objective-C. To makea better communication between Objective-C and JavaScript the project incorporatesa JavaScript engine names iosJavaScriptCore as the cornerstone.3. Ajax is implemented in the engine. The article precisely explains solutions of Ajax. Thanks to that the engine allows asynchronous communication with servers in orderof network game developing.4. The engine provides HTML5Audio. Audion is the foundation of audio playbackusing HTML5.5. The engine complete the HTML Canvas. It the most significant work of the articlewhich implements a GPU hardware acceleration rendering system based on OpenGLES. The whole process is described in detail to explain how the system is built. Thearticle analyses the OpenGL ES FBO (Frame Buffer Object) and Shader programsas well as the implementation of HTML5Canvas API including acquirement ofcanvas object in JavaScript layer, the acquirenment of getContext(2d) object andtypical API implementation such as src and drawImage. Also the Cache plan adoptedto achieve the buffer of image data to memory and the Core Graphics technology iselaborated.At last, the article expounds a social game running on the exact game engine which hasbeen released to App Store. The game is based on JavaScript and HTML5and it isheavyweight. The engine capability can be tested and proved by presenting the game sgraphics and abilities.

Table of contents

Summary 4-6 Abstract 6-11 Chapter 1 Introduction 11-13 1.1 Background 11 <br / > 1.2 HTML5 game engine development status quo 11-12 1.3 The main work 12-13 Chapter 2 Introduction to HTML5 technology 13-15 2.1 HTML5 history 13 Canvas Introduction 2.2 HTML5 is 13-15 technical architecture and basic functions Chapter 3 IOS-HTML5 shell realization 15 - 35 3.1 IOS-HTML5 shell overall framework outlined 15-17 3.1.1 IOS-HTML5 position in the shell game project 15-16 3.1. the main module 2 IOS-HTML5 shell 16-17 3.2 integrated JavaScript engine 17-20 3.2.1 V8 engine analysis 17-18 <br / > 3.2.2 iosJavaScriptCore engine analyzes achieve 18-20 3.3 Ajax technology achieve 20-25 3.3.1 XMLHttpRequest object 20-21 <br / > 3.3.2 sends a request to the server to achieve 21-22 3.3.3 Get achieve server response 22-24 flow nbsp 3.3.4 access to resources ; 24-25 3.4 Audio audio Engine realization specification 25-28 3.4.1 Audio elements 25-26 3.4.2 src interface and achieve play interface 26-28 3.5 Canvas rendering engine technology architecture specification nbsp 28-33 3.5.1 Canvas element ; 28-31 <br / > 3.5.2 Canvas element used in the game project 31-32 interface and technology architecture 3.5.3 src drawImage interface 32-33 3.6 IOS-HTML5 shell other features outlined 33-35 Chapter 4 IOS-HTML5 rendering engine to achieve shell analysis standard use 35-59 4.1 Canvas API is 35 -36 4.2 canvas object implementations 36-42 4.2.1 iOS core knowledge developed 36 4.2.2 build applications control center 36-37 4.2.3 build OpenGL View 37-38 4.2.4 using OpenGL ES FBO technology 38-39 4.2.5 achieve global rendering loop essence 39-41 4.2.6 canvas object 41-42 achieve 4.3 src interface 42-51 4.3.1 achieve image object 42-43 4.3.2 image resource access streaming achieve 43-44 4.3.3 Cache structure 44-46 <br / > 4.3.4 using Core Graphics technology 46-49 4.3.5 different data channels to achieve the same screen rendering 49-50 4.3.6 pixel data to OpenGL 50-51 achieve 4.4 drawImage interface 51-55 4.4.1 Get getContext (2d) object 52 4.4.2 Creating Canvas context environmental 52-53 4.4.3 analysis of OpenGL ES 2.0 rendering pipeline 53-54 4.4.4 using OpenGL ES shaders 54-55 <br / > 4.4.5 realize drawImage function simple test nbsp 55 4.5 Canvas functions ; 55-59 4.5.1 the first test 55-57 <br / > 4.5.2 the second test 57-59 Chapter 5 IOS-HTML5 running on the shell first game 59-63 Chapter 6 conclusions and Prospects 63-64 6.1 summary 63 6.2 job Outlook 63-64 References 64-66 About the author made ??during the study and scientific research 66-67 Thanks 67

Related dissertations

  1. Research on WebGIS based on HTML5
    LongYun ·Jiangxi University of Technology ·2013 ·Master's thesis
  2. Design and Implementation of3D Game Engine
  3. Research and Implementation of Personal Genome Data Visualization
    HaoYaFeng ·Harbin Institute of Technology ·2013 ·Master's thesis
  4. Research and Development of Mobile Application Base on HTML5
  5. Research on Vector Electronic Charts Services Based on HTML5
    ZuoDongLong ·Dalian Maritime University ·2013 ·Master's thesis
  6. Software Design of a Certain Experience Platform Multi-parameter Monitoring System
    BaiZuoZuo ·University of North ·2014 ·Master's thesis
  7. Research and Design for the Simulator and Offline-programme System of Transfer Robot Based on OPENGL
  8. Research Based on HTML5Primitive Translation Mechanism in Virtual Desktop Systems
  9. A Professional Technology Institute Virtual Design and Realization of the System
  10. Particle Systems’ Applied and Achieved in the Virtual Environment
  11. Design and Implement of Visual Simulation System Based on OpenGL for Rehabilitation Training
  12. The Control Based on the Brain Computer Interface and Research of Virtual Scene Application
    ZhangZuoLin ·Harbin Engineering University ·2013 ·Master's thesis
  13. Natural Landscape Simulation Research Based on Particle System
  14. Research and Application of Vector Visualization Method Based on OpenGL
    LiHaiJie ·Northeastern University ·2013 ·Master's thesis
  15. The Unified Data Model of the Single and Multiple Z Value of Geological Bodies and3D Visualization、Spatial Analysis Research
  16. The Application and Research of Three-Dimensional Reconstruction Technology Based on Opengl in Medical Image System
    LuZuo ·Zhejiang University of Technology ·2013 ·Master's thesis
  17. Based on the Embedded System OpenGL Anti-aliasing Technology Research and Application
  18. The Designment and Realization of Small2D Game Engine
  19. Research and Development of Airport Office Automation Application System Based on Mobile Platform
    GuoJianMing ·Dalian Maritime University ·2013 ·Master's thesis
  20. Design and Presentation of "Minnan Tour of Fighting Against Transgenosis" Mobile Game
    LiaoXueQing ·Xiamen University ·2014 ·Master's thesis