Commit Graph

48 Commits

Author SHA1 Message Date
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
Nils Dagsson Moskopp aad231f5e4
Generate test textures with scanline order “top-bottom” 2023-10-16 21:40:51 +02:00
Nils Dagsson Moskopp 10022c93ef
Explicitly state scanline order in test texture script 2023-10-16 21:38:19 +02:00
Nils Dagsson Moskopp 01bcbbf927
Allow encoding with top-bottom scanline order 2023-10-16 21:15:40 +02:00
Nils Dagsson Moskopp 12a33e458f
Add hashbang to script to generate TGA test textures 2023-10-16 20:34:47 +02:00
Nils Dagsson Moskopp 5dcf714cd1
Partially slice 3D rendered donut along its polodial direction 2023-10-16 19:20:30 +02:00
Nils Dagsson Moskopp 0c6d9a4d85
Partially slice 3D rendered donut along its torodial direction 2023-10-16 19:16:29 +02:00
Nils Dagsson Moskopp ef65de54c0
Make 3D rendered donut appear solid 2023-10-16 19:05:56 +02:00
Nils Dagsson Moskopp 4d57ba62bf
Add code to generate TGA type 1 test textures 2023-10-15 20:49:11 +02:00
Nils Dagsson Moskopp 4064333b06
Adjust TGA test texture file names 2023-10-15 20:11:28 +02:00
Nils Dagsson Moskopp e87a8fc332
Add script to generate TGA test textures 2023-10-15 17:02:19 +02:00
Nils Dagsson Moskopp bb68ceb38d
Do not encode images with illegal colormap indexes 2023-09-22 20:06:21 +02:00
Nils Dagsson Moskopp 4dd3833f3b
Move encoding format heuristics from image:save() to image:encode() 2023-09-18 16:45:31 +02:00
Nils Dagsson Moskopp 3029147ed7
Add example code for rendering a 3D shape using a Z-buffer 2023-09-18 15:21:17 +02:00
Nils Dagsson Moskopp 5bf0e79c6f
Add example code to generate TGA logo
The tiny logo is a 12×12 TGA image.
The huge logo is a 1200×1200 TGA image.
2023-08-27 15:12:47 +02:00
Nils Dagsson Moskopp e9862f5f24
Add example code for node colormap generation 2022-07-31 00:24:34 +02:00
Nils Dagsson Moskopp 685bdcb379
Allow encoding with B8G8R8A8 colormap 2022-05-19 18:26:41 +02:00
Nils Dagsson Moskopp 7446a275b5
Remove author from mod.conf
ContentDB sets this field automatically
2022-05-16 22:18:01 +02:00
Nils Dagsson Moskopp 83348bf3ac
Document use cases, image type support, plans 2022-05-16 20:34:33 +02:00
Nils Dagsson Moskopp 45e405982a
Allow encoding with A1R5G5B5 colormap 2022-05-16 18:48:18 +02:00
Nils Dagsson Moskopp e83894fcfa
Treat empty colormap as no colormap 2022-05-16 17:56:53 +02:00
Nils Dagsson Moskopp 9f9b78eed9
Allow color-mapped encoding for RGB images 2022-05-16 17:28:16 +02:00
Nils Dagsson Moskopp ed061e68ff
Allow RLE encoding for RGBA images 2022-05-16 13:16:23 +02:00
Nils Dagsson Moskopp 1f9c446a98
Assert that pixel data is encoded 2022-05-16 03:21:52 +02:00
Nils Dagsson Moskopp 7b94fc026d
Allow to specify color format 2022-05-16 02:48:51 +02:00
Nils Dagsson Moskopp fa23775bf9
Measure pixel_depth in bits everywhere 2022-05-16 01:54:21 +02:00
Nils Dagsson Moskopp 36ee45ebe3
Add RGBA support (only RAW encoding) 2022-05-16 01:39:33 +02:00
Nils Dagsson Moskopp 2112637faf
Use HSP for RGB-to-BW8 conversion 2022-05-15 19:58:19 +02:00
Nils Dagsson Moskopp 5b79bc6fb7
Set default encoding to R8G8B8 RAW
This the most trivial RGB encoding the encoder supports. Setting
it prevents a crash related to BW8 only supporting RAW encoding.
2022-05-15 19:31:24 +02:00
Nils Dagsson Moskopp 759b0a188f
Allow saving R8G8B8 images as BW8 2022-05-15 19:23:26 +02:00
Nils Dagsson Moskopp 376b6404b2
Allow RAW or RLE encoding for true-color images 2022-05-15 15:56:18 +02:00
Nils Dagsson Moskopp 9bd1702d60
Encode image only when saving it to a file 2022-05-15 14:58:12 +02:00
Nils Dagsson Moskopp 5640e19c94
Add fractal example 2022-05-15 03:10:53 +02:00
Nils Dagsson Moskopp 25b7b30945
Allow encoding grayscale images as BW8 2022-05-14 22:41:52 +02:00
Nils Dagsson Moskopp 9af0719df8
Allow encoding RGB images as B8G8R8 2022-05-14 21:56:42 +02:00
Nils Dagsson Moskopp 1b48c3f539
Use raw packets in RLE compression in tga_encoder 2022-05-14 21:52:08 +02:00
Nils Dagsson Moskopp 13552f16f2
Reduce TGA filesize by 25% by using 16-bit colors 2022-05-14 21:52:07 +02:00
Nils Dagsson Moskopp 4f6ea5d035
Add credits to README 2022-05-14 21:52:07 +02:00
Nils Dagsson Moskopp c00b0d50c6
Add usage examples 2022-05-14 21:52:00 +02:00
Nils Dagsson Moskopp adb8e45d67
Fix TGA file writing on Windows
Before this patch, the tga_encoder mod would write corrupted TGA files
on Windows: Bytes that looked like newlines were replaced by a carriage
return and a newline.
2022-05-14 20:21:59 +02:00
Nils Dagsson Moskopp 3f60b5baa6
Speed up TGA encoding by creating fewer strings 2022-05-14 20:21:58 +02:00
Nils Dagsson Moskopp 52e5c955f0
Use RLE compression in tga_encoder 2022-05-14 20:21:58 +02:00
Lizzy Fleckenstein b88579b52e
Add updated tga_encoder 2022-05-14 20:21:58 +02:00
Lizzy Fleckenstein eaa4dc99d7
Initial import 2022-05-14 20:21:52 +02:00