Skip to content

Architecture

SpaceSquare640 edited this page Jun 14, 2026 · 1 revision

Architecture

RB Skin Forge is one shared C# core with three thin front-ends on top.

Source_Code/
  RB_Skin_Forge.Core/   Shared logic — models, pipeline, parsers, engines, localization
  RB_Skin_Forge.Web/    Blazor WebAssembly (HTML)
  RB_Skin_Forge.Maui/   .NET MAUI → .exe (Windows) + .apk (Android)

The Core library

All the real work lives here so every platform behaves identically.

  • ModelsAssetInput (in-memory file: name + bytes, no filesystem dependency), MeshData (positions / texcoords / normals / faces / materials / attachments), ProcessingResult, QualityReport, RobloxSpec (the limits), enums.
  • PipelineIAssetPipeline / AssetPipeline routes each input by type: images → the image processor, meshes → the geometry engine.
  • 2D enginesAssetIngestionEngine, TemplateGenerator (585 × 559 contain-fit + edge-fill), ImageProcessor, RobloxSpecValidator.
  • 3D enginesObjParser, FbxParser (ASCII), GeometryEngine (clean → scale → decimate → rig → export → validate), MeshDecimator (vertex clustering), AutoRigger (attachment placement), MeshRenderer (wireframe PNG).
  • LocalizationLocalizer + Strings provide the shared 10-language UI string table. Engine log lines stay in English (technical); only UI chrome is translated.

Front-ends

Each front-end is intentionally thin — it collects files, calls IAssetPipeline.ProcessAsync, and renders the ProcessingResult (preview, stats, console log, downloadable output). They share the same Localizer so there's a single source of truth for translations.

  • Web (Blazor)Pages/Home.razor, a self-contained stylesheet (wwwroot/css/app.css), and JS helpers for downloads + theme/language persistence (localStorage).
  • MAUI (Windows/Android)MainPage.xaml(.cs), themed styles in Resources/Styles, theme persisted via Preferences.

Key design choices

  • Pure-managed imaging (SixLabors.ImageSharp 3.1.x) so it runs under WebAssembly — no native dependencies.
  • In-memory AssetInput so the same code path works in the browser, on Windows, and on Android.
  • No 3D viewport — previews are flat wireframe PNGs drawn with a Bresenham line into a pixel buffer, avoiding heavy 3D dependencies.
  • Binary FBX is rejected, not bodged — there's no WebAssembly-safe binary-FBX library, so the app fails fast with clear guidance rather than half-working.

See also: Building from Source · 3D Pipeline and Auto-Rigging

Clone this wiki locally