|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.humatic.dsj.CaptureDeviceControls
public class CaptureDeviceControls
CaptureDeviceControls can be used for programatical control of capture device parameters (brightness, contrast, hue etc.; zoom, pan & tilt for
cameras that support it).
This class is in first hand a wrapper around the IAMVideoProcAmp and IAMCameraControl (resp IAMAudioInputMixer for audio devices)
interfaces. There is no guarantee that a device driver
will expose the required interface! Also these interface are a bit aged by now and date back to times before class compliant
drivers etc. Updates to the OSs architecture (namely the 1.1 version of the UVC driver) have defined additional properties that
device minidrivers may expose. Those are not covered by the original interfaces and are handled by some fairly abstract architecture
around "kernel streaming property sets" in Windows. dsj 0_8_62 adds generic get & set methods for properties on the KSPropertySets in
question here.
Also new in dsj 0_8_62 is support for some properties specific to the Logitech UVC driver, version 12 and above. These are proprietary
but have been added nevertheless, because Logitech devices are widely in use and Logitech offers a fairly open api for their devices.
Furthermore the IAMVideoControl interface is now also partly accessible through this class (see getVideoControlCaps(..) for details).
To construct a CaptureDeviceControls object, call getControls() on the capture device or the StreamBufferCaptureSource.
| Field Summary | |
|---|---|
static int |
BACKLIGHTCOMPENSATION
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
BALANCE
Audio capture device controls |
static int |
BASS
Audio capture device controls |
static int |
BRIGHTNESS
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
CAMCONTROL_ABSOLUTE
|
static int |
CAMCONTROL_AUTO
|
static int |
CAMCONTROL_MANUAL
|
static int |
CAMCONTROL_RELATIVE
|
static int |
COLORENABLE
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
CONTRAST
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
DIGITAL
|
static int |
EXPOSURE
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
FOCUS
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
GAIN
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
GAMMA
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
HUE
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
INPUT_LEVEL
Audio capture device controls |
static int |
INPUT_SELECT
Audio capture device controls |
static int |
IRIS
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
KS_CAMCTRL
PropertySet IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_AUTO_EXPOSURE_PRIORITY
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_EXPOSURE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_EXPOSURE_RELATIVE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_FOCAL_LENGTH
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_FOCUS
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_FOCUS_RELATIVE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_IRIS
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_IRIS_RELATIVE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_PAN
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_PAN_RELATIVE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_PANTILT
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_PANTILT_RELATIVE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_PRIVACY
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_ROLL
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_ROLL_RELATIVE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_SCANMODE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_TILT
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_TILT_RELATIVE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_ZOOM
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_CAMCTRL_ZOOM_RELATIVE
CameraControl property IDs (for use with get / setKSProperty) |
static int |
KS_LP1_DIGITAL_PAN
Logitech public property IDs (for use with get / setKSProperty) |
static int |
KS_LP1_DIGITAL_PANTILTZOOM
Logitech public property IDs (for use with get / setKSProperty) |
static int |
KS_LP1_DIGITAL_TILT
Logitech public property IDs (for use with get / setKSProperty) |
static int |
KS_LP1_DIGITAL_ZOOM
Logitech public property IDs (for use with get / setKSProperty) |
static int |
KS_LP1_EXPOSURE_TIME
Logitech public property IDs (for use with get / setKSProperty) |
static int |
KS_LP1_FACE_TRACKING
Logitech public property IDs (for use with get / setKSProperty) |
static int |
KS_LP1_FINDFACE
Logitech public property IDs (for use with get / setKSProperty) |
static int |
KS_LP1_LED
Logitech public property IDs (for use with get / setKSProperty) |
static int |
KS_LT_UVC_PUBLIC
PropertySet IDs (for use with get / setKSProperty) |
static int |
KS_VIDCTRL
PropertySet IDs (for use with get / setKSProperty) |
static int |
KS_VIDCTRL_CAPS
|
static int |
KS_VIDCTRL_MODE
|
static int |
KS_VPROC
PropertySet IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_BACKLIGHT_COMPENSATION
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_BRIGHTNESS
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_COLORENABLE
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_CONTRAST
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_DIGITAL_MULTIPLIER
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_DIGITAL_MULTIPLIER_LIMIT
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_GAIN
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_GAMMA
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_HUE
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_POWERLINE_FREQUENCY
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_SATURATION
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_SHARPNESS
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_WHITEBALANCE
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
KS_VPROC_WHITEBALANCE_COMPONENT
VideoProcAmp property IDs (for use with get / setKSProperty) |
static int |
LT_DIGITAL_PAN
Logitech UVC driver version 12 and above controls |
static int |
LT_DIGITAL_PANTILTZOOM
Logitech UVC driver version 12 and above controls |
static int |
LT_DIGITAL_TILT
Logitech UVC driver version 12 and above controls |
static int |
LT_DIGITAL_ZOOM
Logitech UVC driver version 12 and above controls |
static int |
LT_EXPOSURE_TIME
Logitech UVC driver version 12 and above controls |
static int |
LT_FACE_TRACKING
Logitech UVC driver version 12 and above controls |
static int |
LT_FINDFACE
Logitech UVC driver version 12 and above controls |
static int |
LT_LED
Logitech UVC driver version 12 and above controls |
static int |
MASTER_PAN
Audio capture device controls |
static int |
MASTER_VOL
Audio capture device controls |
static int |
MECHANICAL
|
static int |
PAN
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
ROLL
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
SATURATION
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
SHARPNESS
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
TILT
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
TREBLE
Audio capture device controls |
static int |
VC_FLIP_HOR
IAMVideoControl fields |
static int |
VC_FLIP_VER
IAMVideoControl fields |
static int |
VC_TRIGGER
IAMVideoControl fields |
static int |
VC_TRIGGER_ENABLE
IAMVideoControl fields |
static int |
VIDCTRL_FLIP
IAMVideoControl image flipping (dummy value for controller creation). |
static int |
WHITEBALANCE
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
static int |
ZOOM
Video capture device controls (IAMVideoProcAmp and IAMCameraControl) |
| Constructor Summary | |
|---|---|
CaptureDeviceControls(int t,
long device,
int[] r,
java.util.Vector ins)
This constructor is public for package design reasons. |
|
| Method Summary | |
|---|---|
java.lang.String[] |
getAudioInputNames()
Returns the names of available audio inputs if the CaptureDeviceControls object refers to an audio capture device that supports input selection, null otherwise. |
boolean |
getAuto(int p)
Returns true if the given property is controlled automatically. %p - one of the defined (non KS_ ) constants under audio / video or Logitech capture device controls. |
javax.swing.JComponent |
getController(int p,
int orientation,
boolean titled)
Returns a readily set up JSlider or JCheckBox to control the given property or null if the property can not be controlled. |
int |
getCurrentValue(int p)
Returns the current setting for the given property. %p - one of the defined (non KS_ ) constants under audio / video or Logitech capture device controls. |
int[] |
getKSProperty(int propSetID,
int propID,
int arg)
Generic get method for properties on UVC minidrivers. |
int |
getPanTiltMode()
Deprecated. method |
int[] |
getParameterRange(int p)
Returns the minimal, maximal, minimal delta, default & autoflag values for the given property in an int[]. %p - one of the defined (non KS_ ) constants under audio / video or Logitech capture device controls. |
int |
getVideoControlCaps(int streamIdx)
The IAMVideoControl interface is exposed by some UVC video capture devices and may provide support for device internal image flipping and triggering stream delivery by physical or software means. This method returns a combination of VC_... |
int |
getVideoControlMode(int streamIdx)
Returns a combination of VC_... |
static int[] |
getVProcControls(long pointer)
|
void |
resetDefaults(int p)
Reset the given parameter to the drivers default value. |
boolean |
selectAudioInput(int index)
|
void |
setAuto(int p,
boolean auto)
Attempts to set the given parameter to auto control (which may not be supported). %p - one of the defined (non KS_ ) constants under audio / video or Logitech capture device controls. |
void |
setKSProperty(int propSetID,
int propID,
int[] valuesAndFlags)
Generic set method for properties on UVC minidrivers. |
void |
setPanTiltMode(int mode)
Deprecated. method. This method was used to switch between mechanical and digital PTZ modes on older versions of Logitech's UVC driver. Effectively what it did was switching between absolute and relative mode (which the driver used to toggle mechanical / digital PTZ). Newer drivers implenent an additional PropertySet for digital PTZ and new parameter definitions have been added for those. Switching between absolute and relative mode can now be done using the flags parameter in setParameterValue. |
void |
setParameterValue(int parameter,
int value)
Deprecated. method, use setParameterValue(int parameter, int value, int flags) instead |
void |
setParameterValue(int parameter,
int value,
int flags)
Sets the given property to the given value, which should be in the acceptable range for that parameter (see getParameterRange()). %p - one of the defined (non KS_ ) constants under audio / video or Logitech capture device controls. %value - value lying within the reported range for the parameter %flags - can be used to set execution mode to relative (only very few parameters on some devices support this). |
void |
setVideoControlMode(int streamIdx,
int mode)
Sets the operation mode for the IAMVideoControl interface on the outputpin with the given index. %mode - combination of VC_... |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int CAMCONTROL_ABSOLUTE
public static final int CAMCONTROL_AUTO
public static final int CAMCONTROL_MANUAL
public static final int CAMCONTROL_RELATIVE
public static final int BRIGHTNESS
public static final int CONTRAST
public static final int HUE
public static final int SATURATION
public static final int SHARPNESS
public static final int GAMMA
public static final int COLORENABLE
public static final int WHITEBALANCE
public static final int BACKLIGHTCOMPENSATION
public static final int GAIN
public static final int PAN
public static final int TILT
public static final int ROLL
public static final int ZOOM
public static final int EXPOSURE
public static final int IRIS
public static final int FOCUS
public static final int LT_DIGITAL_PAN
public static final int LT_DIGITAL_TILT
public static final int LT_DIGITAL_ZOOM
public static final int LT_EXPOSURE_TIME
public static final int LT_FACE_TRACKING
public static final int LT_LED
public static final int LT_FINDFACE
public static final int LT_DIGITAL_PANTILTZOOM
public static final int VC_FLIP_HOR
public static final int VC_FLIP_VER
public static final int VC_TRIGGER_ENABLE
public static final int VC_TRIGGER
public static final int MASTER_VOL
public static final int MASTER_PAN
public static final int INPUT_SELECT
public static final int INPUT_LEVEL
public static final int BALANCE
public static final int BASS
public static final int TREBLE
public static final int VIDCTRL_FLIP
public static final int DIGITAL
public static final int MECHANICAL
public static final int KS_VPROC
public static final int KS_CAMCTRL
public static final int KS_VIDCTRL
public static final int KS_LT_UVC_PUBLIC
public static final int KS_VPROC_BRIGHTNESS
public static final int KS_VPROC_CONTRAST
public static final int KS_VPROC_HUE
public static final int KS_VPROC_SATURATION
public static final int KS_VPROC_SHARPNESS
public static final int KS_VPROC_GAMMA
public static final int KS_VPROC_COLORENABLE
public static final int KS_VPROC_WHITEBALANCE
public static final int KS_VPROC_BACKLIGHT_COMPENSATION
public static final int KS_VPROC_GAIN
public static final int KS_VPROC_DIGITAL_MULTIPLIER
public static final int KS_VPROC_DIGITAL_MULTIPLIER_LIMIT
public static final int KS_VPROC_WHITEBALANCE_COMPONENT
public static final int KS_VPROC_POWERLINE_FREQUENCY
public static final int KS_CAMCTRL_PAN
public static final int KS_CAMCTRL_TILT
public static final int KS_CAMCTRL_ROLL
public static final int KS_CAMCTRL_ZOOM
public static final int KS_CAMCTRL_EXPOSURE
public static final int KS_CAMCTRL_IRIS
public static final int KS_CAMCTRL_FOCUS
public static final int KS_CAMCTRL_SCANMODE
public static final int KS_CAMCTRL_PRIVACY
public static final int KS_CAMCTRL_PANTILT
public static final int KS_CAMCTRL_PAN_RELATIVE
public static final int KS_CAMCTRL_TILT_RELATIVE
public static final int KS_CAMCTRL_ROLL_RELATIVE
public static final int KS_CAMCTRL_ZOOM_RELATIVE
public static final int KS_CAMCTRL_EXPOSURE_RELATIVE
public static final int KS_CAMCTRL_IRIS_RELATIVE
public static final int KS_CAMCTRL_FOCUS_RELATIVE
public static final int KS_CAMCTRL_PANTILT_RELATIVE
public static final int KS_CAMCTRL_FOCAL_LENGTH
public static final int KS_CAMCTRL_AUTO_EXPOSURE_PRIORITY
public static final int KS_LP1_DIGITAL_PAN
public static final int KS_LP1_DIGITAL_TILT
public static final int KS_LP1_DIGITAL_ZOOM
public static final int KS_LP1_DIGITAL_PANTILTZOOM
public static final int KS_LP1_EXPOSURE_TIME
public static final int KS_LP1_FACE_TRACKING
public static final int KS_LP1_LED
public static final int KS_LP1_FINDFACE
public static final int KS_VIDCTRL_CAPS
public static final int KS_VIDCTRL_MODE
| Constructor Detail |
|---|
public CaptureDeviceControls(int t,
long device,
int[] r,
java.util.Vector ins)
| Method Detail |
|---|
public int[] getParameterRange(int p)
public int getCurrentValue(int p)
throws DSJException
DSJExceptionpublic boolean getAuto(int p)
public void setAuto(int p,
boolean auto)
throws DSJException
DSJException
public void setParameterValue(int parameter,
int value)
throws DSJException
DSJException
public void setParameterValue(int parameter,
int value,
int flags)
throws DSJException
DSJExceptionpublic void resetDefaults(int p)
public int[] getKSProperty(int propSetID,
int propID,
int arg)
throws DSJException
DSJException
public void setKSProperty(int propSetID,
int propID,
int[] valuesAndFlags)
throws DSJException
DSJExceptionpublic void setPanTiltMode(int mode)
public int getPanTiltMode()
public boolean selectAudioInput(int index)
public javax.swing.JComponent getController(int p,
int orientation,
boolean titled)
public int getVideoControlCaps(int streamIdx)
throws DSJException
DSJException
public int getVideoControlMode(int streamIdx)
throws DSJException
DSJException
public void setVideoControlMode(int streamIdx,
int mode)
throws DSJException
DSJExceptionpublic java.lang.String[] getAudioInputNames()
public static int[] getVProcControls(long pointer)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||