graphics.dat: archive handle in the bindings #431
Labels
No labels
area/ci-release
area/cli
area/docs
area/dungeon
area/ftl
area/graphics
area/gui
area/music
area/saves
area/tooling
port/amiga
port/dos
port/fm-towns
port/mac
port/pc98
port/sega-cd
priority/high
priority/low
priority/medium
type/bug
type/chore
type/docs
type/feature
type/research
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
jqueuniet/dm2-tools#431
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Each
graphics*binding call takes the archive bytes and re-parses them. Through wasm-bindgen that copies the whole file (8.6 MB on DOS) into WASM memory per call: about 1 ms per image on a debug build, dominated by the copy. An asset browser decodes thousands.Proposal
A
GraphicsArchiveclass in the wasm binding (and the equivalent handle elsewhere), built once from the bytes, with the listing and decoders as methods. The free functions can stay as wrappers.Acceptance