API Documentation

Pdf/Image.php

Classes 
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Pdf
subpackage
Images
version
$Id: Image.php 20096 2010-01-06 02:05:09Z bkarwin $
Classes
Zend_Pdf_Image

Description

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Zend_Pdf_Image

copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Pdf
subpackage
Images
Constants
TYPE_UNKNOWN
TYPE_JPEG
TYPE_PNG
TYPE_TIFF
TIFF_FIELD_TYPE_BYTE
TIFF_FIELD_TYPE_ASCII
TIFF_FIELD_TYPE_SHORT
TIFF_FIELD_TYPE_LONG
TIFF_FIELD_TYPE_RATIONAL
TIFF_TAG_IMAGE_WIDTH
TIFF_TAG_IMAGE_LENGTH
TIFF_TAG_BITS_PER_SAMPLE
TIFF_TAG_COMPRESSION
TIFF_TAG_PHOTOMETRIC_INTERPRETATION
TIFF_TAG_STRIP_OFFSETS
TIFF_TAG_SAMPLES_PER_PIXEL
TIFF_TAG_STRIP_BYTE_COUNTS
TIFF_COMPRESSION_UNCOMPRESSED
TIFF_COMPRESSION_CCITT1D
TIFF_COMPRESSION_GROUP_3_FAX
TIFF_COMPRESSION_GROUP_4_FAX
TIFF_COMPRESSION_LZW
TIFF_COMPRESSION_JPEG
TIFF_COMPRESSION_FLATE
TIFF_COMPRESSION_FLATE_OBSOLETE_CODE
TIFF_COMPRESSION_PACKBITS
TIFF_PHOTOMETRIC_INTERPRETATION_WHITE_IS_ZERO
TIFF_PHOTOMETRIC_INTERPRETATION_BLACK_IS_ZERO
TIFF_PHOTOMETRIC_INTERPRETATION_RGB
TIFF_PHOTOMETRIC_INTERPRETATION_RGB_INDEXED
TIFF_PHOTOMETRIC_INTERPRETATION_CMYK
TIFF_PHOTOMETRIC_INTERPRETATION_YCBCR
TIFF_PHOTOMETRIC_INTERPRETATION_CIELAB
PNG_COMPRESSION_DEFAULT_STRATEGY
PNG_COMPRESSION_FILTERED
PNG_COMPRESSION_HUFFMAN_ONLY
PNG_COMPRESSION_RLE
PNG_FILTER_NONE
PNG_FILTER_SUB
PNG_FILTER_UP
PNG_FILTER_AVERAGE
PNG_FILTER_PAETH
PNG_INTERLACING_DISABLED
PNG_INTERLACING_ENABLED
PNG_CHANNEL_GRAY
PNG_CHANNEL_RGB
PNG_CHANNEL_INDEXED
PNG_CHANNEL_GRAY_ALPHA
PNG_CHANNEL_RGB_ALPHA
Methods
imageWithPath
_extractJpegImage
_extractPngImage
_extractTiffImage

Description

Abstract factory class which vends {@link Zend_Pdf_Resource_Image} objects.

This class is also the home for image-related constants because the name of the true base class ({@link Zend_Pdf_Resource_Image}) is not intuitive for the end user.

Constants

TYPE_UNKNOWN

 TYPE_UNKNOWN = '0'

Details

value
0

TYPE_JPEG

 TYPE_JPEG = '1'

Details

value
1

TYPE_PNG

 TYPE_PNG = '2'

Details

value
2

TYPE_TIFF

 TYPE_TIFF = '3'

Details

value
3

TIFF_FIELD_TYPE_BYTE

 TIFF_FIELD_TYPE_BYTE = '1'

Details

value
1

TIFF_FIELD_TYPE_ASCII

 TIFF_FIELD_TYPE_ASCII = '2'

Details

value
2

TIFF_FIELD_TYPE_SHORT

 TIFF_FIELD_TYPE_SHORT = '3'

Details

value
3

TIFF_FIELD_TYPE_LONG

 TIFF_FIELD_TYPE_LONG = '4'

Details

value
4

TIFF_FIELD_TYPE_RATIONAL

 TIFF_FIELD_TYPE_RATIONAL = '5'

Details

value
5

TIFF_TAG_IMAGE_WIDTH

 TIFF_TAG_IMAGE_WIDTH = '256'

Details

value
256

TIFF_TAG_IMAGE_LENGTH

 TIFF_TAG_IMAGE_LENGTH = '257'

Details

value
257

TIFF_TAG_BITS_PER_SAMPLE

 TIFF_TAG_BITS_PER_SAMPLE = '258'

Details

value
258

TIFF_TAG_COMPRESSION

 TIFF_TAG_COMPRESSION = '259'

Details

value
259

TIFF_TAG_PHOTOMETRIC_INTERPRETATION

 TIFF_TAG_PHOTOMETRIC_INTERPRETATION = '262'

Details

value
262

TIFF_TAG_STRIP_OFFSETS

 TIFF_TAG_STRIP_OFFSETS = '273'

Details

value
273

TIFF_TAG_SAMPLES_PER_PIXEL

 TIFF_TAG_SAMPLES_PER_PIXEL = '277'

Details

value
277

TIFF_TAG_STRIP_BYTE_COUNTS

 TIFF_TAG_STRIP_BYTE_COUNTS = '279'

Details

value
279

TIFF_COMPRESSION_UNCOMPRESSED

 TIFF_COMPRESSION_UNCOMPRESSED = '1'

Details

value
1

TIFF_COMPRESSION_CCITT1D

 TIFF_COMPRESSION_CCITT1D = '2'

Details

value
2

TIFF_COMPRESSION_GROUP_3_FAX

 TIFF_COMPRESSION_GROUP_3_FAX = '3'

