Skip to main content
Skip table of contents

Hqn076 - Integrating and configuring screening modules for HMR

 

Introduction

This document describes how to integrate and configure screening modules for the GUI RIP. A number of screens are supplied with the Harlequin RIP. It is possible however to add custom screening modules. These must be integrated using the following procedures.

Example modules

In order to illustrate the installation and configuration of a screening two examples are provided in the Plugin Kit. You will find them here:

\HarlequinRIP_X_X_Generic\PluginKit\HTMScreening\examples\src

where X_X is the version number of the release.

htm4x4

This file provides an example of a bi‐level halftone. This could not be produced using PostScript language thresholds because, when moving from one shade to a darker shade, pixels can be extinguished as well as lit.


htm8ml

This file provides an example of threshold tables. Threshold tables can be thought of as very small, square, HDS cells (Harlequin Dispersed Screening). However, they are not used as a simple threshold screen, but as a distribution table. A contone level above or below the required level is chosen according to the value in the table aligned on the raster grid.

These files are provided to illustrate the various possibilities available with screening modules. Better, more efficient methods can be achieved.

Installing the screen

Adding the screen to the core RIP

This process makes the screen available to the core RIP, but it cannot be used by HMR until it is given a Dot shape name, see Configure the screen for use with HMR below.

The new screen must be added to the RIP screens list, which specifies a particular screen configuration. Adding the screen to the RIP is done using the InstallHalftoneDef function.

The simplest invocation for adding a monochrome screen is:

CODE
/EgHalftone <<
	/HalftoneType 100
	/HalftoneName /EgHalftone
	/HalftoneModule /htm8ml
	/Screen 0
	/Levels 2
>>
/HqnHtm /ProcSet findresource /InstallHalftoneDef get exec

For the provided examples (htm8ml and htm4x4) the parameters /Screen and /Levels are required, but other screen modules might require parameters with different names or no parameters at all. The function ml8HalftoneSelect() (in htm8ml.c) contains an array that is parsed for option names. SW_DATUM_BIT_NOTHING within the array is a flag which defines the option /Inverse as being optional. Its absence indicates that the parameter is required.

A more useful invocation, which allows the individual tailoring of the screens on a per colorant basis (required for multi‐colorant use of htm8ml and htm4x4) is:

TEXT
/EgHalftone <<
  /HalftoneType 5
  /HalftoneName /EgHalftone
  /Cyan    << /HalftoneType 100 /HalftoneModule /htm8ml
              /Screen 0 /Levels 2 >>
  /Magenta << /HalftoneType 100 /HalftoneModule /htm8ml
              /Screen 1 /Levels 2 >>
  /Yellow  << /HalftoneType 100 /HalftoneModule /htm8ml
              /Screen 2 /Levels 2 >>
>>
/HqnHtm /ProcSet findresource /InstallHalftoneDef get exec

The InstallHalftoneDef function links a name that can be used with setscreen to the name of a screening module.

HalftoneType 5 defines a composite screen containing an arbitrary number of halftone screens, one for each color component. The keys in this dictionary are the names of color components (process or spot). The values are halftone dictionaries of other types, each defining the halftone screen for a single color component.

The PostScript language code must be run at startup. For more information see Running the PostScript language start up code.

Configure the screen for use with HMR

Once the screen is available to the core RIP it must now be configured for HMR by creating a specific screen configuration under a unique name, called the Dot shape. To do this an entry needs to be added to the GUI RIP Screen Names file.

The Screen Names file only appears after the RIP has been started up at least once.
  1. Open the file: /SW/Config/Screen Names
  2. Append your Screen Names definition after the last entry in the file. This is an example Screen Names definition:
CODE
<<
  /InternalName (EgHalftone)
  /ExternalName (Example Halftone)
  /Type (Modular)
  /Enabled true
  /DefaultValues []
>>

Change InternalName to your core screening module name within the sw_htm_api structure. This name must be unique within each RIP instance.

The ExternalName string is displayed in the Dot shape field of the Edit Style for Halftone separations dialog in the RIP GUI. The ExternalName does not have to be unique within the RIP instance, but it could cause confusion if it is not. If several arrays are added, the order they appear in the file determines the order in which they appear in the Dot shape field in the GUI.

Configure the screen for use with specific output plugins

If you are implementing a screen for an output device that includes its own Screen Names file, the new screen must also be added to that. Therefore, the new Screen Names file must be included in that device. These files are located in the actual output plugin.
For example:

\HarlequinRIP_X_X_Generic\SW\Devices\epson4800\Screen Names

There may be a number of files within the device Screen Names directory, all of which may be updated with the new entry. These files may exist because there might be limitations to the screening the device can support. For example, VSD printers use 2‐bits per pixel screening and most standard screens cannot cope with that. Therefore, a HEDs file must be provided that copes with this and omits the other standard screening set (round, Euclidean and so on). If there is a Screen Names file entitled with the name of the device it is used. For example:

