scad-gltf 0.2.2 β†’ 0.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -22,7 +22,7 @@ The C++ source code for this custom OpenSCAD version is included directly in thi
22
22
  - **CLI Converter:** Bundled `scad-convert` CLI utility for single file and batch compiling `.scad` files with smart dependency hashing.
23
23
  - **MCP Server for AI Agents:** Bundled `scad-mcp` server enables MCP clients to iteratively design, compile, and **visually inspect** 3D models via multi-angle headless rendering and animation frame evaluation.
24
24
  - **AI Studio Extension:** Chrome extension to natively preview, prompt, take chat snapshots, open in Scadify, and locally save AI-generated 3D models directly inside Google AI Studio.
25
- - **Godot 4, Rust Bevy & Web Integration:** Native Godot 4 importer addon, Rust Bevy compile-time `build.rs` integration, and prebuilt AI-generated game examples for Godot and Bevy.
25
+ - **Godot 4, Rust Bevy & Web Integration:** Native Godot 4 importer addon and Rust Bevy compile-time `build.rs` integration.
26
26
  - **Automated AI Generation:** Pass an OpenAI-compatible base URL (and optional API key) to the `scad-godot`, `scad-bevy`, or `scad-web` CLI to automatically spawn a local MCP server, query the LLM via standard endpoints, allow it to visually iterate, and output a ready-to-run project generator script.
27
27
 
28
28
  ---
@@ -287,11 +287,7 @@ This repository includes an official **Godot 4.x Importer Addon** located in the
287
287
 
288
288
  The addon allows you to drag-and-drop `.scad` files directly into your Godot project. It uses this WASM compiler under the hood to transform scripts into 3D scenes automatically.
289
289
 
290
- **πŸ•ΉοΈ Play Web Demos (No Installation Required):**
291
- Try prebuilt AI-generated Godot games directly in your browser: [https://iliagrigorevdev.github.io/scad-godot/](https://iliagrigorevdev.github.io/scad-godot/)
292
-
293
290
  - **Features:** Supports PBR Materials and Hierarchical Node Animations inside the Godot Editor.
294
- - **Examples:** Check out AI-generated game templates in the [`godot/examples`](./godot/examples) directory.
295
291
  - **License:** The Godot Addon is licensed under **MIT**.
296
292
  - **Setup:** Simply copy the `addons/scad_importer` folder to your project and enable it in Project Settings.
297
293
 
package/godot/README.md CHANGED
@@ -4,9 +4,6 @@ This folder contains the official Godot 4.x Editor plugin for natively importing
4
4
 
5
5
  By leveraging the `scad-gltf` compiler under the hood, this addon allows you to drag and drop procedural CAD files directly into your Godot project. It automatically compiles them into binary glTF (`.glb`) meshes, supporting advanced features like **PBR materials**, **hierarchical node animations**, and **texture baking**β€”all natively within the Godot editor.
6
6
 
7
- **πŸ•ΉοΈ Play Online in Your Browser (No Installation Required):**
8
- πŸ‘‰ **[https://iliagrigorevdev.github.io/scad-godot/](https://iliagrigorevdev.github.io/scad-godot/)**
9
-
10
7
  ## ✨ Features
11
8
 
12
9
  - **Seamless Integration**: Drag and drop `.scad` files directly into the Godot FileSystem dock.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "scad-gltf",
3
- "version": "0.2.2",
3
+ "version": "0.2.4",
4
4
  "description": "WASM build of a custom OpenSCAD fork that compiles .scad scripts directly to glTF/GLB with PBR and animation support",
5
5
  "type": "module",
6
6
  "main": "./src/ext/openscad.js",
@@ -22,7 +22,6 @@
22
22
  "3d",
23
23
  "cad",
24
24
  "godot",
25
- "bevy",
26
25
  "mcp",
27
26
  "ai"
28
27
  ],
@@ -30,7 +29,6 @@
30
29
  "bin",
31
30
  "src",
32
31
  "godot",
33
- "bevy",
34
32
  "editor/dist"
35
33
  ],
