PNG image

package Zend_Pdf
copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
license New BSD License
inherited_from \Zend_Pdf_Resource_Image

 Methods

Clone page, extract it and dependent objects from the current document, so it can be used within other docs.

__clone() 
Inherited

Object constructor

__construct(string $imageFileName) 

If resource is not a Zend_Pdf_Element object, then stream object with specified value is generated.

todo Add compression conversions to support compression strategys other than PNG_COMPRESSION_DEFAULT_STRATEGY.
todo Add pre-compression filtering.
todo Add interlaced image handling.
todo Add support for 16-bit images. Requires PDF version bump to 1.5 at least.
todo Add processing for all PNG chunks defined in the spec. gAMA etc.
todo Fix tRNS chunk support for Indexed Images to a SMask.
inherited_from \Zend_Pdf_Resource_Image::__construct()

Parameters

$imageFileName

string

Exceptions

\Zend_Pdf_Exception

Object constructor.

__construct(\Zend_Pdf_Element|string $resource) 
Inherited

If resource is not a Zend_Pdf_Element object, then stream object with specified value is generated.

Parameters

$resource

\Zend_Pdf_Elementstring

Image height

getPixelHeight() 
inherited_from \Zend_Pdf_Resource_Image::getPixelHeight()

get the height in pixels of the image

getPixelHeight() : integer
Inherited

Returns

integer

Image width

getPixelWidth() 
inherited_from \Zend_Pdf_Resource_Image::getPixelWidth()

get the width in pixels of the image

getPixelWidth() : integer
Inherited

Returns

integer

Image properties

getProperties() 
inherited_from \Zend_Pdf_Resource_Image::getProperties()

gets an associative array of information about an image

getProperties() : array
Inherited

Returns

array

 Properties

 

$_height

$_height 

Default

 

$_imageProperties

$_imageProperties 

Default

 

Each Pdf resource (fonts, images, .

$_objectFactory : \Zend_Pdf_ElementFactory_Interface

Default

..) interacts with a PDF itself. It creates appropriate PDF objects, structures and sometime embedded files. Resources are referenced in content streams by names, which are stored in a page resource dictionaries.

Thus, resources must be attached to the PDF.

Resource abstraction uses own PDF object factory to store all necessary information. At the render time internal object factory is appended to the global PDF file factory.

Resource abstraction also cashes information about rendered PDF files and doesn't duplicate resource description each time then Resource is rendered (referenced).

 

Main resource object

$_resource : \Zend_Pdf_Element_Object

Default

 

$_width

$_width 

Default

 Constants

 

PNG_CHANNEL_GRAY

PNG_CHANNEL_GRAY = 0 
 

PNG_CHANNEL_GRAY_ALPHA

PNG_CHANNEL_GRAY_ALPHA = 4 
 

PNG_CHANNEL_INDEXED

PNG_CHANNEL_INDEXED = 3 
 

PNG_CHANNEL_RGB

PNG_CHANNEL_RGB = 2 
 

PNG_CHANNEL_RGB_ALPHA

PNG_CHANNEL_RGB_ALPHA = 6 
 

PNG_COMPRESSION_DEFAULT_STRATEGY

PNG_COMPRESSION_DEFAULT_STRATEGY = 0 
 

PNG_COMPRESSION_FILTERED

PNG_COMPRESSION_FILTERED = 1 
 

PNG_COMPRESSION_HUFFMAN_ONLY

PNG_COMPRESSION_HUFFMAN_ONLY = 2 
 

PNG_COMPRESSION_RLE

PNG_COMPRESSION_RLE = 3 
 

PNG_FILTER_AVERAGE

PNG_FILTER_AVERAGE = 3 
 

PNG_FILTER_NONE

PNG_FILTER_NONE = 0 
 

PNG_FILTER_PAETH

PNG_FILTER_PAETH = 4 
 

PNG_FILTER_SUB

PNG_FILTER_SUB = 1 
 

PNG_FILTER_UP

PNG_FILTER_UP = 2 
 

PNG_INTERLACING_DISABLED

PNG_INTERLACING_DISABLED = 0 
 

PNG_INTERLACING_ENABLED

PNG_INTERLACING_ENABLED = 1