Commit graph

14 commits

Author SHA1 Message Date
Nathan Fiedler
7a5bd98746 Merge pull request #13 from gadomski/set-option
Add `set_option` method.
2016-08-03 20:34:21 -07:00
Pete Gadomski
eeb014af1f Add set_option method.
This is useful for stuff like setting the loop option for a gif.
2016-08-02 12:01:34 -06:00
Pete Gadomski
b46f8a47ac Add write_images_blob
This method goes down to `MagickGetImagesBlob`, which allows for
creating animated gifs.

I didn't abstract out common operations between the two in the interest
of not overly polluting the codebase. However, this new method is almost
identical to `write_image_blob` so you could probably abstract something
out of there.
2016-08-02 11:35:16 -06:00
Nathan Fiedler
731025764d Fix the tests after the API change 2016-06-25 15:39:36 -07:00
Nathan Fiedler
a5cb97d3cf Correct the rotated image to match expectations
The test image that was meant to be rotated was generated incorrectly.
It now corresponds to the following ImageMagick command:

$ convert in -rotate 90 -orient left-bottom out

cargo test passes
2016-03-29 20:56:58 -07:00
Nathan Fiedler
faebc468ba Detect and correct non-optimal image orientation
cargo test passes
2016-03-29 18:28:33 -07:00
Nathan Fiedler
f115a7a774 Tests now pass on Mac OS X, Ubuntu Linux, and FreeBSD 2016-02-10 17:41:17 -08:00
Nathan Fiedler
61033dbb94 Use cfg! so test passes on FreeBSD 2016-02-03 21:08:02 -08:00
Nathan Fiedler
34c4fec9fe Use canonical tag name for original date 2016-01-02 20:47:38 -08:00
Nathan Fiedler
19377db422 Add get_image_property() to retrieve properties
cargo test passes
2016-01-02 14:31:20 -08:00
Nathan Fiedler
5e091bf488 Add a fit function to resize an image
Given a bounding box defined by the desired width and height, resize the
image to fit that box, maintaining the aspect ratio.

cargo test passes
2015-06-10 21:27:58 -07:00
Nathan Fiedler
56877aaad3 Write image to a vector of bytes (in memory write)
cargo test passes
2015-06-09 22:18:57 -07:00
Nathan Fiedler
78d681608d Read image data from a vector of bytes
cargo test passes
2015-06-09 06:57:56 -07:00
Nathan Fiedler
1781b39863 Basic API in place, some tests working
Reading an image, getting its dimensions, and resizing are working.

cargo test passes
2015-06-08 21:47:17 -07:00