: K-Meleon Forum
General discussion about K-Meleon.
[quote=JohnHell] [quote=siria] But where is the order in a multiplication or addition result? How would the browser know if 65536 = 256*1*256 OR = 1*256*256 OR = 256*256*1 or something in between?[/quote] [b]Forget about multiplication. It was the first thought I got.[/b] What it is, is the concatenation of binary values of given decimal values ranging from 0 to 255 for each color. Also you must understand that the computer doesn't read from left to right but from right to left so it's easy to make 8 binary digits grouping. Understood that, your example will be: B:255 G:1 R:255 = [color=#0000FF]11111111[/color] [color=#00FF00]00000001[/color] [color=#FF0000]11111111[/color] = 16712191 B:1 G:255 B:255 = [color=#0000FF]00000001[/color] [color=#00FF00]11111111[/color] [color=#FF0000]11111111[/color] = 131071 B:255 G:255 R:1 = [color=#0000FF]11111111[/color] [color=#00FF00]11111111[/color] [color=#FF0000]11111111[/color] = 16777215 As you can see they are not the same. Also, in memory they are treated as Hex values of 32 bits (in a 32 bits system I guess), this is 0xAABBGGRR (alpha if exists, Blue, Green, Red) I read a little this afternoon about how RGB and BRG are treated and I think I didn't left anything now (sure something as I'm not a programmer).[/quote]
K-Meleon forum is powered by