Skip to content

feat(ja.soraraw): split stacked chapter images into pages - #697

Draft
kinboy56 wants to merge 8 commits into
Aidoku-Community:mainfrom
kinboy56:ja.soraraw_canvas_split
Draft

feat(ja.soraraw): split stacked chapter images into pages#697
kinboy56 wants to merge 8 commits into
Aidoku-Community:mainfrom
kinboy56:ja.soraraw_canvas_split

Conversation

@kinboy56

@kinboy56 kinboy56 commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

Some chapters here ship as one image with every page stacked on top of each other, up to 49152
pixels tall. Version 2 refused those with an error. This splits them instead.

  • get_page_list measures the image header and expands a stacked image into one page per stacked
    page. The extension doesn't say whether the file is jpeg or webp, so the magic bytes decide.
  • PageImageProcessor cuts the slice each page asks for.
  • A count past 64 pages is read as a bad header rather than an image that deep, and is left whole.
  • Ordinary chapters take no extra request and never reach the processor.

minAppVersion is now 0.8.5 and the source version 3. It depends on two fixes that
landed after v0.8.4:

  • AidokuRunner e44d774: drawing into a canvas shorter than the source image.
  • Aidoku 3fd2913: pages sharing a url and differing only by their PageContext all rendered the
    same image.

Tell me if the next release will be numbered otherwise and I will change it. 3fd2913 is also what
let the ?slice=N workaround the earlier revision carried go, so the image is now fetched once per
chapter rather than once per page.

Device testing covered the ?slice=N revision (iPhone 15, iOS 26.1).
The current one needs a run on a nightly carrying 3fd2913

@kkantan

kkantan commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

since this depends on a fix that is not in a public app version, we should wait to merge until the next app release. the minimum app version should be set to whatever the next version release is.

@kinboy56
kinboy56 marked this pull request as draft August 16, 2026 20:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants