Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WISH: add more getters/setter for image! type, not just RGB and ALPHA #2387

Closed
Siskin-Bot opened this issue Feb 15, 2020 · 0 comments
Closed
Labels
enhancement New feature or request Oldes.resolved Bugs/wishes with Oldes' fixes/features Test.written Type.wish

Comments

@Siskin-Bot
Copy link
Collaborator

Submitted by: Oldes

I often need to create image from foreign data and these data are usually not in two binaries which Rebol is now using to describe an image (RGB and ALPHA). I think that there should be possible to use this to get the binaries from an image:

i: make image! 1x1 i/1: 1.2.3.100
i/rgba ;== #{01020364}
i/rgbo ;== #{0102039B}
i/argb ;== #{64010203}
i/orgb ;== #{9B010203}
i/bgra ;== #{03020164}
i/bgro ;== #{0302019B}
i/abgr ;== #{64030201}
i/obgr ;== #{9B030201}
i/opacity ;== #{9B}
i/alpha   ;== #{64}

.. and also be able to set these. Now it is possible only with: i/rgb: #{050607}

Having also variant with premultiplied alpha would be also useful in many cases.


Imported from: metaeducation#2386

Comments:

Oldes added a commit to Oldes/Rebol3 that referenced this issue on Sep 23, 2019:
FEAT: more getters/setters for image! type


@Siskin-Bot Siskin-Bot added the Oldes.resolved Bugs/wishes with Oldes' fixes/features label Feb 15, 2020
@Oldes Oldes closed this as completed Feb 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Oldes.resolved Bugs/wishes with Oldes' fixes/features Test.written Type.wish
Projects
None yet
Development

No branches or pull requests

2 participants