Layouts differ between SDK versions, so a getter is safer than an offset. Game B exports builder and view getters
(nvnMemoryPoolBuilderGet*, nvnTextureBuilderGet*, nvnTextureViewGet*). Pure getters such as
nvnTextureGetStorageSize, GetTextureAddress, GetStride and GetStorageClass were also called successfully on a
copy of the CPU state after nvnTextureInitialize. The layouts seen:
+4, +16, +24. Game C's older SDK keeps
storage, size and flags at +8, +16, +24.SetRenderTargets and the
register calls, so object identity cannot be keyed on the pointer.TextureViewSetDefaults clears 16 bytes and packs selection and override flags into it
(six selection flags, target, format, swizzle with identity 2,3,4,5, depth mode). Game A's clears 36 bytes with
separate flag and value fields. Game C also uses 36 bytes, with a different constructor and the target at +32.nvnProgramSetShaders passes 16-byte (code, control) pairs. SetShadersExt passes 24-byte entries,
which the SDK splits into those pairs plus an array of third words. Reading the plain pairs as 24-byte entries
shifts every reference after the first.RegisterTexture writes a 32-byte TIC and
RegisterSampler a 32-byte TSC into the pool's memory. RegisterImage writes an image descriptor into the texture
pool. Neither game A nor game B exposed a GPU base for the descriptor pools, so the descriptors were read through
the pool's CPU backing.BindProgram applies to a stage mask. A later partial bind replaces only its stages.ClearColor is not a no-op when repeated: each call advances the cursor by 48 bytes. A clear to an integer target
passes float bits (game D passes 0x3f800000), which reach the Maxwell clear registers unchanged.
Made from docs/layers/gpu/nvn.md at 69237645142c. GPL-3.0-or-later.