You've already forked lazarus-ccr
fpexif: Set WriteJFIFandEXIF after reading a file so that existing segments are preserved.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7428 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -465,6 +465,7 @@ var
|
|||||||
reader: TBasicMetadataReader;
|
reader: TBasicMetadataReader;
|
||||||
bigEndian: Boolean;
|
bigEndian: Boolean;
|
||||||
hdr: TBytes;
|
hdr: TBytes;
|
||||||
|
hasJFIF: Boolean;
|
||||||
{$IFNDEF FPC}
|
{$IFNDEF FPC}
|
||||||
sa: ansistring;
|
sa: ansistring;
|
||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
@ -568,6 +569,7 @@ begin
|
|||||||
Move(hdr[SizeOf(TJpegJFXXSegment)], FJFXXThumbnail[0], Length(FJFXXThumbnail));
|
Move(hdr[SizeOf(TJpegJFXXSegment)], FJFXXThumbnail[0], Length(FJFXXThumbnail));
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
hasJFIF := true;
|
||||||
end;
|
end;
|
||||||
M_SOF0:
|
M_SOF0:
|
||||||
begin
|
begin
|
||||||
@ -584,6 +586,9 @@ begin
|
|||||||
end;
|
end;
|
||||||
AStream.Position := p + size;
|
AStream.Position := p + size;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
// Force writing of JFIF if it coexists with EXIF.
|
||||||
|
FWriteJFIFandEXIF := hasJFIF and HasExif;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TImgInfo.ReadTiff(AStream: TStream);
|
procedure TImgInfo.ReadTiff(AStream: TStream);
|
||||||
|
Reference in New Issue
Block a user