From Olaf Flebbe, "FlightGear/OSG on Windows did not load the Texture Fonts.
1) TXF Fonts are binary. 2) Do not rely on the result of istream::readsome if buffer _is_ empty and no data have been read before."
This commit is contained in:
@@ -39,7 +39,7 @@ class ReaderWriterTXF : public osgDB::ReaderWriter
|
||||
if (fileName.empty()) return ReadResult::FILE_NOT_FOUND;
|
||||
|
||||
std::ifstream stream;
|
||||
stream.open(fileName.c_str(), std::ios::in);
|
||||
stream.open(fileName.c_str(), std::ios::in | std::ios::binary);
|
||||
if (!stream.is_open()) return ReadResult::FILE_NOT_FOUND;
|
||||
|
||||
TXFFont* impl = new TXFFont(fileName);
|
||||
|
||||
Reference in New Issue
Block a user