mirror of
https://github.com/isometimes/rpi4-osdev
synced 2024-11-10 04:10:39 +00:00
21 lines
409 B
C
21 lines
409 B
C
|
#include "wgt.h"
|
||
|
#include "include/mem.h"
|
||
|
|
||
|
extern short bx,by,tx,ty;
|
||
|
|
||
|
void wfreeblock (block ptr)
|
||
|
{
|
||
|
free (ptr);
|
||
|
}
|
||
|
|
||
|
short wgetblockwidth (block ptr)
|
||
|
{
|
||
|
return *(short *)ptr; /* Width is first 2 bytes of data */
|
||
|
}
|
||
|
|
||
|
short wgetblockheight (block ptr)
|
||
|
{
|
||
|
ptr += 2; /* Skip width */
|
||
|
return *(short *)ptr; /* Height is second 2 bytes of data */
|
||
|
}
|