ToolX 1.11.1 [e3f477f]
A GUI debug tool chain for diagnosing GVA systems
Loading...
Searching...
No Matches
utils.h
Go to the documentation of this file.
1//
2// Copyright (c) 2026, Astute Systems PTY LTD
3//
4// This file is part of the VivoeX project developed by Astute Systems.
5//
6// License. See the LICENSE file in the project root for full license details.
7//
13
14#ifndef UTILS_H
15#define UTILS_H
16#include <QString>
17#include "rtp/rtp.h"
18#include "common/datatypes.h"
19
25mediax::rtp::ColourspaceType colourSpaceStringFromString(QString colourspace);
26
31constexpr int kFormatH264OpenH264 = 4;
32constexpr int kFormatH264Vaapi = 5;
33constexpr int kFormatH265 = 6;
34constexpr int kFormatJpeg = 7;
35constexpr int kFormatAv1 = 8;
36
44int colourSpaceToInt(mediax::rtp::ColourspaceType colourspace, bool vaapi = false);
45
52mediax::rtp::ColourspaceType intToColourSpace(int colourspace);
53
60bool isVaapiH264Format(int colourspace);
61
67QString ColourspaceTypeToQString(mediax::rtp::ColourspaceType colourspace);
68
69#endif // UTILS_H
bool isVaapiH264Format(int colourspace)
Check if a stream format ID selects the VAAPI H.264 encoder.
Definition utils.cpp:86
mediax::rtp::ColourspaceType colourSpaceStringFromString(QString colourspace)
Convert the colour space string to an enum.
Definition utils.cpp:16
QString ColourspaceTypeToQString(mediax::rtp::ColourspaceType colourspace)
Convert the colour space to a string.
Definition utils.cpp:91
int colourSpaceToInt(mediax::rtp::ColourspaceType colourspace, bool vaapi=false)
Convert the colour space to a stream format ID.
Definition utils.cpp:39
constexpr int kFormatH264OpenH264
Stream format IDs: the index of the RTP table Encoding drop down, the colourspace column of CSV files...
Definition utils.h:31
mediax::rtp::ColourspaceType intToColourSpace(int colourspace)
Convert a stream format ID to a colour space.
Definition utils.cpp:61