Author: Derick Rethans
Date: 2006-01-27 18:44:15 +0100 (Fri, 27 Jan 2006)
New Revision: 2072
Log:
- Removed excess empty lines from examples
- Fixed grammar/spelling
#- Need to update the line numbers now
Modified:
packages/ImageAnalysis/trunk/docs/example.php
packages/ImageAnalysis/trunk/docs/tutorial.txt
packages/ImageAnalysis/trunk/docs/tutorial_example_01.php
packages/ImageAnalysis/trunk/docs/tutorial_example_02.php
packages/ImageAnalysis/trunk/docs/tutorial_example_03.php
Modified: packages/ImageAnalysis/trunk/docs/example.php
===================================================================
--- packages/ImageAnalysis/trunk/docs/example.php 2006-01-27 16:29:44 UTC
(rev 2071)
+++ packages/ImageAnalysis/trunk/docs/example.php 2006-01-27 17:44:15 UTC
(rev 2072)
@@ -13,11 +13,6 @@
{
return;
}
- if ( strpos( $class_name, '_' ) !== false )
- {
- $file = str_replace( '_', '/', $class_name ) . '.php';
- require_once( $file );
- }
}
// Analyzation of the MIME type is done during creation.
Modified: packages/ImageAnalysis/trunk/docs/tutorial.txt
===================================================================
--- packages/ImageAnalysis/trunk/docs/tutorial.txt 2006-01-27 16:29:44 UTC
(rev 2071)
+++ packages/ImageAnalysis/trunk/docs/tutorial.txt 2006-01-27 17:44:15 UTC
(rev 2072)
@@ -16,18 +16,10 @@
used directly.
ezcImageAnalyzer
- The main class of this package, it is responsible to handle the analysis of
+ The main class of this component. It is responsible to handle the analysis of
image files, as well as caching the results for you.
-Installation
-============
-This tutorial assumes that you have set-up an eZ components environment. For
-information on how to do this, please refer to the `Components Introduction`_.
-
-.. _`Components Introduction`:
http://ez.no/community/articles/an_introduction_to_ez_components
-
-
Usage
=====
@@ -53,22 +45,22 @@
Extracting further data
-----------------------
-Beside the MIME type, ImageAnalysis extracts more information, if you request
it.
+Besides the MIME type, ImageAnalysis extracts more information if you request
it.
The following example shows how this works:
.. include:: tutorial_example_01.php
:literal:
-The example is basically the same as no. 1, except that more data is requested
+The example is basically the same as the first one, except that more data is
requested
from ezcImageAnalyzer (lines 13-17). The major difference here is, that in
example 1, ezcImageAnalyzer has only determined the MIME type of the file and
-has not performed any further analyzation. The analyzation of additional data
+has not performed any further analysis. The analysis of additional data
is performed on the first request to it (line 13). After that, the data is
cached in the ezcImageAnalyzer object.
-The width, height and size values are available for every analyzable image,
-while a comment must not necessarily be available. At least, every datum has
-some sensible default value, if unavailable.
+The width, height and size values are available for every analyzable image.
+A comment is not always necessarily be available however. At least, every data
has
+some sensible default value, even if it unavailable.
The example image and the output printed is shown below:
@@ -88,12 +80,12 @@
--------------------
Like ezcImageConversion, ezcImageAnalyzer is based on handler classes, which
-allow it to utilize different back-ends for image analyzation. Currently
+allow it to utilize different back-ends for image analysis. Currently
implemented are:
ezcImageAnalyzerHandlerPhp
This one uses PHP's getimagesize() function (which does not require the GD
- extension!) and probably PHP's exif extension, if it is available.
+ extension!) and can optionally use PHP's exif extension.
ezcImageAnalyzerHandlerImagemagick
Here `ImageMagick`_'s "identify" program is used.
@@ -112,9 +104,9 @@
.. include:: tutorial_example_01.php
:literal:
-Basically, the code is the same as from example 2, except that the
+Basically, the code is the same as in example 2, except that the
ezcImageAnalyzer is being configured to only use its ImageMagick handler and
-not the PHP handler. Beside that, the location of the "identify" binary is set
+not the PHP handler. Besides that, the location of the "identify" binary is set
explicitly. See the results below:
.. image:: img/imageanalysis_example_03.jpg
Modified: packages/ImageAnalysis/trunk/docs/tutorial_example_01.php
===================================================================
--- packages/ImageAnalysis/trunk/docs/tutorial_example_01.php 2006-01-27
16:29:44 UTC (rev 2071)
+++ packages/ImageAnalysis/trunk/docs/tutorial_example_01.php 2006-01-27
17:44:15 UTC (rev 2072)
@@ -1,11 +1,8 @@
<?php
-
require_once 'tutorial_autoload.php';
-
$tutorialPath = dirname( __FILE__ );
-$image = new ezcImageAnalyzer(
$tutorialPath.'/img/imageanalysis_example_01.jpg' );
+$image = new ezcImageAnalyzer(
"{$tutorialPath}/img/imageanalysis_example_01.jpg" );
echo "Image has MIME type <{$image->mime}>.\n";
-
?>
Modified: packages/ImageAnalysis/trunk/docs/tutorial_example_02.php
===================================================================
--- packages/ImageAnalysis/trunk/docs/tutorial_example_02.php 2006-01-27
16:29:44 UTC (rev 2071)
+++ packages/ImageAnalysis/trunk/docs/tutorial_example_02.php 2006-01-27
17:44:15 UTC (rev 2072)
@@ -1,21 +1,15 @@
<?php
-
require_once 'tutorial_autoload.php';
-
$tutorialPath = dirname( __FILE__ );
$image = new ezcImageAnalyzer(
$tutorialPath.'/img/imageanalysis_example_02.jpg' );
echo "Image data:\n";
-
echo "MIME type:\t{$image->mime}\n";
-
echo "Width:\t\t{$image->data->width} px\n";
echo "Height:\t\t{$image->data->height} px\n";
echo "Filesize:\t{$image->data->size} b\n";
$comment = ( $image->data->comment == '' ) ? 'n/a' : $image->data->comment;
-
echo "Comment:\t{$comment}\n";
-
?>
Modified: packages/ImageAnalysis/trunk/docs/tutorial_example_03.php
===================================================================
--- packages/ImageAnalysis/trunk/docs/tutorial_example_03.php 2006-01-27
16:29:44 UTC (rev 2071)
+++ packages/ImageAnalysis/trunk/docs/tutorial_example_03.php 2006-01-27
17:44:15 UTC (rev 2072)
@@ -1,7 +1,5 @@
<?php
-
require_once 'tutorial_autoload.php';
-
$tutorialPath = dirname( __FILE__ );
ezcImageAnalyzer::setHandlerClasses(
@@ -13,15 +11,11 @@
$image = new ezcImageAnalyzer(
$tutorialPath.'/img/imageanalysis_example_03.jpg' );
echo "Image data:\n";
-
echo "MIME type:\t{$image->mime}\n";
-
echo "Width:\t\t{$image->data->width} px\n";
echo "Height:\t\t{$image->data->height} px\n";
echo "Filesize:\t{$image->data->size} b\n";
$comment = ( $image->data->comment == '' ) ? 'n/a' : $image->data->comment;
-
echo "Comment:\t{$comment}\n";
-
?>
--
svn-components mailing list
[email protected]
http://lists.ez.no/mailman/listinfo/svn-components