Skip to content

Commit

Permalink
Switch PNG saving to libpng
Browse files Browse the repository at this point in the history
  • Loading branch information
RicardoLuis0 committed Sep 5, 2024
1 parent 14fc9c8 commit ab297df
Show file tree
Hide file tree
Showing 11 changed files with 128 additions and 360 deletions.
1 change: 1 addition & 0 deletions src/common/filesystem/include/fs_files.h
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,7 @@ class FileWriter
static FileWriter *Open(const char *filename);

virtual size_t Write(const void *buffer, size_t len);
virtual void Flush();
virtual ptrdiff_t Tell();
virtual ptrdiff_t Seek(ptrdiff_t offset, int mode);
size_t Printf(const char *fmt, ...);
Expand Down
9 changes: 9 additions & 0 deletions src/common/filesystem/source/files.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -465,6 +465,15 @@ size_t FileWriter::Write(const void *buffer, size_t len)
}
}


void FileWriter::Flush()
{
if (File != nullptr)
{
fflush(File);
}
}

ptrdiff_t FileWriter::Tell()
{
if (File != nullptr)
Expand Down
Loading

0 comments on commit ab297df

Please sign in to comment.