Texture/Xbox 360: Difference between revisions

Content added Content deleted
mNo edit summary
(Describe field order inversion, add D3DResource, and update D3DBaseTexture.)
Line 1: Line 1:
{{todo|Identify the bit fields outside the texture fetch constant.}}

= Structures =
= Structures =
Most of this information is derived from the MS Xbox 360 SDK and [[Burnout Paradise (2008-01-30 build)]]'s XDB.
Most of this information is derived from the MS Xbox 360 SDK and [[Burnout Paradise (2008-01-30 build)]]'s XDB.


The texture header is made up of bit fields contained within DWORDs. Many of these bit fields are currently unknown. Microsoft's documentation (which aligns with the XDB's type information) does not match the data in the resource because within each DWORD, the order of the bit fields is inverted. All documentation below has been inverted as well so as to match the resource.
=== D3DBaseTexture ===

=== D3DResource ===
{| class="wikitable"
{| class="wikitable"
! Offset !! Length !! Type !! Name !! Description !! Comments
! Offset !! Length !! Type !! Name !! Description !! Comments
Line 17: Line 21:
|-
|-
| 0x14 || 0x4 || DWORD || BaseFlush || ||
| 0x14 || 0x4 || DWORD || BaseFlush || ||
|}

=== D3DBaseTexture ===
{| class="wikitable"
! Offset !! Length !! Type !! Name !! Description !! Comments
|-
| 0x0 || 0x18 || [[#D3DResource|D3DResource]] || || Base class ||
|-
|-
| 0x18 || 0x4 || DWORD || MipFlush || ||
| 0x18 || 0x4 || DWORD || MipFlush || ||
Line 35: Line 46:


=== GPUTEXTURE_FETCH_CONSTANT ===
=== GPUTEXTURE_FETCH_CONSTANT ===
Stored as 6 DWORDS.
Official documentation is in LSB 0 notation. It has been converted to MSB 0 and its DWORDs have been merged into one table.


{| class="wikitable"
{| class="wikitable"