How carbonengine/fsd works
FSD is a C++ binary-data reader exposed as a Python extension. A Python caller imports the package, which loads the native extension through Blue; the extension registers Python-facing types, and the binary loader decodes values according to schema metadata into primitives, vectors, objects, lists, or dictionaries. Objects and lists load nested values on access, while dictionaries use footer-based offset lookup. The README gives only a high-level product description; detailed format stages and some subsystem wiring are limited to the sampled source.
Main entry points: BinaryLoader.cpp Binary loader · FsdDict.cpp Dictionary access · __init__.py FSD package · pyFSD.cpp Extension registration
Components 12
Python API
- FSD package
python/pyFSD/__init__.py - Blue loader
- Extension registration
pyFSD.cpp
Binary Decoding
- Binary loader
BinaryLoader.cpp
FSD Containers
- Object access
FsdObject.cpp - List access
FsdList.cpp - Dictionary access
FsdDict.cpp - Vector access
FsdVector.cpp - Integer key map
FsdUnsignedIntegerKeyMap.cpp
Schema and Index
- Schema metadata
FsdSchema.cpp - Footer offset lookup
FsdDictOffsetLookup.cpp
Other components
- Python caller
Connections 13
- Python caller → FSD package: imports
- FSD package → Blue loader: loads extension
- Blue loader → Extension registration: loads module
- Extension registration → Binary loader: registers bindings
- Binary loader → Schema metadata: uses metadata
- Binary loader → Object access: creates objects
- Binary loader → List access: creates lists
- Binary loader → Dictionary access: creates dictionaries
- Binary loader → Vector access: creates vectors
- Object access → Binary loader: loads attributes
- List access → Binary loader: loads elements
- Dictionary access → Footer offset lookup: looks up keys
- Dictionary access → Binary loader: loads values