Add features table, refactor test texture generation, encode alpha for A1R5G5B5 images #1

erlehmann wants to merge 15 commits from features-table into master

15 Commits

Author SHA1 Message Date
Nils Dagsson Moskopp 50466ca08b
Encode alpha channel for colormapped A1R5G5B5 images 2024-03-19 11:55:15 +01:00
Nils Dagsson Moskopp 9497a0303c
Add 2×2 white square to bottom left corner of test textures
As the alpha channel of the color is above 127, the square should
show as opaque white in TGA images with the color format A1R5G5B5.
2024-03-19 11:49:08 +01:00
Nils Dagsson Moskopp f6cf592228
Encode number of attribute/alpha bits in image descriptor 2023-12-01 00:22:15 +01:00
Nils Dagsson Moskopp 72a4f41aa7
Use hyphen-minus to separate test texture filename parts
The scanline orders “bottom_top” and “top_bottom” contain an underscore.
Therefore, the underscore is no longer an appropriate separator for the
test texture filename parts (TGA type, color format, scanline order).
2023-11-29 17:38:57 +01:00
Nils Dagsson Moskopp 0272fa5ccd
Change scanline order names
The scanline order ”bottom-top” has been changed to ”bottom_top”.
The scanline order “top-bottom” has been changed to “top_bottom”.

The scanline order names were changed so that API consumers can check if
“tga_encoder.features.scanline_order.top_bottom” is truthy instead of
having to check “tga_encoder.features.scanline_order["top-bottom"]”.

This is a breaking change, but since no release of tga_encoder happened
since commit 01bcbbf927 which allowed the
scanline order to be specified, it can not affect any mod on ContentDB.
2023-11-28 21:41:54 +01:00
Nils Dagsson Moskopp e599c9fe83
Use keys with truthy values in features table
If the features table uses keys with truthy values, it is easy to check
for the presence of some feature by checking if the corresponding table
entry (e.g. “tga_encoder.features.color_format.A1R5G5B5”) is truthy.
2023-11-27 23:07:06 +01:00
Nils Dagsson Moskopp e329052c7f
Generate TGA type 3 test textures from RGB input 2023-10-20 01:00:47 +02:00
Nils Dagsson Moskopp c0cc855a02
Refactor encoding of uncompressed A1R5G5B5 images 2023-10-18 05:08:16 +02:00
Nils Dagsson Moskopp 2b4faee266
Refactor encoding of compressed A1R5G5B5 images 2023-10-18 05:02:41 +02:00
Nils Dagsson Moskopp 64d20ccab8
Generate TGA type 2 and type 10 test textures using loops 2023-10-18 02:13:28 +02:00
Nils Dagsson Moskopp 619e49d3b7
Encode alpha channel for compressed A1R5G5B5 images 2023-10-18 02:12:48 +02:00
Nils Dagsson Moskopp 2e0471c81f
Encode alpha channel for uncompressed A1R5G5B5 images 2023-10-18 02:12:48 +02:00
Nils Dagsson Moskopp fa28f4c8de
Generate TGA type 3 test textures using loops 2023-10-17 20:12:23 +02:00
Nils Dagsson Moskopp 6db7be7b9d
Generate TGA type 1 test textures using loops 2023-10-17 19:50:09 +02:00
Nils Dagsson Moskopp 48d94720c1
Add features table 2023-10-17 12:33:29 +02:00