aboutsummaryrefslogtreecommitdiff
path: root/scumm/smush/codec44.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scumm/smush/codec44.cpp')
-rw-r--r--scumm/smush/codec44.cpp62
1 files changed, 0 insertions, 62 deletions
diff --git a/scumm/smush/codec44.cpp b/scumm/smush/codec44.cpp
deleted file mode 100644
index dae835bb55..0000000000
--- a/scumm/smush/codec44.cpp
+++ /dev/null
@@ -1,62 +0,0 @@
-/* ScummVM - Scumm Interpreter
- * Copyright (C) 2002-2003 The ScummVM project
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
-
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
-
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * $Header$
- *
- */
-
-#include <stdafx.h>
-#include "codec44.h"
-
-bool Codec44Decoder::decode(byte *dst, const byte *src, int length) {
- int32 size_line, num;
- int32 width = getRect().width();
- int32 height = getRect().height();
- const byte *src2 = src;
- byte *dst2 = _buffer;
- byte val;
-
- do {
- size_line = READ_LE_UINT16(src2);
- src2 += 2;
- length -= 2;
-
- while (size_line != 0) {
- num = *src2++;
- val = *src2++;
- memset(dst2, val, num);
- dst2 += num;
- length -= 2;
- size_line -= 2;
- if (size_line != 0) {
- num = READ_LE_UINT16(src2) + 1;
- src2 += 2;
- memcpy(dst2, src2, num);
- dst2 += num;
- src2 += num;
- length -= num + 2;
- size_line -= num + 2;
- }
- }
- dst2--;
-
- } while (length > 1);
-
- memcpy(dst, _buffer, width * height);
-
- return true;
-}