# OpalH281Handler Class Reference

`#include <h281handler.h>`

List of all members.

## Public Types

enum | VideoSource { CurrentVideoSource = 0x00, MainCamera = 0x01, AuxiliaryCamera = 0x02, DocumentCamera = 0x03, AuxiliaryDocumentCamera = 0x04, VideoPlaybackSource = 0x05 }

## Public Member Functions

| OpalH281Handler ()
| ~OpalH281Handler ()
PBoolean | GetRemoteHasH281 () const
void | SetRemoteHasH281 (PBoolean flag)
BYTE | GetLocalNumberOfPresets () const
void | SetLocalNumberOfPresets (BYTE presets)
BYTE | GetRemoteNumberOfPresets () const
H281VideoSource & | GetLocalVideoSource (VideoSource source)
H281VideoSource & | GetRemoteVideoSource (VideoSource source)
void | StartAction (H281_Frame::PanDirection panDirection, H281_Frame::TiltDirection tiltDirection, H281_Frame::ZoomDirection zoomDireciton, H281_Frame::FocusDirection focusDirection)
void | StopAction ()
void | SelectVideoSource (BYTE videoSourceNumber, H281_Frame::VideoMode videoMode)
void | StoreAsPreset (BYTE presetNumber)
void | ActivatePreset (BYTE presetNumber)
void | SendExtraCapabilities () const
void | OnReceivedExtraCapabilities (const BYTE *capabilities, PINDEX size)
void | OnReceivedMessage (const H281_Frame &message)
virtual void | OnRemoteCapabilitiesUpdated ()
virtual void | OnStartAction (H281_Frame::PanDirection panDirection, H281_Frame::TiltDirection tiltDirection, H281_Frame::ZoomDirection zoomDirection, H281_Frame::FocusDirection focusDirection)
virtual void | OnStopAction ()
virtual void | OnSelectVideoSource (BYTE videoSourceNumber, H281_Frame::VideoMode videoMode)
virtual void | OnStoreAsPreset (BYTE presetNumber)
virtual void | OnActivatePreset (BYTE presetNumber)

## Protected Member Functions

| PDECLARE_NOTIFIER (PTimer, OpalH281Handler, ContinueAction)
| PDECLARE_NOTIFIER (PTimer, OpalH281Handler, StopActionLocally)

## Protected Attributes

PBoolean | remoteHasH281
BYTE | localNumberOfPresets
BYTE | remoteNumberOfPresets
H281VideoSource | localVideoSources [6]
H281VideoSource | remoteVideoSources [6]
H281_Frame | transmitFrame
PTimer | transmitTimer
H281_Frame::PanDirection | requestedPanDirection
H281_Frame::TiltDirection | requestedTiltDirection
H281_Frame::ZoomDirection | requestedZoomDirection
H281_Frame::FocusDirection | requestedFocusDirection
PTimer | receiveTimer

## Detailed Description

This class implements a defalt H.281 handler

## Member Enumeration Documentation

enum OpalH281Handler::VideoSource

Enumerator:

  CurrentVideoSource |
  MainCamera |
  AuxiliaryCamera |
  DocumentCamera |
  AuxiliaryDocumentCamera |
  VideoPlaybackSource |

## Constructor & Destructor Documentation

OpalH281Handler::OpalH281Handler | ( |  | ) |

OpalH281Handler::~OpalH281Handler | ( |  | ) |

## Member Function Documentation

PBoolean OpalH281Handler::GetRemoteHasH281 | ( |  | ) | const`[inline]`

void OpalH281Handler::SetRemoteHasH281 | ( | PBoolean | flag | ) | `[inline]`

BYTE OpalH281Handler::GetLocalNumberOfPresets | ( |  | ) | const`[inline]`

void OpalH281Handler::SetLocalNumberOfPresets | ( | BYTE | presets | ) | `[inline]`

BYTE OpalH281Handler::GetRemoteNumberOfPresets | ( |  | ) | const`[inline]`

H281VideoSource& OpalH281Handler::GetLocalVideoSource | ( | VideoSource | source | ) |

H281VideoSource& OpalH281Handler::GetRemoteVideoSource | ( | VideoSource | source | ) |

