mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-31 21:33:24 +00:00
Read and write desaturation from OSTC3's
This adds missing code to read and write the desaturation factor to and from OSTC3's. Signed-off-by: Anton Lundin <glance@acc.umu.se> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
51a112c8bf
commit
0c4f027386
1 changed files with 8 additions and 0 deletions
|
@ -392,6 +392,10 @@ void ReadSettingsThread::run()
|
|||
rc = hw_ostc3_device_config_read(m_data->device, OSTC3_SATURATION, uData, sizeof(uData));
|
||||
if (rc == DC_STATUS_SUCCESS)
|
||||
m_deviceDetails->setSaturation(uData[0]);
|
||||
//Desaturation
|
||||
rc = hw_ostc3_device_config_read(m_data->device, OSTC3_DESATURATION, uData, sizeof(uData));
|
||||
if (rc == DC_STATUS_SUCCESS)
|
||||
m_deviceDetails->setDesaturation(uData[0]);
|
||||
//LastDeco
|
||||
rc = hw_ostc3_device_config_read(m_data->device, OSTC3_LAST_DECO, uData, sizeof(uData));
|
||||
if (rc == DC_STATUS_SUCCESS)
|
||||
|
@ -628,6 +632,10 @@ void WriteSettingsThread::run()
|
|||
data[0] = m_deviceDetails->saturation();
|
||||
hw_ostc3_device_config_write(m_data->device, OSTC3_SATURATION, data, sizeof(data));
|
||||
|
||||
//desaturation
|
||||
data[0] = m_deviceDetails->desaturation();
|
||||
hw_ostc3_device_config_write(m_data->device, OSTC3_DESATURATION, data, sizeof(data));
|
||||
|
||||
//last deco
|
||||
data[0] = m_deviceDetails->lastDeco();
|
||||
hw_ostc3_device_config_write(m_data->device, OSTC3_LAST_DECO, data, sizeof(data));
|
||||
|
|
Loading…
Add table
Reference in a new issue