Skip to main content
Skip table of contents

Streamline Direct


Introduction

Streamline Direct is an application to pre-process PDFs destined to be ripped by Harlequin with the aim of improving RIP throughput by optimizing images, fonts, and reusable page components.

Streamline Direct can also be used to streamline "problem" PDFs to achieve the same output quality while maximizing your device speed. If you require non-PDF formats, you can adapt Streamline Direct to convert many formats to print-ready PDFs.

Streamline Direct is a stand-alone, command-line application whose behavior is controlled by a configuration file in JSON format. This approach simplifies integrating Streamline Direct into a print workflow.

Streamline Direct is built with Mako Core.

Usage

Run StreamlineDirect.exe on the command line to find the most up-to-date usage.

The current version yields:

StreamlineDirect 1.1.1.56 (Mako V6.1.1)
Copyright (c) 2021 Global Graphics Software Ltd. All rights reserved.

Usage:
   StreamlineDirect.exe /features
      Returns a list of processing features supported by the command line.
   StreamlineDirect.exe <configuration file> <input pdf file> <output folder> [/markup] [/report <report text file>]
      Processes the input pdf/ijpds file, writing the output with the same filename (with a PDF extension) to an output folder, where:
          /markup: Adds the processed content to a new layer.

Configuration file

The configuration file describes how Streamline Direct runs. It determines:

  • The features used for processing.
  • The configuration of the target printer.
  • The configuration of Mako.

An example configuration follows:

Configuration example

JS
{
    "configuration" : {
        "enableFontSubsetting" : false,
        "maxAccumulatedPages" : 0
    },

    "printer" : {     
        "dpi" : 900
    },    

    "features" : {    
        "image-downsampler" : true,
        "image-vectorizer" : true,
		"transparency-flattener" : true
    },
	
	"flattener" : {
        "usethreads"          	  : false,
        "resolution"          	  : 600,
        "vectormodeenabled"       : true,
		"vectorandtextresolution" : 1200,
		"rasterfallbackthreshold" : 100,
		"targetspace"             : "USWebCoatedSWOP.icc",
		"monochromemode"          : false,
		"hasthresholdhalftone"    : false,
		"trigger"                 : 1
    },
	
	"ijpds" : {
        "ripsetup" : "cmyk",
		"riporder" : "0,1,3,2",
		"riprotate" : "180",
		"resourcedirectory" : ""
    }
}

Configuration

The configuration section contains settings that affect how Mako processes the document. 

SettingOptionalDescription
enableFontSubsettingYesEnabling font subsetting indicates that Mako should subset fonts when serializing pages to disk. This may result in unused characters in an original embedded font being dropped from the output PDF. Enabling increases the time to serialize pages. Defaults to true if not specified.
maxAccumulatedPagesYesThe maximum number of pages that are retained when serializing before. The pages are processed (font merging) and serialized to disk. Setting to 0 instructs Mako to serialize each page to disk individually, which means that font merging does not occur. Defaults to 0 if not specified.
defaultCmykProfilePathYesPath to an ICC profile to be used as the CMYK target colorspace.
defaultRgbProfilePathYesPath to an ICC profile to be used as the RGB target colorspace.
defaultGrayProfilePathYesPath to an ICC profile to be used as the Gray target colorspace.
targetColorSpaceYesSpecifies the target colorspace. Choose from CMYK (default), RGB, or Gray.
downsamplingThresholdYesSet a blanket threshold resolution (dpi) for downsampling all images. Only images with an effective resolution of at least this value are downsampled.
contoneDownsamplingMethodYesSet the desired downsampling method for gray images. Choose from Bicubic (default) or Subsample.
monoDownsamplingMethodYesSet the desired downsampling method for monochrome images. Choose from Subsample (default) or Bicubic.
naturalImageResolutionYesSet the target resolution for "natural" images. Defaults to the value specified for the target DPI of the printer.
useLossyCompressionForDownsampledNaturalYesDetermines if images are compressed with DCT (JPEG) or flate (Zip) compression. Choose from true or false (default).
useLossyCompressionForColorConvertedNaturalYesDetermines if images are compressed with DCT (JPEG) or flate (Zip) compression. Choose from true or false (default).
jpegQualityYesDCT (JPEG) image quality. This is expressed as an integer between 1 (lowest quality) and 5 (highest quality). The default is 5.
defaultBlackPointCompensationYes

