Skip to content
This repository has been archived by the owner on Sep 10, 2024. It is now read-only.

novi/SwiftMagickWand

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SwiftMagickWand

MagickWand(ImageMagick) wrapper for Swift

Sample

import SwiftMagickWand

Wand.genesis()

// https://en.wikipedia.org/wiki/Pikachu
let inputImage = NSData(contentsOfFile: "025Pikachu.png")!

let inputBytes = Array(UnsafeBufferPointer(start: UnsafePointer<UInt8>(inputImage.bytes), count: inputImage.length))

let wand = Wand(imageBytes: inputBytes)

wand.resize(80, h: 80)

let out = wand.getImageBytes()

let outData = NSData(bytes: out, length: out.count)

outData.writeToFile("/tmp/pikachu_resized.png", atomically: false)

About

MagickWand(ImageMagick) wrapper for Swift

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published