1<?php
2
3/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
4
5/**
6 * Image_Graph - PEAR PHP OO Graph Rendering Utility.
7 *
8 * PHP version 5
9 *
10 * LICENSE: This library is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU Lesser General Public License as published by
12 * the Free Software Foundation; either version 2.1 of the License, or (at your
13 * option) any later version. This library is distributed in the hope that it
14 * will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty
15 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser
16 * General Public License for more details. You should have received a copy of
17 * the GNU Lesser General Public License along with this library; if not, write
18 * to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
19 * 02111-1307 USA
20 *
21 * @category   Images
22 * @package    Image_Graph
23 * @subpackage Fill
24 * @author     Jesper Veggerby <pear.nosey@veggerby.dk>
25 * @author     Stefan Neufeind <pear.neufeind@speedpartner.de>
26 * @copyright  2003-2009 The PHP Group
27 * @license    http://www.gnu.org/copyleft/lesser.html  LGPL License 2.1
28 * @version    SVN: $Id: Image.php 291170 2009-11-23 03:50:22Z neufeind $
29 * @link       http://pear.php.net/package/Image_Graph
30 */
31
32/**
33 * Include file Image/Graph/Fill.php
34 */
35require_once 'Image/Graph/Fill.php';
36
37/**
38 * Fill using an image.
39 *
40 * @category   Images
41 * @package    Image_Graph
42 * @subpackage Fill
43 * @author     Jesper Veggerby <pear.nosey@veggerby.dk>
44 * @author     Stefan Neufeind <pear.neufeind@speedpartner.de>
45 * @copyright  2003-2009 The PHP Group
46 * @license    http://www.gnu.org/copyleft/lesser.html  LGPL License 2.1
47 * @version    Release: 0.8.0
48 * @link       http://pear.php.net/package/Image_Graph
49 */
50class Image_Graph_Fill_Image extends Image_Graph_Fill
51{
52
53    /**
54     * The file name
55     * @var stirng
56     * @access private
57     */
58    var $_filename;
59
60    /**
61     * The GD Image resource
62     * @var resource
63     * @access private
64     */
65    var $_image;
66
67    /**
68     * Resize the image to the bounding box of the area to fill
69     * @var bool
70     * @access private
71     */
72    var $_resize = true;
73
74    /**
75     * Image_Graph_ImageFill [Constructor]
76     *
77     * @param string $filename The filename and path of the image to use for filling
78     */
79    function Image_Graph_Fill_Image($filename)
80    {
81        parent::__construct();
82        $this->_filename = $filename;
83    }
84
85    /**
86     * Return the fillstyle
87     *
88     * @param (something) $ID (Add description)
89     *
90     * @return int A GD fillstyle
91     * @access private
92     */
93    function _getFillStyle($ID = false)
94    {
95        return $this->_filename;
96    }
97
98}
99
100?>
101