MythTV  master
Public Member Functions | Static Public Member Functions | Protected Member Functions | Static Protected Member Functions | Private Attributes | List of all members
V4L2util Class Reference

#include <v4l2util.h>

Public Member Functions

 V4L2util (void)
 V4L2util (const QString &dev_name)
 V4L2util (const QString &dev_name, const QString &vbi_dev_name)
 ~V4L2util (void)
bool Open (const QString &device_name, const QString &vbi_device_name="")
void Close (void)
int FD (void) const
bool operator! (void) const
bool IsOpen (void) const
bool GetOptions (DriverOption::Options &options)
int GetOptionValue (DriverOption::category_t cat, const QString &desc)
bool GetFormats (QStringList &formats)
bool GetVideoStandard (QString &name) const
int GetSignalStrength (void) const
bool GetResolution (int &width, int &height) const
bool HasTuner (void) const
bool HasAudioSupport (void) const
bool HasStreaming (void) const
bool HasSlicedVBI (void) const
bool IsEncoder (void) const
bool UserAdjustableResolution (void) const
QString DriverName (void) const
QString CardName (void) const
QString ProfileName (void) const
int GetStreamType (void) const
bool SetStreamType (int value)
bool SetVideoAspect (int value)
bool SetVideoBitrateMode (int value)
bool SetVideoBitrate (int value)
bool SetVideoBitratePeak (int value)
bool SetResolution (uint32_t width, uint32_t height)
bool SetAudioInput (int value)
bool SetAudioCodec (int value)
bool SetVolume (int volume)
bool SetLanguageMode (int mode)
bool SetAudioSamplingRate (int value)
bool SetAudioBitrateL2 (int value)
bool StartEncoding (void)
bool StopEncoding (void)
bool PauseEncoding (void)
bool ResumeEncoding (void)

Static Public Member Functions

static QString StreamTypeDesc (int value)

Protected Member Functions

bool OpenVBI (const QString &vbi_dev_name)
bool SetSlicedVBI (const VBIMode::vbimode_t &vbimode)
int GetExtControl (int request, const QString &ctrl_desc="") const
bool SetExtControl (int request, int value, const QString &ctrl_desc, const QString &value_desc)
bool SetEncoderState (int mode, const QString &desc)
void SetDefaultOptions (DriverOption::Options &options)
void log_qctrl (struct v4l2_queryctrl &queryctrl, DriverOption &drv_opt, QString &msg)
bool log_control (struct v4l2_queryctrl &qctrl, DriverOption &drv_opt, QString &msg)
void log_controls (bool show_menus)

Static Protected Member Functions

static void bitmask_toString (QString &result, uint32_t flags, uint32_t mask, const QString &desc)
static QString ctrlflags_toString (uint32_t flags)
static QString queryctrl_toString (int type)

Private Attributes

int m_fd
int m_vbi_fd
DriverOption::Options m_options
QString m_device_name
QString m_driver_name
QString m_card_name
int m_version
uint32_t m_capabilities
bool m_have_query_ext_ctrl

Detailed Description

Definition at line 16 of file v4l2util.h.

Constructor & Destructor Documentation

◆ V4L2util() [1/3]

V4L2util::V4L2util ( void  )

Definition at line 15 of file v4l2util.cpp.

◆ V4L2util() [2/3]

V4L2util::V4L2util ( const QString &  dev_name)

Definition at line 24 of file v4l2util.cpp.

◆ V4L2util() [3/3]