May be set to one of three values:

  • an empty string - use default Mako behavior
  • "On" - Use black-point compensation on by default
  • "Off" - Use black-point compensation off by default

These settings are interpreted as follows:

  • Default (default): Black point compensation is applied when ICC Version 4 or greater profiles are used and the intent is perceptual or saturation.
  • On: Black point compensation is applied for all but absolute rendering intents.
  • Off: Black point compensation is not used.
psConfigFilenameYesSpecifies the filename for a PostScript configuration file for Harlequin Core. Defaults to "hhrConfig.ps"

Printer

The printer section contains settings that describe the target printer.

SettingOptionalDescription
dpiNoThe target DPI of the printer. This setting determines the downsampling applied in the "image-downsampler" feature. Defaults to 900dpi.

Features

The features section is a list of features to be used, with a boolean to determine whether the feature is active or not.

JS
"features" : {
	"image-downsampler" : true,
	"image-vectorizer" : true,
	"image-scan-direction-corrector" : true,
	"color-converter" : true,
	"transparency-flattener" : true
}

The order of the features determines the order in which they are applied to the target document.

Use the /features flag to find a full list of features supported by Streamline:

FeatureDescription
image-downsamplerImages are downsampled to the target DPI specified in the printer settings.
image-vectorizerTurns supported images into vectorized paths. Only supports images with a single channel and 1bpp.
image-scan-direction-correctorEnsures image samples are presented in an optimal order.
color-converterPre-converts colors to the fullest extent possible.
transparency-flattenerFlattening is the process of simplifying transparent artwork so that it can be more easily consumed by the a RIP, in some cases significantly improving throughput. See 'Transparency Flattening' below.

Transparency flattening

For a RIP to produce output in the form of a raster, it must calculate the color of every pixel. For objects subject to transparency (that is, those with an opacity of less than 100%) the pixels that make up that object will interact with others that it overlaps, meaning the RIP must perform calculations to determine what the effective color will be. This can be a time-consuming process, and could slow the effective throughput and in direct-to-print scenarios, hold up the press.

Flattening is the process of reducing this complexity by rendering those page regions affected by transparency, replacing them with a pre-rendered raster. Streamline Direct makes use of a Mako custom transform that is designed for this purpose (IRendererTransform), and offers controls over how it it is applied. The table below lists the options. Add a section to the JSON configuration in this format:

JS
"flattener" : {
    "usethreads"          	  : false,
    "resolution"          	  : 600,
    "vectormodeenabled"       : true,
    "vectorandtextresolution" : 1200,
    "rasterfallbackthreshold" : 100,
    "targetspace"             : "DeviceRGB",
    "targetprofile"           : "USWebCoatedSWOP.icc",
    "monochromemode"          : false,
    "hasthresholdhalftone"    : false,
    "trigger"                 : 1
}
ParameterPossible valuesDescription
usethreadstrueUse multiple threads to process page regions concurrently
falseDefault. Use a single thread for processing
resolution96-4096Sets the resolution, in dots-per-inch,  at which to regions requiring it are rendered. Default is 96 dpi.
vectormodeenabledtrueGenerate a vector path to use as an image mask. This gives a smooth edge even then the content is rendered at a low resolution.
falseGenerate a bitmap mask, which may lead to a "stair-step" effect for an object for a given size and resolution.
vectorandtextresolution96-2400Sets the resolution, in DPI, at which geometry is processed. It controls the precision by which curves are converted to straight lines, and how precisely strokes are handled. Default is 1200 dpi.
rasterfallbackthreshold0-1024The process of vector flattening requires regions to be broken up into smaller objects, but there is a point at  which the added complexity will be counter-productive. This value specifies the number of objects, per square inch, that if exceeded will trigger the flattener to generate a raster instead. Default is 100.
targetspaceDeviceRGB

