Ring Daemon
16.0.0
Loading...
Searching...
No Matches
media_device.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2004-2025 Savoir-faire Linux Inc.
3
*
4
* This program is free software: you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License as published by
6
* the Free Software Foundation, either version 3 of the License, or
7
* (at your option) any later version.
8
*
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License
15
* along with this program. If not, see <https://www.gnu.org/licenses/>.
16
*/
17
18
#ifndef __MEDIA_DEVICE_H__
19
#define __MEDIA_DEVICE_H__
20
21
#include "
rational.h
"
22
23
#include <string>
24
#include <chrono>
25
26
namespace
jami
{
27
28
constexpr
static
auto
NEWPARAMS_TIMEOUT
= std::chrono::milliseconds(1000);
29
35
struct
DeviceParams
36
{
37
std::string
name
{};
// friendly name (e.g. Logitech BRIO)
38
std::string
input
{};
// Device path (e.g. /dev/video0)
39
std::string
unique_id
{};
// unique id (e.g. 046d082d8A8B667F)
40
std::string
format
{};
41
unsigned
width
{},
height
{};
42
rational<double>
framerate
{};
43
std::string
pixel_format
{};
44
std::string
channel_name
{};
45
unsigned
channel
{};
// Channel number
46
std::string
loop
{};
47
std::string
sdp_flags
{};
48
int
offset_x
{};
49
int
offset_y
{};
50
int
orientation
{};
51
std::string
window_id
{};
52
int
fd
{};
// file descriptor for PipeWire (only relevant on Wayland)
53
std::string
node
{};
// node id for PipeWire
54
int
is_area
{};
55
// Skip DTS delay while finding stream info when PTS is sufficient
56
bool
disable_dts_probe_delay
=
false
;
57
};
58
59
}
// namespace jami
60
61
#endif
// __MEDIA_DEVICE_H__
jami::rational
Naive implementation of the boost::rational interface, described here: http://www....
Definition
rational.h:38
jami
Definition
account.cpp:61
jami::NEWPARAMS_TIMEOUT
static constexpr auto NEWPARAMS_TIMEOUT
Definition
media_device.h:28
rational.h
jami::DeviceParams
DeviceParams Parameters used by MediaDecoder and MediaEncoder to open a LibAV device/stream.
Definition
media_device.h:36
jami::DeviceParams::height
unsigned height
Definition
media_device.h:41
jami::DeviceParams::channel
unsigned channel
Definition
media_device.h:45
jami::DeviceParams::unique_id
std::string unique_id
Definition
media_device.h:39
jami::DeviceParams::width
unsigned width
Definition
media_device.h:41
jami::DeviceParams::orientation
int orientation
Definition
media_device.h:50
jami::DeviceParams::window_id
std::string window_id
Definition
media_device.h:51
jami::DeviceParams::fd
int fd
Definition
media_device.h:52
jami::DeviceParams::is_area
int is_area
Definition
media_device.h:54
jami::DeviceParams::offset_x
int offset_x
Definition
media_device.h:48
jami::DeviceParams::format
std::string format
Definition
media_device.h:40
jami::DeviceParams::offset_y
int offset_y
Definition
media_device.h:49
jami::DeviceParams::loop
std::string loop
Definition
media_device.h:46
jami::DeviceParams::channel_name
std::string channel_name
Definition
media_device.h:44
jami::DeviceParams::disable_dts_probe_delay
bool disable_dts_probe_delay
Definition
media_device.h:56
jami::DeviceParams::node
std::string node
Definition
media_device.h:53
jami::DeviceParams::framerate
rational< double > framerate
Definition
media_device.h:42
jami::DeviceParams::input
std::string input
Definition
media_device.h:38
jami::DeviceParams::name
std::string name
Definition
media_device.h:37
jami::DeviceParams::sdp_flags
std::string sdp_flags
Definition
media_device.h:47
jami::DeviceParams::pixel_format
std::string pixel_format
Definition
media_device.h:43
src
media
media_device.h
Generated on Thu Jun 19 2025 15:50:37 for Ring Daemon by
1.9.8