Package noodle is a WebGL game engine, designed for low level access for fast and efficent 3D applications
This code launches a simple HTTP server to test the pre-built WASM bundle (This code was inspired by https://github.com/bobcob7/wasm-basic-triangle)
Package webgl provides bindings for WebGL via syscall/js.
Package gfx provides generic interfaces to GPU-based rendering techniques. This package is not useful by itself but instead part of a larger picture as this package provides generic interfaces and data types to modern graphics rendering API's such as OpenGL, OpenGL ES, WebGL, Direct3D, etc. The coordinate system used by this package is the right-handed Z up coordinate system unless explicitly specified otherwise. Texture coordinates do not follow OpenGL convention where the origin (0, 0) is the bottom-left, instead the origin (0, 0) is the top-left because: Go's image package uses top-left as the origin. If we followed OpenGL convention we would have to flip the image or texture coordinates on the CPU before upload to the GPU or in each shader.
Package ebiten provides graphics and input API to develop a 2D game. You can start the game by calling the function RunGame. In the API document, 'the main thread' means the goroutine in init(), main() and their callees without 'go' statement. It is assured that 'the main thread' runs on the OS main thread. There are some Ebiten functions (e.g., DeviceScaleFactor) that must be called on the main thread under some conditions (typically, before ebiten.RunGame is called). `EBITEN_SCREENSHOT_KEY` environment variable specifies the key to take a screenshot. For example, if you run your game with `EBITEN_SCREENSHOT_KEY=q`, you can take a game screen's screenshot by pressing Q key. This works only on desktops. `EBITEN_INTERNAL_IMAGES_KEY` environment variable specifies the key to dump all the internal images. This is valid only when the build tag 'ebitendebug' is specified. This works only on desktops. `ebitendebug` outputs a log of graphics commands. This is useful to know what happens in Ebiten. In general, the number of graphics commands affects the performance of your game. `ebitengl` forces to use OpenGL in any environments. `ebitenwebgl1` forces to use WebGL 1 on browsers. `ebitensinglethread` disables Ebiten's thread safety to unlock maximum performance. If you use this you will have to manage threads yourself. Functions like IsKeyPressed will no longer be concurrent-safe with this build tag. They must be called from the main thread or the same goroutine as the given game's callback functions like Update to RunGame.
Package noodle is a WebGL game engine, designed for low level access for fast and efficent 3D applications
Package gfx provides generic interfaces to GPU-based rendering techniques. This package is not useful by itself but instead part of a larger picture as this package provides generic interfaces and data types to modern graphics rendering API's such as OpenGL, OpenGL ES, WebGL, Direct3D, etc. The coordinate system used by this package is the right-handed Z up coordinate system unless explicitly specified otherwise. Texture coordinates do not follow OpenGL convention where the origin (0, 0) is the bottom-left, instead the origin (0, 0) is the top-left because: Go's image package uses top-left as the origin. If we followed OpenGL convention we would have to flip the image or texture coordinates on the CPU before upload to the GPU or in each shader.
Package unisrv implements http helpers for serving Unity WebGL application.
Package noodle is a WebGL game engine, designed for low level access for fast and efficent 3D applications