wowlib 0.0.0
Read & write World of Warcraft client files — a C++26 core
Loading...
Searching...
No Matches
wowlib::formats::m2::OffsetReadContext Struct Reference

Resolution of SequenceData members while reading: where each outer element's nested data lives. More...

#include <wowlib/formats/m2/offset_block.hpp>

Public Attributes

std::function< std::span< const std::byte >(std::size_t i)> sequenceBase
 The base span the inner arrays of outer element i resolve their offsets against — the matching .anim file's bytes for an M2 sequence stored externally, or the entity's own buffer for an inline one.

Detailed Description

Resolution of SequenceData members while reading: where each outer element's nested data lives.

Without a context (or with an empty function) everything is inline in the entity's own buffer.

Definition at line 73 of file offset_block.hpp.

Member Data Documentation

◆ sequenceBase

std::function<std::span<const std::byte>(std::size_t i)> wowlib::formats::m2::OffsetReadContext::sequenceBase

The base span the inner arrays of outer element i resolve their offsets against — the matching .anim file's bytes for an M2 sequence stored externally, or the entity's own buffer for an inline one.

Returning an empty span skips the element (its vectors stay empty): the graceful path for a missing .anim file.

Definition at line 79 of file offset_block.hpp.

Referenced by wowlib::formats::m2::M2OffsetBlock< Derived >::_readArrayElements().


The documentation for this struct was generated from the following file: