Trenchbroom: Crash on enabling a texture collection containing a 16-bit greyscale PNG

Created on 24 Aug 2020  路  7Comments  路  Source: TrenchBroom/TrenchBroom

System Information

Trenchbroom v2020.1 Release on Windows 10

Expected Behavior

Enabling a texture collection does not crash the program.

Steps to Reproduce

Enable an available texture collection? It works fine with different games, but this one makes it crash. I'm not sure what's different here. Maybe because the game is on a different drive?

Crash Info

trenchbroom-crash-7.txt
trenchbroom-crash-7.log
trenchbroom-crash-7.map.txt

2 Bug

Most helpful comment

It's metal_height.png causing the crash (a 16 bit greyscale png).

FIBITMAP* tempImage = FreeImage_ConvertTo32Bits(image);

is returning null

All 7 comments

I expect this to be one of the textures. Can you make the textures available somewhere so that we can try to replicate the issue?

also, how many textures are in the directory and what are the average dimensions? (good chance this is another OOM crash)

also, how many textures are in the directory and what are the average dimensions? (good chance this is another OOM crash)

It being an OOM crash could make sense. There are 5 textures, all 512x512.
Here is what the materials folder looks like:
materials.zip

Hm I think I see what's happening, TB might be getting tripped up on the .import files (these are files that get created by godot when you import an asset into it) it has an extension of .png.import which might cause TB to think it's a texture so it tries to load it but well it turns out it's not so it crashes, that's my theory anyway

Hm I think I see what's happening, TB might be getting tripped up on the .import files (these are files that get created by godot when you import an asset into it) it has an extension of .png.import which might cause TB to think it's a texture so it tries to load it but well it turns out it's not so it crashes, that's my theory anyway

Doubt it, .png.import is read as an .import extension, and TB might be checking for the extension

It's metal_height.png causing the crash (a 16 bit greyscale png).

FIBITMAP* tempImage = FreeImage_ConvertTo32Bits(image);

is returning null

It's metal_height.png causing the crash (a 16 bit greyscale png).

FIBITMAP* tempImage = FreeImage_ConvertTo32Bits(image);

is returning null

Aha, got it. Thanks!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

HeadClot picture HeadClot  路  4Comments

JackViney96 picture JackViney96  路  5Comments

ericwa picture ericwa  路  4Comments

dumptruckDS picture dumptruckDS  路  5Comments

kduske picture kduske  路  4Comments