Prev Class | Next Class | Frames | No Frames |
Summary: Nested | Field | Method | Constr | Detail: Nested | Field | Method | Constr |
java.lang.Object
Data
public class Data
extends java.lang.Object
Constructor Summary | |
| |
| |
|
Method Summary | |
static void | |
double[][][] |
|
double[][] |
|
double[] |
|
double |
|
Data |
|
Data |
|
Data |
|
Data |
|
private int |
|
int |
|
int |
|
private boolean |
|
private boolean |
|
private boolean |
|
void |
|
void |
|
void |
|
void |
|
void |
|
Data | |
private void |
|
private double[][][] data
public int numBands
public int numCols
public int numRows
public Data(int bands)
Constructor - Creates the first (color bands) array dimension.
- Parameters:
bands
- Number of color bands
public Data(int bands, int rows)
Constructor - Creates the first (color bands) and second (row size) array dimension.
- Parameters:
bands
- Number of color bandsrows
- Number of rows
public Data(int bands, int rows, int cols)
Constructor - Creates the first (color bands) second (row size) and third (column size) array dimension.
- Parameters:
bands
- Number of color bandsrows
- Number of rows
public static void copy(Data src, Data target)
Copies a source 3-dim array to a target 3-dim array with identical dimensions
- Parameters:
src
- Source Data array
public double[][][] get()
Returns the current 3-dim data array
public double[][] get(int band)
Returns the rows and columns in the current double data array for a specified band
- Parameters:
band
- The target color band
public double[] get(int band, int row)
Returns the columns in the current double data array for a specified band and row
- Parameters:
band
- The target color band
public double get(int band, int row, int col)
Returns a single value in the current double data array for a specified band, row and column position
- Parameters:
band
- The target color band
public Data getHighPass()
Get high pass data of the current 3-dim array. High pass column length is half of total column length.
- Returns:
- High pass data
public Data getHighPass(int noOfRows, int noOfCols)
Get high pass data of the current 3-dim array. High pass dimenions (rows and columns) are specified.
- Parameters:
noOfRows
- High pass number of rows
- Returns:
- High pass data
public Data getLowPass()
Get low pass data of the current 3-dim array. Low pass column length is half of total column length.
- Returns:
- Low pass data
public Data getLowPass(int noOfRows, int noOfCols)
Get low pass data of the current 3-dim array. Low pass dimenions (rows and columns) are specified.
- Parameters:
noOfRows
- Low pass number of rows
- Returns:
- Low pass data
private int getNumBands()
Returns the number of color bands of the current 3-dim array.
public int getNumCols()
Returns the number of columns of the current 3-dim array.
public int getNumRows()
Returns the number of rows of the current 3-dim array.
private boolean isBandArrayCreated()
Checks wether the first array dimension (color bands) is created.
private boolean isColArrayCreated()
Checks wether the third array dimension (columns) is created.
private boolean isRowArrayCreated()
Checks wether the second array dimension (rows) is created.
public void set(double newData, int band, int row, int col)
Replaces one single value in the current double data array
- Parameters:
newData
- The new valueband
- The target color band
public void set(double[] newData, int band, int row)
Replaces the column dimension of the current double data array
- Parameters:
newData
- New 1-dim double data array (columns)band
- The target color band
public void set(double[][] newData, int band)
Replaces the row and column dimension of the current double data array
- Parameters:
newData
- New 2-dim double data array (rows and columns)band
- The target 1st dimension
public void set(double[][][] newData)
Replaces all 3 dimensions of the current double data array
- Parameters:
newData
- New 3-dim double data array
public void swap()
Swap rows and cols of the array (in place)
public Data swap(Data out)
Swap rows and cols of the array (no array modification)
- Parameters:
out
- Swap target Data array
- Returns:
- Swapped data in a new array
private void updateDimensions()
In case of array modifications, update the dimension variables here.