Add comments

This commit is contained in:
Crayon2000 2024-04-01 17:10:00 -04:00
parent 08710a77d2
commit 100b1bd2bf

View file

@ -28,14 +28,19 @@ THE SOFTWARE.
#include <grrlib.h> #include <grrlib.h>
#define TPL_HDR_VERSION_FIELD 0 #define TPL_HDR_VERSION_FIELD 0 /**< Version field. */
#define TPL_HDR_NTEXTURE_FIELD 4 #define TPL_HDR_NTEXTURE_FIELD 4 /**< Textrure field. */
#define TPL_HDR_HDRSIZE_FIELD 8 #define TPL_HDR_HDRSIZE_FIELD 8 /**< Header size field. */
#define TPL_HDR_DESCR_FIELD 12 #define TPL_HDR_DESCR_FIELD 12 /**< Descriptor field. */
// texture header /**
* Texture header.
*/
typedef struct _tplimgheader TPLImgHeader; typedef struct _tplimgheader TPLImgHeader;
/**
* Texture header.
*/
struct _tplimgheader { struct _tplimgheader {
u16 height; u16 height;
u16 width; u16 width;
@ -52,9 +57,14 @@ struct _tplimgheader {
u8 unpacked; u8 unpacked;
} ATTRIBUTE_PACKED; } ATTRIBUTE_PACKED;
// texture palette header /**
* Texture palette header.
*/
typedef struct _tplpalheader TPLPalHeader; typedef struct _tplpalheader TPLPalHeader;
/**
* Texture palette header.
*/
struct _tplpalheader { struct _tplpalheader {
u16 nitems; u16 nitems;
u8 unpacked; u8 unpacked;
@ -63,9 +73,14 @@ struct _tplpalheader {
void *data; void *data;
} ATTRIBUTE_PACKED; } ATTRIBUTE_PACKED;
// texture descriptor /**
* Texture descriptor.
*/
typedef struct _tpldesc TPLDescHeader; typedef struct _tpldesc TPLDescHeader;
/**
* Texture descriptor.
*/
struct _tpldesc { struct _tpldesc {
TPLImgHeader *imghead; TPLImgHeader *imghead;
TPLPalHeader *palhead; TPLPalHeader *palhead;