revert #1148 as prematurely incorporated

it's getting there, but there have been a few spots noted where it eroneously corrupts text, so we'll have to pull this back out for a bit barring a proper resolution
This commit is contained in:
AzaezelX 2024-01-11 13:33:03 -06:00
parent 78b56688d3
commit f946088214
22 changed files with 1813 additions and 20385 deletions

View file

@ -565,10 +565,15 @@ void DDSFile::SurfaceData::dumpImage(DDSFile *dds, U32 mip, const char *file)
// Copy our data in.
dMemcpy(foo->getWritableBits(), mMips[mip], dds->getSurfaceSize(dds->mHeight, dds->mWidth, mip) );
FileStream stream;
if(!foo->writeBitmap("png", file))
stream.open( file, Torque::FS::File::Write );
if ( stream.getStatus() == Stream::Ok )
{
Con::errorf("DDSFile::SurfaceData::dumpImage() - Error writing %s !", file);
// Write it out.
foo->writeBitmap("png", stream);
}
// Clean up.