Resources related to the AFP Renderer

IBMs Advanced Function Presentation (AFP) has been described as “a document architecture, a printer dialog and datastream, and a process for fully system managing printing.” Unfortunately that doesn't tell much and seems to be typical marketing language. When it comes to the FOP AFP Renderer it only deals with creating documents conforming to the AFP document architecture. This architecure is called MO:DCA (Mixed Object Document Content Architecture). The following text is taken from:

Data Stream & Object Architectures: MO:DCA Reference (SC31-6802-06)

Begin Quote
A mixed object document is the collection of data objects that comprise the document's content, and the resources and formatting specifications that dictate the processing functions to be performed on the content. The term Mixed in the MO:DCA architecture refers both to the mixture of data objects and the mixture of document constructs that comprise the document's components. A MO:DCA document can contain a mixture of presentation data objects. Each data object type has unique processing requirements. An Object Content Architecture (OCA) has been established for each IBM data object to define its respective syntax and semantics. MO:DCA documents can contain data and data objects governed by the following OCAs:

To generate MO:DCA documents (datastreams in the AFP language) one needs the relevant specifications. Here is how to get them:

For those who don't have access to an IBM AFP environment it is very difficult to verify the correctness of any generated MO:DCA document. The AFP Consortium provides a validator tool to Members for AFP Interchange Set 3. Information for joining the AFPC is available on the website.

Some free tools are also available to help.

Other AFP Tools

Tips for developing with AFP

MO:DCA & Co. have grown over time but the specifications usually don't tell if a particular feature is an old or new feature. There are still a lot of AFP/IPDS environments around which only support a very old version and only bi-level printing. Relying on just the AFP Workbench has proven to be insufficient as this viewer supports a lot of features and is quite lenient about what you do in AFP. Furthermore, fonts are painted using operating system outline fonts even if you specify bitmap fonts in your print files. Obviously, the best way to test is having an older IPDS laser printer around but there you have the problem that you get non-helpful error messages if something's wrong. Additional, unfortunately commercial, viewer applications can help further during debugging. AFP dumpers like AFPAN (see above) are also a very important source for information. It is quite sensitive to mistakes. Rule number one: Test in as many environments as possible. No single tool will be able to tell you that the file you produced is correct and works in most environments.

When implementing AFP features it's a very good idea to use the most simple methods available. For example, for bi-level bitmap images, it's best to use the FS10 function set. Or if you want to reduce print file size or improve printing performance, images should not be included as image objects (because Include Object IOB is not available everywhere). Instead, page segments should be used even if that means that you have to embed the same image twice if it needs to be printed in two different sizes (because Include Page Segment IPS doesn't support scaling). But that has another advantage: you can make use of hard page segments which allows to transfer images to the printer separately, thus conserving bandwidth and processing power in the print processor.

In 2009 AFP transitioned to an open standard managed by the AFP Consortium http://www.afpcinc.org. In August 2011 a new "Interchange Set" (IS/3) was defined which excludes some outdated resources which have been replaced by updated technology (e.g. FOCA bit map fonts replaced by TrueType / OpenType). Many shipping components, such as print servers and printers, will continue to receive and handle legacy AFP datastream but generators are encouraged to transition to IS/3 for improved overall interoperability.

AFPResources (last edited 2011-09-16 22:27:25 by Harry Lewis)