Index: include/core/SkTraceMemoryDump.h |
diff --git a/include/core/SkTraceMemoryDump.h b/include/core/SkTraceMemoryDump.h |
index d7c565f5707b1ed455b6f1d0be5471636f1a38c3..3e34bdf92a0b0acd14ea998138f06ab6beb84475 100644 |
--- a/include/core/SkTraceMemoryDump.h |
+++ b/include/core/SkTraceMemoryDump.h |
@@ -20,6 +20,17 @@ class SkDiscardableMemory; |
class SK_API SkTraceMemoryDump { |
public: |
/** |
+ * Enum to specify the level of the requested details for the dump from the Skia objects. |
+ */ |
+ enum LevelOfDetails { |
+ // Dump only the minimal details to get the total memory usage (Usually just the totals). |
+ kLightDumpRequest, |
Primiano Tucci (use gerrit)
2015/09/24 13:10:27
Remove rquest from the name. Doesn't tell anything
ssid
2015/09/24 13:18:49
I didn't want to make it enum class. So, making it
|
+ |
+ // Dump all the details about the memory usage of the caches. |
+ kDetailedDumpRequest |
+ }; |
+ |
+ /** |
* Appends a new memory dump (i.e. a row) to the trace memory infrastructure. |
* If dumpName does not exist yet, a new one is created. Otherwise, a new column is appended to |
* the previously created dump. |
@@ -55,6 +66,13 @@ public: |
const char* dumpName, |
const SkDiscardableMemory& discardableMemoryObject) = 0; |
+ /** |
+ * Returns the type of details requested in the dump. The skia objects are expected to dump |
Primiano Tucci (use gerrit)
2015/09/24 13:10:27
THis is a bit difficult to read, but the content i
ssid
2015/09/24 13:18:49
Done.
|
+ * according to the LevelOfDetails requested and at the same time dump a consistent total usage |
+ * across multiple dump requests. Only the detailed information about memory usage can vary. |
+ */ |
+ virtual LevelOfDetails getRequestedDetails() const = 0; |
+ |
protected: |
virtual ~SkTraceMemoryDump() { } |
}; |