XGL Architecture Guide
  Sök endast i den här boken
Ladda ner denna bok i PDF

............................Contents


Preface
xiii

1. Introduction to XGL
1
...Introduction to the XGL Product 1
......Running an Application in the X Window Environment 2
...Introduction to the XGL Programming Model 4
......What Is an XGL Object? 4
......How the XGL Programming Interface Works 5
......XGL Object-Oriented Programming 8
...Overview of XGL Functionality 9
......Opening and Closing the XGL Library 9
......Graphical Display 9
......Primitives 11
......Graphical Context 12
......Transformations 14
......XGL Viewing Pipeline 14
......Color 16
......Lighting and Shading 18
......Stroke Fonts 18
......Raster Text 18
......Line Patterns 19
......Geometry Caching 19
......NURBS Curves and Surfaces 20
......Texture Mapping 20

2. Overview of the XGL Architecture
21
...XGL Architecture Design Goals 22
...Basic Components of the XGL Architecture 22
......Device-Independent Library 23
......Graphics Pipelines 23
...Overview of the Device Pipeline Architecture 28
......Architecture at the API Level 29
......Internal Pipeline Architecture 29
...Software Pipeline and Pipeline Switching 34
...Handling Context State Changes 34
......First Things First: What Is Context? 35
......Explicit XGL State Changes 36
......Intraprocess State Changes 36
...Window System Interaction 37
...Color 39

3. XGL Class Structure
41
...Overview of the XGL Class Structure 41
...Device-Independent Classes 42
......Classes That Implement the XGL API 43
......Classes That Provide Internal Utility Functions 45
...Device Pipeline Classes 48
......Pipeline Library Class Hierarchy 49
......Device Pipeline Manager Class Hierarchy 51
......Device-Dependent Device Class Hierarchy 52
......Pipeline-Context Class Hierarchy 53
...Classes for Internal Data Storage 55

4. Object Interactions
57
...Opening XGL 57
...How API Calls Are Mapped to XGL Internal Calls 58
...Instantiation of API Objects 58
......System State Object and API Object Lists 59
......What Is a Device Object? 60
......What Is a Context Object? 61
......Device and Context Association 62
...How the Pipelines Are Created and Managed 64
......The XGL Environment Is Set Up 64
......A Device Object Is Created 65
......A Context Object Is Created 66
......The Device Is Associated With the Context 66
...Object Communication 68
......API Object Relationships 68
......Architecture of Object Relationships 69
......Object Registration: The User List 70
......Message Passing 73
...Destroying Objects and Closing XGL 75
......Destroying the Device Object 75
......Destroying the Context Object 75
......Closing XGL 76

5. Rendering and Handling State Changes
77
...Goals of the Rendering Architecture 77
......How Rendering Works 78
......What Is the opsVec Array? 79
......Device Pipeline Options for Rendering 81
......More on the Rendering Architecture 82
...Context State Changes 83
......State Changes From Attribute Setting 84
......State Changes From XGL Object Message Passing 86
......View Model Derived Data 88
......Changes in Context Stroke Attributes 92
...Device State Changes 94
...Rendering Into Backing Store 95
......Architecture of Backing Store 95
......Creating a Shadow Device 97
......Rendering Into the Backing Store Device 99
......Propagation of API Changes to the Backing Store Device . 103
......Backing Store Support for the Z-Buffer and Accumulation
........Buffer 103

6. Error Handling
105
...Design Goals 105
...Overview of Error Handling 105
...External Error Handling Mechanism 106
......Error Notification Function 106
......Error Types and Categories 107
...Internal Error Handling Mechanism 109

7. XGL Coding Guidelines
111
...Naming Conventions for C++ Constructs 111
...Naming Conventions for C++ Internal Classes 115
...Coding Conventions for set() and get() Interfaces 116
......Conventions for set() Member Functions 116
......Conventions for get() Member Functions 117

Index
119