Sets the target final color space for rendered content. The default is DeviceRGB. Case-sensitive.

SWOP will override targetprofile even if set.


DeviceCMYK

SWOP
targetprofile<ICC color space>

File path to a target color space. Sets the target final color space for rendered content, overriding the value set by targetspace (except for SWOP, as noted above).

monochromemodetrueUse monochrome output.
falseDo not use monochrome output.
hasthresholdhalftonetrueCurrently unused
false
trigger0Process all pages
1Apply transparency flattening only in the presence of a shaded brush (typically, a linear or radial gradient)

IJPDS

Several input parameters are available to control how Inkjet Printer Data Stream (IJPDS) job content is assembled into the PDF. These collation options are needed because IJPDS job files are input to KODAK VERSAMARK printing systems, and therefore essentially a sequence of bitmap pages, the order of which is arbitrary and determined at file creation. For example, each may be separate monochrome pages or a color separation for a page. Although pages are assigned to a logical RIP (raster image processor) for physical printing, IJPDS doesn't directly specify how the different RIPs are to be interpreted. During testing, we encountered:

  • A job with eight RIPs, which should be interpreted as CMYK separations for the front and back of a (duplex) page
  • A job with eight RIPs that are all individual mono pages

The collator works by treating all pages assigned the same logical RIP in the same way. The table below lists the options. Add a section to the JSON configuration in this format:

JS
 "ijpds" : {
      "ripsetup" : "cmyk",
      "riporder" : "ordinal",
      "collation" : "bypage",
      "resourcedirectory" : ""
}

Parameter

Possible values

Description

ripsetup

mono

Default. Each RIP generates its own page.

cmykGroups RIPs together in blocks of four to generate a composite page.
riporder



fromjob

RIPs are arranged in the order the job defines them. Default.

ordinal

RIPs are arranged sequentially in their ordinal numbering (starting from 0,for example, Rip0, Rip1, Rip2, Rip3...

0,1,2,3

A comma-separated sequence of RIP IDs (a number from 0 to 15, or -1 if a blank is desired for that slot). This controls the sequence in which the RIPs are processed. By default, the order in which the RIP is defined by the job is followed.

0,1,3,2

Example: For CMYK output it is sometimes necessary to change the plate order (here 0,1,3,2 is specified) to obtain the correct composite output.

-1,2,-1,-1

Example: If -1 is encountered in CMYK output, then that separation is interpreted as a blank. This is useful to see a separation in a specific color. For example, specifying -1,2,-1,-1 uses the page from RIP 2 as the magenta plane with all other color planes blank. This results in a CMYK composite output where only RIP 2 comes out in a magenta color. For non-composite output, -1 is ignored, as it does not make sense to output a blank page.

collation

bypage

Default. Output is ordered in page number major order. All the first pages from each RIP are output followed by the second pages, and so on.


byripOutput is ordered by RIP major order. All the pages for RIP 1 are output followed by all the pages for RIP 2, and so on.
riprotate


0

This denotes the rotation of a RIP separation in the output page.

The value is an angle in degrees, counter-clockwise.

Possible values are 0, 90, 180, and 270; the default value is 0.

90
180
270
stitchtrue (or 1)

Individual RIP separations are combined into one page by stitching them together. Default.

The orientation of the stitching can be controlled by the stitchhorizontal parameter.

false (or 0)Individual RIP separations are each output as separate pages.
stitchhorizontaltrue (or 1)The RIP separations are stitched in a horizontal orientation.

false (or 0)The RIP separations are stitched in a vertical orientation. Default.

resourcedirectory

<path to resources folder>

Sets the directory where remote resources are located (that is, resources referenced by the IJPDS but external to it).

JavaScript errors detected

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

If this problem persists, please contact our support.