aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlyssa Milburn2011-04-14 18:36:34 +0200
committerAlyssa Milburn2011-04-14 18:37:27 +0200
commit2ac86f8140adde218086a8ccd17880e5eb90887d (patch)
treee43dfa0c1070d44b73287bfcdd700601da32b040
parentf035c2630194ee523dba83ce10eb4140cc6828ff (diff)
downloadscummvm-rg350-2ac86f8140adde218086a8ccd17880e5eb90887d.tar.gz
scummvm-rg350-2ac86f8140adde218086a8ccd17880e5eb90887d.tar.bz2
scummvm-rg350-2ac86f8140adde218086a8ccd17880e5eb90887d.zip
GRAPHICS: Replace PNG_HEADER macro with MKTAG
-rw-r--r--graphics/png.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/graphics/png.cpp b/graphics/png.cpp
index eb066efa57..96dc083092 100644
--- a/graphics/png.cpp
+++ b/graphics/png.cpp
@@ -99,8 +99,6 @@ enum PNGFilters {
kFilterPaeth = 4
};
-#define PNG_HEADER(a, b, c, d) CONSTANT_LE_32(d | (c << 8) | (b << 16) | (a << 24))
-
PNG::PNG() : _compressedBuffer(0), _compressedBufferSize(0),
_unfilteredSurface(0), _transparentColorSpecified(false) {
}
@@ -200,11 +198,11 @@ bool PNG::read(Common::SeekableReadStream *str) {
_stream = str;
// First, check the PNG signature
- if (_stream->readUint32BE() != PNG_HEADER(0x89, 0x50, 0x4e, 0x47)) {
+ if (_stream->readUint32BE() != MKTAG(0x89, 0x50, 0x4e, 0x47)) {
delete _stream;
return false;
}
- if (_stream->readUint32BE() != PNG_HEADER(0x0d, 0x0a, 0x1a, 0x0a)) {
+ if (_stream->readUint32BE() != MKTAG(0x0d, 0x0a, 0x1a, 0x0a)) {
delete _stream;
return false;
}