History

Update documentation, add UPDATING_YOUR_PROJECTS.md.

Christopher Snowhill committed 9 years ago

Commit a54a6401 parent 278ce262 files · +22 −1Browse files

Unified · Split

2 files
  1. CHANGELOG.md +6 −1
  2. UPDATING_YOUR_PROJECTS.md +16 −0
CHANGELOG.md+6−1
@@ -21,13 +21,18 @@ · 20 unmodified lines
21 21
22# DUMB Changelog22# DUMB Changelog
23 23
24## v2.0.1, not released yet.24## v2.0.1, released 9 October 2017
25 25
26* #66, Can't Use DUMB_OFF_T_CUSTOM to Fix Static Assertion On 32-Bit System26* #66, Can't Use DUMB_OFF_T_CUSTOM to Fix Static Assertion On 32-Bit System
27* #69, Make LFS-checks work with MinGW.org-MinGW27* #69, Make LFS-checks work with MinGW.org-MinGW
28* #70, Fix internal getnc to return dumb_ssize_t28* #70, Fix internal getnc to return dumb_ssize_t
29* #71, PSM Playback Has Garbled Sound29* #71, PSM Playback Has Garbled Sound
30* Documentation updates30* Documentation updates
31* More fuzz testing revealed places where order counts were allowed
32 to be extremely high, blowing out the memory requested for the
33 timekeeping arrays. This has been severely limited now to throw errors
34 on load.
35* Added some considerations to a porting document.
31 36
32## v2.0.0, released 26 September 201737## v2.0.0, released 26 September 2017
33 38
UPDATING_YOUR_PROJECTS.md+16−0
@@ -0,0 +1,16 @@
1# Updating your projects
2
3## Transition from 0.9.3 to 2.0.0 and beyond
4
5### The Basics
6
7* Build your DUMB-using project with warnings that show function pointer mismatches. Treat these warnings extremely carefully, most of them imply porting work.
8* `DUMBFILE_SYSTEM` needs 7 pointers instead of 5, and the signatures have changed. Look in include/dumb.h for a quick overview, and in DUMBFILE_SYSTEM.md for a more complete spec. Notable changes include seeking support, file length reporting, and using 64-bit safe seek offsets and file sizes.
9* Some functions return `dumb_off_t` instead of `long`. Most of that is backwards compatible unless you have function pointers to these.
10
11### Shortcomings of the 2.0 API
12
13* `DUH.length` is `dumb_off_t`, but this is not the clearest type. It's good that this is 64-bit, but it doesn't measure disk file offsets. `length` measures the total time of the DUH in 65536-ths of a second, where a DUH is a format-agnostic abstraction of a tracked song.
14* A sigrenderer is like a slider, or iterator, that moves along a DUH and decodes the music. The *position* of a sigrenderer is stored in `pos`, and this is exposed in the API as `long`. It should ideally have the same type as `DUH.length`.
15
16What's the worst impact of these shortcomings? If your `long` is 32-bit (should only happen on Windows when targeting 32-bit processors), your `pos` might be broken 2^15 seconds into a song, which is about 9 hours. It's really minimal impact, and this bug was already in DUMB 0.9.3. As of DUMB 2.0.0, this is even less of an impact, since the newer timekeeping arrays will automatically keep the `pos` within the actual detected length of a song, dropping back down to 0 again if it loops completely, or slightly higher if the loop is partway into the song. It's not perfect, but at least I tried, right?

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t