From 16422831ed49c573c1b8a43ba907bceb00fd5eea Mon Sep 17 00:00:00 2001 From: Christian C Date: Sat, 22 Mar 2025 22:27:40 -0700 Subject: Named Types --- lib/algo/avl_tree.c | 4 ++-- lib/algo/flood_fill.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/algo') diff --git a/lib/algo/avl_tree.c b/lib/algo/avl_tree.c index 9d38662..3b5c8aa 100644 --- a/lib/algo/avl_tree.c +++ b/lib/algo/avl_tree.c @@ -5,7 +5,7 @@ #include // Get the height of an AVL node -uint8_t get_height(struct AVLNode* node) +AvlHeight_t get_height(struct AVLNode* node) { if (node == NULL) { return 0; @@ -14,7 +14,7 @@ uint8_t get_height(struct AVLNode* node) } // Get the Maximum Height between two -uint8_t max_height(uint8_t a, uint8_t b) +AvlHeight_t max_height(AvlHeight_t a, AvlHeight_t b) { return (a > b) ? a : b; } diff --git a/lib/algo/flood_fill.c b/lib/algo/flood_fill.c index 62db658..0506532 100644 --- a/lib/algo/flood_fill.c +++ b/lib/algo/flood_fill.c @@ -8,7 +8,7 @@ // 4. Check if the (x,y) coordinate in the image is the same color as the fill color // 5. If all hold, set the label for the pixel, and check each neighbor // Otherwise, stop flooding -bool_t flood(uint8_t* image, uint16_t* mask, size_t width, size_t height, size_t channels, size_t x, size_t y, uint8_t* fill_color, uint16_t label) +bool_t flood(ImageData_t* image, ImageMaskData_t* mask, size_t width, size_t height, size_t channels, size_t x, size_t y, ImageData_t* fill_color, ImageMaskData_t label) { if ((x >= width) | (y >= height)) { return FALSE; -- cgit v1.2.1