summaryrefslogtreecommitdiff
path: root/dmagick/Utils.d
diff options
context:
space:
mode:
authorMike Wey2011-02-12 23:34:39 +0100
committerMike Wey2011-02-12 23:34:39 +0100
commitff26b979509498cc5ebd2ab003b6f3e530fdc4c9 (patch)
tree479bc9d94aceeded2fdb0287928f8c8b22133b94 /dmagick/Utils.d
parent2fb8dd6619325608157819478edfe4b3b2a1dc0d (diff)
Update some of the documentation
Diffstat (limited to 'dmagick/Utils.d')
-rw-r--r--dmagick/Utils.d7
1 files changed, 7 insertions, 0 deletions
diff --git a/dmagick/Utils.d b/dmagick/Utils.d
index d5e8ff6..b7ebd33 100644
--- a/dmagick/Utils.d
+++ b/dmagick/Utils.d
@@ -62,11 +62,18 @@ void copyString(ref char* dest, string source)
dest[source.length] = '\0';
}
+/** */
real degreesToRadians(real deg)
{
return deg*PI/180;
}
+
+/**
+ * A template struct ot make pointers to ImageMagick structs
+ * reference counted. Excepts a predicate pred which destroys
+ * the struct pointer when refCount is 0.
+ */
struct RefCounted(alias pred, T)
if ( !is(T == class) && is(typeof(pred(cast(T*)null)) == T*) )
{