{"id":47704454,"url":"https://github.com/ryanzll/revittruegltf","last_synced_at":"2026-05-15T13:07:29.024Z","repository":{"id":346055332,"uuid":"1187166303","full_name":"ryanzll/RevitTrueGltf","owner":"ryanzll","description":"A high-fidelity Revit to gltf exporter","archived":false,"fork":false,"pushed_at":"2026-04-26T02:26:27.000Z","size":4084,"stargazers_count":14,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2026-04-26T04:21:53.473Z","etag":null,"topics":["export","gltf","pbr","revit"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ryanzll.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-20T12:19:07.000Z","updated_at":"2026-04-26T02:26:31.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/ryanzll/RevitTrueGltf","commit_stats":null,"previous_names":["ryanzll/revittruegltf"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/ryanzll/RevitTrueGltf","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanzll%2FRevitTrueGltf","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanzll%2FRevitTrueGltf/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanzll%2FRevitTrueGltf/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanzll%2FRevitTrueGltf/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ryanzll","download_url":"https://codeload.github.com/ryanzll/RevitTrueGltf/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanzll%2FRevitTrueGltf/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33067520,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-15T11:35:32.926Z","status":"ssl_error","status_checked_at":"2026-05-15T11:35:31.362Z","response_time":103,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["export","gltf","pbr","revit"],"created_at":"2026-04-02T17:50:30.759Z","updated_at":"2026-05-15T13:07:29.018Z","avatar_url":"https://github.com/ryanzll.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\n  \u003cimg src=\"images/RevitTrueGltf.png\" alt=\"RevitTrueGltf Logo\" width=\"192\"/\u003e\n  \u003cbr/\u003e\n  RevitTrueGltf\n\u003c/h1\u003e\n\nRevitTrueGltf is an advanced Revit to glTF 2.0 exporter plugin built for both high-fidelity rendering and full BIM data integration. It faithfully preserves PBR materials and complete element parameters, bridging the gap between Revit authoring and modern 3D engines (e.g., Babylon.js, Three.js) for Digital Twins and O\u0026M workflows.\n\n## 1. Project Introduction\n\nExporting from Revit to standard 3D formats has long suffered from material distortion, lost transparency, and stripped metadata. RevitTrueGltf addresses all three: it deeply extracts physical material properties (including complex transmissive glass via `KHR_materials_transmission`) and provides flexible BIM data export strategies—Flat Embedded JSON, Shared Schemas, or standalone SQLite databases—so your models arrive in the target engine both visually faithful and structurally data-rich.\n\n### Visual Comparison (Revit vs glTF)\n\n*(Note: The actual rendering appearance in Revit varies significantly depending on the selected **Visual Style** (e.g., Shaded vs. Realistic). RevitTrueGltf exports physically based properties to closely match Revit's high-fidelity **Realistic** or rendered outputs.)*\n\n| Revit Internal Rendering | RevitTrueGltf Export (e.g., in Babylon.js) |\n| :---: | :---: |\n| **Exterior View**\u003cbr\u003e![Exterior view in Revit](images/revit-exterior-view.png) | **Exterior View**\u003cbr\u003e![Exterior view in glTF](images/gltf-exterior-view.png) |\n| **Interior View**\u003cbr\u003e![Interior view in Revit](images/revit-interior-view.png) | **Interior View**\u003cbr\u003e![Interior view in glTF](images/gltf-interior-view.png) |\n\n## 2. Supported Revit Versions\n\nBy configuring Multi-Targeting Frameworks, the project natively supports a wide range of Revit versions.\n\n| Revit Version | Compiled Target | Tested |\n| :---: | :---: | :---: |\n| **2020** | ✔️ | ✔️ |\n| **2021** | ✔️ | - |\n| **2022** | ✔️ | - |\n| **2023** | ✔️ | - |\n| **2024** | ✔️ | - |\n| **2025** | ✔️ | - |\n| **2026** | ✔️ | - |\n\n## 3. Supported Exported PBR Information\n\nIn terms of material conversion, the exporter deeply analyzes Revit's internal material assets and maps them to glTF 2.0 PBR material extensions.\n\n- **Base Color (Albedo)**: Extracted directly from Revit's generic or specific materials, including base texture maps and tints.\n- **Metallic \u0026 Roughness**: Fully supports the standardized PBR Metallic-Roughness workflow, reliably restoring the reflection and roughness characteristics of material surfaces.\n- **Normal Maps (Converted from Bump)**: Because Revit internally uses grayscale Bump Maps, the plugin features a high-performance, zero-allocation algorithm to dynamically convert them into standard Tangent-Space Normal Maps. This ensures correct bump mapping and surface detail in standard rendering engines.\n- **Glazing / Transmissive Materials**: Specifically targets Revit's glazing material classes. It uses the `KHR_materials_transmission` extension for physically accurate glass. This correctly exports **Transmission** (light passthrough), **Index of Refraction (IOR)**, and **Volume** properties. It also implements a standard Alpha Blending fallback for simpler renderer compatibility.\n- **Transparency / Opacity**: Extracts and configures proper blending modes and alpha cutoffs based on the source Revit material setup.\n- **Revit Parameters**: Extracts original Revit parameters (Identity Data, Dimensions, Project Info) and provides three distinct export modes to suit different application scenarios:\n    - **Flat Embedded**: Directly embeds parameter data into each glTF node's `extras`. This is the most compatible mode for standard glTF viewers and is ideal for **prototyping and rapid development validation**, as metadata can be inspected immediately without additional processing.\n    - **Schema Referenced**: Stores a global parameter schema at the root and uses indexed references for each element. This significantly reduces redundancy and file size for large-scale models.\n    - **External SQLite**: Exports parameter data into a standalone `.sqlite` database companion file. This is the professional choice for **Operation \u0026 Maintenance (O\u0026M)** systems, allowing for flexible post-processing, data transformation, and real-time backend updates without modifying the 3D model itself.\n\n- **Logical Element Hierarchy**: Reconstructs the full Revit logical structure (Curtain Walls, Groups, Nested Families) within the glTF scene graph. \n    - **BIM \u0026 O\u0026M Ready**: Parameters attach to logical parents, ensuring data integrity for asset management and Digital Twins.\n\n\n    | Before (Flat Mesh) | After (Logic Tree) |\n    | :---: | :---: |\n    | ![Flat Hierarchy](images/hierarchy-1.png) | ![Structured Hierarchy](images/hierarchy-2.png) |\n\n### Detailed Material \u0026 Data Support Matrix\n\n| Material Property / Feature | Supported | Planned (Roadmap) |\n| :--- | :---: | :---: |\n| **Base Color / Tint / Albedo Texture** | ✔️ | - |\n| **Metallic \u0026 Roughness** | ✔️ | - |\n| **Grayscale Bump to Normal Map** | ✔️ | - |\n| **Glazing (Transmission, IOR, Volume)** | ✔️ | - |\n| **Transparency (Alpha Blend / Cutoff)** | ✔️ | - |\n| **Emissive (Self-Illumination)** | - | - |\n| **Revit Decals** | - | - |\n| **Procedural Maps (Wood, Marble, etc.)** | - | - |\n| **Advanced Texture Transform (UV Offset/Scale)**| - | - |\n| **Basis Universal (KTX2) Texture Compression** | ✔️ | - |\n| **Draco Geometry Compression** | - | - |\n| **Meshoptimizer Support** | ✔️ | - |\n| **Extract Revit parameters** | ✔️ | - |\n| **Level Export \u0026 Element-Level Association** | ✔️ | - |\n\n## 4. How to Install \u0026 Test\n\nSince there is currently no pre-built `.msi` installer, you can load the plugin into Revit manually. Setting it up involves 3 simple steps:\n\n### Step 1: Obtain the Plugin Files (Choose one method)\nYou can get the required `.dll` and `.addin` template files in two ways:\n\n**Method A: Download Pre-compiled Release (For general users)**\n1. Go to the **Releases** page of this repository.\n2. Download the pre-compiled `.zip` file for your target Revit version.\n3. Extract the contents into a local folder.\n\n**Method B: Compile from Source (For developers)**\n1. Open `RevitTrueGltf.sln` in Visual Studio.\n2. Build the project for your target Revit version (e.g., `Debug2024` or `Release2024`). The compiled `RevitTrueGltf.dll` will be generated in your output directory (e.g., `bin/2024/`).\n3. Locate the template `RevitTrueGltf.addin` file at the root of this repository.\n\n### Step 2: Configure the `.addin` File\nOnce you have the `.dll` and `.addin` files from Step 1:\n1. Open the `.addin` file with any text editor (like Notepad).\n2. Find the `\u003cAssembly\u003e` tag line.\n3. Replace the placeholder text with the **absolute path** to your `RevitTrueGltf.dll` (e.g., `\u003cAssembly\u003eD:\\RevitTrueGltf\\RevitTrueGltf.dll\u003c/Assembly\u003e`). \n4. Save the file.\n\n### Step 3: Install and Run in Revit\n1. **Copy the edited `.addin` file** into one of the standard Revit plugin directories for your target version (e.g., `2024`). Common paths include:\n   - **Current User (Testing):** `%AppData%\\Autodesk\\Revit\\Addins\\\u003cYear\u003e` (e.g., `C:\\Users\\\u003cYourUsername\u003e\\AppData\\Roaming\\Autodesk\\Revit\\Addins\\2024`)\n   - **All Users (Global):** `%ProgramData%\\Autodesk\\Revit\\Addins\\\u003cYear\u003e` (e.g., `C:\\ProgramData\\Autodesk\\Revit\\Addins\\2024`)\n2. **Launch Revit** and open a 3D view. \n3. Go to the **Add-Ins \u003e External Tools** ribbon and click **Export True glTF**.\n\n## 5. Building the Installer (MSI)\n\nThis project uses **WiX Toolset v5** to create a single multi-version installer that supports Revit 2020 through 2026.\n\n### Prerequisites\nInstall the WiX Toolset via the .NET tool CLI:\n```cmd\ndotnet tool install --global wix\n```\n\n### Build Steps\n1. **Compile Revit Versions:** Run the root build script to generate binaries for all supported years:\n   ```cmd\n   build.bat\n   ```\n2. **Generate MSI:** Build the installer project:\n   ```cmd\n   dotnet build installer\\RevitTrueGltf.Installer.wixproj -c Release\n   ```\n3. **Output:** The final installer is located at:\n   `installer\\bin\\x64\\Release\\RevitTrueGltf.msi`\n\n## 6. Default Installation Paths\n\nWhen using the MSI installer, the plugin is deployed to the standard Autodesk directory for all users:\n\n- **Plugin Core \u0026 Binaries:**\n  `%ProgramData%\\Autodesk\\ApplicationPlugins\\RevitTrueGltf\\`\n  - `lib/`: Shared dependencies (netfx/net8)\n  - `tools/`: Shared tools (e.g., gltfpack.exe)\n  - `{Year}/`: Version-specific plugin assemblies\n- **Revit Addin Manifests:**\n  `%ProgramData%\\Autodesk\\Revit\\Addins\\{Year}\\RevitTrueGltf.{Year}.addin`\n\n## 7. Open-Source Projects Used\n\nThe successful build of this plugin relies on the following excellent open-source libraries. We highly appreciate their contributions:\n\n- **[SharpGLTF](https://github.com/vpenades/SharpGLTF)** (`SharpGLTF.Core` and `SharpGLTF.Toolkit`): An outstanding glTF/glb read-write framework. This project heavily utilizes it to construct the scene graph, manage materials, and serialize the standard-compliant glTF binaries.\n- **[ImageSharp](https://github.com/SixLabors/ImageSharp)** (`SixLabors.ImageSharp`): A cross-platform, high-performance image processing library. It handles the critical background texture modifications, in particular mapping and regenerating pixels for the Bump Map to Normal Map process.\n\n## 6. Contributing \u0026 Feedback\n\nWe warmly welcome all forms of contributions to make RevitTrueGltf better! \n\nIf you have any suggestions, feature requests (such as supporting more Revit material types), or encounter any bugs, please feel free to:\n- Open an **Issue** to discuss your ideas or report problems.\n- Submit a **Pull Request (PR)** if you are interested in joining the development and contributing directly to the codebase.\n\nLet's build a better, high-fidelity Revit-to-glTF exporter together!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanzll%2Frevittruegltf","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fryanzll%2Frevittruegltf","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanzll%2Frevittruegltf/lists"}