aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar reed@android.com <reed@android.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2010-04-13 13:22:54 +0000
committerGravatar reed@android.com <reed@android.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2010-04-13 13:22:54 +0000
commit9aa8b32233702b19b97bebdc2c702e0c53407d45 (patch)
treeeea03a23e226d006ffed89ec0314a3de6a3d7bad /include
parent2687ae05cbd309072f0b5bb9d872d758108a2776 (diff)
add SKIA_VERSION_[MAJOR, MINOR, PATCH] in header and SkGraphics API
git-svn-id: http://skia.googlecode.com/svn/trunk@542 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'include')
-rw-r--r--include/core/SkGraphics.h7
-rw-r--r--include/core/SkTypes.h6
2 files changed, 12 insertions, 1 deletions
diff --git a/include/core/SkGraphics.h b/include/core/SkGraphics.h
index dd5808a225..25c926f4fc 100644
--- a/include/core/SkGraphics.h
+++ b/include/core/SkGraphics.h
@@ -33,7 +33,12 @@ public:
Returns true if some amount was purged from the font cache.
*/
static bool SetFontCacheUsed(size_t usageInBytes);
-
+
+ /** Return the version numbers for the library. If the parameter is not
+ null, it is set to the version number.
+ */
+ static void GetVersion(int32_t* major, int32_t* minor, int32_t* patch);
+
private:
/** This is automatically called by SkGraphics::Init(), and must be
implemented by the host OS. This allows the host OS to register a callback
diff --git a/include/core/SkTypes.h b/include/core/SkTypes.h
index fa21adcb41..1f8ecaaf63 100644
--- a/include/core/SkTypes.h
+++ b/include/core/SkTypes.h
@@ -30,6 +30,12 @@
/** \file SkTypes.h
*/
+/** See SkGraphics::GetVersion() to retrieve these at runtime
+ */
+#define SKIA_VERSION_MAJOR 1
+#define SKIA_VERSION_MINOR 0
+#define SKIA_VERSION_PATCH 0
+
/*
memory wrappers to be implemented by the porting layer (platform)
*/