diff options
author | Daniel Schulte <trilader@schroedingers-bit.net> | 2021-04-19 13:32:42 +0200 |
---|---|---|
committer | Marcus Meissner <meissner@suse.de> | 2021-04-19 15:47:24 +0200 |
commit | ff6013baab350ed6a93b8ae673fadb41d3aece23 (patch) | |
tree | 6b1220f60c86464312ae65f55113ddf0cf32f65a /camlibs | |
parent | 84eb49d0f8c4adb15a9651d01425de67bf95f811 (diff) | |
download | libgphoto2-ff6013baab350ed6a93b8ae673fadb41d3aece23.tar.gz |
camlibs/ptp2: Unpack Canon EOS changes for INT32 properties
This datatype was missing in the change event unpacking code which caused the WhiteBalanceAdjust{A,B} properties to always read as 0 even though a different value was set on the camera.
Currently WhiteBalanceAdjust{A,B} are the only INT32 properties on Canon cameras.
Diffstat (limited to 'camlibs')
-rw-r--r-- | camlibs/ptp2/ptp-pack.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/camlibs/ptp2/ptp-pack.c b/camlibs/ptp2/ptp-pack.c index 26465efa3..31be53bb2 100644 --- a/camlibs/ptp2/ptp-pack.c +++ b/camlibs/ptp2/ptp-pack.c @@ -2422,6 +2422,11 @@ ptp_unpack_CANON_changes (PTPParams *params, unsigned char* data, unsigned int d break; } switch (dpd->DataType) { + case PTP_DTC_INT32: + dpd->FactoryDefaultValue.i32 = dtoh32a(xdata); + dpd->CurrentValue.i32 = dtoh32a(xdata); + ptp_debug (params ,"event %d: currentvalue of %x is %x", i, proptype, dpd->CurrentValue.i32); + break; case PTP_DTC_UINT32: dpd->FactoryDefaultValue.u32 = dtoh32a(xdata); dpd->CurrentValue.u32 = dtoh32a(xdata); |