From 0231ba12df4b4aca336b08f22883a7e65ad03a00 Mon Sep 17 00:00:00 2001 From: Alex Marshall Date: Thu, 29 Jan 2009 21:19:38 -0800 Subject: Updated the brlan parser (C version) and added a non-functioning brlyt parser (C version) --- brlyt.h | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 brlyt.h (limited to 'brlyt.h') diff --git a/brlyt.h b/brlyt.h new file mode 100644 index 0000000..e257d68 --- /dev/null +++ b/brlyt.h @@ -0,0 +1,73 @@ +/* + * brlyt.h + * + * + * Created by Alex Marshall on 09/01/27. + * Copyright 2009 __MyCompanyName__. All rights reserved. + * + */ + +#ifndef BRLYT_H_ +#define BRLYT_H_ + +#include "types.h" + +typedef struct +{ + fourcc magic; // RLYT + u32 unk1; // 0xFEFF0008 + u32 filesize; // The filesize of the brlyt. + u16 lyt_offset; // Offset to the lyt1 section. + u16 unk2; // Unknown. +} brlyt_header; + +typedef struct +{ + fourcc magic; // The magic. + u32 length; // How long the entry is. +} brlyt_entry_header; + +typedef struct +{ + fourcc magic; // The magic. + u32 length; // How long the entry is. + u32 data_location; // The location of the data in the BRLYT file. +} brlyt_entry; + +typedef struct +{ + u16 flags; + u16 alpha; + char name[0x18]; + f32 x; + f32 y; + f32 unk[3]; + f32 angle; + f32 xmag; + f32 ymag; + f32 width; + f32 height; +} brlyt_pic1_chunk; + +typedef struct +{ + u32 unk[3]; +} brlyt_lyt1_chunk; + +typedef struct +{ + char name[16]; + u16 numsubs; + u16 unk; +} brlyt_grp1_chunkbase; + +typedef struct +{ + u16 num; + u16 offs; +} brlyt_img_chunk; +// grs1, gre1, pas1, and pae1 all don't have anything special. they seem to just be prefixes to some sections. + +void parse_brlyt(char *filename); + +#endif //BRLYT_H_ \ No newline at end of file -- cgit v1.3.1