5#include "BlendingFactory.h"
9#include "BlendingAlgorithms.h"
10#include "blendings/SunLightBlending.h"
15void BlendingFactory::setLevelZeroLayout(
int levelZeroColumns,
int levelZeroRows)
17 m_sunLightBlending->setLevelZeroLayout(levelZeroColumns, levelZeroRows);
20Blending
const *BlendingFactory::findBlending(
QString const &name)
const
25 Blending
const *
const result = m_blendings.
value(name,
nullptr);
27 qWarning() <<
"Unknown blending" <<
name <<
"specified in .dgml file. Please fix the .dgml file.";
31BlendingFactory::BlendingFactory(
const SunLocator *sunLocator)
32 : m_sunLightBlending(new SunLightBlending(sunLocator))
34 m_blendings.insert(QStringLiteral(
"OverpaintBlending"),
new OverpaintBlending);
37 m_blendings.insert(QStringLiteral(
"AllanonBlending"),
new AllanonBlending);
38 m_blendings.insert(QStringLiteral(
"ArcusTangentBlending"),
new ArcusTangentBlending);
39 m_blendings.insert(QStringLiteral(
"GeometricMeanBlending"),
new GeometricMeanBlending);
40 m_blendings.insert(QStringLiteral(
"LinearLightBlending"),
new LinearLightBlending);
42 m_blendings.insert(QStringLiteral(
"OverlayBlending"),
new OverlayBlending);
47 m_blendings.insert(QStringLiteral(
"AlphaBlending"),
new OverpaintBlending);
48 m_blendings.insert(QStringLiteral(
"ColorBurnBlending"),
new ColorBurnBlending);
49 m_blendings.insert(QStringLiteral(
"DarkBlending"),
new DarkBlending);
50 m_blendings.insert(QStringLiteral(
"DarkenBlending"),
new DarkenBlending);
51 m_blendings.insert(QStringLiteral(
"DivideBlending"),
new DivideBlending);
52 m_blendings.insert(QStringLiteral(
"GammaDarkBlending"),
new GammaDarkBlending);
53 m_blendings.insert(QStringLiteral(
"LinearBurnBlending"),
new LinearBurnBlending);
54 m_blendings.insert(QStringLiteral(
"MultiplyBlending"),
new MultiplyBlending);
55 m_blendings.insert(QStringLiteral(
"SubtractiveBlending"),
new SubtractiveBlending);
58 m_blendings.insert(QStringLiteral(
"AdditiveBlending"),
new AdditiveBlending);
59 m_blendings.insert(QStringLiteral(
"ColorDodgeBlending"),
new ColorDodgeBlending);
60 m_blendings.insert(QStringLiteral(
"GammaLightBlending"),
new GammaLightBlending);
61 m_blendings.insert(QStringLiteral(
"HardLightBlending"),
new HardLightBlending);
62 m_blendings.insert(QStringLiteral(
"LightBlending"),
new LightBlending);
63 m_blendings.insert(QStringLiteral(
"LightenBlending"),
new LightenBlending);
64 m_blendings.insert(QStringLiteral(
"PinLightBlending"),
new PinLightBlending);
65 m_blendings.insert(QStringLiteral(
"ScreenBlending"),
new ScreenBlending);
66 m_blendings.insert(QStringLiteral(
"SoftLightBlending"),
new SoftLightBlending);
67 m_blendings.insert(QStringLiteral(
"VividLightBlending"),
new VividLightBlending);
71 m_blendings.insert(QStringLiteral(
"BleachBlending"),
new BleachBlending);
72 m_blendings.insert(QStringLiteral(
"DifferenceBlending"),
new DifferenceBlending);
73 m_blendings.insert(QStringLiteral(
"EquivalenceBlending"),
new EquivalenceBlending);
74 m_blendings.insert(QStringLiteral(
"HalfDifferenceBlending"),
new HalfDifferenceBlending);
77 m_blendings.insert(QStringLiteral(
"CloudsBlending"),
new CloudsBlending);
78 m_blendings.insert(QStringLiteral(
"SunLightBlending"), m_sunLightBlending);
79 m_blendings.insert(QStringLiteral(
"GrayscaleBlending"),
new GrayscaleBlending);
80 m_blendings.insert(QStringLiteral(
"InvertColorBlending"),
new InvertColorBlending);
81 m_blendings.insert(QStringLiteral(
"InvertHueBlending"),
new InvertHueBlending);
84BlendingFactory::~BlendingFactory()
86 m_blendings.remove(QStringLiteral(
"SunLightBlending"));
87 delete m_sunLightBlending;
88 qDeleteAll(m_blendings);
QString name(GameStandardAction id)
Binds a QML item to a specific geodetic location in screen coordinates.
T value(const Key &key) const const
bool isEmpty() const const