Lines Matching refs:dpd

718 ptp_unpack_DPD (PTPParams *params, unsigned char* data, PTPDevicePropDesc *dpd, unsigned int dpdlen)  in ptp_unpack_DPD()  argument
722 memset (dpd, 0, sizeof(*dpd)); in ptp_unpack_DPD()
723 dpd->DevicePropertyCode=dtoh16a(&data[PTP_dpd_DevicePropertyCode]); in ptp_unpack_DPD()
724 dpd->DataType=dtoh16a(&data[PTP_dpd_DataType]); in ptp_unpack_DPD()
725 dpd->GetSet=dtoh8a(&data[PTP_dpd_GetSet]); in ptp_unpack_DPD()
726 dpd->FormFlag=PTP_DPFF_None; in ptp_unpack_DPD()
729 ret = ptp_unpack_DPV (params, data, &offset, dpdlen, &dpd->FactoryDefaultValue, dpd->DataType); in ptp_unpack_DPD()
731 if ((dpd->DataType == PTP_DTC_STR) && (offset == dpdlen)) in ptp_unpack_DPD()
733 ret = ptp_unpack_DPV (params, data, &offset, dpdlen, &dpd->CurrentValue, dpd->DataType); in ptp_unpack_DPD()
744 dpd->FormFlag=dtoh8a(&data[offset]); in ptp_unpack_DPD()
747 switch (dpd->FormFlag) { in ptp_unpack_DPD()
749 …ret = ptp_unpack_DPV (params, data, &offset, dpdlen, &dpd->FORM.Range.MinimumValue, dpd->DataType); in ptp_unpack_DPD()
751 …ret = ptp_unpack_DPV (params, data, &offset, dpdlen, &dpd->FORM.Range.MaximumValue, dpd->DataType); in ptp_unpack_DPD()
753 ret = ptp_unpack_DPV (params, data, &offset, dpdlen, &dpd->FORM.Range.StepSize, dpd->DataType); in ptp_unpack_DPD()
758 #define N dpd->FORM.Enum.NumberOfValues in ptp_unpack_DPD()
761 dpd->FORM.Enum.SupportedValue = malloc(N*sizeof(dpd->FORM.Enum.SupportedValue[0])); in ptp_unpack_DPD()
762 if (!dpd->FORM.Enum.SupportedValue) in ptp_unpack_DPD()
765 memset (dpd->FORM.Enum.SupportedValue,0 , N*sizeof(dpd->FORM.Enum.SupportedValue[0])); in ptp_unpack_DPD()
767 …ret = ptp_unpack_DPV (params, data, &offset, dpdlen, &dpd->FORM.Enum.SupportedValue[i], dpd->DataT… in ptp_unpack_DPD()
777 dpd->FORM.Enum.NumberOfValues = i; in ptp_unpack_DPD()
786 ptp_free_devicepropdesc(dpd); in ptp_unpack_DPD()
1326 PTPDevicePropDesc *dpd; in ptp_unpack_CANON_changes() local
1336 dpd = &params->canon_props[j].dpd; in ptp_unpack_CANON_changes()
1351 i, propxtype, proptype, dpd->DataType, propxcnt); in ptp_unpack_CANON_changes()
1352 dpd->FormFlag = PTP_DPFF_Enumeration; in ptp_unpack_CANON_changes()
1353 dpd->FORM.Enum.NumberOfValues = propxcnt; in ptp_unpack_CANON_changes()
1354 dpd->FORM.Enum.SupportedValue = malloc (sizeof (PTPPropertyValue)*propxcnt); in ptp_unpack_CANON_changes()
1363 dpd->FORM.Enum.SupportedValue[j].u16 = in ptp_unpack_CANON_changes()
1365 …ptp_debug (params, "event %d: suppval[%d] of %x is 0x%x.", i, j, proptype, dpd->FORM.Enum.Supporte… in ptp_unpack_CANON_changes()
1370 switch (dpd->DataType) { in ptp_unpack_CANON_changes()
1373 dpd->FORM.Enum.SupportedValue[j].TYPE = CONV(data); \ in ptp_unpack_CANON_changes()
1385 …ptp_debug (params ,"event %d: data type 0x%04x of %x unhandled, raw values:", i, dpd->DataType, pr… in ptp_unpack_CANON_changes()
1398 PTPDevicePropDesc *dpd; in ptp_unpack_CANON_changes() local
1420 memset (&params->canon_props[j].dpd,0,sizeof(params->canon_props[j].dpd)); in ptp_unpack_CANON_changes()
1421 params->canon_props[j].dpd.GetSet = 1; in ptp_unpack_CANON_changes()
1422 params->canon_props[j].dpd.FormFlag = PTP_DPFF_None; in ptp_unpack_CANON_changes()
1425 dpd = &params->canon_props[j].dpd; in ptp_unpack_CANON_changes()
1459 dpd->GetSet = PTP_DPGS_Get; in ptp_unpack_CANON_changes()
1478 dpd->DataType = PTP_DTC_UINT32; in ptp_unpack_CANON_changes()
1490 dpd->DataType = PTP_DTC_UINT16; in ptp_unpack_CANON_changes()
1496 dpd->DataType = PTP_DTC_UINT8; in ptp_unpack_CANON_changes()
1503 dpd->DataType = PTP_DTC_STR; in ptp_unpack_CANON_changes()
1507 dpd->DataType = PTP_DTC_INT16; in ptp_unpack_CANON_changes()
1514 dpd->DataType = PTP_DTC_UINT16; in ptp_unpack_CANON_changes()
1530 dpd->DataType = PTP_DTC_UINT8; in ptp_unpack_CANON_changes()
1574 switch (dpd->DataType) { in ptp_unpack_CANON_changes()
1576 dpd->FactoryDefaultValue.u32 = dtoh32a(data); in ptp_unpack_CANON_changes()
1577 dpd->CurrentValue.u32 = dtoh32a(data); in ptp_unpack_CANON_changes()
1578 ptp_debug (params ,"event %d: currentvalue of %x is %x", i, proptype, dpd->CurrentValue.u32); in ptp_unpack_CANON_changes()
1581 dpd->FactoryDefaultValue.u16 = dtoh16a(data); in ptp_unpack_CANON_changes()
1582 dpd->CurrentValue.u16 = dtoh16a(data); in ptp_unpack_CANON_changes()
1583 ptp_debug (params,"event %d: currentvalue of %x is %x", i, proptype, dpd->CurrentValue.u16); in ptp_unpack_CANON_changes()
1586 dpd->FactoryDefaultValue.u8 = dtoh8a(data); in ptp_unpack_CANON_changes()
1587 dpd->CurrentValue.u8 = dtoh8a(data); in ptp_unpack_CANON_changes()
1588 ptp_debug (params,"event %d: currentvalue of %x is %x", i, proptype, dpd->CurrentValue.u8); in ptp_unpack_CANON_changes()
1593 dpd->FactoryDefaultValue.str = ptp_unpack_string(params, data, 0, &len); in ptp_unpack_CANON_changes()
1594 dpd->CurrentValue.str = ptp_unpack_string(params, data, 0, &len); in ptp_unpack_CANON_changes()
1596 dpd->FactoryDefaultValue.str = strdup( (char*)data ); in ptp_unpack_CANON_changes()
1597 dpd->CurrentValue.str = strdup( (char*)data ); in ptp_unpack_CANON_changes()
1599 ptp_debug (params,"event %d: currentvalue of %x is %s", i, proptype, dpd->CurrentValue.str); in ptp_unpack_CANON_changes()
1613 dpd->DataType = PTP_DTC_UINT16; in ptp_unpack_CANON_changes()
1614 dpd->FactoryDefaultValue.u16 = ptp_unpack_EOS_ImageFormat( params, &data ); in ptp_unpack_CANON_changes()
1615 dpd->CurrentValue.u16 = dpd->FactoryDefaultValue.u16; in ptp_unpack_CANON_changes()
1616 ptp_debug (params,"event %d: currentvalue of %x is %x", i, proptype, dpd->CurrentValue.u8); in ptp_unpack_CANON_changes()