|
Bartosz Firyn (SarXos) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.github.sarxos.webcam.ds.buildin.WebcamDefaultDevice
public class WebcamDefaultDevice
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.github.sarxos.webcam.WebcamDevice |
|---|
WebcamDevice.BufferAccess |
| Method Summary | |
|---|---|
void |
close()
Close device, however it can be open again. |
void |
dispose()
Dispose device. |
BufferedImage |
getImage()
Fetch image from underlying camera. |
ByteBuffer |
getImageBytes()
Get image in form of raw bytes. |
String |
getName()
Get device name. |
Dimension |
getResolution()
Get currently set image size. |
Dimension[] |
getResolutions()
Get the list of all possible image resolutions. |
int |
getTimeout()
Get timeout for image acquisition. |
boolean |
isOpen()
Is webcam device open? |
void |
open()
Open device, it can be closed any time. |
void |
setFailOnSizeMismatch(boolean fail)
Determines if device should fail when requested image size is different than actually received. |
void |
setResolution(Dimension size)
Set new expected image size. |
void |
setTimeout(int timeout)
Set timeout for image acquisition. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public String getName()
WebcamDevice
getName in interface WebcamDevicepublic Dimension[] getResolutions()
WebcamDevice
getResolutions in interface WebcamDevicepublic Dimension getResolution()
WebcamDevice
getResolution in interface WebcamDevicepublic void setResolution(Dimension size)
WebcamDevice
setResolution in interface WebcamDevicesize - the size to be setpublic ByteBuffer getImageBytes()
WebcamDevice.BufferAccess
getImageBytes in interface WebcamDevice.BufferAccesspublic BufferedImage getImage()
WebcamDevice
getImage in interface WebcamDevicepublic void open()
WebcamDevice
open in interface WebcamDevicepublic void close()
WebcamDevice
close in interface WebcamDevicepublic void dispose()
WebcamDevice
dispose in interface WebcamDevicepublic void setFailOnSizeMismatch(boolean fail)
fail - the fail on size mismatch flag, true or falsepublic boolean isOpen()
WebcamDevice
isOpen in interface WebcamDevicepublic int getTimeout()
public void setTimeout(int timeout)
timeout - the timeout value in milliseconds
|
Bartosz Firyn (SarXos) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||