V4L2util::V4L2util ( const QString &  dev_name,
const QString &  vbi_dev_name 

Definition at line 33 of file v4l2util.cpp.

◆ ~V4L2util()

V4L2util::~V4L2util ( void  )

Definition at line 42 of file v4l2util.cpp.

Member Function Documentation

◆ Open()

bool V4L2util::Open ( const QString &  device_name,
const QString &  vbi_device_name = "" 

◆ Close()

void V4L2util::Close ( void  )

◆ FD()

int V4L2util::FD ( void  ) const

Definition at line 26 of file v4l2util.h.

◆ operator!()

bool V4L2util::operator! ( void  ) const

Definition at line 28 of file v4l2util.h.

◆ IsOpen()

bool V4L2util::IsOpen ( void  ) const

◆ GetOptions()

bool V4L2util::GetOptions ( DriverOption::Options options)

◆ GetOptionValue()

int V4L2util::GetOptionValue ( DriverOption::category_t  cat,
const QString &  desc 

◆ GetFormats()

bool V4L2util::GetFormats ( QStringList &  formats)

◆ GetVideoStandard()

bool V4L2util::GetVideoStandard ( QString &  name) const

◆ GetSignalStrength()

int V4L2util::GetSignalStrength ( void  ) const

◆ GetResolution()

bool V4L2util::GetResolution ( int &  width,
int &  height 
) const

◆ HasTuner()

bool V4L2util::HasTuner ( void  ) const

◆ HasAudioSupport()

bool V4L2util::HasAudioSupport ( void  ) const

◆ HasStreaming()

bool V4L2util::HasStreaming ( void  ) const

◆ HasSlicedVBI()

bool V4L2util::HasSlicedVBI ( void  ) const

◆ IsEncoder()

bool V4L2util::IsEncoder ( void  ) const

◆ UserAdjustableResolution()

bool V4L2util::UserAdjustableResolution ( void  ) const

◆ DriverName()

QString V4L2util::DriverName ( void  ) const

◆ CardName()

QString V4L2util::CardName ( void  ) const

Definition at line 46 of file v4l2util.h.

Referenced by V4L2encGroup::probeCard().

◆ ProfileName()

QString V4L2util::ProfileName ( void  ) const

Definition at line 47 of file v4l2util.h.

◆ GetStreamType()

int V4L2util::GetStreamType ( void  ) const

◆ SetStreamType()

bool V4L2util::SetStreamType ( int  value)

◆ SetVideoAspect()

bool V4L2util::SetVideoAspect ( int  value)

◆ SetVideoBitrateMode()

bool V4L2util::SetVideoBitrateMode ( int  value)

◆ SetVideoBitrate()

bool V4L2util::SetVideoBitrate ( int  value)

◆ SetVideoBitratePeak()

bool V4L2util::SetVideoBitratePeak ( int  value)

◆ SetResolution()

bool V4L2util::SetResolution ( uint32_t  width,
uint32_t  height 

◆ SetAudioInput()

bool V4L2util::SetAudioInput ( int  value)

◆ SetAudioCodec()

bool V4L2util::SetAudioCodec ( int  value)

◆ SetVolume()

bool V4L2util::SetVolume ( int  volume)

◆ SetLanguageMode()

bool V4L2util::SetLanguageMode ( int  mode)

◆ SetAudioSamplingRate()

bool V4L2util::SetAudioSamplingRate ( int  value)

◆ SetAudioBitrateL2()

bool V4L2util::SetAudioBitrateL2 ( int  value)

◆ StartEncoding()

bool V4L2util::StartEncoding ( void  )

◆ StopEncoding()

bool V4L2util::StopEncoding ( void  )

◆ PauseEncoding()

bool V4L2util::PauseEncoding ( void  )

◆ ResumeEncoding()

bool V4L2util::ResumeEncoding ( void  )

◆ StreamTypeDesc()

static QString V4L2util::StreamTypeDesc ( int  value)

◆ OpenVBI()

bool V4L2util::OpenVBI ( const QString &  vbi_dev_name)

Referenced by Open().

◆ SetSlicedVBI()

bool V4L2util::SetSlicedVBI ( const VBIMode::vbimode_t vbimode)

◆ GetExtControl()

int V4L2util::GetExtControl ( int  request,
const QString &  ctrl_desc = "" 
) const

◆ SetExtControl()

bool V4L2util::SetExtControl ( int  request,
int  value,
const QString &  ctrl_desc,
const QString &  value_desc 

◆ SetEncoderState()

bool V4L2util::SetEncoderState ( int  mode,
const QString &  desc 

◆ SetDefaultOptions()

void V4L2util::SetDefaultOptions ( DriverOption::Options options)

◆ bitmask_toString()

static void V4L2util::bitmask_toString ( QString &  result,
uint32_t  flags,
uint32_t  mask,
const QString &  desc 

◆ ctrlflags_toString()

static QString V4L2util::ctrlflags_toString ( uint32_t  flags)

◆ queryctrl_toString()

static QString V4L2util::queryctrl_toString ( int  type)

◆ log_qctrl()

void V4L2util::log_qctrl ( struct v4l2_queryctrl &  queryctrl,
DriverOption drv_opt,
QString &  msg 

◆ log_control()

bool V4L2util::log_control ( struct v4l2_queryctrl &  qctrl,
DriverOption drv_opt,
QString &  msg 

◆ log_controls()

void V4L2util::log_controls ( bool  show_menus)

Member Data Documentation

◆ m_fd

int V4L2util::m_fd

Definition at line 96 of file v4l2util.h.

Referenced by Open().

◆ m_vbi_fd

int V4L2util::m_vbi_fd

Definition at line 97 of file v4l2util.h.

◆ m_options

DriverOption::Options V4L2util::m_options

Definition at line 98 of file v4l2util.h.

◆ m_device_name

QString V4L2util::m_device_name

Definition at line 99 of file v4l2util.h.

Referenced by Open().

◆ m_driver_name

QString V4L2util::m_driver_name

Definition at line 100 of file v4l2util.h.

Referenced by Open().

◆ m_card_name

QString V4L2util::m_card_name

Definition at line 101 of file v4l2util.h.

Referenced by Open().

◆ m_version

int V4L2util::m_version

Definition at line 102 of file v4l2util.h.

Referenced by Open().

◆ m_capabilities

uint32_t V4L2util::m_capabilities

Definition at line 103 of file v4l2util.h.

Referenced by Open().

◆ m_have_query_ext_ctrl

bool V4L2util::m_have_query_ext_ctrl

Definition at line 104 of file v4l2util.h.

Referenced by Open().

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