Class PlanePyramidTools

java.lang.Object
net.algart.matrices.maps.pyramids.io.api.PlanePyramidTools

public class PlanePyramidTools extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static boolean
    areVeryLittleSizes(long dimX, long dimY)
     
    static net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>
    asBackground(Class<?> elementType, long dimX, long dimY, double[] backgroundColor)
     
    static List<net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>>
    buildPyramid(net.algart.arrays.Matrix<? extends net.algart.arrays.PArray> matrix)
     
    static List<net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>>
    buildPyramid(net.algart.arrays.Matrix<? extends net.algart.arrays.PArray> matrix, int compression)
     
    static int
     
    static List<net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>>
    equalizePrecisionToTheBest(List<? extends net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>> matrices)
     
    static void
    fillMatrix(net.algart.arrays.Matrix<? extends net.algart.arrays.UpdatablePArray> m, double[] color)
     
    static void
    fillMatrix(net.algart.arrays.Matrix<? extends net.algart.arrays.UpdatablePArray> m, long fromX, long fromY, long toX, long toY, double[] color)
     
    static void
    fillMatrix(net.algart.arrays.Matrix<? extends net.algart.arrays.UpdatablePArray> m, long fromX, long fromY, long toX, long toY, Color color)
     
    static void
    fillMatrix(net.algart.arrays.Matrix<? extends net.algart.arrays.UpdatablePArray> m, Color color)
     
    static int
    findCompression(long[] dimensionsOfSomeLevel, long[] dimensionsOnNextLevel)
     
    static boolean
    isDimensionsRelationCorrect(long[] dimOfSomeLevel, long[] dimOfNextLevel, int compression)
     
    static int
    numberOfResolutions(long dimX, long dimY, int compression, long minimalPyramidSize)
    Returns the number of resolution in the pyramid with the largest (zero) level dimX x dimY, with given compression between neighbour levels and with the last level less than minimalPyramidSize x minimalPyramidSize.
    static net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>
     
    rmiSafeWrapper(Exception nonStandardException)
     
    static double
     

    Methods inherited from class java.lang.Object

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

    • MIN_PYRAMID_LEVEL_SIDE

      public static final int MIN_PYRAMID_LEVEL_SIDE
      See Also:
  • Method Details

    • readSpecialOrSmallestMatrix

      public static net.algart.arrays.Matrix<? extends net.algart.arrays.PArray> readSpecialOrSmallestMatrix(PlanePyramidSource source, PlanePyramidSource.SpecialImageKind kind) throws NotYetConnectedException
      Throws:
      NotYetConnectedException
    • isDimensionsRelationCorrect

      public static boolean isDimensionsRelationCorrect(long[] dimOfSomeLevel, long[] dimOfNextLevel, int compression)
    • findCompression

      public static int findCompression(long[] dimensionsOfSomeLevel, long[] dimensionsOnNextLevel)
    • numberOfResolutions

      public static int numberOfResolutions(long dimX, long dimY, int compression, long minimalPyramidSize)
      Returns the number of resolution in the pyramid with the largest (zero) level dimX x dimY, with given compression between neighbour levels and with the last level less than minimalPyramidSize x minimalPyramidSize. But the result is never less than 1, even if the specified dimX and dimY are already less than minimalPyramidSize (in this case 1 returned).
      Parameters:
      dimX - width of zero-level (largest) level.
      dimY - height of zero-level (largest) level.
      compression - compression between neighbour levels, usually 2 or 4.
      minimalPyramidSize - minimal size of resulting levels.
      Returns:
      the number of resolutions in the resulting pyramid, always ≥1.
    • areVeryLittleSizes

      public static boolean areVeryLittleSizes(long dimX, long dimY)
    • rmiSafeWrapper

      public static IOException rmiSafeWrapper(Exception nonStandardException)
    • defaultCompression

      public static int defaultCompression(PlanePyramidSource source)
    • equalizePrecisionToTheBest

      public static List<net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>> equalizePrecisionToTheBest(List<? extends net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>> matrices)
    • asBackground

      public static net.algart.arrays.Matrix<? extends net.algart.arrays.PArray> asBackground(Class<?> elementType, long dimX, long dimY, double[] backgroundColor)
    • fillMatrix

      public static void fillMatrix(net.algart.arrays.Matrix<? extends net.algart.arrays.UpdatablePArray> m, long fromX, long fromY, long toX, long toY, Color color)
    • fillMatrix

      public static void fillMatrix(net.algart.arrays.Matrix<? extends net.algart.arrays.UpdatablePArray> m, long fromX, long fromY, long toX, long toY, double[] color)
    • fillMatrix

      public static void fillMatrix(net.algart.arrays.Matrix<? extends net.algart.arrays.UpdatablePArray> m, Color color)
    • fillMatrix

      public static void fillMatrix(net.algart.arrays.Matrix<? extends net.algart.arrays.UpdatablePArray> m, double[] color)
    • buildPyramid

      public static List<net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>> buildPyramid(net.algart.arrays.Matrix<? extends net.algart.arrays.PArray> matrix)
    • buildPyramid

      public static List<net.algart.arrays.Matrix<? extends net.algart.arrays.PArray>> buildPyramid(net.algart.arrays.Matrix<? extends net.algart.arrays.PArray> matrix, int compression)
    • usedMemory

      public static double usedMemory()