2362N/A * Copyright (c) 1997, 2008, Oracle and/or its affiliates. All rights reserved. 0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A * This code is free software; you can redistribute it and/or modify it 0N/A * under the terms of the GNU General Public License version 2 only, as 2362N/A * published by the Free Software Foundation. Oracle designates this 0N/A * particular file as subject to the "Classpath" exception as provided 2362N/A * by Oracle in the LICENSE file that accompanied this code. 0N/A * This code is distributed in the hope that it will be useful, but WITHOUT 0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A * version 2 for more details (a copy is included in the LICENSE file that 0N/A * accompanied this code). 0N/A * You should have received a copy of the GNU General Public License version 0N/A * 2 along with this work; if not, write to the Free Software Foundation, 0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2362N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 2362N/A * or visit www.oracle.com if you need additional information or have any 0N/A * The <code>TexturePaint</code> class provides a way to fill a 0N/A * {@link Shape} with a texture that is specified as 0N/A * a {@link BufferedImage}. The size of the <code>BufferedImage</code> 0N/A * object should be small because the <code>BufferedImage</code> data 0N/A * is copied by the <code>TexturePaint</code> object. 0N/A * At construction time, the texture is anchored to the upper 0N/A * left corner of a {@link Rectangle2D} that is 0N/A * specified in user space. Texture is computed for 0N/A * locations in the device space by conceptually replicating the 0N/A * specified <code>Rectangle2D</code> infinitely in all directions 0N/A * in user space and mapping the <code>BufferedImage</code> to each 0N/A * replicated <code>Rectangle2D</code>. 0N/A * @see Graphics2D#setPaint 213N/A * @version 1.48, 06/05/07 0N/A * Constructs a <code>TexturePaint</code> object. 0N/A * @param txtr the <code>BufferedImage</code> object with the texture 0N/A * @param anchor the <code>Rectangle2D</code> in user space used to 0N/A * anchor and replicate the texture 0N/A * Returns the <code>BufferedImage</code> texture used to 0N/A * @return a <code>BufferedImage</code>. 0N/A * Returns a copy of the anchor rectangle which positions and 0N/A * sizes the textured image. 0N/A * @return the <code>Rectangle2D</code> used to anchor and 0N/A * size this <code>TexturePaint</code>. 213N/A * Creates and returns a {@link PaintContext} used to 213N/A * generate a tiled image pattern. 213N/A * See the {@link Paint#createContext specification} of the 213N/A * method in the {@link Paint} interface for information 213N/A * on null parameter handling. 213N/A * @param cm the preferred {@link ColorModel} which represents the most convenient 213N/A * format for the caller to receive the pixel data, or {@code null} 213N/A * if there is no preference. 213N/A * @param deviceBounds the device space bounding box 213N/A * of the graphics primitive being rendered. 213N/A * @param userBounds the user space bounding box 213N/A * of the graphics primitive being rendered. 213N/A * @param xform the {@link AffineTransform} from user 213N/A * space into device space. 213N/A * @param hints the set of hints that the context object can use to 213N/A * choose between rendering alternatives. 213N/A * @return the {@code PaintContext} for 213N/A * generating color patterns. 0N/A * Returns the transparency mode for this <code>TexturePaint</code>. 0N/A * @return the transparency mode for this <code>TexturePaint</code> 0N/A * as an integer value.