Video Capture Device Commands

These commands are used to create and configure the capture device for use with __prod_name.

-CameraPan <Tracker Name> <Direction> <Offset>
Pans the camera a specified number of degrees in the specified direction from the current location. The direction is relative to the camera inversion setting (e.g. if the camera is set to inverted, panning right would pan left from the perspective of a non-inverted camera).

Example :-CameraPan VT1 Right 270
Default: N/A
Usage: This command can only be used after the specified camera is connected to the DAS.
Arguments
Tracker Name The name of the video tracker to modify.
Direction The direction to pan the camera. This parameter must be one of the following values:
  1. Right: Pans the camera right.
  2. Left: Pans the camera left.
Offset Value in degrees relative to the current location to move in the specified direction. All values will be constrained between 0 and 359 (e.g. a value of 600 would be set to 359).
-CameraTilt <Tracker Name> <Direction> <Offset>
Tilts the camera a specified number of degrees in the specified direction from its current position. The direction is relative to the camera inversion setting (e.g. if the camera is set to inverted, panning up would pan down from the perspective of a non-inverted camera).

Example :-CameraTilt VT1 Up 50
Default: N/A
Usage: This command can only be used after the specified camera is connected to the DAS.
Arguments
Tracker Name The name of the video tracker to modify.
Direction The direction to tilt the camera. This parameter must be one of the following values:
  1. Up: Tilts the camera up.
  2. Down: Tilts the camera down.
Offset Value in degrees relative to the current location to move in the specified direction. All values will be constrained between 0 and 90 (e.g. a value of 600 would be set to 90).
-CameraZoom <Tracker Name> <Direction> <Offset>
Zooms the camera a specified number of percentage points in the specified direction from its current position.

Example :-CameraZoom VT1 In 75
Default: N/A
Usage: This command can only be used after the specified camera is connected to the DAS.
Arguments
Tracker Name The name of the video tracker to modify.
Direction The direction to zoom the camera. This parameter must be one of the following values:
  1. In: Zooms the camera into a more narrow field of view (i.e. makes small objects appear larger).
  2. Out: Zooms the camera out to a wider field of view (i.e. makes large objects appear smaller).
Offset The number of percentage points to move in the specified direction relative to the current zoom location. This value is not a percent of the current value, but a number of points on a range where 0 is at the widest field of view and 100 is at the narrowest field of view supported by the camera (e.g. if the camera is at zoom value 50% and you zoom in 10%, the value after the zoom would be 60%). Values will be constrained between 0 and 100 (e.g. a value of 600 would be set to 100).
-CreateVideoTracker <Name> <Capture Device Name or Hardware IDConnection Info>
Creates a new instance of a video tracker in Cheetah. Video trackers can be used to detect position, direction or just provide an image letting you see what is going on in an experiment. Connects to a networked video camera. This will provide a live video feed correlated with other recorded data.

