Moving to DM SDK 4.x

DM SDK is available as a redistributable XCFramework instead of a framework. Developers upgrading from version 2.x will need to do some reconfiguration for existing projects using DM SDK 3.x before upgrading to 4.x. Those who are upgrading from v3.x have no additional reconfiguration requirements.

Removing DM SDK 3.x

The first step in moving to DM SDK 4.x is to remove DM SDK 3.x from your project. Uninstall DM SDK 3.x Guide details how to remove DM SDK 3.x from your project.

Xcode automatically strips out unrelated architectures in an xcframework.

Adding DM SDK 4

Refer to the Installation Guide to add the DM SDK 4 framework, necessary dependencies, and your license Key to your project.

License Key

DM SDK is initialized with a license key. To get a license key, see Get a License Key.

In older versions of DM SDK, a Resolver was initialized with a Digimarc-provided username and password. Starting with DM SDK 3, the developer provides a license key which is used for authentication with a Resolver service, in addition to trial and commercial licensing.

Custom service URLs have been removed. If your application was using a custom resolver URL, that functionality is provided as part of your license key. Contact Digimarc for more information.

DM SDK Is Provided as an Xcframework with Support for More Apple Platforms

DM SDK 4 is provided as an XCFramework, which is Apple’s preferred packaging for framework distribution. This makes it easier for developers to build DM SDK-enabled applications using tools like Swift UI for multiple devices. Existing frameworks like UIKit and AppKit are also supported.

See the DM SDK Minimum Requirements for information about supported platforms.

The additional platforms have increased the file size of the DM SDK developer package. Xcode will automatically strip out any platforms not used by your build, so these additional platforms will not increase the size of your existing application once built. We’ve found that DM SDK adds only several megabytes to an application’s size on disk.

Digimarc digital watermark for print and product packaging detection works best with an autofocus-capable 1080p camera or better. We are still evaluating support for this feature with devices such as built in MacBook cameras. Built in cameras on iOS devices are still fully supported.

We’d like to know more about how developers are using DM SDK on platforms beyond iOS. Contact Digimarc with any questions or feedback on this feature.

Failable Initializers

The initializers for some classes provide an error to provide feedback if an API key or a set of options aren’t compatible. The following classes’ initializers return/throw errors:

  • DMSImageReader
  • DMSVideoCaptureReader
  • DMSAudioReader
  • DMSAudioCaptureReader
  • DMSResolver

These initializers follow standard NSError convention in Obj-C and are throwable in Swift.

Payload Representation Changes

Representation values are provided as a best-fit type and aren’t always strings. For examples, dates are provided as Date/NSDate, and weights are provided as numbers. See the documentation on Representation types for more information.

GS1 Data String Parsing

GS1-conforming data can be retrieved through a Payload’s GS1Attributes property. This property is a dictionary that is keyed by GS1 AIs as strings.

The values in this dictionary are strings that conform to the GS1 encoding for their AI. Unlike representations, these values are not parsed and are ideal for applications that work best with standard GS1 data and types.

Options Parameters Are Required

Option dictionary parameters are not optional. Include an options dictionary where required. If no options are needed, pass an empty dictionary. In Swift, the options parameter can be omitted instead of passing an empty dictionary.