Table of Contents

Class PdfShading.LatticeFormGouraudShadedTriangleMesh

Namespace
iText.Kernel.Pdf.Colorspace
Assembly
itext.kernel.dll

The class that extends PdfShading class and is in charge of Shading Dictionary with lattice-form Gouraud-shaded triangle mesh type.

public class PdfShading.LatticeFormGouraudShadedTriangleMesh : PdfShading
Inheritance
PdfShading.LatticeFormGouraudShadedTriangleMesh
Inherited Members

Remarks

The class that extends PdfShading class and is in charge of Shading Dictionary with lattice-form Gouraud-shaded triangle mesh type. This type is similar to PdfShading.FreeFormGouraudShadedTriangleMesh but instead of using free-form geometry, the vertices are arranged in a pseudorectangular lattice, which is topologically equivalent to a rectangular grid. The vertices are organized into rows, which need not be geometrically linear. The verticals data in stream is similar to PdfShading.FreeFormGouraudShadedTriangleMesh , except there is no edge flag.

Constructors

LatticeFormGouraudShadedTriangleMesh(PdfColorSpace, int, int, int, float[])

Creates the new instance of the class.

public LatticeFormGouraudShadedTriangleMesh(PdfColorSpace cs, int bitsPerCoordinate, int bitsPerComponent, int verticesPerRow, float[] decode)

Parameters

cs PdfColorSpace

the PdfColorSpace object in which colour values shall be expressed. The special Pattern space isn't excepted.

bitsPerCoordinate int

the number of bits used to represent each vertex coordinate. The value shall be 1, 2, 4, 8, 12, 16, 24, or 32.

bitsPerComponent int

the number of bits used to represent each colour component. The value shall be 1, 2, 4, 8, 12, or 16.

verticesPerRow int

the number of vertices in each row of the lattice (shall be > 1). The number of rows need not be specified.

decode float[]

the int[] of numbers specifying how to map vertex coordinates and colour components into the appropriate ranges of values. The ranges shall be specified as follows: [x_min x_max y_min y_max c1_min c1_max … cn_min cn_max]. Only one pair of color values shall be specified if a Function entry is present.

LatticeFormGouraudShadedTriangleMesh(PdfColorSpace, int, int, int, PdfArray)

Creates the new instance of the class.

public LatticeFormGouraudShadedTriangleMesh(PdfColorSpace cs, int bitsPerCoordinate, int bitsPerComponent, int verticesPerRow, PdfArray decode)

Parameters

cs PdfColorSpace

the PdfColorSpace object in which colour values shall be expressed. The special Pattern space isn't excepted.

bitsPerCoordinate int

the number of bits used to represent each vertex coordinate. The value shall be 1, 2, 4, 8, 12, 16, 24, or 32.

bitsPerComponent int

the number of bits used to represent each colour component. The value shall be 1, 2, 4, 8, 12, or 16.

verticesPerRow int

the number of vertices in each row of the lattice (shall be > 1). The number of rows need not be specified.

decode PdfArray

the PdfArray of numbers specifying how to map vertex coordinates and colour components into the appropriate ranges of values. The ranges shall be specified as follows: [x_min x_max y_min y_max c1_min c1_max … cn_min cn_max]. Only one pair of color values shall be specified if a Function entry is present.

LatticeFormGouraudShadedTriangleMesh(PdfStream)

Creates the new instance of the class from the existing PdfStream.

protected LatticeFormGouraudShadedTriangleMesh(PdfStream pdfStream)

Parameters

pdfStream PdfStream

from which this PdfShading.LatticeFormGouraudShadedTriangleMesh will be created

Methods

GetBitsPerComponent()

Gets the number of bits used to represent each colour component.

public virtual int GetBitsPerComponent()

Returns

int

the number of bits. Can be 1, 2, 4, 8, 12, or 16.

GetBitsPerCoordinate()

Gets the number of bits used to represent each vertex coordinate.

public virtual int GetBitsPerCoordinate()

Returns

int

the number of bits. Can be 1, 2, 4, 8, 12, 16, 24, or 32.

GetDecode()

Gets the PdfArray of numbers specifying how to map vertex coordinates and colour components into the appropriate ranges of values.

public virtual PdfArray GetDecode()

Returns

PdfArray

the PdfArray Decode object.

Remarks

Gets the PdfArray of numbers specifying how to map vertex coordinates and colour components into the appropriate ranges of values. The ranges shall be specified as follows: [x_min x_max y_min y_max c1_min c1_max … cn_min cn_max]. Only one pair of color values shall be specified if a Function entry is present.

GetVerticesPerRow()

Gets the number of vertices in each row of the lattice.

public virtual int GetVerticesPerRow()

Returns

int

the number of vertices. Can only be greater than 1.

SetBitsPerComponent(int)

Sets the number of bits used to represent each colour component.

public virtual void SetBitsPerComponent(int bitsPerComponent)

Parameters

bitsPerComponent int

the number of bits to be set. Shall be 1, 2, 4, 8, 12, or 16.

SetBitsPerCoordinate(int)

Sets the number of bits used to represent each vertex coordinate.

public virtual void SetBitsPerCoordinate(int bitsPerCoordinate)

Parameters

bitsPerCoordinate int

the number of bits to be set. Shall be 1, 2, 4, 8, 12, 16, 24, or 32.

SetDecode(float[])

Sets the float[] of numbers specifying how to map vertex coordinates and colour components into the appropriate ranges of values.

public virtual void SetDecode(float[] decode)

Parameters

decode float[]

the float[] of Decode object to set.

Remarks

Sets the float[] of numbers specifying how to map vertex coordinates and colour components into the appropriate ranges of values. The ranges shall be specified as follows: [x_min x_max y_min y_max c1_min c1_max … cn_min cn_max]. Only one pair of color values shall be specified if a Function entry is present.

SetDecode(PdfArray)

Sets the PdfArray of numbers specifying how to map vertex coordinates and colour components into the appropriate ranges of values.

public virtual void SetDecode(PdfArray decode)

Parameters

decode PdfArray

the PdfArray Decode object to set.

Remarks

Sets the PdfArray of numbers specifying how to map vertex coordinates and colour components into the appropriate ranges of values. The ranges shall be specified as follows: [x_min x_max y_min y_max c1_min c1_max … cn_min cn_max]. Only one pair of color values shall be specified if a Function entry is present.

SetVerticesPerRow(int)

Sets the number of vertices in each row of the lattice.

public virtual void SetVerticesPerRow(int verticesPerRow)

Parameters

verticesPerRow int

the number of vertices to be set. Shall be greater than 1.

Remarks

Sets the number of vertices in each row of the lattice. The number of rows need not be specified.