Example :-CreateVideoTracker VT1 "Hauppague WinTV PVR Capture" :-CreateVideoTracker VT1 "10.1.1.44/axis-media/media.amp?streamprofile=PegasusPreview?recordprofile=PegasusRecord?user=root?pass=pegasus?cameradelay=0"
Default: __prod_name does not create any video trackers unless this command is specified.
Usage: This command can be used only when __prod_name is idle.
Arguments
Name The name of the you wish to use to identify this video device.This name must be unique throughout the system and cannot be changed after creation.
Capture Device Name or Hardware IDConnection Info This argument can be either the capture device name or the hardware ID for the capture device you want to use. The capture device name is the DirectShow friendly name of the capture device you wish to use for this video tracker. If the same friendly name is used for more than one capture device on your PC, Cheetah will select the first unused device matching the capture device name specified. Alternatively, you can specify the hardware ID of the capture device you wish to use. This will bind your video tracker to a specific capture card.You may only use each capture device on your computer with a single video tracker. Attempting to create a video tracker with a device that is attached to a different video tracker will fail. If you do not specify a capture device name or hardware ID, and only on device can be associated with the VT, Cheetah will automatically select that device. If you have multiple unassigned devices, Cheetah will prompt you to select a capture device from a list during startup. This list displays both the friendly name and hardware ID that you can put in your startup file for future use. The media playback URL for the camera to associate with this video source followed by connection parameters. The media URL and all parameters are case sensitive and must be in the format: <ip_address>/axis-media/media.amp?<parameter>=<value> The IP address must be on the same subnet as the computer running the DAS. The connection parameters are appended to the media url. If parameters are duplicated in the connection info, then the value of the first parameter in the string will be used. ex: ?user=root?user=blah, then user will be root. The following connection parameters can be used, other parameters will be ignored.
streamprofileThe name of the cameras video profile set in the camera setup software used for the MJPEG preview stream. Required for viewing the video stream. If this command is omitted, specifies an unknown video profile or uses an incompatible image format, the creation will fail.
recordprofileThe name of the cameras video profile to use when recording H264 video. If audio is desired, this profile must also have G.711 -Law audio at 8KHz and 64Kbps enabled. This parameter is required for both live video recording and audio input monitoring. If this command is omitted, specifies an unknown video profile or uses an incompatible image format, the creation will fail.
user The user name to use when logging into the camera. The user name must be identical for both the ONVIF and video streaming logins. This must be specified the first time that the DAS connects to a new IP address. If the initial connection is successful, as long as the username and password are not changed, this parameter can be omitted from future connections from this installation of the DAS.
passThe password to use when logging into the camera. The password must be identical for both the ONVIF and video streaming logins. If the initial connection is successful, as long as the username and password are not changed, this parameter can be omitted from future connections from this installation of the DAS.
cameradelayA time in microseconds to subtract from each video timestamp. This can be used to compensate for long network latency to better align the video with other recored data during analysis. This value can only be set when connecting and cannot be changed after connection. This is an optional argument and it's value defaults to 0.


-GetCameraAudioInputVolume <Tracker Name>
Gets the volume of the audio input independently of the speaker output volume.

