[ Previous | Next | Contents | Glossary | Home | Search ]
Ultimedia Services Version 2 for AIX: Programmer's Guide and Reference

UMSCameraControl Object

The UMSCameraControl object is an Ultimedia Services Version 2 feature and does not apply to Ultimedia Services Version 1.2.1.

The UMSCameraControl object defines a generic interface to control a video camera. This class is a base class and is not meant to be instantiated. UMS supplies specific camera objects that inherits from this class to support a CCD camera on two video devices.

To learn more about the UMSCameraControl object, see:

For introductory information, see Video, Monitor, and Camera Control Support Objects.

Enumeration Lists

enum ReturnCode {
   Success,
    Failure,
   NotSupported,
   InvalidArgument,
   NotOpen
   };
enum FadeValue {
   FadeIn,
   FadeOut
   };

Method Descriptions

ReturnCode open(in string path)

Description

This method opens the camera device if necessary. Some devices require an open and some have other means of camera access (like use of an Atom in the XServer).

Arguments
in string path Path to the camera device. This most likely is supplied by the Metaclass using the config file.
Return Values

Success

Failure

ReturnCode close()

Description

This method closes the camera device if a close is required. It is assumed that the file descriptor is stored within the object as an instance variable.

Return Values

Success

NotOpen

Failure

ReturnCode set_zoom(in long scale)

Description

This method sets the level of zoom. The zoom scale is defined to be integer values between 1 and 100, with 1 being Wide Angle and 100 being TelePhoto.

Arguments
in long scale Integer zoom value.
Return Values

Success

Failure

InvalidArgument

NotOpen

ReturnCode get_zoom(out long scale)

Description

This method returns the current zoom level.

Arguments
out long scale Integer zoom value.
Return Values

Success

ReturnCode set_pan(in long scale)

Description

This method sets the camera pan. Pan values change according to the current zoom level. Pan is defined as the horizontal movement of the camera.

Arguments
in long scale Integer pan value.
Return Values

Success

Failure

InvalidArgument

NotOpen

ReturnCode get_pan(out long scale)

Description

This method returns the current pan value.

Arguments
Out long scale Integer Pan value.
Return Values

Success

ReturnCode set_tilt(in long scale)

Description

This method sets the tilt value of the camera. The valid values of tilt change according to what the current zoom level is. Tilt is defined as the vertical movement of the camera.

Arguments
in long scale Integer tilt value.
Return Values

Success

Failure

InvalidArgument

NotOpen

ReturnCode get_tilt(out long scale)

Description

This method returns the current camera tilt value.

Arguments
out long scale integer tilt value.
Return Values

Success

ReturnCode set_fade(in long scale)

Description

This method sets the fade value for the camera. Fade is defined as going from black to light and from light to black. The base class defines this as a scale because there could be cameras with a fine fade control. Usually though, there only is a fade in and fade out control. Because of this, there is an enumerated type defined for fade, which can be supplied to this method.

Arguments
in long scale Integer fade value.
Return Values

Success

Failure

InvalidArgument

NotOpen

ReturnCode get_fade(out long scale)

Description

This method returns the current fade value.

Arguments
out long scale Integer fade value.
Return Values

Success

ReturnCode set_focus(in long scale)

Description

This method adjusts the camera focus is supported.

Arguments
in long scale Integer focus value
Return Values

Success

Failure

InvalidArgument

NotOpen

ReturnCode get_focus(out long scale)

Description

This method returns the current focus value.

Arguments
out long scale Integer focus value
Return Values

Success

ReturnCode set_exposure(in long scale)

Description

This method sets the exposure value for the camera. Exposure is defined as how much light the camera lets in. Like the rest of CameraControl methods, this value is an integer scale value that would be interpreted differently depending on the camera type. In other words, this method does not accept an f stop value. Since most cameras do this automatically, the default behavior of this object is to do an automatic exposure. The first time this method is called with any value, the exposure is set to manual until a reset (close/open).

Arguments
in long scale Integer focus value
Return Values

Success

Failure

InvalidArgument

NotOpen

ReturnCode get_exposure(out long scale)

Description

This method returns the current exposure value.

Arguments
out long scale Integer exposure value
Return Values

Success

ReturnCode set_red_blue_balance(in long scale) ReturnCode set_magenta_green_balance(in long scale)

Description

These methods adjusts the white balance with respect to the red/blue values. Since most cameras do this automatically, the default behavior of the camera is to do automatic white balancing. The first time either of these methods are called, the white balance is set to manual.

Arguments
out long scale Integer exposure value.
Return Values

Success

Failure

InvalidArgument

NotOpen

ReturnCode get_red_blue_balance(out long scale) ReturnCode get_magenta_green_balance(out long scale)

Description

These methods returns the current white balance values.

Arguments
out long scale Integer white balance values
Return Values

Success

For introductory information, see Video, Monitor, and Camera Control Support Objects.


[ Previous | Next | Contents | Glossary | Home | Search ]