XII Release 0.1.0
Loading...
Searching...
No Matches
xiiDecalAtlasResourceDescriptor Struct Reference

#include <DecalResource.h>

Public Member Functions

xiiResult Validate () const
 Copyright (c) Theophilus Eriata. All Rights Reserved.
xiiResult Serialize (xiiStreamWriter &ref_stream) const
xiiResult Deserialize (xiiStreamReader &ref_stream)

Public Attributes

xiiSizeU16 m_AtlasSize = xiiSizeU16(2048, 2048)
 Shared extent of all four prepacked channel images (up to 16384 per axis).
xiiUInt8 m_uiPadding = 2U
 Tool packing configuration retained as metadata.
bool m_bGenerateMipMaps = true
 Requires a complete authored mip chain when true, otherwise a single mip.
xiiDynamicArray< xiiDecalAtlasEntry > m_Entries
 Unique decal IDs and their already resolved rectangles. No runtime packing.
xiiImage m_LayerImages [4]
 Albedo (sRGB), tangent normal, roughness/metallic/AO (linear), emissive.

Detailed Description

Prepacked atlas produced by tools. All four channels share each entry's UV rectangle, dimensions and mip count. Images are upload data, released by the resource after GPU creation; source texture handles on entries are metadata.

Member Function Documentation

◆ Deserialize()

xiiResult xiiDecalAtlasResourceDescriptor::Deserialize ( xiiStreamReader & ref_stream)

Failure leaves this descriptor unchanged. Removed metadata-only atlas files require retransformation; they never contained renderable source pixels.


The documentation for this struct was generated from the following files:
  • /home/runner/work/XII/XII/Source/Engine/GraphicsCore/Decals/DecalResource.h
  • /home/runner/work/XII/XII/Source/Engine/GraphicsCore/Decals/Implementation/DecalAtlasDescriptor.cpp