Switch to RGBx pixel format
This is what the browser wants so it avoids having to spend time converting everything. Unfortunately it usually means the server instead needs to convert it for us, but we assume it has more power than we do.
This commit is contained in:
+11
-11
@@ -37,20 +37,20 @@ describe('Raw Decoder', function () {
|
||||
|
||||
it('should handle the Raw encoding', function () {
|
||||
testDecodeRect(decoder, 0, 0, 2, 2,
|
||||
[0x00, 0x00, 0xff, 0, 0x00, 0xff, 0x00, 0,
|
||||
0x00, 0xff, 0x00, 0, 0x00, 0x00, 0xff, 0],
|
||||
[0xff, 0x00, 0x00, 0, 0x00, 0xff, 0x00, 0,
|
||||
0x00, 0xff, 0x00, 0, 0xff, 0x00, 0x00, 0],
|
||||
display, 24);
|
||||
testDecodeRect(decoder, 2, 0, 2, 2,
|
||||
[0xff, 0x00, 0x00, 0, 0xff, 0x00, 0x00, 0,
|
||||
0xff, 0x00, 0x00, 0, 0xff, 0x00, 0x00, 0],
|
||||
[0x00, 0x00, 0xff, 0, 0x00, 0x00, 0xff, 0,
|
||||
0x00, 0x00, 0xff, 0, 0x00, 0x00, 0xff, 0],
|
||||
display, 24);
|
||||
testDecodeRect(decoder, 0, 2, 4, 1,
|
||||
[0xff, 0x00, 0xee, 0, 0xff, 0xee, 0x00, 0,
|
||||
0xff, 0xee, 0xaa, 0, 0xff, 0xee, 0xab, 0],
|
||||
[0xee, 0x00, 0xff, 0, 0x00, 0xee, 0xff, 0,
|
||||
0xaa, 0xee, 0xff, 0, 0xab, 0xee, 0xff, 0],
|
||||
display, 24);
|
||||
testDecodeRect(decoder, 0, 3, 4, 1,
|
||||
[0xff, 0x00, 0xee, 0, 0xff, 0xee, 0x00, 0,
|
||||
0xff, 0xee, 0xaa, 0, 0xff, 0xee, 0xab, 0],
|
||||
[0xee, 0x00, 0xff, 0, 0x00, 0xee, 0xff, 0,
|
||||
0xaa, 0xee, 0xff, 0, 0xab, 0xee, 0xff, 0],
|
||||
display, 24);
|
||||
|
||||
let targetData = new Uint8Array([
|
||||
@@ -65,16 +65,16 @@ describe('Raw Decoder', function () {
|
||||
|
||||
it('should handle the Raw encoding in low colour mode', function () {
|
||||
testDecodeRect(decoder, 0, 0, 2, 2,
|
||||
[0x03, 0x03, 0x03, 0x03],
|
||||
[0x30, 0x30, 0x30, 0x30],
|
||||
display, 8);
|
||||
testDecodeRect(decoder, 2, 0, 2, 2,
|
||||
[0x0c, 0x0c, 0x0c, 0x0c],
|
||||
display, 8);
|
||||
testDecodeRect(decoder, 0, 2, 4, 1,
|
||||
[0x0c, 0x0c, 0x03, 0x03],
|
||||
[0x0c, 0x0c, 0x30, 0x30],
|
||||
display, 8);
|
||||
testDecodeRect(decoder, 0, 3, 4, 1,
|
||||
[0x0c, 0x0c, 0x03, 0x03],
|
||||
[0x0c, 0x0c, 0x30, 0x30],
|
||||
display, 8);
|
||||
|
||||
let targetData = new Uint8Array([
|
||||
|
||||
Reference in New Issue
Block a user