summaryrefslogtreecommitdiff
path: root/include/tinyff/image
diff options
context:
space:
mode:
authorTazyFoundSoup <gardendistrict0x0@outlook.com>2026-06-08 10:24:03 +1000
committerTazyFoundSoup <gardendistrict0x0@outlook.com>2026-06-08 10:24:03 +1000
commitc9f5da1d19e6ace5d6a7c650fe996f359e11d1a5 (patch)
treec5d61055549f1819d902e567f7227e0c3778300c /include/tinyff/image
parent62cbefa6a8fca583c6f600f1d7e24f0c61c91b1e (diff)
docs(headers): Clean up comments across public headers
Diffstat (limited to 'include/tinyff/image')
-rw-r--r--include/tinyff/image/bmp.h7
-rw-r--r--include/tinyff/image/generic.h9
-rw-r--r--include/tinyff/image/png.h3
3 files changed, 4 insertions, 15 deletions
diff --git a/include/tinyff/image/bmp.h b/include/tinyff/image/bmp.h
index 973706d..f56fdd5 100644
--- a/include/tinyff/image/bmp.h
+++ b/include/tinyff/image/bmp.h
@@ -28,7 +28,7 @@ typedef struct {
ff_stream *raw;
- uint32_t file_size; // tbh, i actually have no idea why this is needed
+ uint32_t file_size;
uint32_t data_offset;
uint32_t width;
@@ -50,11 +50,6 @@ typedef struct {
typedef ff_result (*ff_bmp_section_handler_ptr)(ff_ctx* ctx, uint8_t *buf, size_t len, ff_bmp_ctx* bmp_ctx);
typedef struct {
- // Even though the types in bitmaps are invisible (they don't have labels)
- // I'll just keep them in for the sake of being in
- // And I might just handle the section looping a bit differently
- // And their names will be what I saw in the spec
-
const char* type;
ff_bmp_section_handler_ptr handler;
} ff_bmp_section_handler;
diff --git a/include/tinyff/image/generic.h b/include/tinyff/image/generic.h
index a0bba62..60a05b8 100644
--- a/include/tinyff/image/generic.h
+++ b/include/tinyff/image/generic.h
@@ -1,6 +1,3 @@
-// This is the generics image header file for tinyff
-// It contains generic image structures and definitions
-
#include <tinyff/common.h>
#include <tinyff/result.h>
@@ -8,16 +5,14 @@
#define GENERIC_IMAGE_H
-// The image origin is **not** the origin point of the image
-// But rather from what the image was loaded
+// Tracks which format the image was decoded from
typedef enum {
FF_IMAGE_ORIGIN_PNG,
FF_IMAGE_ORIGIN_BMP
} ff_image_origin;
-// Only the basic information about an image
-// Warning: Data is RGBA8888 using scanlines going from top to bottom
+// Warning: Data is RGBA8888, scanlines top to bottom
typedef struct {
uint32_t width;
uint32_t height;
diff --git a/include/tinyff/image/png.h b/include/tinyff/image/png.h
index fb064db..5d55b40 100644
--- a/include/tinyff/image/png.h
+++ b/include/tinyff/image/png.h
@@ -63,8 +63,7 @@ typedef struct {
ff_png_chunk_handler_ptr handler;
} ff_png_chunk_handler;
-// Handler declarations
-// Massive W.I.P
+// Chunk handler declarations
// Required by definition
ff_result ff_png_header_handler(ff_ctx* ctx, uint8_t *buf, size_t len, ff_png_ctx* png_ctx); // IHDR