Class PixelData


  • public class PixelData
    extends java.lang.Object
    Strategy for loading and optionally caching pixel data.
    Since:
    Beta4.1
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected ome.io.nio.PixelsService data  
      protected org.slf4j.Logger log  
      protected ome.api.IPixels meta  
    • Constructor Summary

      Constructors 
      Constructor Description
      PixelData​(ome.io.nio.PixelsService data, ome.api.IPixels meta)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      double get​(ome.io.nio.PixelBuffer buf, int x, int y, int z, int c, int t)  
      ome.io.nio.PixelBuffer getBuffer​(long pix)  
      ome.util.PixelData getPlane​(ome.io.nio.PixelBuffer buf, int z, int c, int t)
      Returns the PixelData for plane given its z, c and t as well as a PixelBuffer
      boolean requiresPixelsPyramid​(ome.model.core.Pixels pix)
      Returns whether a pyramid should be used for the given Pixels.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • log

        protected org.slf4j.Logger log
      • data

        protected final ome.io.nio.PixelsService data
      • meta

        protected final ome.api.IPixels meta
    • Constructor Detail

      • PixelData

        public PixelData​(ome.io.nio.PixelsService data,
                         ome.api.IPixels meta)
    • Method Detail

      • getBuffer

        public ome.io.nio.PixelBuffer getBuffer​(long pix)
      • get

        public double get​(ome.io.nio.PixelBuffer buf,
                          int x,
                          int y,
                          int z,
                          int c,
                          int t)
      • getPlane

        public ome.util.PixelData getPlane​(ome.io.nio.PixelBuffer buf,
                                           int z,
                                           int c,
                                           int t)
        Returns the PixelData for plane given its z, c and t as well as a PixelBuffer
        Parameters:
        buf - the PixelBuffer
        z - the Z
        c - the C
        t - the T
        Returns:
        the ome.util.PixelData for the plane
      • requiresPixelsPyramid

        public boolean requiresPixelsPyramid​(ome.model.core.Pixels pix)
        Returns whether a pyramid should be used for the given Pixels. This usually implies that this is a "Big image" and therefore will need tiling.
        Parameters:
        pix - the pixels
        Returns:
        true if a pyramid should be used, false otherwise
        See Also:
        PixelsService.requiresPixelsPyramid(Pixels)