Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/load1n9/neko
frame buffer deno module built on top of mini_fb with canvas api implementation and a webgpu renderer
https://github.com/load1n9/neko
canvas deno gui javascript typescript
Last synced: about 2 months ago
JSON representation
frame buffer deno module built on top of mini_fb with canvas api implementation and a webgpu renderer
- Host: GitHub
- URL: https://github.com/load1n9/neko
- Owner: load1n9
- License: mit
- Created: 2022-02-27T02:51:29.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2022-10-03T16:13:14.000Z (about 2 years ago)
- Last Synced: 2024-10-03T12:21:04.308Z (2 months ago)
- Topics: canvas, deno, gui, javascript, typescript
- Language: TypeScript
- Homepage:
- Size: 4.04 MB
- Stars: 46
- Watchers: 2
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-deno - neko - 🐈 caviar's twin frame buffer deno module with a framebuffer canvas implementation (Modules / Game engine)
README
Neko 🐈
frame buffer deno module built on top of mini_fb with canvas api implementation
and a webgpu renderer
### Packages
- [Core](https://github.com/load1n9/neko/tree/master/core) - basic frame buffer
library
- [Canvas](https://github.com/load1n9/neko/tree/master/canvas) - javascript
canvas implementation
- [WebGPU](https://github.com/load1n9/neko/tree/master/webgpu) - webgpu renderer### Usage
#### Using Methods
```typescript
import { Neko, World } from "https://deno.land/x/neko/mod.ts";const width = 800;
const height = 600;const neko = new Neko({
title: "Neko",
width,
height,
});
const frame = new Uint8Array(width * height * 4).fill(0x000000);
class Instance extends World {
updateSync() {
frame[Math.round(Math.random() * frame.length)] = Math.round(
Math.random() * 0xffffff,
);
neko.setFrameBuffer(frame);
}
}new Instance().startSync(neko, 60);
```#### Using Functions
```typescript
import { Neko, World } from "https://deno.land/x/neko/mod.ts";const width = 800;
const height = 600;const neko = new Neko({
title: "Neko",
width,
height,
});
const frame = new Uint8Array(width * height * 4).fill(0x000000);
new World().startSync(neko, {
fps: 60,
updateSync: () => {
frame[Math.round(Math.random() * frame.length)] = Math.round(
Math.random() * 0xffffff,
);
neko.setFrameBuffer(frame);
},
});
```### Maintainers
- Loading ([@load1n9](https://github.com/load1n9))