Class OpenSlide
java.lang.Object
qupath.lib.images.servers.openslide.jna.OpenSlide
- All Implemented Interfaces:
 Closeable,AutoCloseable
Minimal Java wrapper for OpenSlide.
- 
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classException thrown whenever a request is made after the OpenSlide object has been closed. - 
Field Summary
Fields - 
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Close; this is important for cleanup.voiddispose()Dispose the OpenSlide object; this is equivalent toclose().getAssociatedImage(String name) Get a named associated image.Get a list of all associated image names.byte[]Request the bytes for an ICC profile.longGet the height of the full-resolution image (level 0).longGet the width of the full-resolution image (level 0).intGet the total number of pyramid levels.longgetLevelHeight(int level) Get the image height at the specified level.longgetLevelWidth(int level) Get the image width at the specified level.Get an unmodifiable map of all available properties.voidpaintRegionARGB(int[] dest, long x, long y, int level, int w, int h)  
- 
Field Details
- 
PROPERTY_NAME_COMMENT
- See Also:
 
 - 
PROPERTY_NAME_VENDOR
- See Also:
 
 - 
PROPERTY_NAME_QUICKHASH1
- See Also:
 
 - 
PROPERTY_NAME_BACKGROUND_COLOR
- See Also:
 
 - 
PROPERTY_NAME_OBJECTIVE_POWER
- See Also:
 
 - 
PROPERTY_NAME_MPP_X
- See Also:
 
 - 
PROPERTY_NAME_MPP_Y
- See Also:
 
 - 
PROPERTY_NAME_BOUNDS_X
- See Also:
 
 - 
PROPERTY_NAME_BOUNDS_Y
- See Also:
 
 - 
PROPERTY_NAME_BOUNDS_WIDTH
- See Also:
 
 - 
PROPERTY_NAME_BOUNDS_HEIGHT
- See Also:
 
 
 - 
 - 
Method Details
- 
dispose
public void dispose()Dispose the OpenSlide object; this is equivalent toclose(). - 
getLevelCount
public int getLevelCount()Get the total number of pyramid levels.- Returns:
 
 - 
getLevel0Width
public long getLevel0Width()Get the width of the full-resolution image (level 0).- Returns:
 
 - 
getLevel0Height
public long getLevel0Height()Get the height of the full-resolution image (level 0).- Returns:
 
 - 
getLevelWidth
public long getLevelWidth(int level) Get the image width at the specified level.- Parameters:
 level-- Returns:
 
 - 
getLevelHeight
public long getLevelHeight(int level) Get the image height at the specified level.- Parameters:
 level-- Returns:
 
 - 
paintRegionARGB
- Throws:
 IOException
 - 
getProperties
Get an unmodifiable map of all available properties.- Returns:
 
 - 
getAssociatedImage
Get a named associated image.- Parameters:
 name-- Returns:
 - Throws:
 IOException
 - 
getAssociatedImages
Get a list of all associated image names.- Returns:
 
 - 
close
public void close()Close; this is important for cleanup.- Specified by:
 closein interfaceAutoCloseable- Specified by:
 closein interfaceCloseable
 - 
getICCProfileBytes
Request the bytes for an ICC profile.- Returns:
 - the bytes of an ICC profile is available, or null otherwise.
 - Throws:
 UnsupportedOperationException- if an unsatisfied link error occurred, which indicates that the OpenSlide version is not compatible (it should be 4.0.0 or greater).
 
 -