Topic: java.awt.graphics 的 drawImage 小问题, 请帮忙.;)

  Print this page

1.java.awt.graphics 的 drawImage 小问题, 请帮忙.;) Copy to clipboard
Posted by: libinbin
Posted on: 2002-08-16 07:12

drawImage public abstract boolean drawImage(Image img,
                                                                  int x,
                                                                  int y,
                                                                  int width,
                                                                  int height,
                                                                  ImageObserver observer)

这个里面的 ImageObserver 设置为 this 或者为 null 有什么区别?
ImageObserver 是干什么的?

2.回复: java.awt.graphics 的 drawImage 小问题, 请帮忙.;) [Re: libinbin] Copy to clipboard
Posted by: scottlai
Posted on: 2002-08-16 13:27

libinbin wrote:
drawImage public abstract boolean drawImage(Image img,
                                                                  int x,
                                                                  int y,
                                                                  int width,
                                                                  int height,
                                                                  ImageObserver observer)

这个里面的 ImageObserver 设置为 this 或者为 null 有什么区别?
ImageObserver 是干什么的?


This method returns immediately in all cases, even if the complete image has not yet been loaded, and it has not been dithered and converted for the current output device.

If the image has not yet been completely loaded, then drawImage returns false. As more of the image becomes available, the process that draws the image ***notifies the specified image observer.***


   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923