* Fix reading bitmap types 5,6 for PNM (fix by reporter of Bug ID #52564)

git-svn-id: trunk@26698 -
This commit is contained in:
michael 2014-02-06 22:14:19 +00:00
parent 98dc27db1c
commit 9699890e3d

View File

@ -136,7 +136,11 @@ var
begin
ReadHeader(Stream);
Img.SetSize(FWidth,FHeight);
FScanLineSize:=FBitPP*((FWidth+7)shr 3);
Case FBitmapType of
5,6 : FScanLineSize:=(FBitPP div 8) * FWidth;
else
FScanLineSize:=FBitPP*((FWidth+7)shr 3);
end;
GetMem(FScanLine,FScanLineSize);
try
for Row:=0 to img.Height-1 do