Krita Source Code Documentation
Loading...
Searching...
No Matches
RecorderConfig Class Reference

#include <recorder_config.h>

Public Member Functions

double captureInterval () const
 
int compression () const
 
bool focusedRecord () const
 
RecorderFormat format () const
 
int quality () const
 
bool realTimeCaptureMode () const
 
bool recordAutomatically () const
 
 RecorderConfig (bool readOnly)
 
bool recordIsolateLayerMode () const
 
int resolution () const
 
void setCaptureInterval (double value)
 
void setCompression (int value)
 
void setFocusedRecord (bool value)
 
void setFormat (RecorderFormat value)
 
void setQuality (int value)
 
void setRealTimeCaptureMode (bool value)
 
void setRecordAutomatically (bool value)
 
void setRecordIsolateLayerMode (bool value)
 
void setResolution (int value)
 
void setSnapshotDirectory (const QString &value)
 
void setThreads (int value)
 
QString snapshotDirectory () const
 
int threads () const
 
 ~RecorderConfig ()
 

Private Attributes

KisConfig * config
 

Detailed Description

Definition at line 16 of file recorder_config.h.

Constructor & Destructor Documentation

◆ RecorderConfig()

RecorderConfig::RecorderConfig ( bool readOnly)

Definition at line 30 of file recorder_config.cpp.

31 : config(new KisConfig(readOnly))
32{
33}
KisConfig * config

◆ ~RecorderConfig()

RecorderConfig::~RecorderConfig ( )

Definition at line 35 of file recorder_config.cpp.

36{
37 delete config;
38}

References config.

Member Function Documentation

◆ captureInterval()

double RecorderConfig::captureInterval ( ) const

Definition at line 59 of file recorder_config.cpp.

60{
61 return config->readEntry(keyCaptureInterval, 1.);
62}
T readEntry(const QString &name, const T &defaultValue=T())
Definition kis_config.h:914

References config, and KisConfig::readEntry().

◆ compression()

int RecorderConfig::compression ( ) const

Definition at line 92 of file recorder_config.cpp.

93{
94 return config->readEntry(keyCompression, 1);
95}

References config, and KisConfig::readEntry().

◆ focusedRecord()

bool RecorderConfig::focusedRecord ( ) const

Definition at line 152 of file recorder_config.cpp.

153{
154 return config->readEntry(keyFocusedRecording, false);
155}

References config, and KisConfig::readEntry().

◆ format()

RecorderFormat RecorderConfig::format ( ) const

Definition at line 70 of file recorder_config.cpp.

71{
72 return static_cast<RecorderFormat>(config->readEntry(keyFormat, static_cast<int>(RecorderFormat::JPEG)));
73}
RecorderFormat

References config, JPEG, and KisConfig::readEntry().

◆ quality()

int RecorderConfig::quality ( ) const

Definition at line 81 of file recorder_config.cpp.

82{
83 return config->readEntry(keyQuality, 80);
84}

References config, and KisConfig::readEntry().

◆ realTimeCaptureMode()

bool RecorderConfig::realTimeCaptureMode ( ) const

Definition at line 123 of file recorder_config.cpp.

124{
125 return config->readEntry(keyRealTimeCaptureMode, false);
126}

References config, and KisConfig::readEntry().

◆ recordAutomatically()

bool RecorderConfig::recordAutomatically ( ) const

Definition at line 142 of file recorder_config.cpp.

143{
144 return config->readEntry(keyRecordAutomatically, false);
145}

References config, and KisConfig::readEntry().

◆ recordIsolateLayerMode()

bool RecorderConfig::recordIsolateLayerMode ( ) const

Definition at line 132 of file recorder_config.cpp.

133{
134 return config->readEntry(keyRecordIsolateLayerMode, false);
135}

References config, and KisConfig::readEntry().

◆ resolution()

int RecorderConfig::resolution ( ) const

Definition at line 103 of file recorder_config.cpp.

104{
105 return config->readEntry(keyResolution, 0);
106}

