diff options
| author | Mike Wey | 2011-09-17 17:46:28 +0200 |
|---|---|---|
| committer | Mike Wey | 2011-09-17 17:46:28 +0200 |
| commit | 9d2ddc506ef3ad96a545539ef56cb3a3c9033cc4 (patch) | |
| tree | 12c22727e849b1e6a5c88369f15af1fd2e0598e7 /dmagick/Image.d | |
| parent | 3535eb0887b805ce8e4538b3e91c290fbb596006 (diff) | |
Add animationDelay, animationIterrations, avarage, clone and display.
Diffstat (limited to 'dmagick/Image.d')
| -rw-r--r-- | dmagick/Image.d | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/dmagick/Image.d b/dmagick/Image.d index c191a2b..f449011 100644 --- a/dmagick/Image.d +++ b/dmagick/Image.d @@ -12,6 +12,7 @@ import std.string; import std.typecons : Tuple; import core.memory; import core.runtime; +import core.time; import core.stdc.string; import core.sys.posix.sys.types; @@ -3076,18 +3077,17 @@ class Image } /** - * Number of ticks which must expire before displaying the - * next image in an animated sequence. The default number - * of ticks is 0. By default there are 100 ticks per second. + * Number time which must expire before displaying the + * next image in an animated sequence. */ - void animationDelay(ushort delay) + void animationDelay(Duration delay) { - imageRef.delay = delay; + imageRef.delay = delay.total!"seconds"() * imageRef.ticks_per_second; } ///ditto - ushort annimationDelay() const + Duration annimationDelay() const { - return cast(ushort)imageRef.delay; + return dur!"seconds"(imageRef.delay * imageRef.ticks_per_second); } /** |
