org.j3d.renderer.java3d.overlay
Class ImageOverlay
java.lang.Object
org.j3d.renderer.java3d.overlay.OverlayBase
org.j3d.renderer.java3d.overlay.ImageOverlay
- All Implemented Interfaces:
- java.awt.event.ComponentListener, java.util.EventListener, Overlay, ScreenComponent, UpdatableEntity
- public class ImageOverlay
- extends OverlayBase
An overlay that draws an image on screen at the given position.
- Version:
- $Revision: 1.1 $
- Author:
- Justin Couch
| Fields inherited from class org.j3d.renderer.java3d.overlay.OverlayBase |
activeBuffer, backgroundColor, backgroundMode, bottomInset, canvas, componentSize, consoleBG, consoleTG, DEFAULT_INSET, DIRTY_ACTIVE_BUFFER, DIRTY_POSITION, DIRTY_SIZE, DIRTY_VISIBLE, fieldOfView, fixedSize, leftInset, overlayBounds, overlayTexGrp, rightInset, subOverlay, topInset |
|
Constructor Summary |
ImageOverlay(javax.media.j3d.Canvas3D canvas,
java.awt.Dimension size,
boolean clipAlpha,
boolean blendAlpha,
java.awt.image.BufferedImage image)
Construct a new overlay that paints the image in the given space
and has control over the alpha. |
ImageOverlay(javax.media.j3d.Canvas3D canvas,
java.awt.Dimension size,
java.awt.image.BufferedImage image)
Construct a new overlay that paints the image in the given space. |
|
Method Summary |
void |
repaint()
Repaint the overlay now. |
void |
setImage(java.awt.image.BufferedImage img)
Change the displayed image to this new image. |
| Methods inherited from class org.j3d.renderer.java3d.overlay.OverlayBase |
componentHidden, componentMoved, componentResized, componentShown, contains, dirty, getBackgroundImage, getBounds, getGraphics, getRoot, getUpdateManager, initialize, isAntialiased, isVisible, paint, setActiveBuffer, setAntialiased, setBackgroundColor, setBackgroundImage, setBackgroundMode, setComponentDetails, setInsets, setInsets, setLocation, setSize, setUpdateManager, setVisible, update, updateBuffer |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ImageOverlay
public ImageOverlay(javax.media.j3d.Canvas3D canvas,
java.awt.Dimension size,
java.awt.image.BufferedImage image)
- Construct a new overlay that paints the image in the given space.
The image is assumed to have an alpha component but it is not blended.
- Parameters:
canvas - The canvas to put the overlay onsize - The size of the overlay in pixelsimage - The image to display
ImageOverlay
public ImageOverlay(javax.media.j3d.Canvas3D canvas,
java.awt.Dimension size,
boolean clipAlpha,
boolean blendAlpha,
java.awt.image.BufferedImage image)
- Construct a new overlay that paints the image in the given space
and has control over the alpha.
- Parameters:
canvas - The canvas to put the overlay onsize - The size of the overlay in pixelsclipAlpha - true if the image contains alphablendAlpha - true if you want to blend the image with the
background of the overlay (ie let the color show through)image - The image to display
setImage
public void setImage(java.awt.image.BufferedImage img)
- Change the displayed image to this new image.
- Parameters:
img - The new image to see
repaint
public void repaint()
- Repaint the overlay now. Overridden to provide an empty implementation
as the repaint is performed with the buffers.
- Overrides:
repaint in class OverlayBase
Latest Info from http://code.j3d.org/
Copyright © 2001 - j3d.org