References config, and KisConfig::readEntry().

◆ setCaptureInterval()

void RecorderConfig::setCaptureInterval ( double value)

Definition at line 64 of file recorder_config.cpp.

65{
66 config->writeEntry(keyCaptureInterval, value);
67}
float value(const T *src, size_t ch)
void writeEntry(const QString &name, const T &value)
Definition kis_config.h:904

References config, value(), and KisConfig::writeEntry().

◆ setCompression()

void RecorderConfig::setCompression ( int value)

Definition at line 97 of file recorder_config.cpp.

98{
99 config->writeEntry(keyCompression, value);
100}

References config, value(), and KisConfig::writeEntry().

◆ setFocusedRecord()

void RecorderConfig::setFocusedRecord ( bool value)

Definition at line 157 of file recorder_config.cpp.

158{
159 return config->writeEntry(keyFocusedRecording, value);
160}

References config, value(), and KisConfig::writeEntry().

◆ setFormat()

void RecorderConfig::setFormat ( RecorderFormat value)

Definition at line 75 of file recorder_config.cpp.

76{
77 return config->writeEntry(keyFormat, static_cast<int>(value));
78}

References config, value(), and KisConfig::writeEntry().

◆ setQuality()

void RecorderConfig::setQuality ( int value)

Definition at line 86 of file recorder_config.cpp.

87{
88 config->writeEntry(keyQuality, value);
89}

References config, value(), and KisConfig::writeEntry().

◆ setRealTimeCaptureMode()

void RecorderConfig::setRealTimeCaptureMode ( bool value)

Definition at line 127 of file recorder_config.cpp.

128{
129 config->writeEntry(keyRealTimeCaptureMode, value);
130}

References config, value(), and KisConfig::writeEntry().

◆ setRecordAutomatically()

void RecorderConfig::setRecordAutomatically ( bool value)

Definition at line 147 of file recorder_config.cpp.

148{
149 config->writeEntry(keyRecordAutomatically, value);
150}

References config, value(), and KisConfig::writeEntry().

◆ setRecordIsolateLayerMode()

void RecorderConfig::setRecordIsolateLayerMode ( bool value)

Definition at line 137 of file recorder_config.cpp.

138{
139 config->writeEntry(keyRecordIsolateLayerMode, value);
140}

References config, value(), and KisConfig::writeEntry().

◆ setResolution()

void RecorderConfig::setResolution ( int value)

Definition at line 108 of file recorder_config.cpp.

109{
110 config->writeEntry(keyResolution, value);
111}

References config, value(), and KisConfig::writeEntry().

◆ setSnapshotDirectory()

void RecorderConfig::setSnapshotDirectory ( const QString & value)

Definition at line 53 of file recorder_config.cpp.

54{
55 config->writeEntry(keySnapshotDirectory, value);
56}

References config, value(), and KisConfig::writeEntry().

◆ setThreads()

void RecorderConfig::setThreads ( int value)

Definition at line 118 of file recorder_config.cpp.

119{
120 config->writeEntry(keyThreads, value);
121}

References config, value(), and KisConfig::writeEntry().

◆ snapshotDirectory()

QString RecorderConfig::snapshotDirectory ( ) const

Definition at line 41 of file recorder_config.cpp.

42{
43 // On Android, there's no user-visible directory we can write to, so we
44 // default to nothing here.
45#ifdef Q_OS_ANDROID
46 const QString defaultValue;
47#else
48 const QString &defaultValue = defaultSnapshotDirectory;
49#endif
50 return config->readEntry(keySnapshotDirectory, defaultValue);
51}

References config, and KisConfig::readEntry().

◆ threads()

int RecorderConfig::threads ( ) const

Definition at line 113 of file recorder_config.cpp.

114{
115 return config->readEntry(keyThreads, 1);
116}

References config, and KisConfig::readEntry().

Member Data Documentation

◆ config

KisConfig* RecorderConfig::config
mutableprivate

Definition at line 68 of file recorder_config.h.


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