36
34
  "bin": {
package/bevy/README.md DELETED
@@ -1,46 +0,0 @@
1
- # OpenSCAD GLTF Integration for Rust Bevy
2
-
3
- This folder contains resources and examples for integrating procedural OpenSCAD (`.scad`) 3D assets natively into the [Bevy](https://bevyengine.org/) game engine using the `scad-gltf` compiler.
4
-
5
- Unlike Godot (which uses a native editor plugin), Bevy integration is achieved programmatically at compile-time using a custom `build.rs` script. This script automatically watches your `.scad` files and compiles them into binary `.glb` meshes in your `assets/models` folder before the game compiles and runs.
6
-
7
- ## πŸ› οΈ How It Works
8
-
9
- To use OpenSCAD files in your Bevy project, ensure you have the CLI compiler installed globally on your machine:
10
-
11
- ```bash
12
- npm install -g scad-gltf
13
- ```
14
-
15
- Then, add a `build.rs` script to the root of your Bevy project (next to `Cargo.toml`):
16
-
17
- ```rust
18
- use std::process::Command;
19
-
20
- fn main() {
21
- // Tell Cargo to re-run this script only if the 'scad' directory changes
22
- println!("cargo::rerun-if-changed=scad");
23
-
24
- // Ensure cross-platform compatibility for npm global binaries
25
- let cmd = if cfg!(target_os = "windows") {
26
- "scad-convert.cmd"
27
- } else {
28
- "scad-convert"
29
- };
30
-
31
- let status = Command::new(cmd)
32
- .args(["./scad", "./assets/models", "--cache"])
33
- .status()
34
- .expect("Failed to execute scad-convert. Is scad-gltf installed globally?");
35
-
36
- if !status.success() {
37
- panic!("scad-convert failed with status: {}", status);
38
- }
39
- }
40
- ```
41
-
42
- Now, any `.scad` files placed in your `scad/` directory will automatically be converted to `.glb` when you run `cargo build` or `cargo run`. They can then be loaded natively in Bevy via the Asset Server:
43
-
44
- ```rust
45
- let my_model = asset_server.load("models/my_model.glb#Scene0");
46
- ```
@@ -1,21 +0,0 @@
1
- MIT License
2
-
3
- Copyright (c) 2026 Ilia Grigorev
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
@@ -1,58 +0,0 @@
1
- # AI-Generated Bevy Examples
2
-
3
- This folder contains a collection of **all-in-one Node.js scripts**, each representing a complete, playable 3D Rust Bevy game generated entirely by AI using the `scad-bevy` CLI tool.
4
-
5
- Instead of committing messy project folders, each example is bundled into a single, self-extracting JavaScript file. These scripts contain the generated OpenSCAD (`.scad`) 3D assets, Rust source code (`main.rs`), and the required `build.rs` and `Cargo.toml` configurations.
6
-
7
- ---
8
-
9
- ## πŸš€ How to Play the Examples
10
-
11
- To test out an example, you need to extract it and run it using Cargo.
12
-
13
- ### Prerequisites
14
-
15
- - **Node.js** installed on your system.
16
- - **Rust and Cargo** installed on your system.
17
- - **scad-gltf** installed globally: `npm install -g scad-gltf`
18
-
19
- ### Step 1: Extract the Project
20
-
21
- Open your terminal in this folder and execute the desired example script using Node.js:
22
-
23
- ```bash
24
- node packman_3d.js
25
- ```
26
-
27
- _The script will automatically create a new folder (e.g., `./packman_3d`) containing the full Bevy project directory structure, saving all the assets and Rust files to disk._
28
-
29
- ---
30
-
31
- ### Step 2: Compile & Play
32
-
33
- Navigate into the newly extracted project folder and use Cargo to run the game:
34
-
35
- ```bash
36
- cd packman_3d
37
- cargo run
38
- ```
39
-
40
- _The `build.rs` script will automatically invoke `scad-convert` to compile the OpenSCAD assets into `.glb` format before Bevy boots up._
41
-
42
- ---
43
-
44
- ## πŸ› οΈ How were these generated?
45
-
46
- These files were created using this repository's built-in AI prompt pipeline. By running the `scad-bevy` CLI command, the system instructs an LLM (like Claude, Gemini, or ChatGPT) to generate procedural OpenSCAD geometry, gameplay logic, and scene configurations, outputting them as a single JS extractor script.
47
-
48
- If you want to generate your own games, run:
49
-
50
- ```bash
51
- scad-bevy "A simple 3D platformer where you control a rolling ball collecting coins"
52
- ```
53
-
54
- _(See the main repository documentation for full details on generating your own AI projects)._
55
-
56
- ## πŸ“œ License
57
-
58
- These examples are licensed under the [MIT License](LICENSE).
@@ -1,5 +0,0 @@
1
- {
2
- "name": "scad-bevy-examples",
3
- "private": true,
4
- "type": "commonjs"
5
- }