pwg subset of cups raster€¦ · web viewabstract: this standard defines a proper subset of the...
TRANSCRIPT
May 20, 2023
Working Draft
The Printer Working Group
PWG IPP Subset of CUPS Raster(PWG IPP Raster)
Status: Draft
Abstract: This standard defines a proper subset of the CUPS Raster format for use with IPP Printers. The subset includes support for a small set of standard and device color spaces and bit depths, and also defines Printer description attributes for IPP that enable a Client to generate a supported raster stream for a Printer.
Copyright © 2011 The Printer Working Group. All rights reserved.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16171819
20
May 20, 2023
Working Draft
The Printer Working Group
This document is a PWG Candidate Standard. For a definition of a "PWG Candidate Standard", see: ftp://ftp.pwg.org/pub/pwg/general/pwg-process30.pdf
This document is available electronically at:
ftp://ftp.pwg.org/pub/pwg/ipp/wd/wd-pwgraster10ippraster10-2011012720110126.pdf/.docx
Copyright © 2011 The Printer Working Group. All rights reserved.
2122
23
24
2526
Working Draft – PWG Subset of CUPS Raster May 20, 2023
Copyright © 2011 The Printer Working Group. All rights reserved.
This document may be copied and furnished to others, and derivative works that comment on, or otherwise explain it or assist in its implementation may be prepared, copied, published and distributed, in whole or in part, without restriction of any kind, provided that the above copyright notice, this paragraph and the title of the Document as referenced below are included on all such copies and derivative works. However, this document itself may not be modified in any way, such as by removing the copyright notice or references to the IEEE-ISTO and the Printer Working Group, a program of the IEEE-ISTO.
Title: PWG IPP Subset of CUPS Raster (PWG IPP Raster)
The IEEE-ISTO and the Printer Working Group DISCLAIM ANY AND ALL WARRANTIES, WHETHER EXPRESS OR IMPLIED INCLUDING (WITHOUT LIMITATION) ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
The Printer Working Group, a program of the IEEE-ISTO, reserves the right to make changes to the document without further notice. The document may be updated, replaced or made obsolete by other documents at any time.
The IEEE-ISTO takes no position regarding the validity or scope of any intellectual property or other rights that might be claimed to pertain to the implementation or use of the technology described in this document or the extent to which any license under such rights might or might not be available; neither does it represent that it has made any effort to identify any such rights.
Page 3 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
1
2
27
28
29303132333435
36
37
38
39404142
43
444546
47
4849505152
53
3
4
Working Draft – PWG Subset of CUPS Raster May 20, 2023
The IEEE-ISTO invites any interested party to bring to its attention any copyrights, patents, or patent applications, or other proprietary rights which may cover technology that may be required to implement the contents of this document. The IEEE-ISTO and its programs shall not be responsible for identifying patents for which a license may be required by a document and/or IEEE-ISTO Industry Group Standard or for conducting inquiries into the legal validity or scope of those patents that are brought to its attention. Inquiries may be submitted to the IEEE-ISTO by e-mail at: [email protected].
The Printer Working Group acknowledges that the IEEE-ISTO (acting itself or through its designees) is, and shall at all times, be the sole entity that may authorize the use of certification marks, trademarks, or other special designations to indicate compliance with these materials.
Use of this document is wholly voluntary. The existence of this document does not imply that there are no other ways to produce, test, measure, purchase, market, or provide other goods and services related to its scope.
About the IEEE-ISTO
The IEEE-ISTO is a not-for-profit corporation offering industry groups an innovative and flexible operational forum and support services. The IEEE-ISTO provides a forum not only to develop standards, but also to facilitate activities that support the implementation and acceptance of standards in the marketplace. The organization is affiliated with the IEEE (http://www.ieee.org/) and the IEEE Standards Association (http://standards.ieee.org/).
For additional information regarding the IEEE-ISTO and its industry programs visit:
Page 4 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
5
6
54555657585960
61
62636465
66
676869
70
71
72
737475767778
79
80
7
8
Working Draft – PWG Subset of CUPS Raster May 20, 2023
http://www.ieee-isto.org.
About the IEEE-ISTO PWG
The Printer Working Group (or PWG) is a Program of the IEEE Industry Standards and Technology Organization (ISTO) with member organizations including printer manufacturers, print server developers, operating system providers, network operating systems providers, network connectivity vendors, and print management application developers. The group is chartered to make printers and the applications and operating systems supporting them work together better. All references to the PWG in this document implicitly mean “The Printer Working Group, a Program of the IEEE ISTO.” In order to meet this objective, the PWG will document the results of their work as open standards that define print related protocols, interfaces, procedures and conventions. Printer manufacturers and vendors of printer related software will benefit from the interoperability provided by voluntary conformance to these standards.
In general, a PWG standard is a specification that is stable, well understood, and is technically competent, has multiple, independent and interoperable implementations with substantial operational experience, and enjoys significant public support.
For additional information regarding the Printer Working Group visit:
http://www.pwg.org
Page 5 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
9
10
81
82
83
84
85
86
8788899091929394959697
98
99100101
102
103
104
105
11
12
Working Draft – PWG Subset of CUPS Raster May 20, 2023
Contact information:
The Printer Working Group
c/o The IEEE Industry Standards and Technology Organization
445 Hoes Lane
Piscataway, NJ 08854
USA
Page 6 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
13
14
106
107
108
109
110
111
112
113
114
15
16
Working Draft – PWG Subset of CUPS Raster May 20, 2023
About the Internet Printing Protocol Work Group
The Internet Printing Protocol (IPP) working group has developed a modern, full-featured network printing protocol which is now the industry standard. IPP allows a print client to query a printer for its supported capabilities, features, and parameters to allow the selection of an appropriate printer for each print job. IPP also provides job information prior to, during, and at the end of job processing.
For additional information regarding IPP visit:
http://www.pwg.org/ipp/
Implementers of this specification are encouraged to join the IPP mailing list in order to participate in any discussions of the specification. Suggested additions, changes, or clarification to this specification, should be sent to the IPP mailing list for consideration.
Page 7 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
17
18
115
116
117118119120121
122
123
124
125
126
127128129
19
20
Working Draft – PWG Subset of CUPS Raster May 20, 2023
Table of Contents
1. Introduction......................................................................................................................7
2. Terminology.....................................................................................................................7
2.1 Conformance Terminology.........................................................................................7
2.2 Other Terminology.....................................................................................................7
3. Requirements..................................................................................................................8
3.1 Rationale for the PWG Subset of CUPS Raster........................................................8
3.2 Use Models................................................................................................................8
3.3 Design Requirements................................................................................................8
4. Subset of CUPS Raster Format.......................................................................................9
4.1 Format Version..........................................................................................................9
4.2 Word Order................................................................................................................9
4.3 Page Header..............................................................................................................9
4.3.1 cupsBitsPerColor, cupsBitsPerPixel, cupsColorOrder, and cupsColorSpace.....9
4.3.2 cupsWidth and cupsHeight................................................................................10
4.3.3 HWResolution...................................................................................................10
5. Printer Description Attributes.........................................................................................10
5.1 cups-back-side (type2 keyword)..............................................................................10
5.2 cups-raster-supported (1setOf type2 keyword)........................................................11
Page 8 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
21
22
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
23
24
Working Draft – PWG Subset of CUPS Raster May 20, 2023
6. Conformance Requirements..........................................................................................11
7. Internationalization Considerations................................................................................11
8. Security Considerations.................................................................................................11
9. IANA Considerations.....................................................................................................11
10. References..................................................................................................................11
10.1 Normative References...........................................................................................11
11. Author's Addresses......................................................................................................11
12. Change History............................................................................................................11
12.1 December 9, 2010.................................................................................................12
List of Tables
Table 1 - Required Color Order, Color Space, and Bit Depth Combinations.......................9
Page 9 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
25
26
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
27
28
Working Draft – PWG Subset of CUPS Raster May 20, 2023
1. Introduction
CUPS Raster [CUPSRASTER] has been used to facilitate raster printing using traditional printer drivers since 1999. The format supports platform-agnostic multi-page printing using many device and standard Color Spaces, bit depths, Color Orders, and printer features. A compressed variant (version 2) uses a combination of run-length encoding compression algorithms to efficiently reduce the size of raster data when transferred over external interfaces such as networks. This variant can also be further reduced in size using HTTP or IPP compression algorithms such as Compress and Flate.
This standard defines a proper subset of CUPS Raster for use with IPP Printers. The subset includes support for a small set of standard and device Color Spaces and bit depths, and also defines Printer description attributes for IPP that enable a Client to generate a supported raster stream for a Printer.
2. Terminology
2.1 Conformance Terminology
Capitalized terms, such as MUST, MUST NOT, REQUIRED, SHOULD, SHOULD NOT, MAY, and OPTIONAL, have special meaning relating to conformance as defined in RFC 2119 [RFC2119].
2.2 Other Terminology
Color Component; an individual element or channel for a Color Space or Pixel, for example “Red”, “Green” and “Blue” are Color Components of the “RGB” Color Space.
Page 10 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
29
30
166
167168169170171172173
174
175176177178
179
180
181182183
184
185186
187
31
32
Working Draft – PWG Subset of CUPS Raster May 20, 2023
Color Order; the order of Color Components within the Page Bitmap. These Color Orders are called “Chunked”, “Banded”, and “Planar” in the CUPS Raster Format specification [CUPSRASTER].
Color Space; the interpretation of color in a page bitmap, for example “RGB”, “Grayscale”, “CMYK”, and so forth.
CUPS Raster; the image file format defined by [CUPSRASTER].
PackBits; a simple run-length encoding algorithm for data compression. Each sequence is encoded as a series of repeated or non-repeated Pixels.
Page Bitmap; a rectangular grid of Pixels.
Page Header; the binary dictionary of PostScript and raster key values for a Page Bitmap.
Pixel; a set of Color Components representing a single grid point in a Page Bitmap.
3. Requirements
3.1 Rationale for the PWG Subset of CUPS Raster
CUPS Raster supports many more Color Spaces, Color Orders, bit depths, and byte orders than are needed for a modern Printer. Moreover, the PostScript page device
Page 11 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
33
34
188189190
191
192193
194
195
196
197198
199
200
201
202
203
204
205
206
207208
35
36
Working Draft – PWG Subset of CUPS Raster May 20, 2023
dictionary does not map cleanly to IPP or the PWG Semantic Model, leading to additional complexities that would make interoperability difficult.
By defining a proper subset of CUPS Raster, we both enable support for a new class of IPP Printer without the use of printer- and platform-specific driver software in the client and greatly reduce the number of variables for interoperability.
3.2 Use Models
Jane has a smart phone with Wi-Fi capability and a built-in camera. She prints photos from her phone to a low-cost Wi-Fi inkjet printer. The printer has limited memory and processor resources that support basic raster printing on a variety of media types and sizes.
John has a desktop PC he uses to write whitepapers and other business documents. He prints these documents to a low-cost Ethernet workgroup laser printer with three paper trays and a duplexing accessory. The printer has enough memory to hold a partial image of one side of a sheet.
3.3 Design Requirements
Since both the client and IPP Printer may have limited memory, a raster format for printing must be streamable to minimize buffering.
Limited network bandwidth requires some form of data compression. Text printing favors lossless compression algorithms to preserve edge detail and resource limitations require simpler compression algorithms.
Page 12 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
37
38
209210
211
212213214
215
216217218219
220
221222223224
225
226227
228
229230231
232
39
40
Working Draft – PWG Subset of CUPS Raster May 20, 2023
Because the client may not have sophisticated color management capabilities, standard color spaces should be used to foster improved color fidelity. Similarly, an IPP Printer may have limited space for color tables, however it should still be possible to support a managed color workflow when both the client and IPP Printer are capable. A bi-level imaging mode may also be useful when printing text and line art.
Because the IPP Printer may have limited memory, the client must be able to discover the supported raster resolutions and how to provide duplex page images – no flip, X flip, Y flip, or rotation by 180 degrees (both X and Y flip).
Finally, to limit the complexity of implementation the order of multi-octet values should be predefined.
4. Subset of CUPS Raster Format
The CUPS Raster specification [CUPSRASTER] defines three format variants for the MIME media type “application/vnd.cups-raster”. The following subsections define the subset used for the MIME media type “image/cups”.
4.1 Format Version
All “image/cups” streams MUST use format version 2.
4.2 Word Order
All “image/cups” streams MUST use network ("big endian") byte order.
Page 13 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
41
42
233234235236237
238
239240241
242
243244
245
246247248
249
250
251
252
43
44
Working Draft – PWG Subset of CUPS Raster May 20, 2023
4.3 Page Header
All "image/cups" streams MUST initialize the cupsBitsPerColor, cupsBitsPerPixel, cupsBytesPerLine, cupsColorOrder, cupsColorSpace, cupsHeight, cupsWidth, and HWResolution fields in the page header. All other fields MUST be initialized to 0.
4.3.1 cupsBitsPerColor, cupsBitsPerPixel, cupsColorOrder, and cupsColorSpace
All “image/cups” streams MUST use one of the following combinations of cupsBitsPerColor, cupsBitsPerPixel, cupsColorOrder, and cupsColorSpace values defined in Table 1, "Allowed Color Order, Color Space, and Bit Depth Combinations".
4.3.2 cupsWidth and cupsHeight
The cupsWidth and cupsHeight fields MUST be initialized to the full width and height of the current page in addressable units as defined by the HWResolution field. Thus, each page bitmap provides a "full bleed" page image.
4.3.3[4.3.2] HWResolution
The HWResolution field MUST be initialized to either one of the supported values reported by the "printeripp-raster-resolution-supported" attribute or a compatible lower resolution. A compatible lower resolution is an integral divisor of a "printeripp-raster-resolution-supported" value, for example 360x360dpi for a printer that supported 720x720dpi.
:
Table 1 - Required Allowed Color Order, Color Space, and Bit Depth Combinations
cupsBits-PerColor
cupsBits-PerPixel
cupsColor-Order
cupsColorSpace
cupsipp-raster-types-supported
Page 14 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
45
46
253
254255256
257
258259260
261
262263264
265
266267268269
270
271
272
47
48
Working Draft – PWG Subset of CUPS Raster May 20, 2023
1 1 0 3 (black) black-1
1 1 0 18 (sGray) sgray-1
8 8 0 3 (black) black-8
8 32 0 6 (CMYK) cmyk-8
8 8 0 18 (sGray) sgray-8
8 24 0 19 (sRGB) srgb-8
8 24 0 20 (AdobeRGB) adobe-rgb-8
16 16 0 3 (black) black-16
16 64 0 6 (CMYK) cmyk-16
16 16 0 18 (sGray) sgray-16
16 48 0 19 (sRGB) srgb-16
16 48 0 20 (AdobeRGB) adobe-rgb-16
4.4 Page Bitmap
Each page bitmap in an "image/cups" stream represents a full-bleed image.
4.4.1 cupsWidth and cupsHeight
The cupsWidth and cupsHeight fields MUST be initialized to the full width and height of the current page in addressable units as defined by the HWResolution field. Thus, each page bitmap provides a "full bleed" page image.
Page 15 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
49
50
273
274
275
276277278
51
52
Working Draft – PWG Subset of CUPS Raster May 20, 2023
[4.4.1] HWResolution
The HWResolution field MUST be initialized to either one of the supported values reported by the "printer-resolution-supported" attribute or a compatible lower resolution. A compatible lower resolution is an integral divisor of a "printer-resolution-supported" value, for example 360x360dpi for a printer that supported 720x720dpi.
5. Printer Description Attributes
This specification defines two three new Printer attributes..
[5.1] cupsipp-raster-back-side (type2 keyword)
This REQUIRED Printer attribute specifies the bitmap coordinate system for the back side of duplex sheets. The following keyword values are defined:
"normal" - The the back side has the origin at the top-left corner of the bitmap,
"manual-tumble" - The the back side has the origin at the top-left corner of the bitmap for "two-sided-long-edge" and the bottom-right corner (rotated 180º) of the bitmap for "two-sided-short-edge",
"rotated" - The the back side image has the origin at the bottom-right corner (rotated 180º) of the bitmap for "two-sided-long-edge" and the top-left corner of the bitmap for "two-sided-short-edge", or
"flipped" - The the back side image has the origin at the bottom-left corner (X flipped) of the bitmap for "two-sided-long-edge" and the top-right corner (Y flipped).
Page 16 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
53
54
279
280281282283
284
285
286
287288
289
290
291
292293294
295
296297298
299
300301
55
56
Working Draft – PWG Subset of CUPS Raster May 20, 2023
5.1[5.2] ipp-raster-resolution-supported (1setOf resolution)
This REQUIRED Printer attribute lists the supported bitmap resolutions in dots per inch. Printers MUST accept "image/cups" streams for the highest reported resolution on the largest supported media.
5.2 cupsipp-raster-types-supported (1setOf type2 keyword)
This REQUIRED Printer attribute lists the supported Color Space and bit depth combinations. Table 1, "Allowed Color Order, Color Space, and Bit Depth Combinations", defines the keyword values for each combination.
[6.] Conformance Requirements
[6.1] This is where we can require a printer to accept CUPS Raster at various resolutions, color spaces, etc.IPP Printer Conformance Requirements
To claim conformance to this specification, an IPP Printer implementation MUST:
(a) support the "image/cups" MIME media type as defined in section 4 of this specification;
(b) support all IPP attributes defined in section 5 of this specification;
(c) conform to the Internationalization Considerations defined in section 7 of this specification; and
(d) conform to the Security Considerations defined in section 8 of this specification.
5.3 IPP Client Conformance Requirements
To claim conformance to this specification, an IPP Client MUST:
Page 17 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
57
58
302
303304305
306
307308309
310
311
312313
314
315316
317
318319
320
321
322
59
60
Working Draft – PWG Subset of CUPS Raster May 20, 2023
(a) generate the "image/cups" MIME media type as defined in section 4 of this specification;
(b) explicitly identify the supported values of all IPP attributes defined in section 5 of this specification;
(c) conform to the Internationalization Considerations defined in section 7 of this specification; and
(d) conform to the Security Considerations defined in section 8 of this specification.
6.[7.] Internationalization Considerations
For interoperability and basic support for multiple languages, conforming implementations MUST support the UTF-8 [RFC3629] encoding of Unicode [UNICODE] [ISO10646].
7.[8.] Security Considerations
IPP Printers MUST range check all page header and bitmap values to protect against integer and buffer overflows.Provide security considerations for this specification.
8.[9.] IANA Considerations
Name : Michael Sweet
E-mail : [email protected]
MIME media type name : Image
MIME subtype name : Standards Tree - cups
Page 18 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
61
62
323324
325326
327328
329
330
331332
333
334335
336
337
338
339
340
341
342
343
63
64
Working Draft – PWG Subset of CUPS Raster May 20, 2023
Required parameters : NONE
Optional parameters : NONE
Encoding considerations :
8-bit (raw) binary data.
Security considerations :
Raster data can be very large, which could fill a filesystem and
cause a denial of service or system failure.
Raster data contains no executables or macros. Authentication and
access control are normally handled by the Internet Printing Protocol
and Hyper-Text Transport Protocol.
Interoperability considerations :
NONE
Published specification :
Page 19 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
65
66
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
67
68
Working Draft – PWG Subset of CUPS Raster May 20, 2023
ftp://ftp.pwg.org/pub/pwg/candidates/cs-ippraster10-YYYYMMDD.pdf
Applications which use this media :
CUPS
IPP Everywhere
Additional information :
1. Magic number(s) :
2. File extension(s) :
3. Macintosh file type code :
Person to contact for further information :
1. Name : Michael Sweet
2. E-mail : [email protected]
Intended usage : Common
Used for printing "raw" image data in formats acceptable to printers.
Page 20 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
69
70
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
71
72
Working Draft – PWG Subset of CUPS Raster May 20, 2023
Author/Change controller :
Michael Sweet
Apple Inc.
10431 N. De Anza Blvd.
MS 38-4LPT
Cupertino CA 95014Provide IANA registration information for this specification.
9.[10.] References
9.1[10.1] Normative References
[CUPSRASTER] “CUPS Raster Format”, http://www.cups.org/spec-raster.html
[RFC2911] "Internet Printing Protocol/1.1: Model and Semantics"
[RFC3805] "Printer MIB v2"
10.[11.] Author's Addresses
Michael Sweet
Apple Inc.
10431 N. De Anza Blvd.
MS 38-4LPT
Cupertino CA 95014
Page 21 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
73
74
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
75
76
Working Draft – PWG Subset of CUPS Raster May 20, 2023
11. Change History
[ PWG Secretary: This section must be removed when Document is approved ]
11.1 January 26, 2011
1. Updated document title and filename to use "IPP" as the prefix instead of "PWG".2. Added normative references to RFC 2911 and RFC 38053. Changed "cups-raster" prefix on attributes to "ipp-raster"4. Added "ipp-raster-resolutions-supported" attribute5. Added page bitmap section6. Added conformance requirements7. Added IANA registration info
11.2 January 24, 2011
Initial draft.
Page 22 of 22 Copyright © 2011 The Printer Working Group, All rights reserved.
77
78
402
403
404
405406407408409410411
412
413
79
80