\HarlequinRIP_X_X_Generic\SW\Devices\epson4800\Screen Names\SP4800 VSD Sheet

If not, and a Screen Names file exists within the \Screen Names directory then that file is used. For example:

\HarlequinRIP_X_X_Generic\SW\Devices\epson4800\Screen Names\Screen Names

If neither of these files exist, the RIP Screen Names file (in SW\Config) is used.

Your startup code can add the entry to the Screen Names list by using the HqnPluginConf procset function AddScreenNames. (HqnPluginConf is a general plugin configuration procset though currently it is only used for screening.)

The following PostScript language code, which should go into the ExtraStart file, shows an example of adding the entry (shown above) using HqnPluginConf:

CODE
[
	<<
		/InternalName (<internal name>)
		/ExternalName (<dot shape name>)
		/Type (Modular)
		/Enabled true
		/DefaultValues []
	>>
]
/HqnPluginConf /ProcSet findresource /AddScreenNames get exec

Where <internal name> is the key name identifying the screen in PostScript language. <dot shape name> is the name used in the Edit Style for Halftone separations dialog.

This template has no error checking. See below for a more complete version.

Type can be one of (Threshold), (SpotFunction), (HDS), or (Modular).

For more information regarding the /DefaultValues array, see Adding extra dot shapes.

To add the htm8ml module, found in the Plugin Kit, this PostScript language code (which includes the error checking omitted earlier) should be placed within

\HarlequinRIP_X_X_Generic\SW\Extensions\CoreModule\htm8ml\ExtraStart.

CODE
[
	<<
		/InternalName (EgHalftone)
		/ExternalName (Example Halftone)
		/Type (Modular)
		/Enabled true
		/DefaultValues []
	>>
]
/HqnPluginConf /ProcSet resourcestatus
{
	pop pop
	% pass an array of Screen Names to be merged with the default one
	/HqnPluginConf /ProcSet findresource /AddScreenNames get exec
}
{
	pop
	(%stderr%) (w) file
      (%%\[HqnPluginConf is not available, so Core htmeg has not been added to standard plugins. %%\]\n)
    writestring
} ifelse

If required, the array passed to AddScreenNames can contain several entries which will be added, in the order presented, to the end of the existing array. The PostScript language code to do this can be added to the same ExtraStart file that includes InstallHalftoneDef.

Once installed, the plugin will report its presence in the RIP monitor when the RIP is booted. For example:

CODE
"Core Screening Example Plugin 1"

"Version 1.0r1 - Copyright (c) 1998-2007 Global Graphics Software Ltd. All Rights Reserved."

The examples provided do not require a password, but if you change an example to indicate that a password is required, you must use the Harlequin RIP > Configure RIP menu item, followed by the Extras... button. In the list displayed there will be an entry in the form: <Example Name>, <Example Security Name>. Click on this and enter the required password. Ensure that the password successfully enables the plugin by checking that the enabled field displays yes.

To use the new screening module a halftone page setup must be created. Open the Dot shape field of the Edit Style for Halftone separations dialog in the RIP GUI. This is where you would usually see items such as Round and Euclidean. If you followed the example above and named the screen using the ExternalName in the Screen Names entry, there should be an additional entry "Example Halftone". When completed, you should RIP a job an examine the results.

Important names

This section provides details of the names required for integrating and configuring your screening modules:

  • The name of the plugin executable and the directory it is stored in. It is recommended that these are the same, but they need not be. This is required for installation of the module.
  • The two names returned from D_GEN_SECURITY_NAME which together identify the plugin to the security system. (Not applicable in the example above.) These names are required for creating the correct keys to enable the plugin.
  • The name of the module (referenced in sw_htm_api as /HalftoneModule) that the plugin provides (for example, the plugin htmeg provides the module htm4x4). This name is used together with /InternalName and /ExternalName to create a screening configuration that can be used in the job.
  • The /InternalName of the screen configuration that you define. This name is used together with the /HalftoneModule and /ExternalName to create a screening configuration that can be used in the job.
  • The /ExternalName of the screen configuration given in Screen Names. This is presented in the Dot shape field of the Edit Style for Halftone separations dialog in the RIP GUI. In this example it is (Example Halftone). This name is used together with the /InternalName and /HalftoneModule to create a screening configuration that can be used in the job.


Running the PostScript language start up code

Whichever style of definition is used, a PostScript language file containing the definition should be added to the ExtraStart directory within the screening plugin's folder. For the core module screening module htm8ml you might, for example, have the file:

\HarlequinRIP_X_X_\SW\Extensions\CoreModule\htm8ml\ExtraStart\htm8mlStartUp

This code needs to be run in a global allocation mode which can be done by wrapping the file with these commands:

  currentglobal
  true setglobal
  <definition code>
 
setglobal




JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.