org.jrabbit.standard.intro.base
Class ImageIntro

java.lang.Object
  extended by org.jrabbit.standard.intro.base.ImageIntro
All Implemented Interfaces:
Renderable, Updateable, Createable, Destroyable, Intro
Direct Known Subclasses:
ImageAudioIntro

public abstract class ImageIntro
extends java.lang.Object
implements Intro

An ImageIntro is an Intro that uses an Image. All that this abstract implementation does is to add the automated loading and deletion of the desired Image.

Author:
Chris Molini

Field Summary
protected  Image image
          The Image that has been loaded and is available for the Intro to use.
protected  Loader imageLoader
          The Loader that will load the desired Image.
 
Constructor Summary
ImageIntro(Loader loader)
          Creates an ImageIntro that uses the Image retrieved from the supplied Loader.
ImageIntro(java.lang.String filepath)
          Creates an ImageIntro that uses the Image at the indicated resource location.
 
Method Summary
 void create()
          Loads the Image this Intro will use.
 void destroy()
          Deletes the loaded Image, freeing memory on the GPU.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jrabbit.standard.intro.Intro
finished, start
 
Methods inherited from interface org.jrabbit.base.core.types.Updateable
update
 
Methods inherited from interface org.jrabbit.base.core.types.Renderable
render
 

Field Detail

imageLoader

protected Loader imageLoader
The Loader that will load the desired Image.


image

protected Image image
The Image that has been loaded and is available for the Intro to use.

Constructor Detail

ImageIntro

public ImageIntro(java.lang.String filepath)
Creates an ImageIntro that uses the Image at the indicated resource location.

Parameters:
filepath - The path to the desired source image file.

ImageIntro

public ImageIntro(Loader loader)
Creates an ImageIntro that uses the Image retrieved from the supplied Loader.

Parameters:
loader - The Loader that accesses the desired source image.
Method Detail

create

public void create()
Loads the Image this Intro will use.

Specified by:
create in interface Createable

destroy

public void destroy()
Deletes the loaded Image, freeing memory on the GPU.

Specified by:
destroy in interface Destroyable