This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| Super bare-bones mesh exporter script. | |
| Exports into a minimal data format ready to upload to the GPU. | |
| Vertices are deduplicated, and using index buffer. | |
| Mesh is triangulated. Hard edges are preserved. | |
| Coordinates are mesh-local, converted to Y-up. | |
| --- Data Format --- | |
| VERTEX_COUNT: u32 | |
| INDEX_COUNT: u32 | |
| VERTEX_BUFFER: float[VERTEX_COUNT][8] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import "core:os"; | |
| import "core:fmt"; | |
| import "core:strconv"; | |
| import "core:strings" | |
| Vec3 :: [3]f32 | |
| Vec2 :: [2]f32 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Godot; | |
| using Flecs.NET.Core; | |
| using static Flecs.NET.Bindings.Native; | |
| public partial class FlecsBootstrapper : Node3D | |
| { | |
| [Export] | |
| Mesh renderMesh; | |
| [Export] |