Package ch.sahits.game.graphic.image
Interface IImageLoader
-
- All Known Subinterfaces:
IDataImageLoader
- All Known Implementing Classes:
SelectiveCachableXMLImageLoader
public interface IImageLoader
Interface defining the functionality for loading images. The implementation provides caching of loaded images- Author:
- aho
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description javafx.scene.image.Image
getImage(java.lang.String name)
Get the image associated withname
.javafx.scene.image.Image
getImage(java.lang.String name, double destWidth, double destHeight)
Retrieve the image with the given dimensionsjavafx.scene.image.Image
loadImage(java.lang.String fnm)
Load the image fromfnm
, returning it as a Image.javafx.scene.image.Image
loadImage(java.lang.String fnm, double width, double height)
Load the image fromfnm
with the defined dimensions, returning it as a Image.
-
-
-
Method Detail
-
getImage
javafx.scene.image.Image getImage(java.lang.String name)
Get the image associated withname
. If there are several images stored under that name, return the first one in the list.
-
loadImage
javafx.scene.image.Image loadImage(java.lang.String fnm)
Load the image fromfnm
, returning it as a Image.
-
loadImage
javafx.scene.image.Image loadImage(java.lang.String fnm, double width, double height)
Load the image fromfnm
with the defined dimensions, returning it as a Image.
-
getImage
javafx.scene.image.Image getImage(java.lang.String name, double destWidth, double destHeight)
Retrieve the image with the given dimensions- Parameters:
name
- of the imagedestWidth
- destination widthdestHeight
- destination height- Returns:
- Image
-
-