Krita Source Code Documentation
Loading...
Searching...
No Matches
KisFrameRateLimitModel.cpp File Reference
#include "KisFrameRateLimitModel.h"
#include <lager/lenses/tuple.hpp>
#include <lager/constant.hpp>
#include <KisLager.h>
#include <kis_assert.h>
#include <QGuiApplication>
#include <QScreen>

Go to the source code of this file.

Functions

 LAGER_QT (frameRate)
 
 LAGER_QT (frameRateState)
 

Variables

auto frameRateLens
 

Function Documentation

◆ LAGER_QT() [1/2]

LAGER_QT ( frameRate )

Definition at line 41 of file KisFrameRateLimitModel.cpp.

41{data.zoom(frameRateLens)}
auto frameRateLens

References frameRateLens.

◆ LAGER_QT() [2/2]

LAGER_QT ( frameRateState )

Definition at line 42 of file KisFrameRateLimitModel.cpp.

42 {
43 lager::with(LAGER_QT(frameRate),
44 lager::make_constant(1),
45 lager::make_constant(300),
46 LAGER_QT(detectFrameRate).map(std::logical_not<>{}))
48 }
LAGER_QT(frameRate)

References LAGER_QT().

Variable Documentation

◆ frameRateLens

auto frameRateLens
Initial value:
= lager::lenses::getset(
[](const KisFrameRateLimitModel::Data &x) -> int { return std::get<bool>(x) ? calculateMaxScreenFrameRate() : std::get<int>(x); },
if (!std::get<bool>(x)) {
std::get<int>(x) = frameRate;
}
return x;
})
VertexDescriptor get(PredecessorMap const &m, VertexDescriptor v)
std::tuple< bool, int > Data

Definition at line 29 of file KisFrameRateLimitModel.cpp.