Commit Graph

10498 Commits

Author SHA1 Message Date
Hajime Hoshi efab369512 all: go fix 2026-03-15 17:46:48 +09:00
Hajime Hoshi b78d867e7a internal/colormshader: extract ColorM shader logic from builtinshader
Create a new internal/colormshader package that owns the color matrix
shader generation, fully independent of internal/builtinshader. It has
its own shader template with ColorM logic baked in, its own
Filter/Address types, and a go:generate pipeline producing defs.go.

This removes the useColorM dimension from internal/builtinshader,
reducing it from 18 shader variants to 9. The colorm package now
imports only colormshader (not builtinshader) for shader sources,
preparing for the v2/v3 split where v2's colorm cannot access v3's
builtinshader.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-14 15:59:50 +09:00
Hajime Hoshi b1101bb967 Revert "internal/colormshader: extract ColorM shader logic from builtinshader"
This reverts commit 708b3d4cf8.

Reason: test failures
2026-03-14 15:55:19 +09:00
Hajime Hoshi 708b3d4cf8 internal/colormshader: extract ColorM shader logic from builtinshader
Create a new internal/colormshader package that owns the color matrix
shader generation, fully independent of internal/builtinshader. It has
its own shader template with ColorM logic baked in, its own
Filter/Address types, and a go:generate pipeline producing defs.go.

