ICCReader

master

Swift definitions for structures, enumerations and functions defined in the [ICC Profile Format Specification]
hughbe/ICCReader

ICCReader

Swift library for reading ICC color profiles defined in the the ICC Profile Format Specification.

Example Usage

Add the following line to your project's SwiftPM dependencies:

.package(url: "https://github.com/hughbe/ICCReader", from: "1.0.0"),
import ICCReader

let data = Data(contentsOfFile: "<path-to-file>.icm")!
let profile = try ICCColorProfile(data: data)

// Dump all the tags.
for tag in profile.tags {
    print(tag.signature)
    print(tag.type)
    print(tag.data)
}

// Print known tags (e.g. copyright)
print(profile.getTag(signature: "cprt"))
print(profile.getTag(signature: ICCTagSignature.copyright))
print(profile.copyright)

Description

  • Swift Tools 5.3.0
View More Packages from this Author

Dependencies

Last updated: Wed Oct 23 2024 10:22:40 GMT-0900 (Hawaii-Aleutian Daylight Time)