KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > batik > ext > awt > image > rendered > CachableRed


1 /*
2
3    Copyright 2001,2003 The Apache Software Foundation
4
5    Licensed under the Apache License, Version 2.0 (the "License");
6    you may not use this file except in compliance with the License.
7    You may obtain a copy of the License at
8
9        http://www.apache.org/licenses/LICENSE-2.0
10
11    Unless required by applicable law or agreed to in writing, software
12    distributed under the License is distributed on an "AS IS" BASIS,
13    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14    See the License for the specific language governing permissions and
15    limitations under the License.
16
17  */

18 package org.apache.batik.ext.awt.image.rendered;
19
20 import java.awt.Rectangle JavaDoc;
21 import java.awt.Shape JavaDoc;
22 import java.awt.image.RenderedImage JavaDoc;
23
24 /**
25  * This provides a number of extra methods that enable a system to
26  * better analyse the dependencies between nodes in a render graph.
27  *
28  * @author <a HREF="mailto:Thomas.DeWeeese@Kodak.com">Thomas DeWeese</a>
29  * @version $Id: CachableRed.java,v 1.4 2004/08/18 07:14:08 vhardy Exp $
30 */

31 public interface CachableRed extends RenderedImage JavaDoc {
32
33     /**
34      * Returns the bounds of the current image.
35      * This should be 'in sync' with getMinX, getMinY, getWidth, getHeight
36      */

37     public Rectangle JavaDoc getBounds();
38
39     /**
40      * Returns the region of input data is is required to generate
41      * outputRgn.
42      * @param srcIndex The source to do the dependency calculation for.
43      * @param outputRgn The region of output you are interested in
44      * generating dependencies for. The is given in the output pixel
45      * coordiate system for this node.
46      * @return The region of input required. This is in the output pixel
47      * coordinate system for the source indicated by srcIndex.
48      */

49     public Shape JavaDoc getDependencyRegion(int srcIndex, Rectangle JavaDoc outputRgn);
50
51     /**
52      * This calculates the region of output that is affected by a change
53      * in a region of input.
54      * @param srcIndex The input that inputRgn reflects changes in.
55      * @param inputRgn the region of input that has changed, used to
56      * calculate the returned shape. This is given in the pixel
57      * coordinate system of the source indicated by srcIndex.
58      * @return The region of output that would be invalid given
59      * a change to inputRgn of the source selected by srcIndex.
60      * this is in the output pixel coordinate system of this node.
61      */

62     public Shape JavaDoc getDirtyRegion(int srcIndex, Rectangle JavaDoc inputRgn);
63 }
64
65
Popular Tags