📄 imageworker.html
字号:
(if any) will save their tiles in the default <A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/TileCache.html" title="class or interface in javax.media.jai">tile cache</A>.<P><DT><B>Parameters:</B><DD><CODE>image</CODE> - The source image.</DL><HR><A NAME="ImageWorker(java.io.File)"><!-- --></A><H3>ImageWorker</H3><PRE>public <B>ImageWorker</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/File.html" title="class or interface in java.io">File</A> input) throws <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/IOException.html" title="class or interface in java.io">IOException</A></PRE><DL><DD>Creates a new builder for an image read from the specified file.<P><DT><B>Parameters:</B><DD><CODE>input</CODE> - The file to read.<DT><B>Throws:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/IOException.html" title="class or interface in java.io">IOException</A></CODE> - if the file can't be read.</DL><HR><A NAME="ImageWorker()"><!-- --></A><H3>ImageWorker</H3><PRE>public <B>ImageWorker</B>()</PRE><DL><DD>Creates a new uninitialized builder for an image read.<P><DT><B>Throws:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/IOException.html" title="class or interface in java.io">IOException</A></CODE> - if the file can't be read.</DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="setImage(java.awt.image.RenderedImage)"><!-- --></A><H3>setImage</H3><PRE>public final <A HREF="../../../org/geotools/image/ImageWorker.html" title="class in org.geotools.image">ImageWorker</A> <B>setImage</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/image/RenderedImage.html" title="class or interface in java.awt.image">RenderedImage</A> image)</PRE><DL><DD>Prepare this builder for the specified image. The images to be computed (if any) will save their tiles in the default <A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/TileCache.html" title="class or interface in javax.media.jai">tile cache</A>.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>image</CODE> - The source image.</DL></DD></DL><HR><A NAME="loadPlanarImageImage(java.lang.String, java.awt.RenderingHints, int, boolean)"><!-- --></A><H3>loadPlanarImageImage</H3><PRE>public static <A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/PlanarImage.html" title="class or interface in javax.media.jai">PlanarImage</A> <B>loadPlanarImageImage</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> source, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/RenderingHints.html" title="class or interface in java.awt">RenderingHints</A> hints, int imageChoice, boolean readMetadata)</PRE><DL><DD>Loads an image using the provided file name and the provided hints, which are used to control caching and layout.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>source</CODE> - The source image.<DD><CODE>hints</CODE> - The hints to use.<DD><CODE>imageChoice</CODE> - For multipage images.<DT><B>Returns:</B><DD>The loaded image.</DL></DD></DL><HR><A NAME="getRenderedImage()"><!-- --></A><H3>getRenderedImage</H3><PRE>public final <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/image/RenderedImage.html" title="class or interface in java.awt.image">RenderedImage</A> <B>getRenderedImage</B>()</PRE><DL><DD>Returns the current image.<P><DD><DL><DT><B>See Also:</B><DD><A HREF="../../../org/geotools/image/ImageWorker.html#getPlanarImage()"><CODE>getPlanarImage()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getRenderedOperation()"><CODE>getRenderedOperation()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getImageAsROI()"><CODE>getImageAsROI()</CODE></A></DL></DD></DL><HR><A NAME="getPlanarImage()"><!-- --></A><H3>getPlanarImage</H3><PRE>public final <A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/PlanarImage.html" title="class or interface in javax.media.jai">PlanarImage</A> <B>getPlanarImage</B>()</PRE><DL><DD>Returns the <A HREF="../../../org/geotools/image/ImageWorker.html#getRenderedImage()">rendered image</A> as a planar image.<P><DD><DL><DT><B>See Also:</B><DD><A HREF="../../../org/geotools/image/ImageWorker.html#getRenderedImage()"><CODE>getRenderedImage()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getRenderedOperation()"><CODE>getRenderedOperation()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getImageAsROI()"><CODE>getImageAsROI()</CODE></A></DL></DD></DL><HR><A NAME="getRenderedOperation()"><!-- --></A><H3>getRenderedOperation</H3><PRE>public final <A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/RenderedOp.html" title="class or interface in javax.media.jai">RenderedOp</A> <B>getRenderedOperation</B>()</PRE><DL><DD>Returns the <A HREF="../../../org/geotools/image/ImageWorker.html#getRenderedImage()">rendered image</A> as a rendered operation.<P><DD><DL><DT><B>See Also:</B><DD><A HREF="../../../org/geotools/image/ImageWorker.html#getRenderedImage()"><CODE>getRenderedImage()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getPlanarImage()"><CODE>getPlanarImage()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getImageAsROI()"><CODE>getImageAsROI()</CODE></A></DL></DD></DL><HR><A NAME="getImageAsROI()"><!-- --></A><H3>getImageAsROI</H3><PRE>public final <A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/ROI.html" title="class or interface in javax.media.jai">ROI</A> <B>getImageAsROI</B>()</PRE><DL><DD>Returns a <A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/ROI.html" title="class or interface in javax.media.jai">Region Of Interest</A> built from the current <A HREF="../../../org/geotools/image/ImageWorker.html#getRenderedImage()">image</A>. If the image is multi-bands, then this method first computes an estimation of its <A HREF="../../../org/geotools/image/ImageWorker.html#intensity()">intensity</A>. Next, this method <A HREF="../../../org/geotools/image/ImageWorker.html#binarize()">binarize</A> the image and constructs a <A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/ROI.html" title="class or interface in javax.media.jai"><CODE>ROI</CODE></A> from the result.<P><DD><DL><DT><B>See Also:</B><DD><A HREF="../../../org/geotools/image/ImageWorker.html#getRenderedImage()"><CODE>getRenderedImage()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getPlanarImage()"><CODE>getPlanarImage()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getRenderedOperation()"><CODE>getRenderedOperation()</CODE></A></DL></DD></DL><HR><A NAME="getROI()"><!-- --></A><H3>getROI</H3><PRE>public final <A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/ROI.html" title="class or interface in javax.media.jai">ROI</A> <B>getROI</B>()</PRE><DL><DD>Returns the <cite>region of interest</cite> currently set, or if none. The default value is .<P><DD><DL><DT><B>See Also:</B><DD><A HREF="../../../org/geotools/image/ImageWorker.html#getMinimums()"><CODE>getMinimums()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getMaximums()"><CODE>getMaximums()</CODE></A></DL></DD></DL><HR><A NAME="setROI(javax.media.jai.ROI)"><!-- --></A><H3>setROI</H3><PRE>public final <A HREF="../../../org/geotools/image/ImageWorker.html" title="class in org.geotools.image">ImageWorker</A> <B>setROI</B>(<A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/ROI.html" title="class or interface in javax.media.jai">ROI</A> roi)</PRE><DL><DD>Set the <cite>region of interest</cite> (ROI). A set the ROI to the whole <A HREF="../../../org/geotools/image/ImageWorker.html#image">image</A>. The ROI is used by statistical m閠hods like <A HREF="../../../org/geotools/image/ImageWorker.html#getMinimums()"><CODE>getMinimums()</CODE></A> and <A HREF="../../../org/geotools/image/ImageWorker.html#getMaximums()"><CODE>getMaximums()</CODE></A>.<P><DD><DL><DT><B>Returns:</B><DD>this <A HREF="../../../org/geotools/image/ImageWorker.html" title="class in org.geotools.image"><CODE>ImageWorker</CODE></A>.<DT><B>See Also:</B><DD><A HREF="../../../org/geotools/image/ImageWorker.html#getMinimums()"><CODE>getMinimums()</CODE></A>, <A HREF="../../../org/geotools/image/ImageWorker.html#getMaximums()"><CODE>getMaximums()</CODE></A></DL></DD></DL><HR><A NAME="getRenderingHint(java.awt.RenderingHints.Key)"><!-- --></A><H3>getRenderingHint</H3><PRE>public final <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A> <B>getRenderingHint</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/RenderingHints.Key.html" title="class or interface in java.awt">RenderingHints.Key</A> key)</PRE><DL><DD>Returns the rendering hint for the specified key, or if none.<P><DD><DL></DL></DD></DL><HR><A NAME="setRenderingHint(java.awt.RenderingHints.Key, java.lang.Object)"><!-- --></A><H3>setRenderingHint</H3><PRE>public final <A HREF="../../../org/geotools/image/ImageWorker.html" title="class in org.geotools.image">ImageWorker</A> <B>setRenderingHint</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/awt/RenderingHints.Key.html" title="class or interface in java.awt">RenderingHints.Key</A> key, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A> value)</PRE><DL><DD>Set a rendering hint tile to use for all images to be computed by this class. This method applies only to the next images to be computed; images already computed before this method call (if any) will not be affected. <p> Some common examples: <p> <ul> <li><code>setRenderingHint(<A HREF="http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/JAI.html#KEY_TILE_CACHE" title="class or interface in javax.media.jai">JAI.KEY_TILE_CACHE</A>, null)</code> disables completly the tile cache.</li> <li><code>setRenderingHint(<A HREF="../../../org/geotools/image/ImageWorker.html#TILING_ALLOWED">TILING_ALLOWED</A>, Boolean.FALSE)</code> forces all operators to produce untiled images.</li> </ul><P><DD><DL><DT><B>Returns:</B><DD>this <A HREF="../../../org/geotools/image/ImageWorker.html" title="class in org.geotools.image"><CODE>ImageWorker</CODE></A>.</DL></DD></DL><HR><A NAME="removeRenderingHint(java.awt.RenderingHints.Key)"><!-- --><
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -