Explicitly state scanline order in test texture script

This commit is contained in:
Nils Dagsson Moskopp 2023-10-16 20:57:00 +02:00
parent 01bcbbf927
commit 10022c93ef
Signed by: erle
GPG Key ID: A3BC671C35191080
1 changed files with 24 additions and 24 deletions

View File

@ -6,7 +6,7 @@ local R = { 1 }
local G = { 2 }
local B = { 3 }
local pixels_colormapped = {
local pixels_colormapped_bt = {
{ _, _, _, _, _, B, _, B, },
{ _, _, _, _, _, B, B, B, },
{ _, _, G, G, G, B, _, B, },
@ -17,7 +17,7 @@ local pixels_colormapped = {
{ R, R, R, _, _, _, _, _, },
}
image_colormapped = tga_encoder.image(pixels_colormapped)
image_colormapped_bt = tga_encoder.image(pixels_colormapped_bt)
colormap_32bpp = {
{ 0, 0, 0, 128 },
@ -25,13 +25,13 @@ colormap_32bpp = {
{ 0, 255, 0, 255 },
{ 0, 0, 255, 255 },
}
image_colormapped:save(
image_colormapped_bt:save(
"type1_32bpp_bt.tga",
{ colormap = colormap_32bpp, color_format = "B8G8R8A8" }
{ colormap = colormap_32bpp, color_format = "B8G8R8A8", scanline_order = "bottom-top" }
)
image_colormapped:save(
image_colormapped_bt:save(
"type1_16bpp_bt.tga",
{ colormap = colormap_32bpp, color_format = "A1R5G5B5" }
{ colormap = colormap_32bpp, color_format = "A1R5G5B5", scanline_order = "bottom-top" }
)
colormap_24bpp = {
@ -40,9 +40,9 @@ colormap_24bpp = {
{ 0, 255, 0 },
{ 0, 0, 255 },
}
image_colormapped:save(
image_colormapped_bt:save(
"type1_24bpp_bt.tga",
{ colormap = colormap_32bpp, color_format = "B8G8R8" }
{ colormap = colormap_32bpp, color_format = "B8G8R8", scanline_order = "bottom-top" }
)
local _ = { 0, 0, 0, 128 }
@ -50,7 +50,7 @@ local R = { 255, 0, 0, 255 }
local G = { 0, 255, 0, 255 }
local B = { 0, 0, 255, 255 }
local pixels_rgba = {
local pixels_rgba_bt = {
{ _, _, _, _, _, B, _, B, },
{ _, _, _, _, _, B, B, B, },
{ _, _, G, G, G, B, _, B, },
@ -61,15 +61,15 @@ local pixels_rgba = {
{ R, R, R, _, _, _, _, _, },
}
image_rgba = tga_encoder.image(pixels_rgba)
image_rgba_bt = tga_encoder.image(pixels_rgba_bt)
image_rgba:save(
image_rgba_bt:save(
"type2_32bpp_bt.tga",
{ color_format="B8G8R8A8", compression="RAW" }
{ color_format="B8G8R8A8", compression="RAW", scanline_order = "bottom-top" }
)
image_rgba:save(
image_rgba_bt:save(
"type10_32bpp_bt.tga",
{ color_format="B8G8R8A8", compression="RLE" }
{ color_format="B8G8R8A8", compression="RLE", scanline_order = "bottom-top" }
)
local _ = { 0, 0, 0 }
@ -77,7 +77,7 @@ local R = { 255, 0, 0 }
local G = { 0, 255, 0 }
local B = { 0, 0, 255 }
local pixels_rgb = {
local pixels_rgb_bt = {
{ _, _, _, _, _, B, _, B, },
{ _, _, _, _, _, B, B, B, },
{ _, _, G, G, G, B, _, B, },
@ -88,22 +88,22 @@ local pixels_rgb = {
{ R, R, R, _, _, _, _, _, },
}
image_rgb = tga_encoder.image(pixels_rgb)
image_rgb_bt = tga_encoder.image(pixels_rgb_bt)
image_rgb:save(
image_rgb_bt:save(
"type2_24bpp_bt.tga",
{ color_format="B8G8R8", compression="RAW" }
{ color_format="B8G8R8", compression="RAW", scanline_order = "bottom-top" }
)
image_rgb:save(
image_rgb_bt:save(
"type10_24bpp_bt.tga",
{ color_format="B8G8R8", compression="RLE" }
{ color_format="B8G8R8", compression="RLE", scanline_order = "bottom-top" }
)
image_rgb:save(
image_rgb_bt:save(
"type2_16bpp_bt.tga",
{ color_format="A1R5G5B5", compression="RAW" }
{ color_format="A1R5G5B5", compression="RAW", scanline_order = "bottom-top" }
)
image_rgb:save(
image_rgb_bt:save(
"type10_16bpp_bt.tga",
{ color_format="A1R5G5B5", compression="RLE" }
{ color_format="A1R5G5B5", compression="RLE", scanline_order = "bottom-top" }
)