Commit Graph

246 Commits

Author SHA1 Message Date
Hajime Hoshi
2b7617da7a graphics: Cache values for uniformMatrix4fv 2015-02-18 11:30:24 +09:00
Hajime Hoshi
9ec7b13f27 example/piano: Speed up 2015-02-16 10:48:57 +09:00
Hajime Hoshi
8c2301e542 Fix misspelling 2015-02-16 02:49:17 +09:00
Hajime Hoshi
ba3feaf52f ui: More precise clock 2015-02-15 19:30:29 +09:00
Hajime Hoshi
c5fc7ea0ab ui: More precise space calc 2015-02-14 23:23:11 +09:00
Hajime Hoshi
beecf31937 Resolve some TODOs 2015-02-10 10:44:58 +09:00
Hajime Hoshi
cd4188b0a3 Add SetScreenScale (#115) 2015-02-10 00:10:50 +09:00
Hajime Hoshi
249add3979 Add SetScreenSize 2015-02-09 11:02:04 +09:00
Hajime Hoshi
2544d74ba0 Use go-gl/glow instead of go-gl/gl (#112) 2015-01-29 00:58:56 +09:00
Hajime Hoshi
ea78b31414 Move internal/audio -> exp/audio/internal 2015-01-27 22:55:45 +09:00
Hajime Hoshi
3964944deb Move ui_*.go back to internal/ui again 2015-01-27 22:37:00 +09:00
Hajime Hoshi
23b3f1afce Move some files of internal/ui to the root 2015-01-27 01:10:17 +09:00
Hajime Hoshi
ae450433db Move some files of internal to internal/graphics 2015-01-27 00:08:24 +09:00
Hajime Hoshi
e23b0758e5 Merge internal/graphics/internal/shaders into internal/graphics 2015-01-26 23:32:50 +09:00
Hajime Hoshi
346bc53d53 Move internal/opengl -> internal/graphics/internal/opengl 2015-01-26 23:27:28 +09:00
Hajime Hoshi
2aa6ebb471 Move internal/assets -> ebitenutil/internal/assets 2015-01-26 22:09:47 +09:00
Hajime Hoshi
17b7969764 audio: Reduce the buffer size (OpenAL) 2015-01-26 10:14:03 +09:00
Hajime Hoshi
6a0c5dfb03 audio: Change the number of buffers 2015-01-26 03:53:40 +09:00
Hajime Hoshi
205c6f1462 audio: Bug fix: Reduce delay for desktops 2015-01-26 01:58:32 +09:00
Hajime Hoshi
7692cf6a1b audio: Refactoring 2015-01-26 01:39:43 +09:00
Hajime Hoshi
9e7dfa2f16 audio: Bug fix: Multi source (or nodes) should be used to play multi sounds 2015-01-26 01:20:56 +09:00
Hajime Hoshi
701de9f82b audio: Bug fix: half volume of any sound on GopherJS 2015-01-25 23:38:26 +09:00
Hajime Hoshi
e1336c2eba audio: Change API: accept []int16 instead of []float32 2015-01-25 19:17:53 +09:00
Hajime Hoshi
c2313c10c1 audio: Grace returning when audio is not available 2015-01-25 16:04:49 +09:00
Hajime Hoshi
fe91d341ac audio: Implement for desktops with OpenAL (#104) 2015-01-25 01:51:51 +09:00
Hajime Hoshi
a8e3b2b619 audio: Start implementing with OpenAL (not finished yet) 2015-01-24 22:20:09 +09:00
Hajime Hoshi
2d5ac9e987 audio: Add comments, add IsPlaying 2015-01-24 21:46:35 +09:00
Hajime Hoshi
2c7430171d audio: Add comments 2015-01-24 15:48:48 +09:00
Hajime Hoshi
edda664ca8 audio: Refactoring 2015-01-24 14:53:42 +09:00
Hajime Hoshi
b57c675996 Remove internal.RGBA 2015-01-24 14:53:40 +09:00
Hajime Hoshi
4d702f964f audio: CurrentBytes returns the time on inserting new sound chunk 2015-01-24 14:53:33 +09:00
Hajime Hoshi
88ac129dd6 Refactoring: only one nextInsertion is needed 2015-01-23 21:51:21 +09:00
Hajime Hoshi
8d250c6b25 audio: Add channel.nextInsertion 2015-01-23 10:58:18 +09:00
Hajime Hoshi
4b74411922 audio: Introduce channels 2015-01-23 03:02:23 +09:00
Hajime Hoshi
ba3a612ce4 Bug fix: Add 'Add' method for non-js environment 2015-01-21 10:37:15 +09:00
Hajime Hoshi
4c37efd673 Merge branch 'master' into audio 2015-01-21 10:12:14 +09:00
Hajime Hoshi
1fa39e3b8a Fix a variable name 2015-01-21 10:12:05 +09:00
Hajime Hoshi
5b41374ac7 Support touch events (esp. for mobile browsers) (#76) 2015-01-21 02:58:29 +09:00
Hajime Hoshi
d994f34d53 Add image.ReplacePixels; Add example/noise (#89) 2015-01-20 23:58:58 +09:00
Hajime Hoshi
ff020e8b1c example/keyboard: Add a keyboard image 2015-01-18 21:33:59 +09:00
Hajime Hoshi
0bd0a4dbc2 Rename image.FillRect -> DrawFilledRect (FillRect is confusing with Fill) 2015-01-18 04:19:38 +09:00
Hajime Hoshi
26358f3e63 Revert lines' vetices (float64 -> int) 2015-01-17 23:33:57 +09:00
Hajime Hoshi
f0d40b4e1f Revert rectangles' vetices (float64 -> int) 2015-01-17 23:31:09 +09:00
Hajime Hoshi
1659e9abab Bug fix: Line's vertices should be moved by 0.5 2015-01-17 23:04:19 +09:00
Hajime Hoshi
683ffafe8d Bug fix: image.Pixels didn't work on WebGL 2015-01-17 19:06:58 +09:00
Hajime Hoshi
efe7b62745 Refactoring (use math.MaxUint16) 2015-01-17 14:44:47 +09:00
Hajime Hoshi
58e2f27513 Use gl.* types instead of int 2015-01-17 14:21:38 +09:00
Hajime Hoshi
8c15b57d58 Add image.DrawLine / DrawLines 2015-01-17 14:17:42 +09:00
Hajime Hoshi
22e6996f74 Remove rectVertexQuads 2015-01-17 03:51:21 +09:00
Hajime Hoshi
db9f5e0984 example:shapes Bug fix: Structs containing js.Object can't be compared again 2015-01-17 01:11:30 +09:00
Hajime Hoshi
fe69c04f8f Bug fix: Structs containing js.Object can't be compared (for now) 2015-01-17 00:56:38 +09:00
Hajime Hoshi
8564ba8541 Use (un)signed short vertices (#90) 2015-01-16 10:37:26 +09:00
Hajime Hoshi
155be5a88d Add Rect.Color 2015-01-16 01:57:10 +09:00
Hajime Hoshi
037f35b0db Pass color values for each vertex on drawing rects 2015-01-16 01:57:07 +09:00
Hajime Hoshi
b2924d193b Use vertices for DrawTexture 2015-01-16 01:01:52 +09:00
Hajime Hoshi
2ec8c39cdd Remove the first argument of FillFramebuffer 2015-01-15 23:42:08 +09:00
Hajime Hoshi
3e376cae18 Update for the latest GopherJS (js.Object can't be casted to other types) 2015-01-15 23:26:05 +09:00
Hajime Hoshi
59ed15b2f7 Bug fix: Use prevent default properly 2015-01-15 22:28:05 +09:00
Hajime Hoshi
25cf2dab22 sprites: Speed up: use float64 as often as possible 2015-01-14 23:58:34 +09:00
Hajime Hoshi
3200ae58a4 Fix a comment 2015-01-14 23:38:25 +09:00
Hajime Hoshi
cb26342b3d Bug fix (#85): The limit of the size of vertices was wrong 2015-01-14 23:29:14 +09:00
Hajime Hoshi
f27ba0ea03 Enable gopherjs test 2015-01-14 23:16:06 +09:00
Hajime Hoshi
6aef42d6fa Bug fix: limit for the number of vertices 2015-01-14 10:31:09 +09:00
Hajime Hoshi
665ef46064 Add example/sprites (#83) 2015-01-13 23:03:37 +09:00
Hajime Hoshi
0328b049d0 Add image.DrawRects (experimental) 2015-01-13 10:36:19 +09:00
Hajime Hoshi
f0519b8604 Use location cache 2015-01-12 23:16:34 +09:00
Hajime Hoshi
9418d4c577 Change useProgramTexture not to return program 2015-01-12 21:04:52 +09:00
Hajime Hoshi
243208b849 Rename programColorMatrix -> programFragmentShader 2015-01-12 18:34:02 +09:00
Hajime Hoshi
02dbeef1b9 Add docs for gamepad API (I checked it worked on Chrome) 2015-01-12 14:59:12 +09:00
Hajime Hoshi
8987f7a645 Implement Gamepad API for JavaScript (working on Firefox so far) 2015-01-12 14:36:13 +09:00
Hajime Hoshi
a500d3a3f8 Improve example/gamepad 2015-01-12 13:33:21 +09:00
Hajime Hoshi
a6b7eab71b Add Gamepad API 2015-01-12 02:29:56 +09:00
Hajime Hoshi
a220251716 Play music at example/audio 2015-01-11 19:52:11 +09:00
Hajime Hoshi
355da1bcbc Add Experimental Audio API 2015-01-11 18:03:51 +09:00
Hajime Hoshi
3b02993a5d Modify comments 2015-01-10 19:59:47 +09:00
Hajime Hoshi
15c7341816 Replace .on* = func -> addEventListener = func 2015-01-10 15:51:07 +09:00
Hajime Hoshi
e656b607f6 Add TODO comment 2015-01-10 01:02:26 +09:00
Hajime Hoshi
6dbe57ec11 Change test import paths 2015-01-10 00:55:53 +09:00
Hajime Hoshi
e7599a6d85 docs: Move example *.js and *.js.map files to another repository 2015-01-10 00:45:21 +09:00
Hajime Hoshi
d96de18074 Remove TODOs 2015-01-09 12:13:29 +09:00
Hajime Hoshi
1dd1403aac Bug fix: opengl.NewBuffer may accept integer value (glfw) 2015-01-09 02:28:16 +09:00
Hajime Hoshi
636ae84ad5 Resolve TODOs 2015-01-09 02:02:56 +09:00
Hajime Hoshi
eb325c9684 Update docs 2015-01-08 23:45:30 +09:00
Hajime Hoshi
5dade52621 Bug fix: Use document.hidden (focus/blue event is not reliable when using <iframe>) 2015-01-08 11:56:21 +09:00
Hajime Hoshi
d933c54e20 Bug fix: Check window.top's focus in case that game is in <iframe> 2015-01-08 02:24:05 +09:00
Hajime Hoshi
a1214ff735 Stop the game when the window is not active (#69) 2015-01-08 01:35:09 +09:00
Hajime Hoshi
6efb806cc2 Stabilize FPS for JS 2015-01-08 00:44:41 +09:00
Hajime Hoshi
9915e6764a Bug fix: blurred canvas in Retina display (#68) 2015-01-08 00:01:18 +09:00
Hajime Hoshi
27cd0610d1 Add 'auto-generated' notices (#66) 2015-01-07 23:21:52 +09:00
Hajime Hoshi
4eaa16b8d1 Rename mod key names 2015-01-07 23:18:40 +09:00
Hajime Hoshi
6bdc875596 Bug fix: Ignore unknown keys 2015-01-07 23:02:58 +09:00
Hajime Hoshi
f78c79a5dd Bug fix: onkeydown function should return false to prevent browser shortcuts 2015-01-07 23:01:23 +09:00
Hajime Hoshi
a710db4c9e Bug fix: invalidate function keys, backspace on browsers 2015-01-07 11:22:48 +09:00
Hajime Hoshi
9f40da41fc Add backspace (not tested) 2015-01-07 11:22:25 +09:00
Hajime Hoshi
62d1395670 Arrange key's order 2015-01-07 11:00:15 +09:00
Hajime Hoshi
74e3c40740 Yield focus to canvas on clicking body 2015-01-07 04:39:33 +09:00
Hajime Hoshi
795e7c8eb2 Focus canvas on start (#64) 2015-01-07 04:34:47 +09:00
Hajime Hoshi
03cf0a7069 Bug fix: glfw.MouseButton should be converted to MouseButton 2015-01-07 04:04:04 +09:00
Hajime Hoshi
7677d885a2 Remove MouseButtonMax 2015-01-07 03:08:33 +09:00
Hajime Hoshi
bc26690b14 Add genkey.go 2015-01-07 03:05:59 +09:00