Package ome.api

Interface RawPixelsStore

  • All Superinterfaces:
    ServiceInterface, StatefulServiceInterface

    public interface RawPixelsStore
    extends StatefulServiceInterface
    Binary data provider. Initialized with the id of a Pixels instance, this interface can provide various slices, stacks, regions of the 5-dimensional (X-Y planes with multiple Z-sections and Channels over Time). The byte array returned by the getter methods and passed to the setter methods can and will be interpreted according to results of getByteWidth(), isFloat(), and isSigned().
    • Method Detail

      • setPixelsId

        void setPixelsId​(long pixelsId,
                         boolean bypassOriginalFile)
        Initializes the stateful service for a given Pixels set.
        Parameters:
        pixelsId - Pixels set identifier.
        bypassOriginalFile - Whether or not to bypass checking for an original file to back the pixel buffer used by this service. If requests are predominantly write-only or involve the population of a brand new pixel buffer using true here is a safe optimization otherwise false is expected.
      • getPixelsPath

        java.lang.String getPixelsPath()
        Returns the current Pixels path.
        Returns:
        See above.
      • getPixelsId

        long getPixelsId()
        Returns the current Pixels set identifier.
        Returns:
        See above.
      • prepare

        void prepare​(java.util.Set<java.lang.Long> pixelsIds)
        Prepares the stateful service with a cache of loaded Pixels objects. This method is designed to combat query overhead, where many sets of Pixels are to be read from or written to, by loading all the Pixels sets at once. Multiple calls will result in the existing cache being overwritten.
        Parameters:
        pixelsIds - Pixels IDs to cache.
      • getPlaneSize

        long getPlaneSize()
        Returns the plane size
        Returns:
        the plane size
      • getRowSize

        int getRowSize()
      • getStackSize

        long getStackSize()
      • getTimepointSize

        long getTimepointSize()
      • getTotalSize

        long getTotalSize()
      • getRowOffset

        long getRowOffset​(int y,
                          int z,
                          int c,
                          int t)
      • getPlaneOffset

        long getPlaneOffset​(int z,
                            int c,
                            int t)
      • getStackOffset

        long getStackOffset​(int c,
                            int t)
      • getTimepointOffset

        long getTimepointOffset​(int t)
      • getTile

        byte[] getTile​(int z,
                       int c,
                       int t,
                       int x,
                       int y,
                       int w,
                       int h)
      • getRegion

        byte[] getRegion​(int size,
                         long offset)
      • getRow

        byte[] getRow​(int y,
                      int z,
                      int c,
                      int t)
      • getCol

        byte[] getCol​(int x,
                      int z,
                      int c,
                      int t)
      • getHistogram

        java.util.Map<java.lang.Integer,​int[]> getHistogram​(int[] channels,
                                                                  int binCount,
                                                                  boolean globalRange,
                                                                  PlaneDef plane)
      • findMinMax

        java.util.Map<java.lang.Integer,​double[]> findMinMax​(int[] channels)
      • getHypercube

        byte[] getHypercube​(java.util.List<java.lang.Integer> offset,
                            java.util.List<java.lang.Integer> size,
                            java.util.List<java.lang.Integer> step)
      • getPlaneRegion

        byte[] getPlaneRegion​(int z,
                              int c,
                              int t,
                              int count,
                              int offset)
      • getPlane

        byte[] getPlane​(int z,
                        int c,
                        int t)
      • getStack

        byte[] getStack​(int c,
                        int t)
      • getTimepoint

        byte[] getTimepoint​(int t)
      • setTile

        void setTile​(byte[] buffer,
                     int z,
                     int c,
                     int t,
                     int x,
                     int y,
                     int w,
                     int h)
      • setRegion

        void setRegion​(int size,
                       long offset,
                       byte[] buffer)
      • setRow

        void setRow​(byte[] buffer,
                    int y,
                    int z,
                    int c,
                    int t)
      • setPlane

        void setPlane​(byte[] buffer,
                      int z,
                      int c,
                      int t)
      • setStack

        void setStack​(byte[] buffer,
                      int z,
                      int c,
                      int t)
      • setTimepoint

        void setTimepoint​(byte[] buffer,
                          int t)
      • getByteWidth

        int getByteWidth()
      • isSigned

        boolean isSigned()
      • isFloat

        boolean isFloat()
      • calculateMessageDigest

        byte[] calculateMessageDigest()
      • save

        ome.model.core.Pixels save()
      • requiresPixelsPyramid

        boolean requiresPixelsPyramid()
      • getResolutionDescriptions

        java.lang.Object getResolutionDescriptions()
      • getResolutionLevels

        int getResolutionLevels()
        Retrieves the number of resolution levels that the backing pixels pyramid contains.
        Returns:
        The number of resolution levels. This value does not necessarily indicate either the presence or absence of a pixels pyramid.
      • getResolutionLevel

        int getResolutionLevel()
        Retrieves the active resolution level.
        Returns:
        The active resolution level. The level will be non-negative and less than getResolutionLevels(). Resolution level 0 is the smallest resolution and resolution level getResolutionLevels() - 1 is the largest resolution. This is the inverse of how Bio-Formats indexes resolutions.
      • setResolutionLevel

        void setResolutionLevel​(int resolutionLevel)
        Sets the active resolution level.
        Parameters:
        resolutionLevel - The resolution level to be used. The level should be non-negative and less than getResolutionLevels(). * Resolution level 0 is the smallest resolution and resolution level getResolutionLevels() - 1 is the largest resolution. This is the inverse of how Bio-Formats indexes resolutions.
      • getTileSize

        int[] getTileSize()