diff options
author | Christian C <cc@localhost> | 2025-04-01 17:38:32 -0700 |
---|---|---|
committer | Christian C <cc@localhost> | 2025-04-01 17:38:32 -0700 |
commit | a18cea2fef7aa1545c9a984b60919541b26a6f84 (patch) | |
tree | d1ab991e28b701bdfdc9035704389ad6c57391c9 /lib/color.c | |
parent | 2bc54ac42b831a7dfcba26c2d12ba002f80a5e40 (diff) |
Clang Format
Diffstat (limited to 'lib/color.c')
-rw-r--r-- | lib/color.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/color.c b/lib/color.c index 172b627..564d7c5 100644 --- a/lib/color.c +++ b/lib/color.c @@ -1,10 +1,10 @@ -#include <stdio.h> -#include <lib/color.h> #include <lib/bool.h> +#include <lib/color.h> +#include <stdio.h> // Color Equal to Background // Background: zeros in RGB, alpha can be whatever -bool_t color_zero(const ImageData_t* color1, size_t channels) { +bool_t color_zero(const ImageData_t *color1, size_t channels) { for (size_t idx = 0; idx < channels; idx++) { if (idx == 3) { break; @@ -18,7 +18,8 @@ bool_t color_zero(const ImageData_t* color1, size_t channels) { // Color Equality // Determine if two colors are identical -bool_t color_equal(const ImageData_t* color1, const ImageData_t* color2, size_t channels) { +bool_t color_equal(const ImageData_t *color1, const ImageData_t *color2, + size_t channels) { for (size_t idx = 0; idx < channels; idx++) { if (color1[idx] != color2[idx]) { return FALSE; @@ -28,7 +29,7 @@ bool_t color_equal(const ImageData_t* color1, const ImageData_t* color2, size_t } // Print out the `channels` length color vector -void print_color(ImageData_t* color, size_t channels) { +void print_color(ImageData_t *color, size_t channels) { for (size_t index = 0; index < channels; index++) { printf("%hhu ", color[index]); } |