Commit Graph

908 Commits

Author SHA1 Message Date
Zyko
ced0c62827 go vet error check 2024-04-10 21:11:32 +02:00
Zyko
6a8c00e0aa Fixed opengl tests 2024-04-10 21:08:03 +02:00
Zyko
92a257a557 directx: Better logic to assume MRT 2024-04-10 20:17:20 +02:00
Zyko
65646df8ed Temporary fix for directx11 2024-04-10 20:12:10 +02:00
Zyko
c73221ac16 Merge upstream - fixed conflicts 2024-04-10 19:15:34 +02:00
Zyko
1b3bfda17b Fixed empty target for directx11 2024-04-10 19:10:21 +02:00
Zyko
c9eb30d66f Fixed magic number 2024-04-10 18:59:21 +02:00
Zyko
55f1a5d32e (Fixed) webgl 2024-04-10 18:57:55 +02:00
Hajime Hoshi
3cf3b27729 internal/graphicsdriver/opengl: refactoring: rename variables
A framebuffer's width and height are unclear. Rename them to
viewportWidth and viewportHeight.
2024-04-10 23:38:25 +09:00
Zyko
c3a358b44b Fixed missing arg on gl with CGo 2024-04-09 02:40:21 +02:00
Zyko
d1fd70495b Revert to gl_FragData (future webgl) 2024-04-09 02:26:29 +02:00
Zyko
c7eeae7189 Cleanup 2024-04-09 01:00:26 +02:00
Hajime Hoshi
9c070eb2f3 Revert "internal/graphicsdriver/gl: use PureGo for Linux and UNIX"
This reverts commit 5701206229.

Reason: error on Android:

```
/Users/runner/go/pkg/mod/github.com/ebitengine/purego@v0.8.0-alpha.0.20240404024320-d0aedd0f4393/func.go:301:4: too few values in struct literal of type syscall15Args
```

https://github.com/hajimehoshi/ebiten/actions/runs/8582651053/job/23521003819
2024-04-07 03:00:13 +09:00
Hajime Hoshi
5701206229 internal/graphicsdriver/gl: use PureGo for Linux and UNIX
Updates #2284
2024-04-07 02:08:40 +09:00
Zyko
577664c1cb Dirty directx11 2024-04-06 14:54:32 +02:00
Zyko
c247da0f05 Remove useless debug + setviewport only once 2024-04-06 11:40:12 +02:00
Zyko
32b5e3edd8 Saving 2024-04-05 20:39:14 +02:00
Hajime Hoshi
caecd81f4e Revert "internal/graphicsdriver/directx: add 'tearing' for EBITENGINE_DIRECTX"
This reverts commit b6252a41f2.

Reason: We need more investigation about tearing and vsync=off

Updates #2858
2024-03-30 20:08:06 +09:00
Hajime Hoshi
b6252a41f2 internal/graphicsdriver/directx: add 'tearing' for EBITENGINE_DIRECTX
Now tearing happens only when 'tearing' is specified and vsync is off.

Closes #2858
2024-03-23 17:53:13 +09:00
Hajime Hoshi
732eedf2e0 all: use github.com/ebitengine/gomobile instead of golang.org/x/mobile
Closes #2748
Closes #2899
2024-02-24 22:07:27 +09:00
Hajime Hoshi
770fcff4c2 internal/graphicsdriver/directx: bug fix: Go 1.22 + 32bit Windows + DirectX 12 didn't work well
Apparently, a pseudo padding was needed for D3D12_RESOURCE_DESC,
but this is still mysterious.

This change also add Go 1.22 to the GitHub Actions.

Closes #2867
2024-01-27 18:06:53 +09:00
Hajime Hoshi
8551cd350f internal/ui: bug fix: need to sleep when swapping buffers is skipped
Closes #2890
2024-01-24 12:20:30 +09:00
Hajime Hoshi
006f14ac19 internal/graphicsdriver/playstation5: bug fix: link error 2024-01-22 00:14:00 +09:00
Hajime Hoshi
52e0f10ff7 internal/graphicsdriver/playstation5: bug fix: compile error 2024-01-22 00:05:02 +09:00
Hajime Hoshi
f0509096f8 internal/graphicsdriver/playstation5: add ebitengine_IsErrorNil 2024-01-21 23:54:02 +09:00
Hajime Hoshi
e0ccd013ac internal/graphicsdriver/directx: bug fix: depth should be passed by math.Float32bits
As depth was always 0, there was not an actual problem.
2024-01-21 21:43:09 +09:00
Hajime Hoshi
5887142da7 internal/grpahicsdriver/metal/mtl: use 3 drawings for fullscreen
Hajime found that renderings were delayed with 2 drawing in fullscreen
though FPS might be lowered. This is mysterious but there is no other
good solution.

