[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: koffice/krita/image
From: Cyrille Berger <cyb () lepi ! org>
Date: 2010-03-13 14:43:22
Message-ID: 1268491402.258238.31445.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 1102760 by berger:
fix the fade of the autobrush being divided by two until it reaches 0
M +4 -15 kis_base_mask_generator.cpp
M +0 -1 kis_base_mask_generator.h
--- trunk/koffice/krita/image/kis_base_mask_generator.cpp #1102759:1102760
@@ -25,17 +25,6 @@
#include "kis_circle_mask_generator.h"
#include "kis_rect_mask_generator.h"
-KisMaskGenerator::KisMaskGenerator(double width, double height, double fh, double \
fv, Type type) : d(new Private)
-{
- d->m_radius = width;
- d->m_ratio = height / width;
- d->m_fh = 2.0 * fh / width;
- d->m_fv = 2.0 * fv / height;
- d->m_spikes = 2;
- d->type = type;
- init();
-}
-
KisMaskGenerator::KisMaskGenerator(double radius, double ratio, double fh, double \
fv, int spikes, Type type) : d(new Private) {
d->m_radius = radius;
@@ -64,8 +53,8 @@
Q_UNUSED(doc);
e.setAttribute("radius", d->m_radius);
e.setAttribute("ratio", d->m_ratio);
- e.setAttribute("hfade", d->m_fh * 2); // 'cause in init we divide it again
- e.setAttribute("vfade", d->m_fv * 2); // 'cause in init we divide it again
+ e.setAttribute("hfade", horizontalFade());
+ e.setAttribute("vfade", verticalFade());
e.setAttribute("spikes", d->m_spikes);
}
@@ -111,12 +100,12 @@
qreal KisMaskGenerator::horizontalFade() const
{
- return d->m_fh;
+ return 2.0 * d->m_fh; // 'cause in init we divide it again
}
qreal KisMaskGenerator::verticalFade() const
{
- return d->m_fv;
+ return 2.0 * d->m_fv; // 'cause in init we divide it again
}
int KisMaskGenerator::spikes() const
--- trunk/koffice/krita/image/kis_base_mask_generator.h #1102759:1102760
@@ -37,7 +37,6 @@
};
public:
- KDE_DEPRECATED KisMaskGenerator(qreal width, qreal height, qreal fh, qreal fv, \
Type type); /**
* This function creates an auto brush shape with the following value :
* @param w width
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic