## Printer Device Driver

[prev][next][parent][TOC]

### 32-bit Omni Presentation Driver

Omni is a 32-bit raster-graphics driver developed in conjunction with the OS/2 Warp graphics engine and The Generic Printer Library. The Omni model was designed to provide Independent Hardware/Software Suppliers with a device-driver model that allows them to easily create raster OS/2 Printer Drivers.

Omni driver code consists of two major functional groups. The first group is a generic, core set of functions that are typical to most OS/2 presentation device drivers. These core functions manage the following:

Printer driver enabling and disabling
Device context (DC) initialization
Job and printer property user-interface

The second set of functions are "plug-in" routines that support specific raster languages and printers. Each module requires that a developer need only supply a few functions and fill out a few tables to describe the language and characteristics for the specified printer models. The plug-in functions include the following:

Device query
Job initialization
Page/band rasterization
Job pagination
Job termination
Job abort

The plug-in tables describe the following:

Supported trays
Supported paper sizes
Supported media types
Supported resolutions
Supported print modes (i.e. 1,8,24-bit image formats)

Omni code has been organized into core and plug-in functional groups to simplify a developer's initial attempt to create an OS/2 raster printer driver. However, developers can modify the core Omni code to achieve better support for their devices.

The time required to develop plug-in modules will vary based on the printer language and the developer's experience. On printer models that utilize popular languages, a device can be added in as little as a few hours. Development time will increase in proportion to the level of customizing and extending required for the driver and for the user-interface. Common examples include modifying the user-interface to match another manufacturer 's user-interface and adding support for device or downloadable fonts.

The plug-in module can be designed to "hook out" and provide the functions required for the level of control that best utilizes the printer through its native language and capabilities. Examples of optionally hooked functions include the following:

Subclass all spooler calls (Spl calls)
Subclass all port driver calls (Prt calls)