TAILIEUCHUNG - 3D Graphics with OpenGL ES and M3G- P34

3D Graphics with OpenGL ES and M3G- P34:Mobile phones are the new vehicle for bringing interactive graphics technologies to consumers. Graphics that in the 1980s was only seen in industrial flight simulators and at the turn of the millennium in desktop PCs and game consoles is now in the hands of billions of people. This book is about the technology underpinnings of mobile threedimensional graphics, the newest and most rapidly advancing area of computer graphics. | 314 BASIC M3G CONCEPTS CHAPTER 13 own exporters viewers or optimization tools for M3G content or simply need to debug an existing file. The simplicity is achieved by four primary means First there is a one-to-one mapping between object types in the file format and Java classes in the run-time API. Second there are no forward references so objects can only refer to objects that reside earlier in the file. Third compression is based on the widely available zlib rather than specialized encodings for different data types or complex algorithms such as arithmetic coding. Finally the Loader has an all-or-nothing policy a file is either loaded completely or not at all. No attempt is made to recover from errors. We will now go through the structure of the file format shown at a high level in Figure . To shed light on individual details we will refer to the example file in Figure . Note that what follows is not intended to be an exhaustive description or a replacement for the specification but only to give you an idea of how things are laid out. Having read this you should be able to more quickly dig up whatever details you need in the spec. File structure M3G files are easy to recognize in a text editor by their file identifier JSR184 located at the very beginning. To be exact the identifier consists of that string and a few special characters to quickly catch file transmission errors for a total of twelve bytes in hexadecimal AB 4A 53 52 31 38 34 BB 0D 0A 1A 0A. File Section Object Data Figure M3G files are divided into sections each containing one or more objects which are further divided into fields. The fields are laid out in the order of class inheritance for example a . object is derived from Object3D Transformable Node and Mesh as shown in Figure . SECTION IMPORTING CONTENT 315 File Identifier I I J I S I R I 1 I 8 I 4 I 0x0D 0x0A 0x1A 0x0A Header Section .X ObjectType 0 Header 0 TotalSectionLength 30 UncompressedLength 30 0 ObjectLength 12 1 0

Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.