⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 qtimagedrawer.html

📁 这个是java的quicktime for java 的详细使用文档
💻 HTML
📖 第 1 页 / 共 4 页
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd"><!--NewPage--><HTML><HEAD><!-- Generated by javadoc on Mon Jul 15 11:49:49 PDT 2002 --><TITLE>: Class  QTImageDrawer</TITLE><LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style"></HEAD><BODY BGCOLOR="white"><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_top"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_top_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">  <TR ALIGN="center" VALIGN="top">  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/QTImageDrawer.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../../quicktime/app/image/QTFilter.html"><B>PREV CLASS</B></A>&nbsp;&nbsp;<A HREF="../../../quicktime/app/image/QTImageProducer.html"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="QTImageDrawer.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY: &nbsp;INNER&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: &nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><!-- =========== END OF NAVBAR =========== --><HR><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">quicktime.app.image</FONT><BR>Class  QTImageDrawer</H2><PRE>java.lang.Object  |  +--<B>quicktime.app.image.QTImageDrawer</B></PRE><DL><DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../quicktime/app/image/Compositable.html">Compositable</A>, <A HREF="../../../quicktime/app/display/Drawable.html">Drawable</A>, <A HREF="../../../quicktime/app/image/DynamicImage.html">DynamicImage</A>, <A HREF="../../../quicktime/app/image/ImageSpec.html">ImageSpec</A>, <A HREF="../../../quicktime/app/spaces/Listener.html">Listener</A>, <A HREF="../../../quicktime/app/actions/Notifier.html">Notifier</A>, <A HREF="../../../quicktime/app/display/QTDrawable.html">QTDrawable</A>, <A HREF="../../../quicktime/app/image/Redrawable.html">Redrawable</A>, <A HREF="../../../quicktime/app/image/Transformable.html">Transformable</A></DD></DL><HR><DL><DT>public class <B>QTImageDrawer</B><DT>extends java.lang.Object<DT>implements <A HREF="../../../quicktime/app/actions/Notifier.html">Notifier</A>, <A HREF="../../../quicktime/app/display/QTDrawable.html">QTDrawable</A>, <A HREF="../../../quicktime/app/image/DynamicImage.html">DynamicImage</A>, <A HREF="../../../quicktime/app/image/Redrawable.html">Redrawable</A></DL><P>Enables standard java drawing commands and graphics objects to have their content rendered by QuickTime within a QuickTime graphics space. The QTImageDrawer is a parent container for an object that implements the Paintable interface - which is the object that actually does the drawing using standard java.awt paint commands and graphics objects.  The QTImageDrawer implements the DynamicImage interface so can be added to the  quicktime.app.display.Compositor object and thus used to draw into the same display space as other QuickTime generated content, or can be a direct client of a QTCanvas. <P> The isSingleFrame flag that is specified in the constructor allows optimisations to be made by the QTImageDrawer. If this flag is set to Redrawable.kSingleFrame then the QTImageDrawer will only call its Paintable object once to capture the image it Paintable draws. It will then discard all of the objects it has acquired to allow the paint call to the Paintable. If kMultiFrame is specified then on each redraw call the Paintable's paint call is called and the result is redrawn. If the QTImageDrawer is a member of the SWCompositor a similar efficiency can be achieved - if kSingleFrame is specified then when the drawer is added to the Compositor it does not require invalidation so does not create an invalidator as its image data is static. If kMultiFrame is specified then an invalidator is created. <P> An application can explicitly call prepaint - which is the method that calls the Paintable's paint method at any time. If the application is itself controlling the prepaint call then it will probably want to set and reset the isRedrawing flag as the redraw method determines whether to call prepaint or not based on the value of this flag. Once image data has been captured using the prepaint call to see the results in destination QDGraphics redraw must be called. Thus if an application is calling prepaint itself it will likely want to then setRedrawing to false and would only require redrawing to be set to true if it requires any consequent calls of the redraw method to re-capture image data from a call to prepaint. <P> The Invalidator determines if the QTImageDrawer requires redrawing and invalidation based on the value of the isRedrawing flag - it redraws and invalidates if isRedrawing returns true. If the application is controlling the prepaint calls (and thus would typically set redrawing to false) then it should invalidate the sprite presenter of the QTImageDrawer.<P><DL><DT><B>See Also: </B><DD><CODE>quicktime.app.display.Compositor</CODE>, <CODE>quicktime.app.display.Paintable</CODE></DL><HR><P><!-- ======== INNER CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><A NAME="field_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Field Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#kMultiFrameRetain">kMultiFrameRetain</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This flag modifies the behaviour of the multiFrame flag in that  it will retain resources that are used between invocations of the  attached Paintables paint method.</TD></TR></TABLE>&nbsp;<A NAME="fields_inherited_from_class_quicktime.app.image.Redrawable"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Fields inherited from interface quicktime.app.image.<A HREF="../../../quicktime/app/image/Redrawable.html">Redrawable</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="../../../quicktime/app/image/Redrawable.html#kMultiFrame">kMultiFrame</A>, <A HREF="../../../quicktime/app/image/Redrawable.html#kSingleFrame">kSingleFrame</A></CODE></TD></TR></TABLE>&nbsp;<!-- ======== CONSTRUCTOR SUMMARY ======== --><A NAME="constructor_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Constructor Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#QTImageDrawer(java.awt.Image)">QTImageDrawer</A></B>(java.awt.Image&nbsp;image)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This creates a QTImageDrawer that will grab the pixel data that results from drawing the specified image at its full size.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#QTImageDrawer(java.awt.Image, java.awt.Dimension)">QTImageDrawer</A></B>(java.awt.Image&nbsp;image,              java.awt.Dimension&nbsp;initialSize)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This creates a QTImageDrawer that will grab the pixel data that results from a scaled drawing of the specified image at the specified size.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#QTImageDrawer(quicktime.app.image.Paintable, java.awt.Dimension, int)">QTImageDrawer</A></B>(<A HREF="../../../quicktime/app/image/Paintable.html">Paintable</A>&nbsp;painter,              java.awt.Dimension&nbsp;initialSize,              int&nbsp;isSingleFrame)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This creates the QTImageDrawer object which is the parent container of the Paintable object.</TD></TR></TABLE>&nbsp;<!-- ========== METHOD SUMMARY =========== --><A NAME="method_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Method Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#addedTo(java.lang.Object)">addedTo</A></B>(java.lang.Object&nbsp;interest)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method is called by the specified object when the instance of  the class that implements this interface is added to the object that is the source of the interest.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../quicktime/app/actions/Invalidator.html">Invalidator</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#addedToCompositor(quicktime.app.anim.SWCompositor, quicktime.app.anim.TwoDSprite)">addedToCompositor</A></B>(<A HREF="../../../quicktime/app/anim/SWCompositor.html">SWCompositor</A>&nbsp;c,                  <A HREF="../../../quicktime/app/anim/TwoDSprite.html">TwoDSprite</A>&nbsp;s)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an object that invalidates a sprite.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#addNotifyListener(quicktime.app.actions.NotifyListener)">addNotifyListener</A></B>(<A HREF="../../../quicktime/app/actions/NotifyListener.html">NotifyListener</A>&nbsp;nl)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This registers the deferred listener.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#export(quicktime.std.image.GraphicsExporter)">export</A></B>(<A HREF="../../../quicktime/std/image/GraphicsExporter.html">GraphicsExporter</A>&nbsp;exporter)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method uses the supplied GraphicsExporter to export the current image that is being presented by the QTImageDrawer  and its Paintable client.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#export(quicktime.std.image.GraphicsExporter, quicktime.qd.QDGraphics)">export</A></B>(<A HREF="../../../quicktime/std/image/GraphicsExporter.html">GraphicsExporter</A>&nbsp;exporter,       <A HREF="../../../quicktime/qd/QDGraphics.html">QDGraphics</A>&nbsp;offscreenGWorld)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method uses the supplied GraphicsExporter to export the current image that is being presented by the QTImageDrawer  and its Paintable client.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../quicktime/qd/Region.html">Region</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#getClip()">getClip</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a region that defines the current clipping region for the object.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../quicktime/std/image/ImageDescription.html">ImageDescription</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#getDescription()">getDescription</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method should return an ImageDescription that describes the image data that the class contains.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../quicktime/qd/QDRect.html">QDRect</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#getDisplayBounds()">getDisplayBounds</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;QTCanvas calls this method when it needs to ask the client for its boundary.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../quicktime/std/image/GraphicsMode.html">GraphicsMode</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#getGraphicsMode()">getGraphicsMode</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This gets the current GraphicsMode for the compositor.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../quicktime/qd/QDGraphics.html">QDGraphics</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#getGWorld()">getGWorld</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;QTCanvas calls this method to get the destination QDGraphics of its client.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../quicktime/util/EncodedImage.html">EncodedImage</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../quicktime/app/image/QTImageDrawer.html#getImage()">getImage</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method returns the actual image data.</TD>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -