<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://mii.j0.lol/index.php?action=history&amp;feed=atom&amp;title=Nn%3A%3Amii%3A%3Adetail%3A%3AResourceShapeHeader</id>
	<title>Nn::mii::detail::ResourceShapeHeader - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://mii.j0.lol/index.php?action=history&amp;feed=atom&amp;title=Nn%3A%3Amii%3A%3Adetail%3A%3AResourceShapeHeader"/>
	<link rel="alternate" type="text/html" href="https://mii.j0.lol/index.php?title=Nn::mii::detail::ResourceShapeHeader&amp;action=history"/>
	<updated>2026-05-06T09:40:02Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.44.0</generator>
	<entry>
		<id>https://mii.j0.lol/index.php?title=Nn::mii::detail::ResourceShapeHeader&amp;diff=471&amp;oldid=prev</id>
		<title>Jo: Jo moved page Shape＊.dat to Nn::mii::detail::ResourceShapeHeader</title>
		<link rel="alternate" type="text/html" href="https://mii.j0.lol/index.php?title=Nn::mii::detail::ResourceShapeHeader&amp;diff=471&amp;oldid=prev"/>
		<updated>2025-09-24T14:39:31Z</updated>

		<summary type="html">&lt;p&gt;Jo moved page &lt;a href=&quot;/wiki/Shape%EF%BC%8A.dat&quot; class=&quot;mw-redirect&quot; title=&quot;Shape＊.dat&quot;&gt;Shape＊.dat&lt;/a&gt; to &lt;a href=&quot;/wiki/Nn::mii::detail::ResourceShapeHeader&quot; title=&quot;Nn::mii::detail::ResourceShapeHeader&quot;&gt;Nn::mii::detail::ResourceShapeHeader&lt;/a&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 14:39, 24 September 2025&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;4&quot; class=&quot;diff-notice&quot; lang=&quot;en&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff cache key my_wiki:diff:1.41:old-327:rev-471 --&gt;
&lt;/table&gt;</summary>
		<author><name>Jo</name></author>
	</entry>
	<entry>
		<id>https://mii.j0.lol/index.php?title=Nn::mii::detail::ResourceShapeHeader&amp;diff=327&amp;oldid=prev</id>
		<title>Jo: Created page with &quot;ShapeMid.dat, and others.  == Struct Format (Header) == This abridged sample is implemented in Rust, using the binrw library. This sample is edited for readability, full sample can be found here&lt;ref&gt;https://github.com/j0lol/vee/blob/f134e28eec22bdf8587d5abbf0f2d0f1ffc5b8a5/crates/vee_resources/src/shape.rs#L1&lt;/ref&gt;.  &lt;syntaxhighlight lang=&quot;rust&quot;&gt; /// Specifies where data is, now big it is, and how compressed it is. /// Used for both textures and shapes. #[derive(BinRead)...&quot;</title>
		<link rel="alternate" type="text/html" href="https://mii.j0.lol/index.php?title=Nn::mii::detail::ResourceShapeHeader&amp;diff=327&amp;oldid=prev"/>
		<updated>2025-09-23T19:58:25Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;ShapeMid.dat, and others.  == Struct Format (Header) == This abridged sample is implemented in Rust, using the binrw library. This sample is edited for readability, full sample can be found here&amp;lt;ref&amp;gt;https://github.com/j0lol/vee/blob/f134e28eec22bdf8587d5abbf0f2d0f1ffc5b8a5/crates/vee_resources/src/shape.rs#L1&amp;lt;/ref&amp;gt;.  &amp;lt;syntaxhighlight lang=&amp;quot;rust&amp;quot;&amp;gt; /// Specifies where data is, now big it is, and how compressed it is. /// Used for both textures and shapes. #[derive(BinRead)...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;ShapeMid.dat, and others.&lt;br /&gt;
