1
1
mirror of https://github.com/wader/fq.git synced 2024-12-20 03:41:46 +03:00
fq/format/icc/testdata/sRGB2014.fqtest
Mattias Wadman 051a70bd4b interp: Change bit ranges to use exclusive end
All other ranges and slicing uses exclusive end so i think it make sense
to make it consistent.

Update docs and add additional example for non-byte-aligned field.

Also fixes issue showing zero bit ranges as start-NA.
2023-10-20 15:37:26 +02:00

207 lines
21 KiB
Plaintext
Raw Blame History

# sRGB2014.icc is from https://www.color.org/srgbprofiles.xalter
$ fq -d icc_profile dv sRGB2014.icc
|00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f|0123456789abcdef|.{}: sRGB2014.icc (icc_profile) 0x0-0xbd0 (3024)
| | | header{}: 0x0-0x80 (128)
0x000|00 00 0b d0 |.... | size: 3024 0x0-0x4 (4)
0x000| 00 00 00 00 | .... | cmm_type_signature: "" 0x4-0x8 (4)
0x000| 02 | . | version_major: 2 0x8-0x9 (1)
0x000| 00 | . | version_minor: 0 0x9-0xa (1)
0x000| 00 00 | .. | version_reserved: 0 0xa-0xc (2)
0x000| 6d 6e 74 72| mntr| device_class_signature: "mntr" 0xc-0x10 (4)
0x010|52 47 42 20 |RGB | color_space: "RGB " 0x10-0x14 (4)
0x010| 58 59 5a 20 | XYZ | connection_space: "XYZ " 0x14-0x18 (4)
| | | timestamp{}: 0x18-0x24 (12)
0x010| 07 df | .. | year: 2015 0x18-0x1a (2)
0x010| 00 02 | .. | month: 2 0x1a-0x1c (2)
0x010| 00 0f | .. | day: 15 0x1c-0x1e (2)
0x010| 00 00| ..| hours: 0 0x1e-0x20 (2)
0x020|00 00 |.. | minutes: 0 0x20-0x22 (2)
0x020| 00 00 | .. | seconds: 0 0x22-0x24 (2)
0x020| 61 63 73 70 | acsp | file_signature: "acsp" 0x24-0x28 (4)
0x020| 00 00 00 00 | .... | primary_platform: "" 0x28-0x2c (4)
0x020| 00 00 00 00| ....| flags: 0 0x2c-0x30 (4)
0x030|00 00 00 00 |.... | device_manufacturer: "" 0x30-0x34 (4)
0x030| 00 00 00 00 | .... | device_model: "" 0x34-0x38 (4)
0x030| 00 00 00 01 00 00 00 00| ........| device_attribute: "" 0x38-0x40 (8)
0x040|00 00 00 00 |.... | render_intent: "" 0x40-0x44 (4)
0x040| 00 00 f6 d6 00 01 00 00 00 00 d3 2d| ...........-| xyz_illuminant: "" 0x44-0x50 (12)
0x050|00 00 00 00 |.... | profile_creator_signature: "" 0x50-0x54 (4)
0x050| 3d 0e b2 de ae 93 97 be 9b 67 26 ce| =........g&.| profile_id: "=\x0e<30>ޮ<EFBFBD><DEAE><EFBFBD><EFBFBD>g&Ό\nC<6E>" 0x54-0x64 (16)
0x060|8c 0a 43 ce |..C. |
0x060| 00 00 00 00 00 00 00 00 00 00 00 00| ............| reserved: raw bits (all zero) 0x64-0x80 (28)
0x070|00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00|................|
| | | tag_table{}: 0x80-0xbd0 (2896)
0x080|00 00 00 10 |.... | count: 16 0x80-0x84 (4)
| | | table[0:16]: 0x84-0xbd0 (2892)
| | | [0]{}: element 0x84-0x1a8 (292)
0x080| 64 65 73 63 | desc | signature: "desc" 0x84-0x88 (4)
0x080| 00 00 01 44 | ...D | offset: 324 0x88-0x8c (4)
0x080| 00 00 00 63| ...c| size: 99 0x8c-0x90 (4)
0x140| 64 65 73 63 | desc | type: "desc" 0x144-0x148 (4)
0x140| 00 00 00 00 | .... | reserved: 0 0x148-0x14c (4)
0x140| 00 00 00 09| ....| description_length: 9 0x14c-0x150 (4)
0x150|73 52 47 42 32 30 31 34 00 |sRGB2014. | description: "sRGB2014" 0x150-0x159 (9)
0x150| 00 00 00 00 | .... | language_code: 0 0x159-0x15d (4)
0x150| 00 00 00| ...| localizable_description_length: 0 0x15d-0x161 (4)
0x160|00 |. |
| | | localizable_description: "" 0x161-0x161 (0)
0x160| 00 00 | .. | script_code: 0 0x161-0x163 (2)
0x160| 00 | . | macintosh_description_length: 0 0x163-0x164 (1)
0x160| 00 00 00 00 00 00 00 00 00 00 00 00| ............| macintosh_description: "" 0x164-0x1a7 (67)
0x170|00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00|................|
* |until 0x1a6.7 (67) | |
0x1a0| 00 | . | alignment: raw bits 0x1a7-0x1a8 (1)
| | | [1]{}: element 0x90-0x1bc (300)
0x090|62 58 59 5a |bXYZ | signature: "bXYZ" 0x90-0x94 (4)
0x090| 00 00 01 a8 | .... | offset: 424 0x94-0x98 (4)
0x090| 00 00 00 14 | .... | size: 20 0x98-0x9c (4)
0x1a0| 58 59 5a 20 | XYZ | type: "XYZ " 0x1a8-0x1ac (4)
0x1a0| 00 00 00 00| ....| reserved: 0 0x1ac-0x1b0 (4)
0x1b0|00 00 24 a0 |..$. | x: 0.14306640625 0x1b0-0x1b4 (4)
0x1b0| 00 00 0f 84 | .... | y: 0.06060791015625 0x1b4-0x1b8 (4)
0x1b0| 00 00 b6 cf | .... | z: 0.7140960693359375 0x1b8-0x1bc (4)
| | | [2]{}: element 0x9c-0x9c8 (2348)
0x090| 62 54 52 43| bTRC| signature: "bTRC" 0x9c-0xa0 (4)
0x0a0|00 00 01 bc |.... | offset: 444 0xa0-0xa4 (4)
0x0a0| 00 00 08 0c | .... | size: 2060 0xa4-0xa8 (4)
0x1b0| 63 75 72 76| curv| type: "curv" 0x1bc-0x1c0 (4)
0x1c0|00 00 00 00 |.... | reserved: 0 0x1c0-0x1c4 (4)
0x1c0| 00 00 04 00 00 00 00 05 00 0a 00 0f| ............| data: raw bits 0x1c4-0x9c8 (2052)
0x1d0|00 14 00 19 00 1e 00 23 00 28 00 2d 00 32 00 37|.......#.(.-.2.7|
* |until 0x9c7.7 (2052) | |
| | | [3]{}: element 0xa8-0x9c8 (2336)
0x0a0| 67 54 52 43 | gTRC | signature: "gTRC" 0xa8-0xac (4)
0x0a0| 00 00 01 bc| ....| offset: 444 0xac-0xb0 (4)
0x0b0|00 00 08 0c |.... | size: 2060 0xb0-0xb4 (4)
0x1b0| 63 75 72 76| curv| type: "curv" 0x1bc-0x1c0 (4)
0x1c0|00 00 00 00 |.... | reserved: 0 0x1c0-0x1c4 (4)
0x1c0| 00 00 04 00 00 00 00 05 00 0a 00 0f| ............| data: raw bits 0x1c4-0x9c8 (2052)
0x1d0|00 14 00 19 00 1e 00 23 00 28 00 2d 00 32 00 37|.......#.(.-.2.7|
* |until 0x9c7.7 (2052) | |
| | | [4]{}: element 0xb4-0x9c8 (2324)
0x0b0| 72 54 52 43 | rTRC | signature: "rTRC" 0xb4-0xb8 (4)
0x0b0| 00 00 01 bc | .... | offset: 444 0xb8-0xbc (4)
0x0b0| 00 00 08 0c| ....| size: 2060 0xbc-0xc0 (4)
0x1b0| 63 75 72 76| curv| type: "curv" 0x1bc-0x1c0 (4)
0x1c0|00 00 00 00 |.... | reserved: 0 0x1c0-0x1c4 (4)
0x1c0| 00 00 04 00 00 00 00 05 00 0a 00 0f| ............| data: raw bits 0x1c4-0x9c8 (2052)
0x1d0|00 14 00 19 00 1e 00 23 00 28 00 2d 00 32 00 37|.......#.(.-.2.7|
* |until 0x9c7.7 (2052) | |
| | | [5]{}: element 0xc0-0xa50 (2448)
0x0c0|64 6d 64 64 |dmdd | signature: "dmdd" 0xc0-0xc4 (4)
0x0c0| 00 00 09 c8 | .... | offset: 2504 0xc4-0xc8 (4)
0x0c0| 00 00 00 88 | .... | size: 136 0xc8-0xcc (4)
0x9c0| 64 65 73 63 | desc | type: "desc" 0x9c8-0x9cc (4)
0x9c0| 00 00 00 00| ....| reserved: 0 0x9cc-0x9d0 (4)
0x9d0|00 00 00 2e |.... | description_length: 46 0x9d0-0x9d4 (4)
0x9d0| 49 45 43 20 36 31 39 36 36 2d 32 2d| IEC 61966-2-| description: "IEC 61966-2-1 Default RGB Colour Space - sRGB" 0x9d4-0xa02 (46)
0x9e0|31 20 44 65 66 61 75 6c 74 20 52 47 42 20 43 6f|1 Default RGB Co|
* |until 0xa01.7 (46) | |
0xa00| 00 00 00 00 | .... | language_code: 0 0xa02-0xa06 (4)
0xa00| 00 00 00 00 | .... | localizable_description_length: 0 0xa06-0xa0a (4)
| | | localizable_description: "" 0xa0a-0xa0a (0)
0xa00| 00 00 | .. | script_code: 0 0xa0a-0xa0c (2)
0xa00| 00 | . | macintosh_description_length: 0 0xa0c-0xa0d (1)
0xa00| 00 00 00| ...| macintosh_description: "" 0xa0d-0xa50 (67)
0xa10|00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00|................|
* |until 0xa4f.7 (67) | |
| | | [6]{}: element 0xcc-0xa64 (2456)
0x0c0| 67 58 59 5a| gXYZ| signature: "gXYZ" 0xcc-0xd0 (4)
0x0d0|00 00 0a 50 |...P | offset: 2640 0xd0-0xd4 (4)
0x0d0| 00 00 00 14 | .... | size: 20 0xd4-0xd8 (4)
0xa50|58 59 5a 20 |XYZ | type: "XYZ " 0xa50-0xa54 (4)
0xa50| 00 00 00 00 | .... | reserved: 0 0xa54-0xa58 (4)
0xa50| 00 00 62 99 | ..b. | x: 0.3851470947265625 0xa58-0xa5c (4)
0xa50| 00 00 b7 85| ....| y: 0.7168731689453125 0xa5c-0xa60 (4)
0xa60|00 00 18 da |.... | z: 0.097076416015625 0xa60-0xa64 (4)
| | | [7]{}: element 0xd8-0xa78 (2464)
0x0d0| 6c 75 6d 69 | lumi | signature: "lumi" 0xd8-0xdc (4)
0x0d0| 00 00 0a 64| ...d| offset: 2660 0xdc-0xe0 (4)
0x0e0|00 00 00 14 |.... | size: 20 0xe0-0xe4 (4)
0xa60| 58 59 5a 20 | XYZ | type: "XYZ " 0xa64-0xa68 (4)
0xa60| 00 00 00 00 | .... | reserved: 0 0xa68-0xa6c (4)
0xa60| 00 00 00 00| ....| x: 0 0xa6c-0xa70 (4)
0xa70|00 50 00 00 |.P.. | y: 80 0xa70-0xa74 (4)
0xa70| 00 00 00 00 | .... | z: 0 0xa74-0xa78 (4)
| | | [8]{}: element 0xe4-0xa9c (2488)
0x0e0| 6d 65 61 73 | meas | signature: "meas" 0xe4-0xe8 (4)
0x0e0| 00 00 0a 78 | ...x | offset: 2680 0xe8-0xec (4)
0x0e0| 00 00 00 24| ...$| size: 36 0xec-0xf0 (4)
0xa70| 6d 65 61 73 | meas | type: "meas" 0xa78-0xa7c (4)
0xa70| 00 00 00 00| ....| reserved: 0 0xa7c-0xa80 (4)
0xa80|00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00|................| data: raw bits 0xa80-0xa9c (28)
0xa90|00 00 00 00 00 00 00 00 00 00 00 02 |............ |
| | | [9]{}: element 0xf0-0xab0 (2496)
0x0f0|62 6b 70 74 |bkpt | signature: "bkpt" 0xf0-0xf4 (4)
0x0f0| 00 00 0a 9c | .... | offset: 2716 0xf4-0xf8 (4)
0x0f0| 00 00 00 14 | .... | size: 20 0xf8-0xfc (4)
0xa90| 58 59 5a 20| XYZ | type: "XYZ " 0xa9c-0xaa0 (4)
0xaa0|00 00 00 00 |.... | reserved: 0 0xaa0-0xaa4 (4)
0xaa0| 00 00 00 9e | .... | x: 0.002410888671875 0xaa4-0xaa8 (4)
0xaa0| 00 00 00 a4 | .... | y: 0.00250244140625 0xaa8-0xaac (4)
0xaa0| 00 00 00 87| ....| z: 0.0020599365234375 0xaac-0xab0 (4)
| | | [10]{}: element 0xfc-0xac4 (2504)
0x0f0| 72 58 59 5a| rXYZ| signature: "rXYZ" 0xfc-0x100 (4)
0x100|00 00 0a b0 |.... | offset: 2736 0x100-0x104 (4)
0x100| 00 00 00 14 | .... | size: 20 0x104-0x108 (4)
0xab0|58 59 5a 20 |XYZ | type: "XYZ " 0xab0-0xab4 (4)
0xab0| 00 00 00 00 | .... | reserved: 0 0xab4-0xab8 (4)
0xab0| 00 00 6f a2 | ..o. | x: 0.436065673828125 0xab8-0xabc (4)
0xab0| 00 00 38 f5| ..8.| y: 0.2224884033203125 0xabc-0xac0 (4)
0xac0|00 00 03 90 |.... | z: 0.013916015625 0xac0-0xac4 (4)
| | | [11]{}: element 0x108-0xad0 (2504)
0x100| 74 65 63 68 | tech | signature: "tech" 0x108-0x10c (4)
0x100| 00 00 0a c4| ....| offset: 2756 0x10c-0x110 (4)
0x110|00 00 00 0c |.... | size: 12 0x110-0x114 (4)
0xac0| 73 69 67 20 | sig | type: "sig " 0xac4-0xac8 (4)
0xac0| 00 00 00 00 | .... | reserved: 0 0xac8-0xacc (4)
0xac0| 43 52 54 20| CRT | data: raw bits 0xacc-0xad0 (4)
| | | [12]{}: element 0x114-0xb58 (2628)
0x110| 76 75 65 64 | vued | signature: "vued" 0x114-0x118 (4)
0x110| 00 00 0a d0 | .... | offset: 2768 0x118-0x11c (4)
0x110| 00 00 00 87| ....| size: 135 0x11c-0x120 (4)
0xad0|64 65 73 63 |desc | type: "desc" 0xad0-0xad4 (4)
0xad0| 00 00 00 00 | .... | reserved: 0 0xad4-0xad8 (4)
0xad0| 00 00 00 2d | ...- | description_length: 45 0xad8-0xadc (4)
0xad0| 52 65 66 65| Refe| description: "Reference Viewing Condition in IEC 61966-2-1" 0xadc-0xb09 (45)
0xae0|72 65 6e 63 65 20 56 69 65 77 69 6e 67 20 43 6f|rence Viewing Co|
* |until 0xb08.7 (45) | |
0xb00| 00 00 00 00 | .... | language_code: 0 0xb09-0xb0d (4)
0xb00| 00 00 00| ...| localizable_description_length: 0 0xb0d-0xb11 (4)
0xb10|00 |. |
| | | localizable_description: "" 0xb11-0xb11 (0)
0xb10| 00 00 | .. | script_code: 0 0xb11-0xb13 (2)
0xb10| 00 | . | macintosh_description_length: 0 0xb13-0xb14 (1)
0xb10| 00 00 00 00 00 00 00 00 00 00 00 00| ............| macintosh_description: "" 0xb14-0xb57 (67)
0xb20|00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00|................|
* |until 0xb56.7 (67) | |
0xb50| 00 | . | alignment: raw bits 0xb57-0xb58 (1)
| | | [13]{}: element 0x120-0xb6c (2636)
0x120|77 74 70 74 |wtpt | signature: "wtpt" 0x120-0x124 (4)
0x120| 00 00 0b 58 | ...X | offset: 2904 0x124-0x128 (4)
0x120| 00 00 00 14 | .... | size: 20 0x128-0x12c (4)
0xb50| 58 59 5a 20 | XYZ | type: "XYZ " 0xb58-0xb5c (4)
0xb50| 00 00 00 00| ....| reserved: 0 0xb5c-0xb60 (4)
0xb60|00 00 f6 d6 |.... | x: 0.964202880859375 0xb60-0xb64 (4)
0xb60| 00 01 00 00 | .... | y: 1 0xb64-0xb68 (4)
0xb60| 00 00 d3 2d | ...- | z: 0.8249053955078125 0xb68-0xb6c (4)
| | | [14]{}: element 0x12c-0xba4 (2680)
0x120| 63 70 72 74| cprt| signature: "cprt" 0x12c-0x130 (4)
0x130|00 00 0b 6c |...l | offset: 2924 0x130-0x134 (4)
0x130| 00 00 00 37 | ...7 | size: 55 0x134-0x138 (4)
0xb60| 74 65 78 74| text| type: "text" 0xb6c-0xb70 (4)
0xb70|00 00 00 00 |.... | reserved: 0 0xb70-0xb74 (4)
0xb70| 43 6f 70 79 72 69 67 68 74 20 49 6e| Copyright In| text: "Copyright International Color Consortium, 2015" 0xb74-0xba3 (47)
0xb80|74 65 72 6e 61 74 69 6f 6e 61 6c 20 43 6f 6c 6f|ternational Colo|
* |until 0xba2.7 (47) | |
0xba0| 00 | . | alignment: raw bits 0xba3-0xba4 (1)
| | | [15]{}: element 0x138-0xbd0 (2712)
0x130| 63 68 61 64 | chad | signature: "chad" 0x138-0x13c (4)
0x130| 00 00 0b a4| ....| offset: 2980 0x13c-0x140 (4)
0x140|00 00 00 2c |..., | size: 44 0x140-0x144 (4)
0xba0| 73 66 33 32 | sf32 | type: "sf32" 0xba4-0xba8 (4)
0xba0| 00 00 00 00 | .... | reserved: 0 0xba8-0xbac (4)
0xba0| 00 01 0c 44| ...D| data: raw bits 0xbac-0xbd0 (36)
0xbb0|00 00 05 df ff ff f3 26 00 00 07 94 00 00 fd 8f|.......&........|
0xbc0|ff ff fb a1 ff ff fd a2 00 00 03 db 00 00 c0 75|...............u|