|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectgov.nasa.worldwind.util.TextureAtlas.AtlasBackingStore
protected class TextureAtlas.AtlasBackingStore
Implementation of the JOGL BackingStoreManager interface for texture atlas. This is used by the JOGL RectanglePacker, and delegates calls from a JOGL rectangle packer to methods in this texture atlas.
| Constructor Summary | |
|---|---|
protected |
TextureAtlas.AtlasBackingStore()
|
| Method Summary | |
|---|---|
boolean |
additionFailed(Rect cause,
int attemptNumber)
If this texture atlas is configured to evicts old elements, this attempts to remove the oldest one then exits, allowing the caller to attempt the addition again. |
Object |
allocateBackingStore(int w,
int h)
Calls TextureAtlas.createBackingImage(int, int) with the specified width and height. |
void |
beginMovement(Object oldBackingStore,
Object newBackingStore)
Calls TextureAtlas.beginMoveEntries(java.awt.image.BufferedImage, java.awt.image.BufferedImage),
casting the specified backing stores to BufferedImages. |
boolean |
canCompact()
Returns true. |
void |
deleteBackingStore(Object backingStore)
Calls TextureAtlas.disposeBackingImage(). |
void |
endMovement(Object oldBackingStore,
Object newBackingStore)
Calls TextureAtlas.endMoveEntries(java.awt.image.BufferedImage, java.awt.image.BufferedImage),
casting the specified backing stores to BufferedImages. |
void |
move(Object oldBackingStore,
Rect oldLocation,
Object newBackingStore,
Rect newLocation)
Calls TextureAtlas.moveEntry(java.awt.image.BufferedImage, com.jogamp.opengl.util.packrect.Rect,
java.awt.image.BufferedImage, com.jogamp.opengl.util.packrect.Rect), casting the specified backing stores to
BufferedImages. |
boolean |
preExpand(Rect cause,
int attemptNumber)
Returns false, indicating that the rectangle packer should just expand. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected TextureAtlas.AtlasBackingStore()
| Method Detail |
|---|
public boolean additionFailed(Rect cause,
int attemptNumber)
additionFailed in interface BackingStoreManagerWWRuntimeException - if this backing store cannot fit the rectangle in its layout.
public Object allocateBackingStore(int w,
int h)
TextureAtlas.createBackingImage(int, int) with the specified width and height.
allocateBackingStore in interface BackingStoreManager
public void beginMovement(Object oldBackingStore,
Object newBackingStore)
TextureAtlas.beginMoveEntries(java.awt.image.BufferedImage, java.awt.image.BufferedImage),
casting the specified backing stores to BufferedImages.
beginMovement in interface BackingStoreManagerpublic boolean canCompact()
true. The texture atlas can always attempt to expand or compact.
canCompact in interface BackingStoreManagerpublic void deleteBackingStore(Object backingStore)
TextureAtlas.disposeBackingImage().
deleteBackingStore in interface BackingStoreManager
public void endMovement(Object oldBackingStore,
Object newBackingStore)
TextureAtlas.endMoveEntries(java.awt.image.BufferedImage, java.awt.image.BufferedImage),
casting the specified backing stores to BufferedImages.
endMovement in interface BackingStoreManager
public void move(Object oldBackingStore,
Rect oldLocation,
Object newBackingStore,
Rect newLocation)
TextureAtlas.moveEntry(java.awt.image.BufferedImage, com.jogamp.opengl.util.packrect.Rect,
java.awt.image.BufferedImage, com.jogamp.opengl.util.packrect.Rect), casting the specified backing stores to
BufferedImages.
move in interface BackingStoreManager
public boolean preExpand(Rect cause,
int attemptNumber)
false, indicating that the rectangle packer should just expand. When configured to do
so, texture atlas evicts old elements in additionFailed if this texture atlas is full and the
addition would otherwise fail.
preExpand in interface BackingStoreManager
|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||