-
Couldn't load subscription status.
- Fork 71
Open
Description
New to Luxor, I'm doing the following to draw a small blue box and output the top left pixel value. With the blue channel set to 1 and alpha set to 0.5, I expect the pixel I output to have 1.0 blue channel and 0.5 alpha but I'm getting 0.5 for the blue channel, which is effectively doubling the alpha channel effect.
Is there something I'm misunderstanding about how this should work?
using Luxor, Colors, Images
function test()
w, h = (10, 10)
m = @imagematrix! zeros(UInt32, h, w) begin
setcolor((0.0, 0.0, 1.0, 0.5))
box(Point(0, 0), w, h, :fill)
end w h
println(m[1, 1])
end
test()
Ouput:
ARGB32(0.0N0f8, 0.0N0f8, 0.502N0f8, 0.502N0f8)
Expected output:
ARGB32(0.0N0f8, 0.0N0f8, 1.0N0f8, 0.502N0f8)
Metadata
Metadata
Assignees
Labels
No labels