Example :-GetCameraAudioInputVolume VT1
Default: N/A
Usage: This command should only be used from a NetCom client application after a connection to a server has been established. This command can be issued only after the specified camera is connected to the DAS.
Arguments
Tracker Name The name of the video device we want to retrieve information from.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0. Otherwise, the value will be equal to -1.
Volume This is on a scale from 0 to 100 with 100 being maximum amplification and 0 being muted.
-GetCameraAudioMonitorMute <Tracker Name>
Gets the current mute state of the audio monitor. This value is independent of the PC speaker mute (i.e. if the PC speakers are muted, but the audio monitor isn't, no audio will be heard even though the monitor is not muted).

Example :-GetCameraAudioMonitorMute VT1
Default: N/A
Usage: This command should only be used from a NetCom client application after a connection to a server has been established. This command can be issued only after the specified camera is connected to the DAS.
Arguments
Tracker Name The name of the video device we want to retrieve information from.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0. Otherwise, the value will be equal to -1.
Mute This value can be either the string “On” or “Off”
-GetCameraPosition <Tracker Name>
Gets the current position of the camera. NOTE: This position may be different than the position set via a call to -SetCameraPosition. This is due to the fact that the motor that controls the camera may have to rotate pan or tilt to different locations to get the lens pointed to the absolute position specified.

Example :-GetCameraPosition VT1
Default: N/A
Usage: This command should only be used from a NetCom client application after a connection to a server has been established. This command can be issued only after the specified camera is connected to the DAS.
Arguments
Tracker Name The name of the video device we want to retrieve information from.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0. Otherwise, the value will be equal to -1.
Pan Degrees The pan location in degrees of the camera. This value will be constrained between -1 and 359. This position is relative to the 0 location defined by the camera hardware. A value of -1 indicates that the camera did not report a location.
Tilt Degrees The tilt location in degrees of the camera. This value will be constrained between -1 and 90. This position is relative to the 0 location defined by the camera hardware. A value of -1 indicates that the camera did not report a location.
Zoom Percent The zoom location in percent of the camera. This value will be constrained between -1 and 100. This position is relative to the 0 location defined by the camera hardware. A value of -1 indicates that the camera did not report a location.
Motion State This argument is only returned if the camera is in motion and will have a value of “MOVING”. If the camera is not in motion, this argument is not returned.
-GetImageRotation <Tracker Name>
Returns the current rotation value of the video image.

Example :-GetImageRotation VT1
Default: N/A
Usage: This command should only be used from a NetCom client application after a connection to a server has been established.
Arguments
Tracker Name The name of the video device we want to retrieve information from.
NetCom Reply
Error Code
If the command is successful, this value will be equal to 0. Otherwise, the value will be equal to -1.
Value Value in degrees that the incoming video image is rotated.
-SetAnalogVideoFormat <Tracker Name> <Format>
Sets the analog video format to use for the specified video tracker. This command is used for analog video sources only.

Example :-SetAnalogVideoFormat VT1 NTSC
Default: __prod_name creates video trackers using the NTSC analog video format.
Usage: This command can be used only when __prod_name is idle.
Arguments
Tracker Name The name of the video tracker whose analog video format you wish to change.
Format Specifies the analog video format you wish to use for this video tracker. __prod_name supports the following format types:
  1. NTSC : Uses NTS_M video formatting with 33ms frame intervals (30FPS). Used throughout North and South America, Japan, and Oceania
  2. PAL : Uses PAL_B video formatting with 40ms frame intervals (25FPS). Used throughout the rest of the world. Except in along the Mediterranean, where SECAM is used.
Your capture device must also support the specified video format. If your hardware does not support the specified format, the command will fail.

-SetBrightness <Tracker Name> <Value>
Sets the brightness level for the specified video tracker. Brightness adjustment will increase the values of the RGB signals in the color evenly, shifting the image towards white (high values) or black(low values). After setting the value, the setting will persist even after __prod_name is exited. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

Example :-SetBrightness VT1 128
Default: __prod_name will use the value currently set on the capture device.
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the video that you wish to adjust.
Value This is a whole number between 0 and 255. Values below 0 will be adjusted to 0, and values above 255 will be adjusted to 255.This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

-SetCameraAudioInputVolume <Tracker Name> <Volume>
Sets the volume of the audio input independently of the speaker output volume. This affects the volume level of all audio data saved to the live video file for this camera.

Example :-SetCameraAudioInputVolume VT1 30
Default: 0.
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the capture device that you wish to adjust.
Volume This is on a scale from 0 to 100 with 100 being maximum amplification and 0 being muted.
-SetCameraAudioMonitorMute <Tracker Name> <Mute>
Mutes or un-mutes the audio being played out of the PC speakers. This command only affects the PC speaker output for the audio stream being received from the specified camera. It does not affect the volume of the audio being written to a live video file nor the audio output for any acquisition entities.

Example :-SetCameraAudioMonitorMute VT1 On
Default: Off
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the capture device that you wish to adjust.
Mute This value can be one of the following:
  1. On - Only the audio coming from the specified camera will be muted.
  2. Off - The audio coming from the camera will return to the volume it was prior to being muted.
-SetCameraPosition <Tracker Name> <Pan Degrees> <Tilt Degrees> <Zoom Percent>
Sets the absolute position to move the camera.If the camera is not yet connected to the DAS, the most recent call to this command will determine the initial position to place the camera after connecting. If this command is not specified before connection, the camera will move to location 0,0,0.

Example :-SetCameraPosition VT1 30 50 62
Default: 0,0,0.
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the video that you wish to adjust.
Pan Degrees The location in degrees to pan the camera. This value will be constrained between 0 and 359 (e.g. a value of 600 would be set to 359). This position is relative to the 0 location defined by the camera hardware.
Tilt Degrees The location in degrees to tilt the camera. This value will be constrained between 0 and 90 (e.g. a value of -60 would be set to 0). This position is relative to the 0 location defined by the camera hardware.
Zoom Percent The percent between wide and telephoto to place the camera’s zoom. Values will be constrained between 0 and 100 (e.g. a value of 600 would be set to 100). This position is relative to the widest possible field of view supported by the camera hardware.

-SetContrast <Tracker Name> <Value>
Sets the contrast level for the specified video tracker. Contrast adjustment will intensify the boundaries between different luminance values. Increasing the contrast will make those boundaries more distinct, while decreasing contrast will tend to give the image a more muted look. After setting the value, the setting will persist even after __prod_name is exited. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

Example :-SetContrast VT1 128
Default: __prod_name will use the value currently set on the capture device.
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the video that you wish to adjust.
Value This is a whole number between 0 and 255. Values below 0 will be adjusted to 0, and values above 255 will be adjusted to 255. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

-SetGamma <Tracker Name> <Value>
Sets the gamma level for the specified video tracker. Gamma adjustment is an attempt to linearize the power-law relationship between the encoded luminance and actual desired brightness. If the actual source luminance is L, gamma will adjust the luminance encoded by the capture card to L^(1/gamma). After setting the value, the setting will persist even after __prod_name is exited. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

Example :-SetGamma VT1 128
Default: __prod_name will use the value currently set on the capture device.
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the video that you wish to adjust.
Value This is a whole number between 0 and 255. Values below 0 will be adjusted to 0, and values above 255 will be adjusted to 255. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

-SetHue <Tracker Name> <Value>
Sets the hue level for the specified video tracker. Hue control will adjust all the colors in the signal according to the following formula . Where σ is saturation, μ is brightness, R is the RGB color value and φ is hue. This adjustment essentially skews the image towards green (lower values) or violet (higher values). Hue is sometimes referred to astint. After setting the value, the setting will persist even after __prod_name is exited. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

Example :-SetHue VT1 128
Default: __prod_name will use the value currently set on the capture device.
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the video that you wish to adjust.
Value This is a whole number between 0 and 255. Values below 0 will be adjusted to 0, and values above 255 will be adjusted to 255. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

-SetImageRotation <Tracker Name> <Value>
Adjusts the rotation of the video image. __prod_name will need to be restared for a rotation change to take effect.

Example :-SetImageRotation VT1 180
Default: N/A
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the video device that you wish to adjust.
Value Value in degrees to rotate the incoming video image. The only supported values at this time will be 0 (no rotation) and 180 (invert image).

-SetSaturation <Tracker Name> <Value>
Sets the saturation level for the specified video tracker. Adjusting this setting will increase or decrease the intensity of all color information evenly. If a signal is more red than blue or green, increasing saturation will show more of an effect on the red component than any other component. Saturation is sometimes referred to ascolor. After setting the value, the setting will persist even after __prod_name is exited. If black and white images are desired, this setting should be 0. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

Example :-SetSaturation VT1 128
Default: __prod_name will use the value currently set on the capture device.
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the video that you wish to adjust.
Value This is a whole number between 0 and 255. Values below 0 will be adjusted to 0, and values above 255 will be adjusted to 255. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

-SetSharpness <Tracker Name> <Value>
Sets the sharpness level for the specified video tracker. Sharpness dictates the number of pixels to use for color transitions. When an image switches between two distinct colors abruptly (say red and black), the video signal attempts to smooth that transition by adjusting a few pixels on the boundary of the color change. Adjusting the sharpness will either increase (lower values) or decrease (higher values) the number of pixels used for this transition. After setting the value, the setting will persist even after __prod_name is exited. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

Example :-SetSharpness VT1 128
Default: __prod_name will use the value currently set on the capture device.
Usage: This command can be used at any time.
Arguments
Tracker Name The name of the video that you wish to adjust.
Value This is a whole number between 0 and 255. Values below 0 will be adjusted to 0, and values above 255 will be adjusted to 255. This setting must be able to be adjusted by your hardware, this function will be ignored if your device does not support this setting.

-SetVideoFileOutput <Tracker Name> <Output File Name>
Sets up a live video recording on your PC. This can be done concurrently with standard video tracking. If video file output is enabled (see -SetVideoFileOutputEnabled) when recording is started, __prod_name will begin to compress the live video image, without processing, and save that video to the file specified. A subtitle file will be recorded, along with the compressed video, to allow you to view the __prod_name timestamp overlaid over each video frame in any media player that supports subtitles. This setting is only available if you are using a video tracking capture card that supports hardware video encoding or using GigE cameras. The file format for GigE cameras should be "avi".

Example :-SetVideoFileOutput VT1 VT1.mpg
Default: __prod_name does not set a video output file name when a video tracker is created.
Usage: This command can be used only when __prod_name is idle or in acquisition mode.
Arguments
Tracker Name The name of the video tracker to use when making the live recording.
Output File Name __prod_nameis designed to work with capture devices that have hardware video encoders. The encoding format is dependent on the capture device you are using, and it is your responsibility to name the file with the appropriate extension. If you are using GigE camera, file extension should be "avi" .

Sets the file to use for live video recording. If only a filename is specified, __prod_name will create the file in the current data directory.

Example : -SetVideoFileOutput VT1 VT1.mpg

If a complete path is specified, __prod_name will create the file in the specified location.

Example : -SetVideoFileOutput VT1 "C:\Video\My_Video.mpg"

The directory "C:\Video\" must exist or this command will fail. If __prod_name recording is stopped while recording to a video output file, a new file will be created with the same name and "_#" appended to the end. The next time recording is started, __prod_name will record all video to the new file. The # is incremented every time recording is stopped.
- SetVideoFileOutputEnabled <Tracker Name> <Value>
Enables or disables video file output using the compression and file specified by -SetVideoFileOutput. Changing the enabled state does not change the value of the -SetVideoFileOutput command unless the -SetVideoFileOutput command was never issued.

Example :-SetVideoFileOutputEnabled VT1 false
Default: __prod_name creates video trackers with the video file output enabled set to false.
Usage: This command can be used only when __prod_name is idle or in acquisition mode.
Arguments
Tracker Name The name of the video tracker that you wish to adjust.
Value Specifies the input you wish to use for this video tracker. __prod_name supports the following input types:
  1. True : Enables recording of live video to an output file. If no output file is defined using the -SetVideoFileOutput command, a video file is created in the current data directory using the specified video tracker name (i.e. VT1.mpg).
  2. False: Disables recording of live video to an output file.
-SetVideoInput <Tracker Name> <Input Type>
This command will determine what connection your video camera is using to feed images to the computer.These inputs will work with both NTSC and PAL video formats. The video input for GigE vision cameras should be only "GigE".

Example :-SetVideoInput VT1 SVideo
Default: __prod_name creates video trackers using the SVideo input.
Usage: This command can be used only when __prod_name is idle or in acquisition mode.
Arguments
Tracker Name The name of the video tracker whose input you wish to change.
Input Type Specifies the input you wish to use for this video tracker. __prod_name supports the following input types:
  1. GigE : Uses an ethernet network connection to transfer video frames. GigE cameras are high-performance industrial cameras.
  2. SVideo : Uses a 4 pin connection to transfer video signal. It gives better image quality than composite because it transmits luminance and color information on separate wires. The remaining two wires are ground.
  3. Composite : Generally uses a coaxial wire with either a BNC or an RCA connection. Composite signals transmit all image information over a single wire. This results in a less accurate image than SVideo.

Your capture device must also support the specified input type. If your hardware does not support the specified input type, the command will fail.

-SetVideoResolution <Tracker Name> <Width> <Height>
Sets the resolution to be used for this video tracker. Because this setting is device dependent, it will fail if the resolution specified is not supported by the device in its current state (i.e. 800x600 resolution with NTSC format). If this command is not specified, __prod_name will automatically select a resolution for you based on the other video settings.

Example :-SetVideoResolution VT1 800 600
Default: __prod_name creates video trackers the first valid NTSC format resolution returned by the capture card.
Usage: This command can be used only when __prod_name is idle.
Arguments
Tracker Name The name of the video tracker to adjust.
Width
The width of the desired resolution in pixels. This number must be greater than or equal to 0. A value of 0 will tell __prod_name to automatically select a resolution based on the current video settings.
Height The height of the desired resolution in pixels. This number must be greater than or equal to 0. A value of 0 will tell __prod_name to automatically select a resolution based on the current video settings.

-SetVideoFrameRate <Tracker Name> <frame rate>
Sets frame rate to be used for this video tracker. Because this setting is device dependent, it will fail if the frame rate specified is not supported by the device in its current state (i.e. the device does not support the specified frame rate). If this command is not specified, __prod_name will automatically select a frame rate for you based on the other video settings.
The frame rate is also dependent on the current resolution of the video tracker. Not every device will support every frame rate at every resolution. As such, if a frame rate is specified that is in excess of that supported by the current resolution, the frame rate will be automatically decreased to the maximum supported at this resolution. This new, effective frame rate will be visible in the Video Tracker properties for this Tracker Name.

Example :-SetVideoResolution VT1 800 600
Default: __prod_name creates video trackers the first valid NTSC format resolution returned by the capture card.
Usage: This command can be used only when __prod_name is idle.
Arguments
Tracker Name The name of the video tracker to adjust.
Width
The width of the desired resolution in pixels. This number must be greater than or equal to 0. A value of 0 will tell __prod_name to automatically select a resolution based on the current video settings.
Height The height of the desired resolution in pixels. This number must be greater than or equal to 0. A value of 0 will tell __prod_name to automatically select a resolution based on the current video settings.