From 8e5ac3ea6eaa8b7dd24523003057e5fa8f564c20 Mon Sep 17 00:00:00 2001 From: Jakub Vrana Date: Wed, 15 May 2013 20:12:58 +0000 Subject: [PATCH] Add PHP 5.5 image functions git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@330230 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/image/functions/imageaffine.xml | 77 ++++++++++++++++ .../functions/imageaffinematrixconcat.xml | 75 ++++++++++++++++ .../image/functions/imageaffinematrixget.xml | 76 ++++++++++++++++ reference/image/functions/imagecrop.xml | 68 ++++++++++++++ reference/image/functions/imagecropauto.xml | 86 ++++++++++++++++++ reference/image/functions/imagescale.xml | 90 +++++++++++++++++++ 6 files changed, 472 insertions(+) create mode 100644 reference/image/functions/imageaffine.xml create mode 100644 reference/image/functions/imageaffinematrixconcat.xml create mode 100644 reference/image/functions/imageaffinematrixget.xml create mode 100644 reference/image/functions/imagecrop.xml create mode 100644 reference/image/functions/imagecropauto.xml create mode 100644 reference/image/functions/imagescale.xml diff --git a/reference/image/functions/imageaffine.xml b/reference/image/functions/imageaffine.xml new file mode 100644 index 0000000000..eea510a05b --- /dev/null +++ b/reference/image/functions/imageaffine.xml @@ -0,0 +1,77 @@ + + + + + + imageaffine + Return an image containing the affine tramsformed src image, using an optional clipping area + + + + &reftitle.description; + + resourceimageaffine + resourceimage + arrayaffine + arrayclip + + + + + + &warn.undocumented.func; + + + + + &reftitle.parameters; + + &gd.image.description; + + affine + + + Array with keys 0 to 5. + + + + + clip + + + Array with keys "x", "y", "width" and "height". + + + + + + + + &reftitle.returnvalues; + + Return affined image resource on success&return.falseforfailure;. + + + + + + diff --git a/reference/image/functions/imageaffinematrixconcat.xml b/reference/image/functions/imageaffinematrixconcat.xml new file mode 100644 index 0000000000..b47a237552 --- /dev/null +++ b/reference/image/functions/imageaffinematrixconcat.xml @@ -0,0 +1,75 @@ + + + + + + imageaffinematrixconcat + Concat two matrices (as in doing many ops in one go) + + + + &reftitle.description; + + arrayimageaffinematrixconcat + arraym1 + arraym2 + + + + + + &warn.undocumented.func; + + + + + &reftitle.parameters; + + + m1 + + + Array with keys 0 to 5. + + + + + m2 + + + Array with keys 0 to 5. + + + + + + + + &reftitle.returnvalues; + + Array with keys 0 to 5 and float values&return.falseforfailure;. + + + + + + diff --git a/reference/image/functions/imageaffinematrixget.xml b/reference/image/functions/imageaffinematrixget.xml new file mode 100644 index 0000000000..98e9e74766 --- /dev/null +++ b/reference/image/functions/imageaffinematrixget.xml @@ -0,0 +1,76 @@ + + + + + + imageaffinematrixget + Return an image containing the affine tramsformed src image, using an optional clipping area + + + + &reftitle.description; + + arrayimageaffinematrixget + inttype + mixedoptions + + + + + + &warn.undocumented.func; + + + + + &reftitle.parameters; + + + type + + + One of IMG_AFFINE_* constants. + + + + + options + + + + + + + + + + + &reftitle.returnvalues; + + Array with keys 0 to 5 and float values&return.falseforfailure;. + + + + + + + diff --git a/reference/image/functions/imagecrop.xml b/reference/image/functions/imagecrop.xml new file mode 100644 index 0000000000..ba1734bd6f --- /dev/null +++ b/reference/image/functions/imagecrop.xml @@ -0,0 +1,68 @@ + + + + + + imagecrop + Crop an image using the given coordinates and size, x, y, width and height + + + + &reftitle.description; + + resourceimagecrop + resourceimage + arrayrect + + + + + + &warn.undocumented.func; + + + + + &reftitle.parameters; + + &gd.image.description; + + rect + + + Array with keys "x", "y", "width" and "height". + + + + + + + + &reftitle.returnvalues; + + Return cropped image resource on success&return.falseforfailure;. + + + + + + diff --git a/reference/image/functions/imagecropauto.xml b/reference/image/functions/imagecropauto.xml new file mode 100644 index 0000000000..9e9b9b9770 --- /dev/null +++ b/reference/image/functions/imagecropauto.xml @@ -0,0 +1,86 @@ + + + + + + imagecropauto + Crop an image automatically using one of the available modes + + + + &reftitle.description; + + resourceimagecropauto + resourceimage + intmode-1 + floatthreshold.5 + intcolor-1 + + + + + + &warn.undocumented.func; + + + + + &reftitle.parameters; + + &gd.image.description; + + mode + + + One of IMG_CROP_* constants. + + + + + threshold + + + Used in IMG_CROP_THRESHOLD mode. + + + + + color + + + Used in IMG_CROP_THRESHOLD mode. + + + + + + + + &reftitle.returnvalues; + + Return cropped image resource on success&return.falseforfailure;. + + + + + + diff --git a/reference/image/functions/imagescale.xml b/reference/image/functions/imagescale.xml new file mode 100644 index 0000000000..e889bde8fd --- /dev/null +++ b/reference/image/functions/imagescale.xml @@ -0,0 +1,90 @@ + + + + + + imagescale + Scale an image using the given new width and height + + + + &reftitle.description; + + resourceimagescale + resourceimage + intnew_width + intnew_height-1 + intmodeIMG_BILINEAR_FIXED + + + + + + &warn.undocumented.func; + + + + + &reftitle.parameters; + + &gd.image.description; + + new_width + + + + + + + + new_height + + + + + + + + mode + + + One of IMG_NEAREST_NEIGHBOUR, + IMG_BILINEAR_FIXED, + IMG_BICUBIC, + IMG_BICUBIC_FIXED or anything else (will use two + pass). + + + + + + + + &reftitle.returnvalues; + + Return scaled image resource on success&return.falseforfailure;. + + + + + +