Updates #2883
2024-01-19 18:29:47 +09:00
Hajime Hoshi
e39c50c296 internal/graphicsdriver/metal: add comments
Updates #2880
Updates #2883
2024-01-17 20:51:32 +09:00
Hajime Hoshi
055db234a1 internal/graphicsdriver/metal: bug fix: use 2 as a drawable count for Arm Mac
Closes #2883
2024-01-17 18:57:50 +09:00
Hajime Hoshi
a0cb0d0568 internal/graphicsdriver/playstation5: use message to detect errors 2024-01-14 22:18:12 +09:00
Hajime Hoshi
00e67b8419 internal/graphicsdriver/playstation5: improve error handlings
Updates #2799
2024-01-14 00:42:13 +09:00
Hajime Hoshi
5a36b4bb48 internal/graphicsdriver/opengl/gl: remove IsTexture
Updates #805
2024-01-09 02:35:30 +09:00
Hajime Hoshi
48e3c766f7 internal/graphicsdriver: remove Image.IsInvalidated
Updates #805
2024-01-09 00:30:21 +09:00
Hajime Hoshi
a19f079da8 internal/graphicsdriver/playstation5: remove NeedsRestoring 2024-01-09 00:26:01 +09:00
Hajime Hoshi
771e5685f8 internal/graphicsdriver: remove NeedsRestoring()
Updates #805
2024-01-08 23:27:28 +09:00
Hajime Hoshi
a30f075896 cmd/ebitenmobile: use setPreserveEGLContextOnPause(true)
setPreserveEGLContextOnPause(true) suppresses context losts, and
basically we will no longer need our restoring logic.

Updates #805
2024-01-08 20:13:13 +09:00
Hajime Hoshi
9539a87b17 all: drop the support of gomobile-build
Closes #2741
2024-01-08 00:43:26 +09:00
Hajime Hoshi
a4abc4472b internal/shaderir/msl: always use the same function names 2024-01-07 18:54:15 +09:00
Hajime Hoshi
87fe7bfd99 internal/graphicsdriver/metal: refactoring 2024-01-02 23:42:50 +09:00
Hajime Hoshi
fd63820139 internal/graphicsdriver/metal: bug fix: always use 3 drawables
Updates #2822
Closes #2880
2024-01-02 22:50:46 +09:00
Hajime Hoshi
ec9613dd94 Revert "internal/graphicsdriver/metal: bug fix: use 3 drawables for fullscreen"
This reverts commit 3c7bcf3035.

Reason: the window unexpectedly blinks when exiting from fullscreen

Updates #2880
2024-01-02 22:47:09 +09:00
Hajime Hoshi
3c7bcf3035 internal/graphicsdriver/metal: bug fix: use 3 drawables for fullscreen
Closes #2880
2024-01-02 22:33:05 +09:00
Hajime Hoshi
dddfb7317b internal/cocoa: integrate internal/graphicsdriver/metal/ns and internal/cocoa 2024-01-02 22:22:19 +09:00
Hajime Hoshi
c48fc05132 internal/graphicsdriver/metal: use %w instead of %v for errors 2023-12-24 22:29:53 +09:00
Hajime Hoshi
4895ae7f93 internal/graphicsdriver/opengl: refactoring: move some functions from internal/ui
Updates #2714
2023-12-23 22:30:13 +09:00
Hajime Hoshi
ee2ca6d20c internal/graphicsdriver/opengl: refactoring 2023-12-23 19:28:41 +09:00
Hajime Hoshi
01a4e29c5b internal/graphicsdriver/opengl/gl: add a build tag for PS5 2023-12-23 19:01:36 +09:00
Hajime Hoshi
037a818601 internal/graphicsdriver/opengl: bug fix: go-vet failed 2023-12-20 03:06:58 +09:00
Hajime Hoshi
4ef7b5c166 internal/graphicsdriver/opengl: refactoring: hide SetGLFWClientAPI
Updates #2714
2023-12-20 02:47:19 +09:00
Hajime Hoshi
f6f0cf05e6 internal/ui: refactoring: move updateVsyncOnRenderThread to the OpenGL driver
Updates #2714
2023-12-20 02:38:20 +09:00