Chilkat
HOME
Android™
ASP
Visual Basic
VB.NET
C#
iOS (IPhone)
Objective-C
C++
C
MFC
Delphi
FoxPro
Java
Perl
PHP Extension
PHP ActiveX
Python
PowerShell
Ruby
SQL Server
VBScript
Remove One XMP from Image File with Multiple Embedded XMPsDownloads: MS Windows Visual C/C++ Libraries Linux/CentOS C/C++ Libraries MAC OS X C/C++ Libraries Solaris C/C++ Libraries C++ Builder Libraries C++ XMP sample code to remove individual XMP docs from an image file containing multiple XMPs
void XmpRemoveOneXmp(void)
{
// In the case where a JPG or TIFF image file contains multiple
// XMP documents, it is possible to remove one or more by index
CkXmp xmp;
xmp.UnlockComponent("anything for 30-day trial");
bool success = xmp.LoadAppFile("AgencyPhotographer-Example.jpg");
if (!success)
{
xmp.SaveLastError("lastError.txt");
return;
}
// Assume the JPG has 2 or more embedded XMPs.
// Remove the 2nd XMP document (the 1st XMP doc is at index 0).
xmp.RemoveEmbedded(1);
xmp.SaveAppFile("out.jpg");
return;
}
|
© 2000-2010 Chilkat Software, Inc. All Rights Reserved.