Commit graph

3776 commits

Author SHA1 Message Date
jack
9148754b76
sysgpu: spirv codegen fix (#1234) 2024-07-29 12:00:45 -07:00
Stephen Gutekanst
3ea364413b objc-generator: move to github.com/hexops/mach-objc
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-07-14 10:04:00 -07:00
Stephen Gutekanst
03a8445b90 objc-generator: update to latest nominated Zig
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-07-13 18:50:42 -07:00
Stephen Gutekanst
6e2f937026 core: add Null backend to show what implementing a backend looks like
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-07-13 15:48:07 -07:00
Hordur Johannsson
c32e763e11
add new win32 platform implementation (#1224)
* Buffer resources from swap chain were not being released.
* sysgpu Texture.getWidth() should return width not height.
* d3d12: Fixing issues with d3d12 on sysgpu.
* Initial win32 platform
2024-07-13 15:33:45 -07:00
Ali Cheraghi
3fa889b136 core: revive wayland 2024-07-13 09:06:35 -07:00
Ali Cheraghi
0023ab14fb {vulkan,examples}: fix descriptor set bug 2024-07-13 09:06:35 -07:00
Ali Cheraghi
266e7a548b core: refactor 2024-07-13 09:06:35 -07:00
Ali Cheraghi
c254337e4b {core, build}: remove glfw 2024-07-13 09:06:35 -07:00
Ali Cheraghi
539aadf664 sysgpu: remove everything related to dawn 2024-07-13 09:06:35 -07:00
Stephen Gutekanst
98801a258e remove Dawn / WebGPU support in favor of sysgpu
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-07-07 22:08:16 -07:00
Stephen Gutekanst
e6cecc3ebe core: remove all examples
These examples were great at showing how to use the WebGPU and sysgpu APIs
but otherwise had poor code quality, depended on zmath instead of mach.math,
etc. and so are being removed.

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-07-07 22:08:16 -07:00
Stephen Gutekanst
2385b93a2b github: update dev release process
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-07-07 21:23:24 -07:00
Hordur Johannsson
9e4611d5d6 Buffer resources from swap chain were not being released. 2024-07-07 20:03:17 -07:00
Stephen Gutekanst
2f0415a603 sysgpu: fix Texture.getWidth()
Authored by @hordurj in https://github.com/hexops/mach/pull/1220/commits/235decb4aa5736f4f25643e960c74ae41088ad4e

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-07-06 11:18:30 -07:00
Stephen Gutekanst
d9e11a8296 Audio: respect volume properly
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-07-06 11:16:55 -07:00
Stephen Gutekanst
316f2354d1 mach: add centralized is_debug flag
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-16 10:05:08 -07:00
Stephen Gutekanst
b72f0e11b6 build: update Zig version check
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 19:00:43 -07:00
Stephen Gutekanst
742b87709f zigversion: update to Zig 2024.05
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 18:59:25 -07:00
Stephen Gutekanst
2a7e6049fd linux: update to latest vulkan-zig API; fix build
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 18:57:45 -07:00
Stephen Gutekanst
130c474874 fix windows build
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 18:57:45 -07:00
Stephen Gutekanst
707e5cc756 update to Zig 2024.05
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 18:57:45 -07:00
Wrench[bot]
c64bc513b9 all: update Zig to version 0.13.0-dev.351+64ef45eb0
Signed-off-by: Wrench[bot] <wrench@hexops.com>
2024-06-02 18:57:45 -07:00
Stephen Gutekanst
3df871d8b1 github: update Zig nomination issue template
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 12:01:25 -07:00
Stephen Gutekanst
ad43834b78 github: update Zig nomination issue template
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 10:43:55 -07:00
Stephen Gutekanst
4ac8de4692 examples: move core examples into core/ folder; add triangle example
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 10:15:01 -07:00
Stephen Gutekanst
1b448dd02a github: update Zig nomination issue template
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 09:57:26 -07:00
Stephen Gutekanst
2f406c341f move mach-objc-generator to src/mach/objc-generator
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 09:57:01 -07:00
Stephen Gutekanst
570c5f26ec update .gitignore for Zig 2024.05
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 09:35:13 -07:00
Stephen Gutekanst
b09b462ef1 src/sysjs: move sysjs@v0 to here
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 09:34:39 -07:00
Stephen Gutekanst
c06dc261c8 dev: update Zig nomination issue template
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 09:01:29 -07:00
Stephen Gutekanst
ffd03c3b0b remove examples that require model3d
See hexops/mach#969

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-06-02 09:01:09 -07:00
Stephen Gutekanst
13ff5097db module: fix potential archetype hash collision lookup issues
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-26 18:04:08 -07:00
Stephen Gutekanst
b6a7296251 sysaudio: examples: add support for 8ch output
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-26 13:00:29 -07:00
Stephen Gutekanst
aa0ec4ba5e module: remove archetypeByID, improve "entity does not exist" error cases
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-24 13:42:29 -07:00
Stephen Gutekanst
f4f89af8b9 gfx: Sprite/Text: add ability to specify view*projection matrix
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-24 07:17:14 -07:00
Stephen Gutekanst
b261a8177f gfx: Sprite: sort/draw sprites back-to-front always
Prior to this change sprite draw order was not something we could specify,
now we can by changing the Z value of sprites (sprites further away / with
greater Z values are drawn first), which is obviously desirable for layering
and alpha blending purposes.

The implementation here is rather naive: we sort all sprites each frame based
on their Z value; but its performance is quite good with ~half a million sprites
and so is good enough for now.

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-22 18:13:26 -07:00
Stephen Gutekanst
1237858359 math: fix projection2D bug with reverse-z
This went unnoticed because our test had near=-100 and far=100 which
is pretty uncommonly balanced, added a new test near=0 far=100 to test
for this.

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-22 18:12:34 -07:00
Stephen Gutekanst
a6157642b8 Audio: fix accounting for remainder of sample buffer
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-22 17:35:22 -07:00
Stephen Gutekanst
4ac222b36c gfx: Sprite: minor shader simplification
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-22 08:24:40 -07:00
Stephen Gutekanst
031164d9b5 gfx: Text: add ability to change font color
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-22 08:22:25 -07:00
Stephen Gutekanst
f79351ed59 wip
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-22 08:21:33 -07:00
Stephen Gutekanst
18e32ee6bf build: use ReleaseFast for opus decoding
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-18 17:06:20 +02:00
Stephen Gutekanst
205a1f33db Core: support configuring window before it opens
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-14 00:12:26 +02:00
Stephen Gutekanst
122a1ea9a7 {gfx,examples}: simplify text rendering API a bit
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-14 00:12:26 +02:00
Stephen Gutekanst
393320aa68 build: do not force install/build of core- examples
CoreApp users can call b.installArtifact(app.compile) themselves if
they desire that behavior

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-14 00:12:26 +02:00
Ali Chraghi
182c6a9180 math: collision module 2024-05-14 00:07:47 +02:00
Ali Chraghi
6e5c68c1c7 Audio: don't deinit the player 2024-05-13 14:54:51 +02:00
Ali Chraghi
39bf303057 Audio: add volume component 2024-05-13 14:54:51 +02:00
Stephen Gutekanst
9a059d6f8c Audio: fix unlock
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2024-05-13 07:57:38 +02:00