#825 added printPressure for panasonic makernotes to display hPa values or infinite when value is 65535 for Exif field 0x0086
This commit is contained in:
parent
3706233c8d
commit
bf56bbf7fa
@ -511,7 +511,7 @@ namespace Exiv2 {
|
||||
TagInfo(0x0079, "IntelligentDRange", N_("Intelligent Dynamic Range"), N_("Intelligent Dynamic Range"), panasonicId, makerTags, unsignedShort, -1, EXV_PRINT_TAG(panasonicIntelligentDRange)),
|
||||
TagInfo(0x007c, "ClearRetouch", N_("Clear Retouch"), N_("Clear Retouch"), panasonicId, makerTags, unsignedShort, -1, EXV_PRINT_TAG(panasonicClearRetouch)),
|
||||
TagInfo(0x0080, "City2", N_("City2"), N_("City2"), panasonicId, makerTags, undefined, -1, printPanasonicText),
|
||||
TagInfo(0x0086, "ManometerPressure", N_("Manometer Pressure"), N_("Manometer pressure"), panasonicId, makerTags, unsignedShort, -1, printValue),
|
||||
TagInfo(0x0086, "ManometerPressure", N_("Manometer Pressure"), N_("Manometer pressure"), panasonicId, makerTags, unsignedShort, -1, printPressure),
|
||||
TagInfo(0x0089, "PhotoStyle", N_("Photo style"), N_("Photo style"), panasonicId, makerTags, unsignedShort, -1, EXV_PRINT_TAG(panasonicPhotoStyle)),
|
||||
TagInfo(0x008a, "ShadingCompensation", N_("Shading Compensation"), N_("Shading Compensation"), panasonicId, makerTags, unsignedShort, -1, EXV_PRINT_TAG(panasonicShadingCompensation)),
|
||||
TagInfo(0x008c, "AccelerometerZ", N_("Accelerometer Z"), N_("positive is acceleration upwards"), panasonicId, makerTags, unsignedShort, -1, printAccelerometer),
|
||||
@ -685,6 +685,21 @@ namespace Exiv2 {
|
||||
};
|
||||
} // PanasonicMakerNote::printPanasonicText
|
||||
|
||||
// Manometer Pressure
|
||||
std::ostream& PanasonicMakerNote::printPressure(std::ostream& os, const Value& value, const ExifData*)
|
||||
{
|
||||
switch(value.toLong())
|
||||
{
|
||||
case 65535:
|
||||
os << N_("infinite");
|
||||
break;
|
||||
default:
|
||||
os << value << N_(" hPa");
|
||||
break;
|
||||
};
|
||||
return os;
|
||||
} // PanasonicMakerNote::printPressure
|
||||
|
||||
std::ostream& PanasonicMakerNote::printAccelerometer(std::ostream& os, const Value& value, const ExifData*)
|
||||
{
|
||||
// value is stored as unsigned int, but should be readed as signed int, so manually convert it
|
||||
|
||||
@ -73,6 +73,8 @@ namespace Exiv2 {
|
||||
static std::ostream& print0x0036(std::ostream& os, const Value& value, const ExifData*);
|
||||
//! Print ISO
|
||||
static std::ostream& print0x003c(std::ostream& os, const Value& value, const ExifData*);
|
||||
//! Print Manometer Pressure
|
||||
static std::ostream& printPressure(std::ostream& os, const Value& value, const ExifData*);
|
||||
//! Print special text values: title, landmark, county and so on
|
||||
static std::ostream& printPanasonicText(std::ostream& os, const Value& value, const ExifData*);
|
||||
//! Print accerometer readings
|
||||
|
||||
Loading…
Reference in New Issue
Block a user