Gralloc: Make size calculation consistent at all places

Fix size calculation by consistently using adreno or gralloc calculation APIs

Change-Id: Ic0cef22d6f99a17d7ce392d02a21edc812cd907b
CRs-Fixed: 2262355
diff --git a/gralloc/gr_utils.h b/gralloc/gr_utils.h
index 9f21f5b..d273754 100644
--- a/gralloc/gr_utils.h
+++ b/gralloc/gr_utils.h
@@ -78,6 +78,8 @@
 unsigned int GetSize(const BufferInfo &d, unsigned int alignedw, unsigned int alignedh);
 void GetBufferSizeAndDimensions(const BufferInfo &d, unsigned int *size, unsigned int *alignedw,
                                 unsigned int *alignedh);
+void GetBufferSizeAndDimensions(const BufferInfo &d, unsigned int *size, unsigned int *alignedw,
+                                unsigned int *alignedh, GraphicsMetadata *graphics_metadata);
 void GetCustomDimensions(private_handle_t *hnd, int *stride, int *height);
 void GetColorSpaceFromMetadata(private_handle_t *hnd, int *color_space);
 void GetAlignedWidthAndHeight(const BufferInfo &d, unsigned int *aligned_w,
@@ -112,6 +114,7 @@
 uint64_t GetHandleFlags(int format, uint64_t usage);
 int GetImplDefinedFormat(uint64_t usage, int format);
 int GetCustomFormatFlags(int format, uint64_t usage, int *custom_format, uint64_t *priv_flags);
+int GetBufferType(int inputFormat);
 }  // namespace gralloc
 
 #endif  // __GR_UTILS_H__