void OpalH281Handler::StartAction | ( | H281_Frame::PanDirection | panDirection,
|  | H281_Frame::TiltDirection | tiltDirection,
|  | H281_Frame::ZoomDirection | zoomDireciton,
|  | H281_Frame::FocusDirection | focusDirection |
| ) |  |  |

Causes the H.281 handler to start the desired action The action will continue until StopAction() is called.

void OpalH281Handler::StopAction | ( |  | ) |

Stops any action currently ongoing

void OpalH281Handler::SelectVideoSource | ( | BYTE | videoSourceNumber,
|  | H281_Frame::VideoMode | videoMode |
| ) |  |  |

Tells the remote side to select the desired video source using the mode specified. Does nothing if either video source or mode aren't available

void OpalH281Handler::StoreAsPreset | ( | BYTE | presetNumber | ) |

Tells the remote side to store the current camera settings as a preset with the preset number given

void OpalH281Handler::ActivatePreset | ( | BYTE | presetNumber | ) |

Tells the remote side to activate the given preset

void OpalH281Handler::SendExtraCapabilities | ( |  | ) | const

Causes the H.281 handler to send its capabilities. Capabilities include the number of available cameras, (default one) the camera abilities (default none) and the number of presets that can be stored (default zero)

void OpalH281Handler::OnReceivedExtraCapabilities | ( | const BYTE * | capabilities,
|  | PINDEX | size |
| ) |  |  |

Processing incoming frames

void OpalH281Handler::OnReceivedMessage | ( | const H281_Frame & | message | ) |

virtual void OpalH281Handler::OnRemoteCapabilitiesUpdated | ( |  | ) | `[virtual]`

Called each time a remote endpoint sends its capability list

virtual void OpalH281Handler::OnStartAction | ( | H281_Frame::PanDirection | panDirection,
|  | H281_Frame::TiltDirection | tiltDirection,
|  | H281_Frame::ZoomDirection | zoomDirection,
|  | H281_Frame::FocusDirection | focusDirection |
| ) |  |  | `[virtual]`

Indicates to start the action specified

virtual void OpalH281Handler::OnStopAction | ( |  | ) | `[virtual]`

Indicates to stop the action stared with OnStartAction()

virtual void OpalH281Handler::OnSelectVideoSource | ( | BYTE | videoSourceNumber,
|  | H281_Frame::VideoMode | videoMode |
| ) |  |  | `[virtual]`

Indicates to select the desired video source

virtual void OpalH281Handler::OnStoreAsPreset | ( | BYTE | presetNumber | ) | `[virtual]`

Indicates to store the current camera settings as a preset

virtual void OpalH281Handler::OnActivatePreset | ( | BYTE | presetNumber | ) | `[virtual]`

Indicates to activate the given preset number

OpalH281Handler::PDECLARE_NOTIFIER | ( | PTimer | ,
|  | OpalH281Handler | ,
|  | ContinueAction |  |
| ) |  |  | `[protected]`

OpalH281Handler::PDECLARE_NOTIFIER | ( | PTimer | ,
|  | OpalH281Handler | ,
|  | StopActionLocally |  |
| ) |  |  | `[protected]`

## Member Data Documentation

PBoolean OpalH281Handler::remoteHasH281 `[protected]`

BYTE OpalH281Handler::localNumberOfPresets `[protected]`

BYTE OpalH281Handler::remoteNumberOfPresets `[protected]`

H281VideoSource OpalH281Handler::localVideoSources[6]`[protected]`

H281VideoSource OpalH281Handler::remoteVideoSources[6]`[protected]`

H281_Frame OpalH281Handler::transmitFrame `[protected]`

PTimer OpalH281Handler::transmitTimer `[protected]`

H281_Frame::PanDirection OpalH281Handler::requestedPanDirection `[protected]`

H281_Frame::TiltDirection OpalH281Handler::requestedTiltDirection `[protected]`

H281_Frame::ZoomDirection OpalH281Handler::requestedZoomDirection `[protected]`

H281_Frame::FocusDirection OpalH281Handler::requestedFocusDirection `[protected]`

PTimer OpalH281Handler::receiveTimer `[protected]`

The documentation for this class was generated from the following file:

- h281handler.h