|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--jm.jigl.DiscreteSignal
A discrete signal is a 1-d of shorts DiscreteSignal implements Signal
jigl.math.DiscreteSignal
Field Summary | |
protected short[] |
data
One dimensional integer array |
protected int |
length
Length of the Signal |
Constructor Summary | |
DiscreteSignal()
Creates an empty one dimensional DiscreteSignal with a height and width of zero |
|
DiscreteSignal(DiscreteSignal s)
Creates a one dimensional DiscreteSignal (shallow copy) for a DiscreteSignal |
|
DiscreteSignal(int x)
Creates an empty one dimensional of length x |
Method Summary | |
DiscreteSignal |
add(DiscreteSignal s)
Adds another DiscreteSignal to this signal |
DiscreteSignal |
add(DiscreteSignal s,
ROI sourceSignal,
ROI destSignal)
Divides this signal's Region of Interest by a Region of Interest of another DiscreteSignal |
DiscreteSignal |
add(int v)
Adds a value to all the samples in this signal |
void |
add(int x,
int value)
Adds a value to a single sample |
void |
add(int x,
int value,
ROI r)
Adds a value to a single sample |
DiscreteSignal |
add(int v,
ROI r)
Adds a value to all the samples in in a Region of Interest |
DiscreteSignal |
addbuffer(int w,
int color)
Makes a copy of this image with a buffer so the resulting image has a width x and height y |
void |
byteSize()
Scales the range of this signal to byte (0..255) |
void |
byteSize(ROI r)
Scales the range of a Region of Interest to byte (0..255) |
DiscreteSignal |
clear()
Clears the signal to zero |
DiscreteSignal |
clear(int val)
Clears to constant value |
DiscreteSignal |
clear(int val,
ROI r)
Clears to constant value |
DiscreteSignal |
clear(ROI r)
Clears the signal to zero |
void |
clip(int min,
int max)
Clips the range of this signal to an arbitrary min/max |
void |
clip(int min,
int max,
ROI r)
Clips the range of in a Region of Interest to an arbitrary min/max |
void |
convolve(DiscreteSignal kernel)
Performs convolution in place with a kernel signal on this signal. |
void |
convolve(DiscreteSignal kernel,
ROI r)
Performs convolution in place with a kernel signal on a Region of Interest. |
Signal |
copy()
Makes a deep copy of this signal |
Signal |
copy(ROI r)
Makes a deep copy in a Region of Interest |
short[] |
data()
Makes a shallow copy of a JIGL signal's sample buffer |
DiscreteSignal |
diff(DiscreteSignal s)
Subtracts the second signal from the first and returns the absolute value |
DiscreteSignal |
divide(DiscreteSignal s)
Divides this signal by a DiscreteSignal |
DiscreteSignal |
divide(DiscreteSignal s,
ROI sourceSignal,
ROI destSignal)
Multiplies a Region of Interest of another DiscreteSignal to a Region of Interest of this signal |
DiscreteSignal |
divide(int v)
Divides all the samples in this signal by a value |
void |
divide(int x,
int value)
Divides a single sample by a value |
void |
divide(int x,
int value,
ROI r)
Divides a single sample by a value |
DiscreteSignal |
divide(int v,
ROI r)
Divides all the samples in in a Region of Interest by a value |
int |
get(int x)
Returns the sample value at the given x, y value |
int |
get(int x,
ROI r)
Returns the sample value at the given x, y value |
int |
length()
Returns the length of this signal |
int |
max()
Finds the maximum value of this signal |
int |
max(ROI r)
Finds the maximum value of in a Region of Interest |
void |
median(int size)
Performs median filter on this signal |
void |
median(int size,
ROI r)
Performs median filter on a Region of Interest |
int |
min()
Finds the minimum value of this signal |
int |
min(ROI r)
Finds the minimum value of in a Region of Interest |
DiscreteSignal |
multiply(DiscreteSignal s)
Multiplies a DiscreteSignal by this signal |
DiscreteSignal |
multiply(DiscreteSignal s,
ROI sourceSignal,
ROI destSignal)
Subtracts a Region of Interest from another DiscreteSignal from a Region of Interest of this signal |
DiscreteSignal |
multiply(int v)
Multiplies all the samples in this signal by a value |
void |
multiply(int x,
int value)
Mutiplies a single sample by a value |
void |
multiply(int x,
int value,
ROI r)
Mutiplies a single sample by a value |
DiscreteSignal |
multiply(int v,
ROI r)
Multiplies all the samples in in a Region of Interest by a value |
void |
set(int x,
int value)
Sets the sample value at x, y to a given value |
void |
set(int x,
int value,
ROI r)
Sets the sample value at x, y to a given value |
DiscreteSignal |
subtract(DiscreteSignal s)
Subtracts a DiscreteSignal from this signal |
DiscreteSignal |
subtract(DiscreteSignal s,
ROI sourceSignal,
ROI destSignal)
Adds a Region of Interest of another DiscreteSignal to a Region of Interest of this signal |
DiscreteSignal |
subtract(int v)
Subtracts a value from all the samples in this signal |
void |
subtract(int x,
int value)
Subtracts a value from a single sample |
void |
subtract(int x,
int value,
ROI r)
Subtracts a value from a single sample |
DiscreteSignal |
subtract(int v,
ROI r)
Subtracts a value from all the samples in in a Region of Interest |
java.lang.String |
toString()
Prints the string in integer format. |
java.lang.String |
toString(ROI r)
Prints the string in integer format. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected short[] data
protected int length
Constructor Detail |
public DiscreteSignal()
public DiscreteSignal(int x)
public DiscreteSignal(DiscreteSignal s)
Method Detail |
public Signal copy()
copy
in interface Signal
public final int length()
length
in interface Signal
public final short[] data()
public final int get(int x)
x
- the X coordinantpublic final void set(int x, int value)
x
- the X coordinantvalue
- the value to set the sample topublic final DiscreteSignal clear()
public final DiscreteSignal clear(int val)
val
- the value to "clear" the signal topublic final void add(int x, int value)
x
- X-coordinantvalue
- the value to add to the samplepublic final void subtract(int x, int value)
x
- X-coordinantvalue
- the value to subtract from the samplepublic final void multiply(int x, int value)
x
- X-coordinantvalue
- - the value to mutiply to the samplepublic final void divide(int x, int value)
x
- X-coordinantvalue
- - the value to mutiply to the samplepublic final int min()
public final int max()
public final DiscreteSignal add(int v)
v
- value to be added to the samples
public final DiscreteSignal subtract(int v)
v
- value to be added to the samples
public final DiscreteSignal multiply(int v)
v
- value to be added to the samples
public final DiscreteSignal divide(int v)
v
- value to be added to the samples
public final DiscreteSignal add(DiscreteSignal s)
public DiscreteSignal addbuffer(int w, int color)
public final DiscreteSignal subtract(DiscreteSignal s)
public final DiscreteSignal diff(DiscreteSignal s)
public final DiscreteSignal multiply(DiscreteSignal s)
public final DiscreteSignal divide(DiscreteSignal s)
public java.lang.String toString()
toString
in interface Signal
toString
in class java.lang.Object
public void byteSize()
public final void clip(int min, int max)
min
- minimum valuemax
- maximum valuepublic void convolve(DiscreteSignal kernel)
kernel
- kernel to perform the convolution withpublic void median(int size)
size
- the size of the median filterpublic Signal copy(ROI r)
r
- Region of Interest
public final int get(int x, ROI r)
x
- the X coordinantpublic final void set(int x, int value, ROI r)
x
- the X coordinantvalue
- the value to set the sample topublic final DiscreteSignal clear(ROI r)
r
- Region of Interestpublic final DiscreteSignal clear(int val, ROI r)
val
- the value to "clear" the signal tor
- Region of Interestpublic final void add(int x, int value, ROI r)
x
- X-coordinantvalue
- the value to add to the sampler
- Region of Interestpublic final void subtract(int x, int value, ROI r)
x
- X-coordinantvalue
- the value to subtract from the sampler
- Region of Interestpublic final void multiply(int x, int value, ROI r)
x
- X-coordinantvalue
- - the value to mutiply to the sampler
- Region of Interestpublic final void divide(int x, int value, ROI r)
x
- X-coordinantvalue
- - the value to mutiply to the sampler
- Region of Interestpublic final int min(ROI r)
r
- Region of Interest
public final int max(ROI r)
r
- Region of Interest
public final DiscreteSignal add(int v, ROI r)
v
- value to be added to the samplesr
- Region of Interest
public final DiscreteSignal subtract(int v, ROI r)
v
- value to be added to the samplesr
- Region of Interest
public final DiscreteSignal multiply(int v, ROI r)
v
- value to be added to the samplesr
- Region of Interest
public final DiscreteSignal divide(int v, ROI r)
v
- value to be added to the samplesr
- Region of Interest
public final DiscreteSignal subtract(DiscreteSignal s, ROI sourceSignal, ROI destSignal)
s
- the DiscreteSignal to addsourceSignal
- Region of Interest for Source SignaldestSignal
- Region of Interest for Destination Signal
public final DiscreteSignal multiply(DiscreteSignal s, ROI sourceSignal, ROI destSignal)
s
- the DiscreteSignal to subtractsourceSignal
- Region of Interest for Source SignaldestSignal
- Region of Interest for Destination Signal
public final DiscreteSignal divide(DiscreteSignal s, ROI sourceSignal, ROI destSignal)
s
- the DiscreteSignal to multiplysourceSignal
- Region of Interest for Source SignaldestSignal
- Region of Interest for Destination Signal
public final DiscreteSignal add(DiscreteSignal s, ROI sourceSignal, ROI destSignal)
s
- the DiscreteSignal to dividesourceSignal
- Region of Interest for Source SignaldestSignal
- Region of Interest for Destination Signal
public java.lang.String toString(ROI r)
public void byteSize(ROI r)
r
- Region of Interestpublic final void clip(int min, int max, ROI r)
min
- minimum valuemax
- maximum valuer
- Region of Interestpublic void convolve(DiscreteSignal kernel, ROI r)
kernel
- kernel to perform the convolution withr
- Region of Interestpublic void median(int size, ROI r)
size
- the size of the median filterr
- Region of Interest
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |