utils: Use libpng enum instead of hard-coded value

BUG=b:177290952
TEST=./vkbench -t draw.TriangleTexture.512 and check the image

Change-Id: I5c636ce3713f4d62f2000a1c81ff316e9e3ff316
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vkbench/+/3139060
Reviewed-by: Ilja Friedel <ihf@chromium.org>
Tested-by: Ilja Friedel <ihf@chromium.org>
Auto-Submit: Po-Hsien Wang <pwang@chromium.org>
diff --git a/src/utils.cc b/src/utils.cc
index 4ddc5b8..3e3a64a 100644
--- a/src/utils.cc
+++ b/src/utils.cc
@@ -115,11 +115,11 @@
   /* write header */
   if (setjmp(png_jmpbuf(png_ptr)))
     RUNTIME_ERROR("error during writing png header");
-  png_byte bit_depth = 8;   // 8 bits per channel RGBA
-  png_byte color_type = 6;  // RGBA
+  png_byte bit_depth = 8;                     // 8 bits per channel RGBA
+  png_byte color_type = PNG_COLOR_TYPE_RGBA;  // RGBA
   png_set_IHDR(png_ptr, info_ptr, extent_.width, extent_.height, bit_depth,
-               color_type, PNG_INTERLACE_NONE, PNG_COMPRESSION_TYPE_BASE,
-               PNG_FILTER_TYPE_BASE);
+               color_type, PNG_INTERLACE_NONE, PNG_COMPRESSION_TYPE_DEFAULT,
+               PNG_FILTER_TYPE_DEFAULT);
   png_write_info(png_ptr, info_ptr);
 
   /* write bytes */