@carbonenginejs/reader-dxbc

CarbonEngineJS DXBC reader. Parses Direct3D shader bytecode containers, signatures and the SM4/SM5 token stream, and emits JSON or raw decoder objects for shader translation backends.


Keywords
carbonenginejs, reader-dxbc, dxbc, direct3d, d3d11, shader, bytecode, sm4, sm5, hlsl
License
MIT
Install
npm install @carbonenginejs/reader-dxbc@0.1.0

Documentation

@carbonenginejs/format-dxbc

Reads Microsoft DXBC containers, signatures, and SM4/SM5 instruction streams as plain JavaScript data or internal decoder objects.

Use this package when a browser or Node application needs a pure-JavaScript DXBC decoder. Shader lowering remains in @carbonenginejs/format-webgl and @carbonenginejs/format-webgpu; compiled effect-container parsing remains in @carbonenginejs/format-hlsl.

Install

npm install @carbonenginejs/format-dxbc

Quick start

Inspect or fully decode caller-supplied DXBC bytes:

import { CjsFormatDxbc } from "@carbonenginejs/format-dxbc";

const summary = CjsFormatDxbc.inspect(shaderBytes);
const decoded = CjsFormatDxbc.read(shaderBytes);

console.log(summary.shaderModel, decoded.instructions.length);

The default json output contains plain data suitable for serialization. Advanced backends may request emit: "raw" for the package's internal container, signature, program, and instruction-decoder instances.

Documentation

License

MIT. See LICENSE and NOTICE. DXBC is a Microsoft format; CarbonEngine and Fenris Creations (CCP Games) are named only for interoperability and target-ecosystem context. This package contains no Microsoft, CarbonEngine, or Fenris Creations source code and is not affiliated with or endorsed by CCP Games.