This removes the useColorM dimension from internal/builtinshader,
reducing it from 18 shader variants to 9. The colorm package now
imports only colormshader (not builtinshader) for shader sources,
preparing for the v2/v3 split where v2's colorm cannot access v3's
builtinshader.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-14 15:47:25 +09:00
TotallyGamerJet 839bcc9fb5 internal/graphicsdriver/metal: convert to purego (#3411)
Updates #1162
2026-03-13 15:15:46 +09:00
Hajime Hoshi 31c195e344 Revert ".github/workflows: re-enable Android test for Windows"
This reverts commit 9385ff8f11.

Reason: this didn't resolve the issue.

Updates #3362
2026-03-13 02:13:14 +09:00
Hajime Hoshi 0793390468 .github/workflows: add retry logic for Wasm tests
Updates #2982

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 02:09:58 +09:00
Hajime Hoshi 9385ff8f11 .github/workflows: re-enable Android test for Windows
Closes #3362
2026-03-13 01:46:41 +09:00
TotallyGamerJet 3fa4cad5bb exp/textinput: convert to purego (#3410)
Updates #1162
2026-03-13 00:28:43 +09:00
Hajime Hoshi 23fd98f097 internal/colormode: fix wrong byte length for NSString UTF-8 conversion
NSString's length returns UTF-16 code unit count, not UTF-8 byte
count. Use lengthOfBytesUsingEncoding: with NSUTF8StringEncoding
instead.

Updates ebitengine/purego#438

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 00:18:43 +09:00
Hajime Hoshi a61219607b .github/workflows: drop Go 1.24 support 2026-03-12 13:58:38 +09:00
Hajime Hoshi 26819f0a29 all: update dependencies 2026-03-12 13:54:57 +09:00
Hajime Hoshi 3a9e3846cf exp/textinput: bug fix: wrong conversion from UTF-8 to UTF-16 2026-03-12 13:40:56 +09:00
Hajime Hoshi b35899ed06 internal/ui: store color mode before RunGame to avoid nil dereference
Closes #3409

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-10 22:55:25 +09:00
Hajime Hoshi fcf531f249 internal/gamepad, internal/gamepaddb: rename files from hid to iokit
Updates #2014
Updates #2015
2026-03-05 01:45:03 +09:00
Hajime Hoshi 1c2d5f8c52 internal/gamepad: update comments
Updates #2014
Updates #2015
2026-03-04 23:36:00 +09:00
Hajime Hoshi 9b968a8856 internal/gamepad: fix swapped arguments
Updates #2014
Updates #2015
2026-03-04 13:00:39 +09:00
Hajime Hoshi 93c19f25dd internal/gamepad: remove unnecessary conditions
Updates #2014
Updates #2015
2026-03-04 12:54:36 +09:00
Hajime Hoshi 87eb2af572 .github/workflows: update wasmbrowsertest 2026-03-04 01:28:56 +09:00
John Schember 4bbcb54c9c internal/gamepad: add rumble via CoreHaptics to GC Darwin (#3401)
Add rumble to GC Darwin gamepad. Currently on works on iOS but once / if macOS
uses GC it will work on macOS too.

Updates #2014
Updates #2015
2026-03-04 00:42:55 +09:00
Hajime Hoshi 7398e080ce all: update go-text/typesetting to v0.3.4 2026-03-03 17:42:19 +09:00
Hajime Hoshi 256980ff68 text/v2: use font.NewFace instead of &font.Face{}
Updates go-text/typesettings#237
2026-03-03 17:40:08 +09:00
Hajime Hoshi 2a9d49a43b all: update errcheck 2026-03-03 13:43:11 +09:00
Hajime Hoshi fbd0c9e0fe internal/ui: refactoring: remove a mutex for error values 2026-03-03 01:20:09 +09:00
Hajime Hoshi a5fdfa181b internal/ui: use errors.Join at setError not to miss multiple errors 2026-03-03 00:43:37 +09:00
Hajime Hoshi a9bee24711 internal/ui: use atomic values to reduce mutex usages for mobile
Updates #3403
2026-03-02 23:43:38 +09:00
Hajime Hoshi 83d6bee4c2 internal/ui: use atomic values to reduce mutex usages
Updates #3403
2026-03-02 23:18:33 +09:00
Hajime Hoshi 13d83f74b0 internal/ui: use atomic values to reduce mutex usages
Updates #3403
2026-03-02 22:33:15 +09:00
Hajime Hoshi c1069c18e7 internal/ui: avoid creating closures at (*glfwWindow).ColorMode
Now every call of ColorMode creates a closure to access the main
thread, and this allocates a lot of heap objects.

This change uses atomic values instead of closures.
2026-03-02 21:29:15 +09:00
Hajime Hoshi 0a77ad5807 internal/ui: avoid using a mutext at getInitMonitor
As (*UserInterface).getInitMonitor could be invoked from
(*UserInterface).updateInputStateForFrame, this could cause a deadlock.

This change fixes the issue by not using the mutex at getInitMonitor.

The mutex usage itself should be reduced more.

Closes #3402
2026-03-02 17:27:09 +09:00
Hajime Hoshi 9e6f06191e ebiten: update comments
Updates #3387
2026-02-28 23:09:17 +09:00
Hajime Hoshi 585a70934a ebiten: bug fix: typo in API WindowColorMode
Updates #3387
2026-02-28 22:23:13 +09:00
Hajime Hoshi a20c4747be internal/ui: refactoring
Updates #3387
2026-02-28 21:58:58 +09:00
Hajime Hoshi 1629157ad6 ebiten: add SetWindowColorMode
Closes #3387
2026-02-28 21:45:22 +09:00
Hajime Hoshi 0e6c3375c2 Revert "internal/colormode: return Unknown on Xbox"
This reverts commit b53bb5274e.

Reason: the Xbox part was already separated
2026-02-28 20:26:26 +09:00
Hajime Hoshi b53bb5274e internal/colormode: return Unknown on Xbox 2026-02-28 20:25:23 +09:00
Hajime Hoshi d386ee3e6a internal/ui: bug fix: glfwWindow.SetTitle was not concurrent-safe for some edge cases 2026-02-28 19:47:32 +09:00
Hajime Hoshi 250897be82 ebiten: add CursorPositionF
Closes #3394
2026-02-28 15:45:31 +09:00
Hajime Hoshi 554a400643 all: update dependencies 2026-02-27 03:05:54 +09:00
Hajime Hoshi 380ae844a0 internal/gamepaddb: integrate macOS and iOS part
The database items with "Mac OS X" are for HID devices, while "iOS"
are for GC devices. In the near future, macOS should treat GC devices
in Ebitengine, especially for vibrations.

Updates #2014
Updates #2015
2026-02-26 13:02:26 +09:00
Hajime Hoshi 28a8f8bfe3 internal/gamepad: fix typo
Updates #2014
Updates #2015
2026-02-24 23:45:57 +09:00
Hajime Hoshi 89bb8fb3a0 internal/gamepad: refactoring: add a common nativeGamepadsImpl for iOS and macOS
This is a preparation to integrate iOS and macOS implementations
for gamepads.

Updates #2014
Updates #2015
2026-02-24 23:41:59 +09:00
Hajime Hoshi 62aaf807d6 text/v2/internal/textutil: remove direct dependency on uniseg 2026-02-24 14:29:52 +09:00
Hajime Hoshi d9122b68e1 ebiten: add comments at RunOnMainThread
Updates #3385
2026-02-24 03:59:34 +09:00
Hajime Hoshi e4d7d9fe7e exp/textinput: refactoring 2026-02-24 02:27:56 +09:00
Hajime Hoshi 0199c97e6e ebiten: add RunOnMainThread
This change implements RunOnMainThread for most platforms.

Android and consoles don't support RunOnMainThread (yet).

Closes #3385
2026-02-24 00:26:53 +09:00
Jon Rafkind e8a9c3581a audio: add opus package (#3393)
Adds support for opus audio decoding in the ebiten/v2/audio/opus package.

Closes #368
2026-02-21 11:40:20 +09:00
Hajime Hoshi 04a834101a all: update PureGo to v0.10.0-alpha.5 2026-02-21 09:16:02 +09:00
Hajime Hoshi 8e7f381531 internal/ui: bug fix: ignore anomalous wheel values
With some devices, anomalous wheel values unexpectedly come. These
cause sudden spikes and/or rapid reversals.

This change fixes this issue by detecting and ignoring them.

Closes #3390
2026-02-15 16:59:34 +09:00
Hajime Hoshi 9119570dd8 internal/ui: bug fix: WheelX and WheelY should be accumulated on browsers 2026-02-15 01:47:50 +09:00