Skip to content

Commit 945938b

Browse files
author
amalxloop
committed
Update README with new backends, thread safety, depth testing, and CI jobs
1 parent a21ab81 commit 945938b

1 file changed

Lines changed: 14 additions & 9 deletions

File tree

README.md

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,13 @@ SilverCore removes the bridge. App logic, layout, animation, and rendering are a
2323
| Memory | `include/sc_arena.h` | Linear bump allocator + typed slab pool — zero `malloc` on the hot path |
2424
| Layout engine | `include/sc_layout.h` | Flexbox subset in C: row/column, flex-grow, flex-wrap, align-self, gap, justify-content, align-items, margin, padding |
2525
| Font system | `include/sc_font.h` | stb_truetype-based font rasterizer with glyph atlas caching and text rendering |
26-
| Graphics layer | `include/sc_gfx.h` | Backend-agnostic 2-D/3-D API with full resource management: buffers, textures, shaders, pipelines, index buffers, batch 2-D helpers |
26+
| Graphics layer | `include/sc_gfx.h` | Backend-agnostic 2-D/3-D API: buffers, textures, shaders, pipelines, depth/stencil testing, batch 2-D helpers, draw-call sorting, O(1) resource slot allocator, optional thread-safe mode |
2727
| Widget/scene | `include/sc_widget.h` | Retained widget tree with animations, events, and layout sync |
2828
| Runtime | `include/sc_runtime.h` | Cooperative fiber scheduler, MPSC task queue, min-heap timer, 60 Hz loop |
29-
| Vulkan backend | `backends/sc_backend_vulkan.h` | Full Vulkan 1.0 implementation: swapchain, offscreen, shaders via embedded SPIR-V, push constants, batch rendering, user buffer/shader/pipeline management, indexed draws |
30-
| Metal backend | `backends/sc_backend_metal.h` | Full API surface declared (make_buffer/destroy_buffer/make_texture/make_shader/make_pipeline etc.) |
31-
| D3D12 backend | `backends/sc_backend_d3d12.h` | Full API surface declared with SCD3D12Desc configuration |
29+
| Vulkan backend | `backends/sc_backend_vulkan.h` | Full Vulkan 1.0 implementation: swapchain, offscreen, SPIR-V shaders, push constants, pipeline caching by descriptor hash, batch + indexed draws |
30+
| Metal backend | `backends/sc_backend_metal.h` | Full Metal implementation (Obj-C): device, command queue, render pipeline, buffers, textures, shader compilation from source, depth/stencil, frame overlap, windowed + headless |
31+
| D3D12 backend | `backends/sc_backend_d3d12.h` | Full API surface declared with SCD3D12Desc (stub — link d3d12.lib on Windows) |
32+
| WebGPU backend | `backends/sc_backend_wgpu.h` | Full API surface declared with SCWGPUDesc (stub — link wgpu-native or Dawn) |
3233
| Python bindings | `bindings/python/silvercore.py` | ctypes wrapper + simulation mode (no native lib required) |
3334
| WASM glue | `tools/wasm/silvercore.js` | Emscripten JS bridge, Canvas2D blit, requestAnimationFrame loop |
3435
| PoC app | `apps/stock_dashboard/` | 1 024-ticker stock dashboard, 60 Hz, zero heap allocs per frame |
@@ -130,7 +131,7 @@ cmake --build build-wasm -j$(nproc)
130131

131132
| Option | Default | Description |
132133
|---|---|---|
133-
| `SC_GFX_BACKEND` | `SOFTWARE` | Graphics backend: `SOFTWARE` or `VULKAN` |
134+
| `SC_GFX_BACKEND` | `SOFTWARE` | Graphics backend: `SOFTWARE`, `VULKAN`, `METAL`, `D3D12`, or `WGPU` |
134135
| `SC_TESTS` | `ON` | Build test suite |
135136
| `SC_SHARED` | `ON` | Build shared library for Python ctypes |
136137
| `SC_ASAN` | `OFF` | Enable AddressSanitizer |
@@ -145,6 +146,9 @@ The `.github/workflows/ci.yml` runs four jobs on every push and PR:
145146
|---|---|
146147
| `test-software` | Compiles all 6 tests + stock dashboard with `-Wall -Wextra -Wpedantic -Wshadow`, runs suite, produces PPM output |
147148
| `test-vulkan` | Compiles Vulkan backend header + headless test (requires `libvulkan-dev`) |
149+
| `test-metal` | *(macOS CI only)* Compiles Metal backend as Obj-C, runs headless test |
150+
| `test-d3d12` | *(Windows CI only)* Compiles D3D12 stub, verifies stub dispatch |
151+
| `test-wgpu` | Compiles WebGPU stub, verifies stub dispatch |
148152
| `test-asan` | Same tests with AddressSanitizer enabled |
149153
| `test-ubsan` | Same tests with UndefinedBehaviourSanitizer enabled |
150154
| `wasm` | Cross-compiles with Emscripten SDK, verifies `.wasm`/`.js` output |
@@ -194,9 +198,10 @@ silvercore-kernel/
194198
│ ├── sc_widget.h Widget tree, scene, animations
195199
│ └── sc_runtime.h Fibers, tasks, timers, event loop
196200
├── backends/
197-
│ ├── sc_backend_vulkan.h Full Vulkan 1.0 backend (buffers, shaders, pipelines, indexed draws)
198-
│ ├── sc_backend_metal.h Metal stub (full API surface)
199-
│ └── sc_backend_d3d12.h D3D12 stub (full API surface + SCD3D12Desc)
201+
│ ├── sc_backend_vulkan.h Full Vulkan 1.0 backend (buffers, shaders, pipelines, indexed draws, pipeline cache)
202+
│ ├── sc_backend_metal.h Full Metal backend (Obj-C, windowed + headless)
203+
│ ├── sc_backend_d3d12.h D3D12 stub (full API surface + SCD3D12Desc)
204+
│ └── sc_backend_wgpu.h WebGPU stub (full API surface + SCWGPUDesc)
200205
├── bindings/
201206
│ └── python/silvercore.py
202207
├── tools/
@@ -215,7 +220,7 @@ silvercore-kernel/
215220
│ ├── test_arena.c
216221
│ ├── test_math.c
217222
│ ├── test_layout.c 35 tests (wrap, gap, align-self, edge cases)
218-
│ ├── test_gfx.c 9 tests (boundary conditions, frame loop)
223+
│ ├── test_gfx.c 26 tests (boundary conditions, frame loop, depth/stencil, thread safety, resize)
219224
│ ├── test_font.c Font tests (requires TEST_FONT_PATH)
220225
│ └── test_runtime.c
221226
└── CMakeLists.txt

0 commit comments

Comments
 (0)