Canonical repo for Dong Web (dong.vielle.dev)
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Added Dong specs

afterlifepro d8af1b79

+43
+7
README.md
··· 1 + # Dong Web 2 + 3 + A PWA to read `.dong` files (see [working with dong](./work-with-dong.md) files for more info) 4 + 5 + ## Usage 6 + 7 + do some stuff
+36
work-with-dong.md
··· 1 + # Dong Files 2 + 3 + Dong files are image files that play audio when opened. The mime type is `application/prs.vielle.dong` 4 + 5 + ## Creating a `.dong` file 6 + 7 + A dong file is structured as follows: 8 + 9 + ```txt 10 + d0<version> 11 + <image-mime><image-data> 12 + <audio-mime><audio-data> 13 + <image-data> 14 + <audio-data> 15 + ``` 16 + 17 + ### Version 18 + 19 + Version is an 8 bit number that indicates the version of the dong file. This file documents version 2 of the dong file format. This is prefixed with the hex value d0 to indicate that this is a dong file. The first 16 bits of a version 2 `.dong` file should be `11010000 00000010`. If this does not match, it is either a different file format or version. 20 + 21 + ### Image Metadata 22 + 23 + Image metadata starts with a mimetype. The mimetype is 255 bytes long, followed by a 00 byte. If the mimetype is shorter than 255 characters, the remaining bytes are filled with 00 bytes. 24 + The metadata is then followed with an image length, which must be 32 bits long. This represents the number of bytes in the image data. 25 + 26 + ### Audio Metadata 27 + 28 + See: Image metadata 29 + 30 + ### Image Data 31 + 32 + This is a binary blob taking up the number of bytes allocated in image-length. 33 + 34 + ### Audio Data 35 + 36 + This is a binary blob taking up the number of bytes allocated in audio-length.