Jellyfin Qt
QML Library for interacting with the Jellyfin multimedia server
Loading...
Searching...
No Matches
transcodinginfo.h
Go to the documentation of this file.
1/*
2 * Sailfin: a Jellyfin client written using Qt
3 * Copyright (C) 2021 Chris Josten and the Sailfin Contributors.
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 */
19/*
20 * WARNING: THIS IS AN AUTOMATICALLY GENERATED FILE! PLEASE DO NOT EDIT THIS, AS YOUR EDITS WILL GET
21 * OVERWRITTEN AT SOME POINT!
22 *
23 * If there is a bug in this file, please fix the code generator used to generate this file found in
24 * core/openapigenerator.d.
25 *
26 * This file is generated based on Jellyfin's OpenAPI description, "openapi.json". Please update that
27 * file with a newer file if needed instead of manually updating the files.
28 */
29
30#ifndef JELLYFIN_DTO_TRANSCODINGINFO_H
31#define JELLYFIN_DTO_TRANSCODINGINFO_H
32
33#include <QJsonObject>
34#include <QJsonValue>
35#include <QList>
36#include <QString>
37#include <QStringList>
38#include <optional>
39
43
44namespace Jellyfin {
45// Forward declaration
46class ApiClient;
47}
48namespace Jellyfin {
49namespace DTO {
50
51
53public:
55 bool isVideoDirect,
56 bool isAudioDirect,
59 );
60
61 TranscodingInfo(const TranscodingInfo &other);
62
66 void replaceData(TranscodingInfo &other);
67
68 static TranscodingInfo fromJson(QJsonObject source);
69 void setFromJson(QJsonObject source);
70 QJsonObject toJson() const;
71
72 // Properties
76 QString audioCodec() const;
80 void setAudioCodec(QString newAudioCodec);
81 bool audioCodecNull() const;
82 void setAudioCodecNull();
83
87 QString videoCodec() const;
91 void setVideoCodec(QString newVideoCodec);
92 bool videoCodecNull() const;
93 void setVideoCodecNull();
94
98 QString container() const;
102 void setContainer(QString newContainer);
103 bool containerNull() const;
104 void setContainerNull();
105
109 bool isVideoDirect() const;
113 void setIsVideoDirect(bool newIsVideoDirect);
114
118 bool isAudioDirect() const;
122 void setIsAudioDirect(bool newIsAudioDirect);
123
127 std::optional<qint32> bitrate() const;
131 void setBitrate(std::optional<qint32> newBitrate);
132 bool bitrateNull() const;
133 void setBitrateNull();
134
138 std::optional<float> framerate() const;
142 void setFramerate(std::optional<float> newFramerate);
143 bool framerateNull() const;
144 void setFramerateNull();
145
149 std::optional<double> completionPercentage() const;
153 void setCompletionPercentage(std::optional<double> newCompletionPercentage);
154 bool completionPercentageNull() const;
156
160 std::optional<qint32> width() const;
164 void setWidth(std::optional<qint32> newWidth);
165 bool widthNull() const;
166 void setWidthNull();
167
171 std::optional<qint32> height() const;
175 void setHeight(std::optional<qint32> newHeight);
176 bool heightNull() const;
177 void setHeightNull();
178
182 std::optional<qint32> audioChannels() const;
186 void setAudioChannels(std::optional<qint32> newAudioChannels);
187 bool audioChannelsNull() const;
189
190
192
193 void setHardwareAccelerationType(HardwareAccelerationType newHardwareAccelerationType);
194
202 void setTranscodeReasons(QList<TranscodeReason> newTranscodeReasons);
203
204
205protected:
208 QString m_container;
211 std::optional<qint32> m_bitrate = std::nullopt;
212 std::optional<float> m_framerate = std::nullopt;
213 std::optional<double> m_completionPercentage = std::nullopt;
214 std::optional<qint32> m_width = std::nullopt;
215 std::optional<qint32> m_height = std::nullopt;
216 std::optional<qint32> m_audioChannels = std::nullopt;
219
220private:
221 // Private constructor which generates an invalid object, for use withing TranscodingInfo::fromJson();
223};
224
225
226} // NS DTO
227
228namespace Support {
229
231
232template <>
234
235template<>
237
238} // NS DTO
239} // NS Jellyfin
240
241#endif // JELLYFIN_DTO_TRANSCODINGINFO_H
An Api client for Jellyfin. Handles requests and authentication.
Definition apiclient.h:90
Definition transcodinginfo.h:52
void setAudioChannelsNull()
Definition transcodinginfo.cpp:286
std::optional< qint32 > m_audioChannels
Definition transcodinginfo.h:216
bool m_isVideoDirect
Definition transcodinginfo.h:209
void setFromJson(QJsonObject source)
Definition transcodinginfo.cpp:89
QList< TranscodeReason > transcodeReasons() const
Gets or sets the transcode reasons.
Definition transcodinginfo.cpp:296
void setFramerateNull()
Definition transcodinginfo.cpp:234
void setVideoCodecNull()
Definition transcodinginfo.cpp:183
HardwareAccelerationType hardwareAccelerationType() const
Definition transcodinginfo.cpp:290
TranscodingInfo(bool isVideoDirect, bool isAudioDirect, HardwareAccelerationType hardwareAccelerationType, QList< TranscodeReason > transcodeReasons)
Definition transcodinginfo.cpp:36
bool audioCodecNull() const
Definition transcodinginfo.cpp:166
QString m_audioCodec
Definition transcodinginfo.h:206
bool framerateNull() const
Definition transcodinginfo.cpp:230
QString videoCodec() const
Gets or sets the thread count used for encoding.
Definition transcodinginfo.cpp:174
std::optional< qint32 > width() const
Gets or sets the video width.
Definition transcodinginfo.cpp:251
void setVideoCodec(QString newVideoCodec)
Gets or sets the thread count used for encoding.
Definition transcodinginfo.cpp:176
QList< TranscodeReason > m_transcodeReasons
Definition transcodinginfo.h:218
void setIsAudioDirect(bool newIsAudioDirect)
Gets or sets a value indicating whether the audio is passed through.
Definition transcodinginfo.cpp:208
void setAudioChannels(std::optional< qint32 > newAudioChannels)
Gets or sets the audio channels.
Definition transcodinginfo.cpp:279
bool isVideoDirect() const
Gets or sets a value indicating whether the video is passed through.
Definition transcodinginfo.cpp:200
bool videoCodecNull() const
Definition transcodinginfo.cpp:179
bool widthNull() const
Definition transcodinginfo.cpp:256
HardwareAccelerationType m_hardwareAccelerationType
Definition transcodinginfo.h:217
void setWidth(std::optional< qint32 > newWidth)
Gets or sets the video width.
Definition transcodinginfo.cpp:253
std::optional< qint32 > audioChannels() const
Gets or sets the audio channels.
Definition transcodinginfo.cpp:277
QString m_videoCodec
Definition transcodinginfo.h:207
void setWidthNull()
Definition transcodinginfo.cpp:260
bool heightNull() const
Definition transcodinginfo.cpp:269
std::optional< float > framerate() const
Gets or sets the framerate.
Definition transcodinginfo.cpp:225
std::optional< qint32 > height() const
Gets or sets the video height.
Definition transcodinginfo.cpp:264
void setAudioCodecNull()
Definition transcodinginfo.cpp:170
QString audioCodec() const
Gets or sets the thread count used for encoding.
Definition transcodinginfo.cpp:161
void setIsVideoDirect(bool newIsVideoDirect)
Gets or sets a value indicating whether the video is passed through.
Definition transcodinginfo.cpp:202
void setCompletionPercentageNull()
Definition transcodinginfo.cpp:247
void setHardwareAccelerationType(HardwareAccelerationType newHardwareAccelerationType)
Definition transcodinginfo.cpp:292
void setHeight(std::optional< qint32 > newHeight)
Gets or sets the video height.
Definition transcodinginfo.cpp:266
std::optional< double > m_completionPercentage
Definition transcodinginfo.h:213
void setBitrateNull()
Definition transcodinginfo.cpp:221
std::optional< qint32 > m_width
Definition transcodinginfo.h:214
std::optional< qint32 > bitrate() const
Gets or sets the bitrate.
Definition transcodinginfo.cpp:212
QString container() const
Gets or sets the thread count used for encoding.
Definition transcodinginfo.cpp:187
QJsonObject toJson() const
Definition transcodinginfo.cpp:106
void setContainerNull()
Definition transcodinginfo.cpp:196
bool audioChannelsNull() const
Definition transcodinginfo.cpp:282
bool completionPercentageNull() const
Definition transcodinginfo.cpp:243
void setBitrate(std::optional< qint32 > newBitrate)
Gets or sets the bitrate.
Definition transcodinginfo.cpp:214
QString m_container
Definition transcodinginfo.h:208
bool m_isAudioDirect
Definition transcodinginfo.h:210
void setFramerate(std::optional< float > newFramerate)
Gets or sets the framerate.
Definition transcodinginfo.cpp:227
std::optional< qint32 > m_bitrate
Definition transcodinginfo.h:211
void setContainer(QString newContainer)
Gets or sets the thread count used for encoding.
Definition transcodinginfo.cpp:189
void setTranscodeReasons(QList< TranscodeReason > newTranscodeReasons)
Gets or sets the transcode reasons.
Definition transcodinginfo.cpp:298
bool containerNull() const
Definition transcodinginfo.cpp:192
std::optional< float > m_framerate
Definition transcodinginfo.h:212
void replaceData(TranscodingInfo &other)
Definition transcodinginfo.cpp:66
void setHeightNull()
Definition transcodinginfo.cpp:273
void setCompletionPercentage(std::optional< double > newCompletionPercentage)
Gets or sets the completion percentage.
Definition transcodinginfo.cpp:240
void setAudioCodec(QString newAudioCodec)
Gets or sets the thread count used for encoding.
Definition transcodinginfo.cpp:163
bool isAudioDirect() const
Gets or sets a value indicating whether the audio is passed through.
Definition transcodinginfo.cpp:206
bool bitrateNull() const
Definition transcodinginfo.cpp:217
std::optional< double > completionPercentage() const
Gets or sets the completion percentage.
Definition transcodinginfo.cpp:238
std::optional< qint32 > m_height
Definition transcodinginfo.h:215
static TranscodingInfo fromJson(QJsonObject source)
Definition transcodinginfo.cpp:82
Definition mediaplayer2.h:20
Contains auto-generated Data Transfer Objects for the Jellyfin HTTP API.
HardwareAccelerationTypeClass::Value HardwareAccelerationType
Definition hardwareaccelerationtype.h:65
Definition accessschedule.h:128
Jellyfin::DTO::TranscodingInfo TranscodingInfo
Definition transcodinginfo.h:230
AccessSchedule fromJsonValue(const QJsonValue &source, convertType< AccessSchedule >)
Definition accessschedule.cpp:133
QJsonValue toJsonValue(const AccessSchedule &source, convertType< AccessSchedule >)
Definition accessschedule.cpp:139
Definition jsonconvimpl.h:45