解决色调曲线灰度和彩色分别保存异常的问题

This commit is contained in:
yangjiaxuan 2023-08-11 16:44:18 +08:00
parent c145842d92
commit 72758246f5
1 changed files with 50 additions and 46 deletions

View File

@ -1397,6 +1397,8 @@ void hg_settingdialog::slot_gammaButtonClicked()
setPicClrTool dlg(colorMode, this);
if (1 == colorMode)
{
QList<QPoint> grayKeyTable;
for (int i = 0; i < m_gammaData.count[GAMMA_INDEX_GRAY]; ++i)
{
@ -1409,7 +1411,9 @@ void hg_settingdialog::slot_gammaButtonClicked()
{
dlg.setGrayKeyTable(grayKeyTable);
}
}
else if (0 == colorMode)
{
QList<QPoint> colorKeyTable;
for (int i = 0; i < m_gammaData.count[GAMMA_INDEX_COLOR]; ++i)
{
@ -1451,6 +1455,7 @@ void hg_settingdialog::slot_gammaButtonClicked()
keyTableList.append(bKeyTable);
dlg.setRGBKeyTable(keyTableList);
}
}
int rgbTypeIndex = 0;
rgbTypeIndex = m_gammaData.app_data & 0x0F;
@ -1460,7 +1465,6 @@ void hg_settingdialog::slot_gammaButtonClicked()
dlg.setRgbAndColorType(rgbTypeIndex, colorTypeIndex);
if (dlg.exec())
{
memset(&m_gammaData, 0, sizeof(m_gammaData));
clicked_gamma_ = true;
if (1 == colorMode)