<description>Color curves adjustment</description>
<author>Till Theato, Maksim Golovkin</author>
- <parameter type="list" name="Channel" default="0" paramlist="0,1,2,3" paramlistdisplay="Red,Green,Blue,Luma">
+ <parameter type="list" name="Channel" default="0.5" paramlist="0.5,0,0.1,0.2,0.3,0.4" paramlistdisplay="RGB,Red,Green,Blue,Alpha,Luma">
<name>Channel</name>
</parameter>
BezierSplineWidget::BezierSplineWidget(const QString& spline, QWidget* parent) :
QWidget(parent),
- m_mode(ModeRed)
+ m_mode(ModeRGB)
{
QVBoxLayout *layout = new QVBoxLayout(this);
layout->addWidget(&m_edit);
{
m_showPixmap = show;
KdenliveSettings::setBezier_showpixmap(show);
- if (show)
- m_edit.setPixmap(QPixmap::fromImage(ColorTools::rgbCurvePlane(m_edit.size(), (ColorTools::ColorsRGB)((int)m_mode), 0.8)));
+ if (show && m_mode != ModeAlpha && m_mode != ModeRGB)
+ m_edit.setPixmap(QPixmap::fromImage(ColorTools::rgbCurvePlane(m_edit.size(), (ColorTools::ColorsRGB)((int)(m_mode == ModeLuma ? 3 : m_mode)), 0.8)));
else
m_edit.setPixmap(QPixmap());
}
QString spline();
- enum CurveModes { ModeRed, ModeGreen, ModeBlue, ModeLuma };
+ enum CurveModes { ModeRed, ModeGreen, ModeBlue, ModeAlpha, ModeLuma, ModeRGB };
void setMode(CurveModes mode);
private slots:
} else if (type == "bezier_spline") {
BezierSplineWidget *widget = (BezierSplineWidget*)m_valueItems[name];
if (widget) {
- widget->setMode((BezierSplineWidget::CurveModes)value.toInt());
+ widget->setMode((BezierSplineWidget::CurveModes)((int)(value.toDouble() * 10)));
}
}
}