SOIL icon indicating copy to clipboard operation
SOIL copied to clipboard

File Returns NULL data

Open xSeditx opened this issue 6 years ago • 0 comments

I have a file that came with the Sponza test scene, Dielectric_metallic.png. When loading it, it returns the correct Channels however the Size returns 0,0 and Data returns as null. I suspect this to do with the File compression since the image is totally black but not 100% sure at the moment. I opened the file in Windows paint and just resaved it and the file now loads suggesting the format it originally used was not being read by SOIL correctly.

I was loading the image using the following command. Size being the Dimensions, Data = SOIL_load_image(Filepath.c_str(), &Size.x, &Size.y, &Channels, SOIL_LOAD_AUTO);

[edit] The pure white Metallic_metallic.png also has done the same thing.

xSeditx avatar Jul 03 '19 04:07 xSeditx