&lt;br /&gt;
== Struct Format (Header) ==&lt;br /&gt;
This abridged sample is implemented in Rust, using the binrw library. This sample is edited for readability, full sample can be found here&amp;lt;ref&amp;gt;https://github.com/j0lol/vee/blob/f134e28eec22bdf8587d5abbf0f2d0f1ffc5b8a5/crates/vee_resources/src/shape.rs#L1&amp;lt;/ref&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;rust&amp;quot;&amp;gt;&lt;br /&gt;
/// Specifies where data is, now big it is, and how compressed it is.&lt;br /&gt;
/// Used for both textures and shapes.&lt;br /&gt;
#[derive(BinRead)]&lt;br /&gt;
pub struct ResourceCommonAttribute {&lt;br /&gt;
    pub offset: u32,&lt;br /&gt;
    pub size: u32,&lt;br /&gt;
    pub size_compressed: u32,&lt;br /&gt;
    pub compression_level: u8,&lt;br /&gt;
    pub memory_level: u8,&lt;br /&gt;
    pad: u16,&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/// Specifies where {vertex,index} buffers are, and how big they are.&lt;br /&gt;
#[derive(BinRead)]&lt;br /&gt;
pub struct ResourceShapeAttribute {&lt;br /&gt;
    pub attr_offset: [u32; 5],&lt;br /&gt;
    pub attr_size: [u32; 5],&lt;br /&gt;
    pub index_offset: u32,&lt;br /&gt;
    pub index_size: u32,&lt;br /&gt;
    pub bounding_box: [[f32; 3]; 2],&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/// All the data required to read a mesh from the shape file.&lt;br /&gt;
/// Essentially a &amp;#039;pointer&amp;#039; to the data.&lt;br /&gt;
#[derive(BinRead)]&lt;br /&gt;
pub struct ShapeElement {&lt;br /&gt;
    pub common: ResourceCommonAttribute,&lt;br /&gt;
    pub shape: ResourceShapeAttribute,&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/// Contains positional data for any headwear that&lt;br /&gt;
/// may be placed on the model post-render.&lt;br /&gt;
#[derive(BinRead)]&lt;br /&gt;
pub struct ResourceShapeHairTransform {&lt;br /&gt;
    front_translate: [f32; 3],&lt;br /&gt;
    front_rotate: [f32; 3],&lt;br /&gt;
    side_translate: [f32; 3],&lt;br /&gt;
    side_rotate: [f32; 3],&lt;br /&gt;
    top_translate: [f32; 3],&lt;br /&gt;
    top_rotate: [f32; 3],&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/// Contains positional data used to move face parts&lt;br /&gt;
/// like the beard, nose, hair, glasses, etc.&lt;br /&gt;
#[derive(BinRead)]&lt;br /&gt;
pub struct ResourceShapeFacelineTransform {&lt;br /&gt;
    pub hair_translate: [f32; 3],&lt;br /&gt;
    pub nose_translate: [f32; 3],&lt;br /&gt;
    pub beard_translate: [f32; 3],&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/// Header of the `Shape` resource file.&lt;br /&gt;
#[derive(BinRead)]&lt;br /&gt;
#[br(little, magic = b&amp;quot;NFSR&amp;quot;)]&lt;br /&gt;
pub struct ResourceShape {&lt;br /&gt;
    ver: u32,&lt;br /&gt;
    file_size: u32,&lt;br /&gt;
    max_size: [u32; 12],&lt;br /&gt;
    max_alignment: [u32; 12],&lt;br /&gt;
    pub beard: [ShapeElement; 4],&lt;br /&gt;
    pub face_line: [ShapeElement; 12],&lt;br /&gt;
    pub mask: [ShapeElement; 12],&lt;br /&gt;
    pub hat_normal: [ShapeElement; 132],&lt;br /&gt;
    pub hat_cap: [ShapeElement; 132],&lt;br /&gt;
    pub forehead_normal: [ShapeElement; 132],&lt;br /&gt;
    pub forehead_cap: [ShapeElement; 132],&lt;br /&gt;
    pub hair_normal: [ShapeElement; 132],&lt;br /&gt;
    pub hair_cap: [ShapeElement; 132],&lt;br /&gt;
&lt;br /&gt;
    pub glasses: [ShapeElement; 1],&lt;br /&gt;
&lt;br /&gt;
    pub nose: [ShapeElement; 18],&lt;br /&gt;
    pub nose_line: [ShapeElement; 18],&lt;br /&gt;
&lt;br /&gt;
    pub hair_transform: [ResourceShapeHairTransform; 132],&lt;br /&gt;
    pub face_line_transform: [ResourceShapeFacelineTransform; 12],&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&amp;lt;references /&amp;gt;{{Resource-Navbox}}&lt;/div&gt;</summary>
		<author><name>Jo</name></author>
	</entry>
</feed>