Skip to content

Fix capture on big endian systems#49

Merged
thomasp85 merged 2 commits intor-lib:masterfrom
QuLogic:capture-big-endian
Oct 1, 2020
Merged

Fix capture on big endian systems#49
thomasp85 merged 2 commits intor-lib:masterfrom
QuLogic:capture-big-endian

Conversation

@QuLogic
Copy link
Copy Markdown
Contributor

@QuLogic QuLogic commented Aug 5, 2020

R expects colours to be integers of ABGR, which on little-endian machines maps to singular bytes in RGBA order, but maps to ABGR order on bit-endian machines.

Fixes #48.

@QuLogic
Copy link
Copy Markdown
Contributor Author

QuLogic commented Aug 5, 2020

Waiting to see if the build actually works (it's a bit slow...)

@QuLogic
Copy link
Copy Markdown
Contributor Author

QuLogic commented Aug 5, 2020

Well, apparently it's a little bit better, as it's failing on [['blue']] instead of [['black']] now.

QuLogic added 2 commits August 9, 2020 20:07
R expects colours to be integers of ABGR, which on little-endian
machines maps to singular bytes in RGBA order, but maps to ABGR order on
bit-endian machines.
This seems to actually work, as __BIG_ENDIAN__ isn't defined on s390x.
Possibly it needs another header, but it's easier to use a macro already
in R.
@QuLogic QuLogic force-pushed the capture-big-endian branch from b1fe359 to fb06330 Compare August 10, 2020 00:07
@QuLogic
Copy link
Copy Markdown
Contributor Author

QuLogic commented Aug 10, 2020

Oops, that was a silly typo on my part.

@QuLogic QuLogic marked this pull request as ready for review August 10, 2020 00:15
@thomasp85 thomasp85 merged commit 2f81608 into r-lib:master Oct 1, 2020
@thomasp85
Copy link
Copy Markdown
Member

Thanks!

@QuLogic QuLogic deleted the capture-big-endian branch October 1, 2020 08:13
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.

Tests fail on s390x (big-endian)

2 participants