Hajime Hoshi
03079ba067
restorable: Refactoring
2018-06-10 18:40:46 +09:00
Hajime Hoshi
c782380a1c
restorable: Specify indices from restorable package
2018-06-10 18:17:58 +09:00
Hajime Hoshi
2853895e6b
graphics: Refactoring: Rename functions
2018-06-10 17:53:57 +09:00
Hajime Hoshi
32ac3840a7
graphics: Add comments
2018-06-10 17:10:11 +09:00
Hajime Hoshi
4e21bfd005
graphics: Rename elements -> indices
2018-06-10 17:06:40 +09:00
Hajime Hoshi
8a268e871f
graphics: Specify indices before commands
2018-06-10 17:04:58 +09:00
Hajime Hoshi
be665a3526
ui: Better way to avoid blocking
...
Fixes #625
2018-06-09 13:36:35 +09:00
Hajime Hoshi
6e12f287b0
ui: Use goroutine to avoid blocking on GopherJS
2018-06-09 03:05:37 +09:00
Hajime Hoshi
e6d0943366
graphics: Rename color_matrix -> color_matrix_body
2018-06-06 02:46:54 +09:00
Hajime Hoshi
b86860abcc
graphics: Call BindBuffer only when the program was null
2018-06-04 00:13:23 +09:00
Hajime Hoshi
fac639f9b7
graphics: Refactoring: Remove drawImageCommand.quadsNum
2018-06-03 23:58:08 +09:00
Hajime Hoshi
c9dd04d471
graphics: Refactoring: Remove command groups
2018-06-03 23:13:01 +09:00
Hajime Hoshi
9d87622a19
graphics: Set elements for every EnqueueDrawImageCommand
2018-06-03 20:42:45 +09:00
Hajime Hoshi
525ad04568
graphics: Split the notion of vertices and elements
2018-06-03 16:07:26 +09:00
Hajime Hoshi
25f2dfc677
graphics: Refactoring
2018-06-03 01:43:10 +09:00
Hajime Hoshi
03e3f0f5f7
graphics: Call glBufferSubData for element array buffer every frame
...
This is a preparation for more flexible drawing commands.
2018-05-31 00:53:05 +09:00
Hajime Hoshi
5e93d75ae0
graphics: Fix comments
2018-05-28 02:38:26 +09:00
Hajime Hoshi
399f965729
opengl: Add BindBuffer accepting both element-array-buffer and array-buffer
...
This change is a pure refactoring to clarify that array buffer is
binded before its usage.
2018-05-28 00:34:00 +09:00
Hajime Hoshi
311788dfe2
ui: Remove warnings of deadlock
...
Now gopherwasm fixed this problem by avoiding js.MakeFunc.
See also: 3fe87b73c0
2018-05-27 04:10:14 +09:00
Hajime Hoshi
8e9c3bd304
ui: Use gopherwasm
2018-05-27 02:35:17 +09:00
Hajime Hoshi
faaf391619
audio: Give up syncing audio timer and game timer ( #617 )
...
Syncing was already incomplete (e.g. decoding takes more than one
frame and delays can happen in this case). Giving up syncing audio
timer and game timer should not affect the game experience so much.
Instead, clock implementation will be much simpler.
2018-05-27 00:30:12 +09:00
Hajime Hoshi
5976e4bbbc
audio: More intellegent suspending/resuming ( #617 )
...
Before this change, the audio is suspended when the game stops for
1/12[s]. However, as game often stops for more than 1/12[s]
especially on mobiles, this implemntation caused some audio
glitches.
This change fixes this problem by re-implementing suspending/
resumeing audio by detecting the window is active/focused or not.
2018-05-26 23:31:04 +09:00
Hajime Hoshi
d88d1be4ad
mobile: Refactoring
2018-05-26 22:51:30 +09:00
Hajime Hoshi
980055e07a
devicescale: Use gopherwasm
2018-05-25 02:00:41 +09:00
Hajime Hoshi
d894a13698
web: Use gopherwasm
2018-05-25 01:59:50 +09:00
Hajime Hoshi
2ec075004a
clock: Use gopherwasm
2018-05-25 01:14:31 +09:00
Hajime Hoshi
4c5613d73c
opengl: Remove unneeded casts
2018-05-23 01:29:16 +09:00
Hajime Hoshi
b84dc0585d
opengl: Remove dependencies on gopherjs/webgl
...
This is a preparation for #528
2018-05-23 00:48:24 +09:00
Hajime Hoshi
81a1fd4744
testflock: Use just sync.Mutex on browsers ( #615 )
2018-05-19 21:10:34 +09:00
Hajime Hoshi
0637a812bc
web: Fix detecting mobile browsers for NodeJS
2018-05-16 22:29:19 +09:00
Hajime Hoshi
a5eb1b84ab
web: Better way to detect NodeJS
2018-05-16 22:10:35 +09:00
Hajime Hoshi
c2df8326fc
ui: Refactoring: Use IsNodeJS
2018-05-16 22:02:33 +09:00
Hajime Hoshi
d7d892f2d6
graphics: Allow a little margin for edge pixels
2018-05-13 23:00:06 +09:00
Hajime Hoshi
a1dd7b39a3
graphics: Remove roundTexel function
...
Actually, at least 704d4cf464
,
examples/moire doesn't work well without roundTexel on MacBook Pro.
However, now other parts are fixed (e.g. highp is used), it looks
like roundTexel is no longer needed.
2018-05-13 22:30:22 +09:00
Hajime Hoshi
b402cddd01
graphics: Bug fix: wrong refactoring in shader
2018-05-13 14:20:54 +09:00
Hajime Hoshi
efaa5aa17a
graphics: Refactor shader
2018-05-13 03:31:28 +09:00
Hajime Hoshi
3ccfe087d9
Refactoring
2018-05-12 15:25:01 +09:00
Hajime Hoshi
453921f1d3
ui: Bug fix: sizeChange must be set after updateFullscreenScaleIfNeeded
2018-05-12 02:11:37 +09:00
Hajime Hoshi
f5336ce7bc
opengl: Use 'EXT' functions for framebuffers
...
Some pretty old machines don't support OpenGL 3.x or later, and in
such environment, some framebuffer functions like glGenFramebuffers
are not available. Instead, EXT versions can be used even on
machines that don't support OpenGL 3.x.
After this change, Ebiten always tries to use EXT version of
framebuffer functions. I believe EXT version is always available
when non-EXT version is available, so this chang eshould be safe.
Fixes #602
2018-05-10 02:11:23 +09:00
Hajime Hoshi
92631e64ed
Remove internal/sync
...
nosync package for GopherJS is problematic since nosync's mutex
assumes that Lock call is never duplicated, which is not true in
actual applications.
See also #603 .
2018-05-09 23:41:08 +09:00
Hajime Hoshi
167d21ec46
devicescale: Panic on Android when called from init funcs
2018-05-05 03:16:29 +09:00
Hajime Hoshi
d8dba69b47
ui: Add MonitorSize
...
Fixes #470
2018-05-05 02:42:45 +09:00
Hajime Hoshi
9a06b31556
ui: Don't panic at DeviceScaleFactor in init
...
Fixes #597
2018-05-05 01:28:29 +09:00
Hajime Hoshi
d41f959b96
ui: Initialize GLFW before Run
2018-05-04 23:55:23 +09:00
Hajime Hoshi
f1927d8aca
shareable: Add tests
2018-05-03 14:10:43 +09:00
Hajime Hoshi
03dcd94884
shareable: Bug fix: Don't mark disposed when the image becomes not shared
2018-05-03 11:49:55 +09:00
Hajime Hoshi
9efccea31c
ui: Add SetWindowTitle
...
Fixes #595
2018-05-02 19:21:17 +09:00
Hajime Hoshi
0e19aa558a
graphics: Remove unneeded GL calls
2018-05-02 01:12:17 +09:00
Hajime Hoshi
6a34b87a6c
opengl: Refactoring
2018-05-02 01:01:04 +09:00
Hajime Hoshi
ea1444ea7e
shareable: Add checks at operations for disposed images
2018-04-30 03:34:35 +09:00