Krita Source Code Documentation
Loading...
Searching...
No Matches
kis_my_paint_shade_selector.cpp File Reference
#include "kis_my_paint_shade_selector.h"
#include <cmath>
#include <cstdlib>
#include <QImage>
#include <QColor>
#include <QPainter>
#include <QMouseEvent>
#include <QApplication>
#include <QScreen>
#include <QtGlobal>
#include <QTimer>
#include <kconfig.h>
#include <kconfiggroup.h>
#include <ksharedconfig.h>
#include "KoColorSpace.h"
#include "KoColorSpaceRegistry.h"
#include "KoColor.h"
#include "KoCanvasResourceProvider.h"
#include "kis_paint_device.h"
#include "kis_painter.h"
#include "kis_display_color_converter.h"

Go to the source code of this file.

Functions

int signedSqr (int x)
 
int sqr (int x)
 
qreal sqr2 (qreal x)
 

Function Documentation

◆ signedSqr()

int signedSqr ( int x)
inline

Definition at line 331 of file kis_my_paint_shade_selector.cpp.

331 {
332 int sign = x>0?1:-1;
333 return x*x*sign;
334}

References sign().

◆ sqr()

int sqr ( int x)
inline

Definition at line 323 of file kis_my_paint_shade_selector.cpp.

323 {
324 return x*x;
325}

◆ sqr2()

qreal sqr2 ( qreal x)
inline

Definition at line 327 of file kis_my_paint_shade_selector.cpp.

327 {
328 return (x*x)/2+x/2;
329}