Jump to content

FFLiResourceHeader: Difference between revisions

From Mii Technical Wiki
not for cfl, add miitomo details, let's say it has "shapes" and "textures" before then going into the "vertex and texture formats". ok?
Line 1: Line 1:
FFLiResourceHeader is a [[Mii Resources|Mii resource struct]] that specifies both ''vertex'' and ''texture'' data. It is used in [[FFL]], [[CFL]], and [[AFL]].
FFLiResourceHeader is a [[Mii Resources|Mii resource struct]] that specifies both ''shape'' and ''texture'' data. It is used in both [[FFL]] on Wii U and [[AFL]] in Miitomo.


== Files ==
== Files ==
Line 29: Line 29:


==== In games on the Wii U ====
==== In games on the Wii U ====
The games ''Wii Party U'', ''Wii Fit U'', and ''Mario & Sonic at the Sochi 2014 Olympic Winter Games'' all have altered versions of FFLiResourceHeader. In ''Wii Party U'', some texture mipmaps are removed, and some undefined data is altered in all game versions.
The games ''Wii Party U'', ''Wii Fit U'', and ''Mario & Sonic at the Sochi 2014 Olympic Winter Games'' all have altered versions of the FFL resource file. In ''Wii Party U'', some textures (noseline) have extra mipmaps, and some undefined "transform" data is altered in all game versions.
 
=== On 3DS ===
..


=== In Miitomo ===
=== In Miitomo ===
AFL... come in two versions, 2whatever and 2whatever. some extra things are added. <<TODO>>
The AFL resource file comes in two versions, ''AFLResHigh.dat'' from the original release of the game and ''AFLResHigh_2_3.dat'' for Miitomo 2.3.0, which added Switch features and colors.
The only additions in AFLResHigh_2_3.dat are extra glass types from the Switch, but both include more eye, eyebrow, and mouth types for the various expressions in the game.<<TODO>>


== Header format ==
== Header format ==

Revision as of 17:57, 24 September 2025

FFLiResourceHeader is a Mii resource struct that specifies both shape and texture data. It is used in both FFL on Wii U and AFL in Miitomo.

Files

On Wii U

The location of these at MLC are at: /sys/title/0005001b/10056000/content/. There are also "LG" variants of both, meant to be used for linear gamma. (Differences are unknown, shapes are all unchanged.)

Hashes of data files
File Name SHA256 Notes
FFLResMiddle.dat 2a048021fb35b67481bdd92948827e0e130a5d7270689983896772a7255a0f14
FFLResMiddleLG.dat b7d0e8c31b97be12c99a0b4b0158bfa32cf3fb0e236fab46c2497a22a62411fa Linear Gamma
FFLResHigh.dat 75381dec8c73f6cad5e74ecd6c850f202223fd6fc57ddaa02475c7f62027e7ed
FFLResHighLG.dat 31dfc741eddd59c5e96f37df2c0e4784e6ace4a94539eb58641a6ae20bccaf73 Linear Gamma

In games on the Wii U

The games Wii Party U, Wii Fit U, and Mario & Sonic at the Sochi 2014 Olympic Winter Games all have altered versions of the FFL resource file. In Wii Party U, some textures (noseline) have extra mipmaps, and some undefined "transform" data is altered in all game versions.

In Miitomo

The AFL resource file comes in two versions, AFLResHigh.dat from the original release of the game and AFLResHigh_2_3.dat for Miitomo 2.3.0, which added Switch features and colors. The only additions in AFLResHigh_2_3.dat are extra glass types from the Switch, but both include more eye, eyebrow, and mouth types for the various expressions in the game.<<TODO>>

Header format

This sample is in the ImHex Pattern[1] format.

struct ResourcePartsInfo {
    u32 dataPos;
    u32 dataSize;
    u32 compressedSize;
    u8 compressLevel;
    u8 windowBits;
    u8 memoryLevel;
    u8 strategy;
};

struct ResourceShapeHeader {
    u32 maxSize[12];
    ResourcePartsInfo beard[4];
    ResourcePartsInfo hatNormal[132];
    ResourcePartsInfo hatCap[132];
    ResourcePartsInfo faceline[12];
    ResourcePartsInfo glass[1];
    ResourcePartsInfo mask[12];
    ResourcePartsInfo noseline[18];
    ResourcePartsInfo nose[18];
    ResourcePartsInfo hairNormal[132];
    ResourcePartsInfo hairCap[132];
    ResourcePartsInfo foreheadNormal[132];
    ResourcePartsInfo foreheadCap[132];
};

struct ResourceTextureHeader {
    u32 maxSize[11];
    ResourcePartsInfo beard[3];
    ResourcePartsInfo hat[132];
    ResourcePartsInfo eye[62];     // [80] in AFL
    ResourcePartsInfo eyebrow[24]; // [28] in AFL
    ResourcePartsInfo faceline[12];
    ResourcePartsInfo faceMakeup[12];
    ResourcePartsInfo glass[9]; // [20] in AFL
    ResourcePartsInfo mole[2];
    ResourcePartsInfo mouth[37]; // [52] in AFL
    ResourcePartsInfo mustache[6];
    ResourcePartsInfo noseline[18];
};

struct ResourceHeader { 
    u32 signature; // "FFRA"
    u32 version;
    u32 uncompressedBufferSize;
    u32 expandedBufferSize;
    u32 expanded;
    ResourceTextureHeader textureHeader;
    ResourceShapeHeader shapeHeader;
    u32 unknown[12]; // Always 0x0?
};

Vertex data format

...

Texture data format

...

In codebases

  1. FFL Decomp

References