PWG Subset of CUPS Raster€¦ · Web viewAbstract: This standard defines a proper subset of the CUPS Raster format for use with IPP Printers. The subset includes support for a
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
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.
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.
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:
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:
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.
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.
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
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.
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.
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
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.
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).
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.
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:
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.
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