Details

value
3

TIFF_COMPRESSION_GROUP_4_FAX

 TIFF_COMPRESSION_GROUP_4_FAX = '4'

Details

value
4

TIFF_COMPRESSION_LZW

 TIFF_COMPRESSION_LZW = '5'

Details

value
5

TIFF_COMPRESSION_JPEG

 TIFF_COMPRESSION_JPEG = '6'

Details

value
6

TIFF_COMPRESSION_FLATE

 TIFF_COMPRESSION_FLATE = '8'

Details

value
8

TIFF_COMPRESSION_FLATE_OBSOLETE_CODE

 TIFF_COMPRESSION_FLATE_OBSOLETE_CODE = '32946'

Details

value
32946

TIFF_COMPRESSION_PACKBITS

 TIFF_COMPRESSION_PACKBITS = '32773'

Details

value
32773

TIFF_PHOTOMETRIC_INTERPRETATION_WHITE_IS_ZERO

 TIFF_PHOTOMETRIC_INTERPRETATION_WHITE_IS_ZERO = '0'

Details

value
0

TIFF_PHOTOMETRIC_INTERPRETATION_BLACK_IS_ZERO

 TIFF_PHOTOMETRIC_INTERPRETATION_BLACK_IS_ZERO = '1'

Details

value
1

TIFF_PHOTOMETRIC_INTERPRETATION_RGB

 TIFF_PHOTOMETRIC_INTERPRETATION_RGB = '2'

Details

value
2

TIFF_PHOTOMETRIC_INTERPRETATION_RGB_INDEXED

 TIFF_PHOTOMETRIC_INTERPRETATION_RGB_INDEXED = '3'

Details

value
3

TIFF_PHOTOMETRIC_INTERPRETATION_CMYK

 TIFF_PHOTOMETRIC_INTERPRETATION_CMYK = '5'

Details

value
5

TIFF_PHOTOMETRIC_INTERPRETATION_YCBCR

 TIFF_PHOTOMETRIC_INTERPRETATION_YCBCR = '6'

Details

value
6

TIFF_PHOTOMETRIC_INTERPRETATION_CIELAB

 TIFF_PHOTOMETRIC_INTERPRETATION_CIELAB = '8'

Details

value
8

PNG_COMPRESSION_DEFAULT_STRATEGY

 PNG_COMPRESSION_DEFAULT_STRATEGY = '0'

Details

value
0

PNG_COMPRESSION_FILTERED

 PNG_COMPRESSION_FILTERED = '1'

Details

value
1

PNG_COMPRESSION_HUFFMAN_ONLY

 PNG_COMPRESSION_HUFFMAN_ONLY = '2'

Details

value
2

PNG_COMPRESSION_RLE

 PNG_COMPRESSION_RLE = '3'

Details

value
3

PNG_FILTER_NONE

 PNG_FILTER_NONE = '0'

Details

value
0

PNG_FILTER_SUB

 PNG_FILTER_SUB = '1'

Details

value
1

PNG_FILTER_UP

 PNG_FILTER_UP = '2'

Details

value
2

PNG_FILTER_AVERAGE

 PNG_FILTER_AVERAGE = '3'

Details

value
3

PNG_FILTER_PAETH

 PNG_FILTER_PAETH = '4'

Details

value
4

PNG_INTERLACING_DISABLED

 PNG_INTERLACING_DISABLED = '0'

Details

value
0

PNG_INTERLACING_ENABLED

 PNG_INTERLACING_ENABLED = '1'

Details

value
1

PNG_CHANNEL_GRAY

 PNG_CHANNEL_GRAY = '0'

Details

value
0

PNG_CHANNEL_RGB

 PNG_CHANNEL_RGB = '2'

Details

value
2

PNG_CHANNEL_INDEXED

 PNG_CHANNEL_INDEXED = '3'

Details

value
3

PNG_CHANNEL_GRAY_ALPHA

 PNG_CHANNEL_GRAY_ALPHA = '4'

Details

value
4

PNG_CHANNEL_RGB_ALPHA

 PNG_CHANNEL_RGB_ALPHA = '6'

Details

value
6

Methods

_extractJpegImage

_extractJpegImage( Zend_Pdf_FileParserDataSource $dataSource ) : Zend_Pdf_Resource_Image_Jpeg

Attempts to extract a JPEG Image from the data source.

Arguments
$dataSource
Zend_Pdf_FileParserDataSource
Output
Zend_Pdf_Resource_Image_Jpeg
May also return null if the data source does not appear to contain valid image data.
Details
visibility
protected
final
false
static
true
throws

_extractPngImage

_extractPngImage( Zend_Pdf_FileParserDataSource $dataSource ) : Zend_Pdf_Resource_Image_Png

Attempts to extract a PNG Image from the data source.

Arguments
$dataSource
Zend_Pdf_FileParserDataSource
Output
Zend_Pdf_Resource_Image_Png
May also return null if the data source does not appear to contain valid image data.
Details
visibility
protected
final
false
static
true

_extractTiffImage

_extractTiffImage( Zend_Pdf_FileParserDataSource $dataSource ) : Zend_Pdf_Resource_Image_Tiff

Attempts to extract a TIFF Image from the data source.

Arguments
$dataSource
Zend_Pdf_FileParserDataSource
Output
Zend_Pdf_Resource_Image_Tiff
May also return null if the data source does not appear to contain valid image data.
Details
visibility
protected
final
false
static
true
throws

imageWithPath

imageWithPath( string $filePath ) : Zend_Pdf_Resource_Image

Returns a {@link Zend_Pdf_Resource_Image} object by file path.

Arguments
$filePath
string
Full path to the image file.
Details
visibility
public
final
false
static
true
throws
Documentation was generated by DocBlox.