ExOxvif.Imaging (ex_oxvif v0.1.0)

Copy Markdown View Source

Imaging service: focus.

source is a video source token (ExOxvif.MediaProfile :video_source_token), not a profile token.

Summary

Functions

Current focus position and movement state.

Stop focus movement.

Types

focus_move()

@type focus_move() ::
  {:absolute, number(), number() | nil}
  | {:relative, number(), number() | nil}
  | {:continuous, number()}

Functions

move(session, source, focus, opts \\ [])

@spec move(ExOxvif.Session.t(), String.t(), focus_move(), ExOxvif.call_opts()) ::
  :ok | {:error, ExOxvif.Error.t()}

Move the focus.

  • {:absolute, position, speed} - to a position in the device's range
  • {:relative, distance, speed} - positive is far, negative is near
  • {:continuous, speed} - until stop/3; positive is far

speed may be nil for the device default.

status(session, source, opts \\ [])

@spec status(ExOxvif.Session.t(), String.t(), ExOxvif.call_opts()) ::
  {:ok, ExOxvif.Imaging.Status.t()} | {:error, ExOxvif.Error.t()}

Current focus position and movement state.

stop(session, source, opts \\ [])

@spec stop(ExOxvif.Session.t(), String.t(), ExOxvif.call_opts()) ::
  :ok | {:error, ExOxvif.Error.t()}

Stop focus movement.