Cmdlet
New-OfficePdfVisualComparisonOptions
Creates discoverable rendering and tolerance settings for Compare-OfficePdfVisual.
Syntax
New-OfficePdfVisualComparisonOptions
[-Alignment <TopLeft| Center>]
[-AllowedDifferenceRatio <Double>]
[-BackgroundColor <String>]
[-ChannelTolerance <Byte>]
[-MaxPages <Int32>]
[-MaxPixelsPerImage <Int64>]
[-MaxTotalOutputBytes <Int64>]
[-MaxTotalPixels <Int64>]
[-Scale <Double>]
[<CommonParameters>]#Parameter set:
All Parameter SetsExamples
Compare PDFs with a small rendering tolerance.
$options = New-OfficePdfVisualComparisonOptions -ChannelTolerance 2 -AllowedDifferenceRatio 0.001 -MaxPages 50
Compare-OfficePdfVisual -ReferencePath .\Expected.pdf -DifferencePath .\Actual.pdf -Options $optionsParameters
- -Alignment PdfVisualPageAlignment
- Page alignment used for differently sized renders.
- Possible values:
TopLeft,Center - -AllowedDifferenceRatio Double
- Maximum differing-pixel ratio treated as equal.
- -BackgroundColor String
- Background color name or hex value.
- -ChannelTolerance Byte
- Maximum per-channel byte difference treated as equal.
- -MaxPages Int32
- Maximum pages compared.
- -MaxPixelsPerImage Int64
- Maximum pixels accepted per rendered image.
- -MaxTotalOutputBytes Int64
- Maximum total bytes retained for comparison artifacts.
- -MaxTotalPixels Int64
- Maximum pixels accepted across the comparison.
- -Scale Double
- Render scale applied before comparison.
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.