Bug #539

Cannot add XMP properties in a custom namespace

Added by Andreas Huggel about 9 years ago. Updated over 8 years ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:Andreas Huggel% Done:

0%

Category:xmp
Target version:0.17

Description

Vladimir Nadvornik reported:

Is this supposed to work? It gives me 'No namespace info available for
XMP prefix `ns'' exception.

Exiv2::XmpData xmpData;

Exiv2::XmpProperties::registerNs("myNamespace/", "ns");
xmpData["Xmp.ns.test"] = "myvalue";

std::string xmpPacket;
if (0 != Exiv2::XmpParser::encode(xmpPacket, xmpData)) {
throw Exiv2::Error(1, "Failed to serialize XMP data");
}
std::cout << xmpPacket << "\n";

History

Also available in: Atom PDF

Redmine Appliance - Powered by TurnKey Linux