Overview of the Printing Process

This section provides a general overview of printing at a Windows NT Workstation. Although the primary focus of this chapter is on local printing from the Windows NT Workstation itself, you can also provide printing to as many as 10 peer-to-peer connections with the Windows NT Workstation functioning as the print server. For more information about network printing using a Windows NT 4.0 Workstation as a print server, see "Network Printing Using Windows NT Workstation" later in this chapter.

1. The user at the Windows NT Workstation chooses to print a document.

For the Windows NT Workstation or for a client running any Windows operating system and printing from a Windows application, the application calls the graphics device interface (GDI). GDI calls the printer driver associated with the target print device. Using the document information from the application and the print device information from the printer driver, GDI renders the print job in the printer language of the print device.

2. The print job gets passed to the spooler.

The client side of the spooler (Winspool.drv) makes a remote procedure call (RPC) to the server side of the spooler (Spoolss.exe), which makes a direct application programming interface (API) call to the router (Spoolss.dll). The router passes the print job to the local print provider (Localspl.dll), which spools it (writes it to disk).

3. The print job is altered, if necessary, to print correctly.

The local print provider (Localspl.dll) polls the print processors. When a print processor recognizes the job's data type, that print processor receives the print job and alters it (or not) according to its data type to ensure that the job prints correctly.

4. Control of the print job passes to the separator page processor, which adds a separator page, if specified, to the front of the job.

5. The job is despooled to the print monitor.

If the print device is bi-directional, the monitor is a language monitor, which handles bi-directional communication with the printer and then passes the job to the port monitor.

If the print device is not bi-directional, the job goes directly to the port monitor, which transmits the print job to the print device or to another server over a specific communications channel.

6. The print device receives the print job, translates it into a bitmap, and prints it onto paper or another medium.