diff -urN bmconv-1.1.0-2.orig/src/bmconv.h bmconv-1.1.0-2/src/bmconv.h
--- bmconv-1.1.0-2.orig/src/bmconv.h	2004-12-22 14:55:40.000000000 +0200
+++ bmconv-1.1.0-2/src/bmconv.h	2006-09-24 15:09:50.000000000 +0300
@@ -190,7 +190,7 @@
 	int WriteRomheader();
 	int WriteRombitmap(SEpocBitmapHeader* aPbm);
 	int WriteFileheader();
-	int WriteFilebitmap(SEpocBitmapHeader* aPbm);
+	int WriteFilebitmap(SEpocBitmapHeader* aPbm, bool aCompress);
 	int WriteHeadStream();
 	void Write16(unsigned short v);
 	void WriteBuf16(const char *buf, int size);
diff -urN bmconv-1.1.0-2.orig/src/pbmcomp.cpp bmconv-1.1.0-2/src/pbmcomp.cpp
--- bmconv-1.1.0-2.orig/src/pbmcomp.cpp	2004-12-22 14:55:40.000000000 +0200
+++ bmconv-1.1.0-2/src/pbmcomp.cpp	2006-09-24 15:09:50.000000000 +0300
@@ -186,7 +186,7 @@
 		return ret;
 	for (count=0;count<iNumSources;count++)
 		{
-		ret = WriteFilebitmap(iPbmSources[count]);
+		ret = WriteFilebitmap(iPbmSources[count], aCompress);
 		if (ret)
 			return ret;
 		}
@@ -368,7 +368,7 @@
 }
 
 
-int BitmapCompiler::WriteFilebitmap(SEpocBitmapHeader* aPbm)
+int BitmapCompiler::WriteFilebitmap(SEpocBitmapHeader* aPbm, bool aCompress)
 	{
 	if (aPbm->iPaletteEntries != 0)
 		return PaletteSupportNotImplemented;
@@ -376,7 +376,10 @@
 	int dataSize = aPbm->iBitmapSize - sizeof(SEpocBitmapHeader);
 
 	WriteBuf32((char*)(aPbm),sizeof(SEpocBitmapHeader));
-	WriteBuf16(((char*)(aPbm)) + sizeof(SEpocBitmapHeader),dataSize);
+	if (aPbm->iBitsPerPixel==12 || (aPbm->iBitsPerPixel==16 && !aCompress))
+		WriteBuf16(((char*)(aPbm)) + sizeof(SEpocBitmapHeader),dataSize);
+	else
+		iDestFile.write(((char*)(aPbm)) + sizeof(SEpocBitmapHeader),dataSize);
 
 	return NoError;
 	}
@@ -773,17 +776,35 @@
 	while (aLength > 128)
 		{
 		*aDest++ = -128;
-		memcpy(aDest,srcePtr,256);
-		aDest += 256;
+//		memcpy(aDest,srcePtr,256);
+//		aDest += 256;
+		unsigned short *sptr = (unsigned short*) srcePtr;
+		for (int i = 0; i < 128; i++)
+			{
+			char lowByte = char(*sptr);
+			char highByte = char(*sptr >> 8);
+			sptr++;
+			*aDest++ = lowByte;
+			*aDest++ = highByte;
+			}
 		srcePtr += 256;
 		aLength -= 128;
 		}
 
 	*aDest++ = char(-aLength);
 
-	int remainingBytes = aLength * 2;
-	memcpy(aDest,srcePtr,remainingBytes);
-	aDest += remainingBytes;
+//	int remainingBytes = aLength * 2;
+//	memcpy(aDest,srcePtr,remainingBytes);
+//	aDest += remainingBytes;
+	unsigned short *sptr = (unsigned short*) srcePtr;
+	for (int i = 0; i < aLength; i++)
+		{
+		char lowByte = char(*sptr);
+		char highByte = char(*sptr >> 8);
+		sptr++;
+		*aDest++ = lowByte;
+		*aDest++ = highByte;
+		}
 
 	return NoError;
 	}
