Package net.imglib2

Interface RealLocalizable

    • Method Detail

      • localize

        default void localize​(float[] position)
        Write the current position into the passed array.
        Parameters:
        position - receives current position, length must be ≥ EuclideanSpace.numDimensions()
      • localize

        default void localize​(double[] position)
        Write the current position into the passed array.
        Parameters:
        position - receives current position, length must be ≥ EuclideanSpace.numDimensions()
      • positionAsDoubleArray

        default double[] positionAsDoubleArray()
        Allocate and return a double array with the position. Please note that his method allocates a new array each time which introduces notable overhead in both compute and memory. If you query it frequently, you should allocate a dedicated array first and reuse it with localize(double[]).
        Returns:
        the position
      • positionAsRealPoint

        default RealPoint positionAsRealPoint()
        Allocate and return a RealPoint with the current position. Please note that his method allocates a new RealPoint each time which introduces notable overhead in both compute and memory. If you query it frequently, you should allocate a dedicated RealPoint first and reuse it with localize(RealPositionable).
        Returns:
        the position
      • getFloatPosition

        default float getFloatPosition​(int d)
        Return the current position in a given dimension.
        Parameters:
        d - dimension
        Returns:
        dimension of current position
      • getDoublePosition

        double getDoublePosition​(int d)
        Return the current position in a given dimension.
        Parameters:
        d - dimension
        Returns:
        dimension of current position