diff options
author | Paul Oliver <contact@pauloliver.dev> | 2024-02-29 02:29:14 +0100 |
---|---|---|
committer | Paul Oliver <contact@pauloliver.dev> | 2024-02-29 02:29:14 +0100 |
commit | 0a03015960e99290cb8efe8321dc312a2c1a0a39 (patch) | |
tree | 218b050073c922752b1965fe23dfde273788f052 /src/render.c | |
parent | 879fe74e2a18b7b89d35cf1fc0fb8829a1b70b3d (diff) |
Format tweaks to C files [#30]
Diffstat (limited to 'src/render.c')
-rw-r--r-- | src/render.c | 23 |
1 files changed, 10 insertions, 13 deletions
diff --git a/src/render.c b/src/render.c index 128ce3b..7a2315d 100644 --- a/src/render.c +++ b/src/render.c @@ -9,10 +9,9 @@ #define BLOCK_FLAG 0x40 #define IP_FLAG 0x80 -static void apply_flag( - uint32 origin, uint32 max_pos, uint32 cell_size, uint32 address, - uint32 flag, uint8_p buffer -) { +static void apply_flag(uint32 origin, uint32 max_pos, uint32 cell_size, + uint32 address, uint32 flag, uint8_p buffer) +{ if (address >= origin && address < max_pos) { /* Flag falls inside rendered image. We can 'and' the bit to the corresponding pixel. @@ -22,9 +21,9 @@ static void apply_flag( } } -void sal_ren_get_image( - uint32 origin, uint32 cell_size, uint32 buff_size, uint8_p buffer -) { +void sal_ren_get_image(uint32 origin, uint32 cell_size, uint32 buff_size, + uint8_p buffer) +{ /* Render a 1D image of a given section of memory, at a given resolution (zoom) and store it in a pre-allocated 'buffer'. @@ -79,14 +78,12 @@ void sal_ren_get_image( if (!sal_proc_is_free(i)) { Process proc = sal_proc_get_proc(i); apply_flag(origin, max_pos, cell_size, proc.ip, IP_FLAG, buffer); - apply_flag( - origin, max_pos, cell_size, proc.mb1a, BLOCK_FLAG, buffer - ); + apply_flag(origin, max_pos, cell_size, proc.mb1a, BLOCK_FLAG, + buffer); if (proc.mb2s) { - apply_flag( - origin, max_pos, cell_size, proc.mb2a, BLOCK_FLAG, buffer - ); + apply_flag(origin, max_pos, cell_size, proc.mb2a, BLOCK_FLAG, + buffer); } } } |