|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--PixelSource
| Field Summary | |
int |
kHeight
This is the height of the video that you requested when you constructed this object |
int |
kWidth
This is the width of the video that you requested when you constructed this object |
int |
vidWidth
This is the actual width of the video which may differ from the width you requested because some extra slop bytes may be added at the end of each line. |
| Constructor Summary | |
PixelSource(int pw,
int ph)
This is the constructor class. |
|
| Method Summary | |
java.lang.String |
changeSource(int whichSource)
|
int[][] |
getBackground()
This returns a two dimensional array describing the background as last grabbed with the grab background commnad. |
int[] |
getBackGroundPixel(int x,
int y)
This returns a 3 element array which contains the values for Red Green and Blue at the specified x,y coordinate within the background. |
int[] |
getBackGroundPixelSlow(int x,
int y)
This returns a 3 element array which contains the values for Red Green and Blue at the specified x,y coordinate within the background. |
int[] |
getMasks()
This is a mask that hilites the red, green, blue or alpha part of the integer packed full of ARGB. |
int[] |
getPackedBackground()
This returns the array for the current background. |
int[] |
getPixel(int[] inArray,
int x,
int y)
This returns a 3 element array which contains the values for Red Green and Blue at the specified x,y coordinate within the array you supply. |
int[] |
getPixel(int x,
int y)
This returns a 3 element array which contains the values for Red Green and Blue at the specified x,y coordinate. |
int[] |
getPixelArray()
This gives you back the pixels in an int array created and sized by pixel source. |
void |
getPixelArray(int[] _newPixels)
This tickles tickles the video and puts the pixels in an int array that you supplied . |
int[] |
getShifts()
This is the amount you would would have to shift a byte packed into an int to give you an accurate value. |
void |
grabBackground()
This refreshes the background. |
void |
grabFrame()
This gives you a fresh frame for getPixel and setPixel to operate on. |
void |
idleIt()
This tickles whatever is suppling the video to give up fresh pixels. |
void |
idleIt(int numberOfTimes)
This tickles whatever is suppling the video, with DV cameras you may have to tickle them many times between every frames to get rid of a lag. |
void |
killSession()
Be sure to call this when you close or destroy your main window so a connection to your camera is not left hanging . |
void |
makeJPEG(java.lang.String pathname,
java.lang.String filename)
This does a quick dump of a jpeg and writes it out to a file at a given pathname in a given filename. |
void |
setPixel(int[] inputArray,
int x,
int y,
int alpha)
This sets the alpha (transparency) at a given x, y position. |
void |
setPixel(int[] inputArray,
int x,
int y,
int red,
int green,
int blue,
int alpha)
This sets the red, green, blue and alpha (transparency) at a given x, y position. |
void |
setPixel(int x,
int y,
int alpha)
This sets the alpha (transparency) at a given x, y position which is often necessary to see anything at all with an ARGB image. |
void |
setPixel(int x,
int y,
int red,
int green,
int blue,
int alpha)
This sets the alpha (transparency) at a given x, y position. |
void |
unpackBackground()
Culls out the r g and b ahead of time so you save on the shifting and masking. |
void |
videoSettings()
This pops up the video setting dialog box. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public int kWidth
public int vidWidth
public int kHeight
| Constructor Detail |
public PixelSource(int pw,
int ph)
| Method Detail |
public int[] getPixel(int x,
int y)
public int[] getPixel(int[] inArray,
int x,
int y)
public int[] getBackGroundPixelSlow(int x,
int y)
public int[] getBackGroundPixel(int x,
int y)
public void setPixel(int x,
int y,
int red,
int green,
int blue,
int alpha)
public void setPixel(int x,
int y,
int alpha)
public void setPixel(int[] inputArray,
int x,
int y,
int alpha)
public void setPixel(int[] inputArray,
int x,
int y,
int red,
int green,
int blue,
int alpha)
public void idleIt()
public void idleIt(int numberOfTimes)
public void getPixelArray(int[] _newPixels)
public int[] getPixelArray()
public void videoSettings()
public int[][] getBackground()
public int[] getPackedBackground()
public void unpackBackground()
public void grabFrame()
public void grabBackground()
public void killSession()
public java.lang.String changeSource(int whichSource)
public int[] getMasks()
public int[] getShifts()
public void makeJPEG(java.lang.String pathname,
java.lang.String filename)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||