]> git.cworth.org Git - apitrace/blobdiff - image/image_bmp.cpp
image: Add floating point support.
[apitrace] / image / image_bmp.cpp
index e0c64283a5f08299d868f526416ce1d0759019b6..d349be06b887c4a3ae50f8f123a9b3cb7ab908e0 100644 (file)
@@ -28,6 +28,8 @@
 #include <assert.h>
 #include <stdint.h>
 
+#include <fstream>
+
 #include "image.hpp"
 
 
@@ -69,6 +71,7 @@ struct Pixel {
 bool
 Image::writeBMP(const char *filename) const {
     assert(channels == 4);
+    assert(channelType == TYPE_UNORM8);
 
     struct FileHeader bmfh;
     struct InfoHeader bmih;