X Server Device Developer's Guide
  Search only this book
Download this book in PDF

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


Preface
xvii

New Features and Changes
xxiii

1. DDX Porting Overview
1
...The DDX Interface 2
...The Loadable DDX 3
......Simple Frame Buffer Support 3
......Multiple-Plane Group Support 3

2. The Loadable DDX Interface
5
...How the Server Interfaces With the Loadable DDX Handler 5
......The Initialization Function 7
......Device Self-Identification 8
......DDX Versioning 9

3. Screen Initialization
13
...Initialization Steps 14
......sunGetDDKVersion 15
......Initialize the ScreenRec Functions 15
......sunScreenAllocate 16
......Device-Dependent Initialization 17
......sunSetPixmapFormat 18
......sunGetMonitorRes 20
......sunGetVisualInfo 20
......Export Supported Visuals 21
......Initialize Utility Layers 21
......Initialize the Banner Code 21
......Supply a SaveScreen Function 22
......Supply a CloseScreen Function 23
...Initializing Visual Gamma 24
......Gamma-Corrected Visuals 24
......The Monitor Intensity Response Property 25
......Initializing a Root Window Property 26

4. Cursors
29
...The Basic DDX Interface 29
...Software Cursor 30
......miDC Layer 30
......miPointer Layer 32
......miSprite Layer 33
......miSetZeroLineBias Function 34
...Hardware Cursor 34
......The sunSprite Layer 35
......Examples of miPointerSpriteFuncs 37
......Kernel Cursor Tracking - The sunHWCursor Layer 41

5. Multiple Plane Group Interface
45
...MPG Architectural Overview 45
......Data Structure Initialization 47
...MPG Functional Interface 48
......initPixmap 48
......mpgGetScreenState 49
......mpgInsertPlanegroup 51
......Plane Group Aliasing 53
......mpgScreenInit 57
......getMpgInfoFromVisual 59
......mpgChangeInfo 59
......freeMpgInfo 60
......mpgCursorInitialize 60
......mpgSetCursorValues 61
......mpgSetCursorHasEnable 61
......CopyPlanes and AggregatePlanes 61
......mpgSetScreenFuncs 65

6. Overlay Window Interface
67
...Introduction 67
...Device Setup 68
......Transparent Pixel 69
...Initializing Overlays 72
...Overlay GPI Specification 73
......OvlPairs 73
......ovlScreenInit 73
......ovlWrapDevFuncs 74
......ovlGetPaintType 75
......ovlIsOverlay 75
......XOvlClutInfo 76
......OvlDevFuncs 76

7. Window ID Interface
85
...Hardware Window IDs 85
...Software WID Object 86
......WID Object Attributes 86
...Accessing WID 88
...Using MPG 88
...How to Use WID 88
......DDX Handler 88
......MPG 89
......CMAP 89
...WID Data Types 90
......WidPtr 90
......WidAllocFunc 91
......WidFreeFunc 92
......WidSetColorLutFunc 92
...Window ID Functions 93
......General Routines 93
......Handler-Specific Routines 99
...WID Device-Dependent Allocation and Free Functions
......Implementation 100
......Allocation Function 101
......Free Function 102

8. Colormap Interface
105
...Introduction to CMAP 105
...CMAP Call Summary 106
......General Calls 106
......MHC Calls 106
...Compiling and Linking 106
...MPG and WID Initialization 107
...CMAP Initialization and Utilities 108
......Screen Initialization Routine 108
......Device-Dependent Color LUT Access Routines 109
......Color LUT Pool Description 116
......Initialization Example - Multiple Color LUT 125
......Initialization Example - Single Color LUT 126
......WID Types 127
......Utility Routines 127
......Colormap Private Data 129
...Controlling MHC's WIDs 130
......Overloading WIDs 131
......Overloading Control Routines 132
...Changing a Window's WID 134
......cmapMhcWindowAttachWid 134
......cmapMhcWindowDetachWid 135
...Changing A Window's Colormap 135
......cmapMhcChangeFlavor 136
......Allocating Unique WIDs 138

9. Multibuffering Extension to X Interface
141
...Multibuffering 141
......Multibuffered Windows and Multibuffer Sets 141
......Multibuffer Flip Modes 142
...HW MBX Functions 143
......MbxScreenInit 143
......MbxDevFuncs 144
......TryMpg 144
......CreateMultibuffer2 146
......DestroyMultibuffer 147
......ResizeMultibuffer 148
......RepositionMultibuffer 149
......DisplayMultibuffer 149
......SetupMultibufferInvisible 150
......SetMultibufferVisible 151
......LastUpdateTime 151

10. Direct Graphics Access Drawable Client Interface
153
...Overview 153
......Drawable Types 154
......DGA Drawables 154
......Mutual Exclusion 155
......Sites 156
......Backing Store 157
...Compiling and Linking 158
...DGA Drawable Functions 159
......Initialization and Cleanup 159
......Drawable Locking and Change Detection 162
......General Utility Functions 166
......Drawable Sites 170
......Clipping State 175
......Dealing with Cursor Conflicts 180
......Backing Store Routines 182
......Colormap Grabber Interface 188
......Multibuffering Grabber Interface 192
......Miscellaneous Grabbers 201
......Zombie Drawables 204
......DGA Overlays 205

11. Direct Graphics Access Drawable DDX Interface
209
...Initializing Drawable Grabs 209
...Device-Supplied Routines 211
...Server-Supplied Multibuffering Routines 222
...Caching Routines 226
...Device Information Routines 228
...DGA and Colormaps 229

12. Input Devices
231
...Extension Input Device Overview 232
...Handling of Extension Input Devices 233
......Extension Device Initialization 233
......Extension Device Open 234
......Reading Input Data 234
......Extension Device Close 236
......Restart and Shutdown 236
...Adding An Extension Input Device 236
......Writing the Device Handler 237
......Adding An OWconfig File Entry 240
......Debugging the Device Handler 240
......Writing The STREAMS Module 241
...Input Library Functions 241
......Public Server Functions 241
......Device Shared Library Functions 260

13. Direct Pixel Access DDX Interface
269
...The Direct Access Cycle 269
...Requirements for Drawables Using DPA 270
...Initialization 271
......sunDPAScreenRec 271
......sunDPAScreenInit 272
...Device-Supplied Routines 273
......sunDPAAccessType 273

14. Debug Server Modules
277

15. MIT Shared Memory Extension
279
...MIT Shared Memory Interface 280
......ShmRegisterFbFuncs 280
......ShmRegisterFuncs 281
......ShmSetPixmapFormat 281

A. The OWconfig File
283
...SPARC: Sample OWconfig File 284
...x86: Sample OWconfig File 286
...PowerPC: Sample OWconfig File 288
...File Format Definition 289
...File and Module Search Paths 291
...The XDISPLAY Class 292
...The XSCREENCONFIG Class 293
...The XSCREEN Class 294
...The XINPUT Class 295
......SPARC: Sample XINPUT Class 295
......x86: Sample XINPUT Class 295
......PowerPC: Sample XINPUT Class 296
...The XEXTENSION Class 296
...OWconfig Access Method 297
......OWconfig Database 297
......OWconfig API 297
......Packaging 300
......Typical Usage 300

B. Packaging and Installation Hints
303
...Installation Hints 303
...Packaging Hints 304

C. Virtual User Input Device Interface
309
...Virtual User Input Device (vuid) 309
...Vuid Station Codes 310
...Firm Events 311
...Device Controls 313

D. Dynamically Loadable Extensions
315

Index
317