Krita Source Code Documentation
Loading...
Searching...
No Matches
recorder_const.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2020 Dmitrii Utkin <loentar@gmail.com>
3 *
4 * SPDX-License-Identifier: LGPL-2.1-only
5 */
6
7#ifndef RECORDER_CONST_H
8#define RECORDER_CONST_H
9
10#include <QThread>
11
12class QString;
13class QRegularExpression;
14
15namespace RecorderConst
16{
17
18constexpr int waitThreadTimeoutMs = 5000;
19
20QRegularExpression snapshotFilePatternFor(const QString &extension);
21
22}
23
25{
26const unsigned int MaxThreadCount = QThread::idealThreadCount();
27const unsigned int MaxRecordThreadCount = qMax(static_cast<int>(MaxThreadCount) - 1, 1);
28const unsigned int IdealRecordThreadCount = qMax(static_cast<int>(MaxRecordThreadCount) - 2, 1);
29}
30
31#endif // RECORDER_CONST_H
QRegularExpression snapshotFilePatternFor(const QString &extension)
constexpr int waitThreadTimeoutMs
const unsigned int IdealRecordThreadCount
const unsigned int MaxThreadCount
const unsigned int MaxRecordThreadCount