[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-112036":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":13,"contributorsCount":14,"subscribersCount":14,"size":14,"stars1d":15,"stars7d":16,"stars30d":17,"stars90d":14,"forks30d":14,"starsTrendScore":18,"compositeScore":19,"rankGlobal":9,"rankLanguage":9,"license":20,"archived":21,"fork":21,"defaultBranch":22,"hasWiki":23,"hasPages":21,"topics":24,"createdAt":9,"pushedAt":25,"updatedAt":26,"readmeContent":27,"aiSummary":28,"trendingCount":14,"starSnapshotCount":14,"syncStatus":15,"lastSyncTime":29,"discoverSource":30},112036,"nxformat","fab918\u002Fnxformat","fab918","NXFormat is a high-performance archive format for decrypted Nintendo Switch and Switch 2 game dumps, featuring smart compression, fast random access, deduplication, and easy update\u002FDLC management.",null,"Rust",82,3,1,0,2,7,19,6,51.21,"MIT License",false,"main",true,[],"2026-11-18 23:28:23","2026-11-23 07:01:38","\u003Cp align=\"center\">\n  \u003Cimg src=\"docs\u002Fnxformat.png\" alt=\"NXFormat\" width=\"900\">\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003Ca href=\"LICENSE\">\u003Cimg alt=\"MIT License\" src=\"https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Flicense\u002Ffab918\u002Fnxformat\" height=\"20\" align=\"top\">\u003C\u002Fa>\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Ffab918\u002Fnxformat\u002Factions\u002Fworkflows\u002Fci.yml\">\u003Cimg alt=\"Tests and conformance\" src=\"https:\u002F\u002Fgithub.com\u002Ffab918\u002Fnxformat\u002Factions\u002Fworkflows\u002Fci.yml\u002Fbadge.svg?branch=main\" height=\"20\" align=\"top\">\u003C\u002Fa>\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Ffab918\u002Fnxformat\u002Freleases\u002Ftag\u002FV1.0.3\">\u003Cimg alt=\"NXFormat v1.0.3\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Frelease-v1.0.3-blue\" height=\"20\" align=\"top\">\u003C\u002Fa>\n  \u003Cimg alt=\"Switch 1 and Switch 2\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FSwitch-1%20%26%202-337ab7\" height=\"20\" align=\"top\">\n  \u003Cimg alt=\"C++17 reader\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Freader-C%2B%2B17-00599C\" height=\"20\" align=\"top\">\n\u003C\u002Fp>\n\n\u003Ch2 align=\"center\">Store once. Read fast. Update without starting over.\u003C\u002Fh2>\n\n\u003Cp align=\"center\">\n  \u003Cstrong>NX is a modern archive format for decrypted Nintendo Switch and Switch 2 game dumps.\u003C\u002Fstrong>\u003Cbr>\n  It is built for fast reads, smart storage, and easy management of updates and DLC.\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Ffab918\u002Fnxformat\u002Freleases\u002Ftag\u002FV1.0.3\">\u003Cstrong>Download NXConvert 1.0.3\u003C\u002Fstrong>\u003C\u002Fa>\n  &nbsp;·&nbsp;\n  \u003Ca href=\"#performance-nx-vs-nup\">NX vs NUP\u003C\u002Fa>\n  &nbsp;·&nbsp;\n  \u003Ca href=\"#quick-start\">Quick start\u003C\u002Fa>\n  &nbsp;·&nbsp;\n  \u003Ca href=\"docs\u002FSPEC.md\">Format specification\u003C\u002Fa>\n\u003C\u002Fp>\n\n- 🚀 **Modern format built for speed.** Designed to reduce decompression-related stutter. **104× faster median random reads than NUP** in the local benchmark described below. [See performance](#performance-nx-vs-nup).\n- ✏️ **Updates and DLC, in place.** Add or remove content without copying the base game during normal edits.\n- 🧩 **Store shared content once.** Reuse identical blocks across game files, updates and DLC.\n- 🎮 **Switch 1 and Switch 2.** Convert supported decrypted **DNSP\u002FDXCI** packages, extracted folders and NUP archives.\n- 📦 **Get your original files back.** Native package conversions try to keep a recipe to recreate the original bytes (on by default, `--no-recipe` to skip it). Rebuilding needs all referenced content. [Learn more](docs\u002FRECIPE.md).\n- 🛡️ **Spot damaged game files.** Built-in integrity checks detect corruption during reads or a full archive check.\n- 🛠️ **Emulator ready.** C++17 reader, Rust library and C API for Windows, Linux, macOS and Android (libraries). [Integration](#developer-integration).\n\n> **Legal note**\n> \u003Csub>**NXConvert does not decrypt anything.** It only repackages game files you have already decrypted yourself, from games you own. It contains no keys and no copyrighted content.\u003C\u002Fsub>\n\n## Quick start\n\n**NXConvert 1.0.3** writes NX archives with separate header pages.\nThe existing NX wire formats are unchanged.\nDownload the [V1.0.3 release](https:\u002F\u002Fgithub.com\u002Ffab918\u002Fnxformat\u002Freleases\u002Ftag\u002FV1.0.3),\nor build from source below. Desktop apps are available for Windows, Linux and\nmacOS; Android packages provide libraries only.\n\nBuild with Rust 1.95 or newer:\n\n```bash\ncargo build --release --locked --manifest-path app\u002FCargo.toml\n.\u002Fapp\u002Ftarget\u002Frelease\u002Fnxconvert --version\n```\n\nThe executable is `app\u002Ftarget\u002Frelease\u002Fnxconvert` (`nxconvert.exe` on Windows).\nUse that path below, or add its directory to `PATH`.\n\nRun `nxconvert` for the graphical interface, or use the CLI:\n\n```bash\nnxconvert pack game.dnsp game.nx            # Create an archive; recipe enabled\nnxconvert add game.nx update.dnsp           # Add an update or DLC\nnxconvert contents game.nx                  # List stored content\nnxconvert remove game.nx SNAPSHOT_IDENTITY  # Remove a version or DLC\nnxconvert verify game.nx                    # Check integrity\nnxconvert compact game.nx                   # Recover unused physical space\nnxconvert compact game.nx --no-compress     # Convert existing game-data blocks to RAW\nnxconvert pack game.dnsp game-raw.nx --no-compress --no-recipe  # RAW data blocks\nnxconvert pack-nup game.nup game.nx --platform switch2\n```\n\nSee [CLI.md](docs\u002FCLI.md) for extracted folders, metadata editing, limits and\nmachine-readable progress. Game boot support also depends on the emulator\nintegration; format validation alone does not establish game compatibility.\n\n## Performance: NX vs NUP\n\nCompression saves disk space, but decoding takes CPU time. When a game needs a few kilobytes from the middle of a compressed file, it should not have to decode everything before them. NX uses independent blocks to keep that work small.\n\nA slow read can cause a hitch if a game is waiting for it. P99 measures the slow tail: roughly 99% of measured reads finish at or below this time. These read timings do not measure FPS or demonstrate an in-game stutter reduction.\n\n![Random 4 KiB reads: NUP vs NX](docs\u002Fbenchmarks\u002Fnup-vs-nx-random-reads.png)\n\n**Why?** NUP stores a compressed file in one Zstandard frame. Reading far into that file may require decoding data from its beginning. NX uses smaller, independently accessible compressed blocks. Raw data can be read directly without Zstandard decoding.\n\n![Random reads inside compressed files: NUP vs NX](docs\u002Fbenchmarks\u002Fnup-vs-nx-compressed-files.png)\n\nFor reads inside compressed files, the tested median was **1.7 ms with NUP** versus **5.2 µs with NX**. The second chart also shows an especially slow NUP read, which is an example of a worst case, **not** a typical speedup.\n\n**Small reads. Big difference.** In the local NUP reference-reader benchmark, NX completed random 4 KiB reads **104× faster at the median** and **about 94× faster at P99**.\n\n> **Benchmark details:** Donkey Kong Bananza, update 3.2.0 and DLC (Switch 2); Windows 11; 300 seeded random 4 KiB reads; warm operating-system cache. The comparison uses the NUP Python reference reader with libzstd and the NX C++17 reader. These are results for the tested implementations and workload, not a universal format speedup or an FPS benchmark. A native-to-native comparison and a larger sample are needed before making broader claims.\n\nThe charts summarize an earlier local run whose individual read samples are not\nincluded. The [NUP comparison tools](benchmarks\u002FREADME.md#nup-and-native-package-comparisons)\ncan repeat this kind of measurement on your own dumps.\n\n### Faster packing\n\n![Packing a dump: NX vs NUP — Mario Kart World dump (Switch 2)](docs\u002Fbenchmarks\u002Fnup-vs-nx-packing.png)\n\n*NX skips compression with marginal savings, favoring faster packing and reads for a little extra space.*\n\n## Developer integration\n\n[ffi\u002Finclude\u002Fnxformat.h](ffi\u002Finclude\u002Fnxformat.h) runs any `nxconvert` command\nin process: each output line goes to a callback, and a cancel handle stops the\nrun without leaving a partial file.\n\n```c\nconst char* args[] = {\"contents\", \"game.nx\", \"--frontend\"};\nnxformat_run(args, 3, on_line, user, cancel, error, sizeof error);\n```\n\nAn emulator that decrypts games itself can hand nxformat the plaintext bytes\nwithout writing them to disk or sharing keys: `nxformat_source_new` takes a\nfile name (`.nsp` or `.xci`), a size and a read callback, and\n`nxformat_source_path` gives the path to pass to `pack`, `add` or `scan`.\n\n```c\nnxformat_source* game = nxformat_source_new(\"game.nsp\", size, read_plaintext, ctx);\nconst char* args[] = {\"pack\", nxformat_source_path(game), \"game.nx\", \"--frontend\"};\nnxformat_run(args, 4, on_line, user, cancel, error, sizeof error);\nnxformat_source_free(game);\n```\n\nThe [release workflow](.github\u002Fworkflows\u002Frelease.yml) builds one archive per\nplatform (Windows x64, Linux x64 and arm64, macOS universal, Android arm64):\n`include\u002F` (the C API and the C++ reader), `lib\u002F` (shared and static library),\n`bin\u002F` (the Windows DLL and desktop NXConvert app). Android archives contain\nlibraries and headers only. `SHA256SUMS` is a separate release attachment.\n\nFor xmake, download `nxformat-xmake-1.0.3.zip` from the release and extract it.\nIt contains the package recipe with the published archive hashes. Point xmake\nat that extracted directory:\n\n```lua\nadd_repositories(\"nxformat \u002Fpath\u002Fto\u002Fextracted\u002Fnxformat-xmake\")\nadd_requires(\"nxformat\")\ntarget(\"app\")\n    add_packages(\"nxformat\")\n```\n\nWith CMake, unpack an archive and point `nxformat_DIR` at its\n`lib\u002Fcmake\u002Fnxformat`:\n\n```cmake\nfind_package(nxformat 1.0 REQUIRED CONFIG)\ntarget_link_libraries(app PRIVATE nxformat::nxformat) # or nxformat::static, or nxformat::static_nozstd with your own libzstd\n# Copy ${NXFORMAT_RUNTIME} next to the program.\n```\n\nPushing a tag `VX.Y.Z` runs [release.yml](.github\u002Fworkflows\u002Frelease.yml): it\nbuilds and tests every platform, publishes the release and attaches a populated\nxmake repository generated from [packages\u002Fn\u002Fnxformat](packages\u002Fn\u002Fnxformat\u002Fxmake.lua).\nPublishing adds no commits to the source repository. If the release already\nexists, the workflow validates its published xmake package without rebuilding\nor replacing assets. Windows consumers explicitly target MSVC (`-p windows\n-a x64 --toolchain=msvc`), including when invoked from Git Bash.\n\n## Tests\n\n```text\n# Requires Rust, Python 3.14+, a C++17 compiler and a Zstandard runtime.\ncargo test --release --locked --manifest-path packer\u002FCargo.toml\ncargo clippy --all-targets --manifest-path packer\u002FCargo.toml -- -D warnings\ncargo test --release --locked --manifest-path ffi\u002FCargo.toml\ncargo build --release --locked --manifest-path ffi\u002FCargo.toml\npython tools\u002Ftest_c_api.py\npython tests\u002Fconformance\u002Fcheck_phase0.py\npython tests\u002Fconformance\u002Fvalidate_fixtures.py\npython tests\u002Fconformance\u002Ftest_reader.py\npython tests\u002Fconformance\u002Ftest_rust_writer.py\n```\n\n[Tests and conformance](.github\u002Fworkflows\u002Fci.yml) run on every push and pull request, and can also be started manually. Windows, Linux and macOS run Rust, C++ reader, C API, app and packaged CMake consumer checks. The workflow also checks deterministic fixtures and the generated header, and runs Linux AddressSanitizer, UndefinedBehaviorSanitizer and a one-minute coverage-guided fuzzing job. A release cannot publish unless these checks pass. Real game files are never used in CI.\n\nA code coverage percentage is not currently published. Coverage-guided fuzzing is not a line or branch coverage report.\n\n## What is in this repository\n\n| Folder | Content |\n| --- | --- |\n| [packer\u002F](packer\u002F) | Rust library: convert, edit, verify, rebuild the original files. Its `cli` module holds the `nxconvert` commands. |\n| [app\u002F](app\u002F) | NXConvert: a small native window (egui) and the same commands from a shell. |\n| [ffi\u002F](ffi\u002F) | C API ([ffi\u002Finclude\u002Fnxformat.h](ffi\u002Finclude\u002Fnxformat.h)): runs the `nxconvert` commands inside another program. |\n| [packages\u002F](packages\u002F) | xmake package of the release builds. |\n| [reader\u002F](reader\u002F) | Header-only C++17 reader. [dist\u002F](dist\u002F) holds the copy used by emulators. |\n| [docs\u002F](docs\u002F) | Format specification and usage guides. |\n| [tests\u002F](tests\u002F) | Conformance fixtures, Python validator, C++ reader tests, fuzz target. |\n| [benchmarks\u002F](benchmarks\u002F) | Reader and writer benchmark scripts. |\n| [integration\u002F](integration\u002F) | NXEmu loader patch and its export tool. |\n\nThe Rust side writes NX files. The C++ reader only reads them: an emulator\nlinks the reader for play, and the nxformat library for every change.\n\n## Documentation and development\n\n- [RELEASE.md](docs\u002FRELEASE.md): V1.0.3 release notes and platform packages.\n- [SPEC.md](docs\u002FSPEC.md): wire format and versioning.\n- [CLI.md](docs\u002FCLI.md): commands, native\u002FNUP imports, extracted-tree declarations and resource limits.\n- [READER.md](docs\u002FREADER.md): C++ API, persistent sessions, emulator integration and access profiles.\n- [SECURITY.md](docs\u002FSECURITY.md): validation rules, resource ceilings and integrity policies.\n- [RECIPE.md](docs\u002FRECIPE.md): optional exact-source reconstruction.\n- [benchmarks\u002FREADME.md](benchmarks\u002FREADME.md): performance tools and real-content acceptance checks.\n- [tests\u002F](tests\u002F), [benchmarks\u002F](benchmarks\u002F): tests, fixtures and benchmark tooling.\n\nThe project is licensed under the [MIT License](LICENSE). NXFormat is an independent project and is not affiliated with Nintendo.\n\n## NX vs NUP\n\nNUP made it possible to package decrypted Switch 1 and Switch 2 trees in one file. NX builds on that idea with a greater focus on **random reads, content changes, and predictable version handling**.\n\n| Capability | NUP reference format and tools | NX |\n| --- | --- | --- |\n| Random reads in compressed files | One Zstd frame per file; seeking can require earlier decompression | **Independent compressed blocks** |\n| Compression policy | Compress if it saves any space | **Selective Zstd; raw storage for marginal savings** |\n| Deduplication | Identical files | **Identical blocks** |\n| Several updates and DLC in one archive | Yes | **Yes** |\n| Add or remove game content later | No dedicated payload add\u002Fremove command in the reference CLI | **Incremental add\u002Fremove** |\n| Explicit update dependency tracking | Limited in the package model | **Explicit composition and dependencies** |\n| Data verification | TOC and per-file SHA-256 | **CRC-32C reads, SHA-256 and full verification** |\n| Rebuild original decrypted package bytes | No equivalent documented in NUP | **Optional embedded rebuild recipes** |\n| Import NUP | Native format | **Supported by NXConvert** |\n\nThis comparison covers the published NUP specification and reference tools. NUP also supports multiple packages, metadata editing, and SHA-256 verification.\n\nRead the [NUP specification](https:\u002F\u002Fgithub.com\u002Fa55uka\u002Fnup\u002Fblob\u002Fmeow\u002FSPEC.md), the [NUP reference CLI](https:\u002F\u002Fgithub.com\u002Fa55uka\u002Fnup\u002Fblob\u002Fmeow\u002FREADME.md), and the [NX format specification](docs\u002FSPEC.md).\n","NXFormat 是一种专为已解密的 Nintendo Switch 及 Switch 2 游戏镜像设计的高性能归档格式。它支持智能压缩、毫秒级随机读取、跨游戏\u002F更新\u002FDLC 的数据去重，以及无需重写基础镜像即可原地增删内容的增量更新机制；底层采用 Rust 实现，提供 C++17 读取器与跨平台 C API，兼顾性能与嵌入式兼容性。适用于游戏备份管理、模拟器资源加载、本地化补丁分发及 ROM 库长期归档等需要高可靠性与低延迟访问的场景。","2026-11-24 04:42:09","CREATED_QUERY"]