Skip to content

fix: XTC 1-bit thumb BMP polarity inversion#373

Merged
daveallie merged 1 commit intocrosspoint-reader:masterfrom
crosspoint-reader-ko:fix/xtc-thumb-polarity
Jan 19, 2026
Merged

fix: XTC 1-bit thumb BMP polarity inversion#373
daveallie merged 1 commit intocrosspoint-reader:masterfrom
crosspoint-reader-ko:fix/xtc-thumb-polarity

Conversation

@eunchurn
Copy link
Contributor

@eunchurn eunchurn commented Jan 14, 2026

Summary

  • What is the goal of this PR? (e.g., Implements the new feature for file uploading.)
  • What changes are included?
  • Fix inverted colors in Continue Reading cover image for 1-bit XTC files

Additional Context

  • Add any other information that might be helpful for the reviewer (e.g., performance implications, potential risks,
    specific areas to focus on).
  • Fix grayValue = pixelBit ? 0 : 255grayValue = pixelBit ? 255 : 0 in lib/Xtc/Xtc.cpp
    • The thumb BMP generation had inverted polarity compared to cover BMP generation
    • bit=0 should be black, bit=1 should be white (matching the BMP palette order)
  • Update misleading comment about XTC polarity

AI Usage

While CrossPoint doesn't have restrictions on AI tools in contributing, please be transparent about their usage as it
helps set the right context for reviewers.

Did you use AI tools to help write this code? PARTIALLY

@daveallie daveallie changed the title Fix XTC 1-bit thumb BMP polarity inversion fix: XTC 1-bit thumb BMP polarity inversion Jan 14, 2026
@daveallie daveallie enabled auto-merge (squash) January 14, 2026 15:55
The thumb BMP generation for 1-bit XTC files had inverted polarity,
causing the Continue Reading cover image to appear with inverted colors.

- Fix: Change `grayValue = pixelBit ? 0 : 255` to `grayValue = pixelBit ? 255 : 0`
  to match the cover BMP generation logic where bit=0 is black and bit=1 is white
- Update misleading comment about XTC polarity
auto-merge was automatically disabled January 14, 2026 15:55

Head branch was pushed to by a user without write access

@eunchurn eunchurn force-pushed the fix/xtc-thumb-polarity branch from c9a8fe9 to 4cb9158 Compare January 14, 2026 15:55
@daveallie daveallie merged commit 12940cc into crosspoint-reader:master Jan 19, 2026
1 check passed
jdk2pq added a commit to jdk2pq/crosspoint-reader that referenced this pull request Jan 20, 2026
* origin:
  fix: truncate chapter names that are too long (crosspoint-reader#422)
  feat: dict based Hyphenation (crosspoint-reader#305)
  fix: render U+FFFD replacement character instead of ? (crosspoint-reader#366)
  fix: Invert colors on home screen cover overlay when recent book is selected (crosspoint-reader#390)
  Adds KOReader Sync support (crosspoint-reader#232)
  feat: Change keyboard "caps" to "shift" & Wrap Keyboard (crosspoint-reader#377)
  fix: XTC 1-bit thumb BMP polarity inversion (crosspoint-reader#373)
yingirene pushed a commit to yingirene/crosspoint-reader that referenced this pull request Jan 25, 2026
## Summary

* **What is the goal of this PR?** (e.g., Implements the new feature for
file uploading.)
* **What changes are included?**

- Fix inverted colors in Continue Reading cover image for 1-bit XTC
files

## Additional Context

* Add any other information that might be helpful for the reviewer
(e.g., performance implications, potential risks,
  specific areas to focus on).

- Fix `grayValue = pixelBit ? 0 : 255` → `grayValue = pixelBit ? 255 :
0` in `lib/Xtc/Xtc.cpp`
- The thumb BMP generation had inverted polarity compared to cover BMP
generation
- bit=0 should be black, bit=1 should be white (matching the BMP palette
order)
- Update misleading comment about XTC polarity

---

### AI Usage

While CrossPoint doesn't have restrictions on AI tools in contributing,
please be transparent about their usage as it
helps set the right context for reviewers.

Did you use AI tools to help write this code? _**PARTIALLY**_
Unintendedsideeffects pushed a commit to Unintendedsideeffects/crosspoint-reader that referenced this pull request Feb 17, 2026
## Summary

* **What is the goal of this PR?** (e.g., Implements the new feature for
file uploading.)
* **What changes are included?**

- Fix inverted colors in Continue Reading cover image for 1-bit XTC
files

## Additional Context

* Add any other information that might be helpful for the reviewer
(e.g., performance implications, potential risks,
  specific areas to focus on).

- Fix `grayValue = pixelBit ? 0 : 255` → `grayValue = pixelBit ? 255 :
0` in `lib/Xtc/Xtc.cpp`
- The thumb BMP generation had inverted polarity compared to cover BMP
generation
- bit=0 should be black, bit=1 should be white (matching the BMP palette
order)
- Update misleading comment about XTC polarity

---

### AI Usage

While CrossPoint doesn't have restrictions on AI tools in contributing,
please be transparent about their usage as it
helps set the right context for reviewers.

Did you use AI tools to help write this code? _**PARTIALLY**_
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