In wPdf 4.76, adding a png image using DrawPng or DrawPngFile does not work in the delphi 7 variant, while it work using the DX11 variant

  • Hi,


    It looks like DrawPng and DrawPngFile do not work under the delphi 7 variant of wPdf in version 4.76.


    Here is how our code look like :


    temp := TMemoryStream.Create;

    try

    png.SaveToStream(temp);

    png.SaveToFile('picture.png');

    (* PdfPrinter.DrawPNG(adaptedDrawRect.Left, adaptedDrawRect.Top,

    adaptedDrawRect.Right - adaptedDrawRect.Left,

    adaptedDrawRect.Bottom - adaptedDrawRect.Top,

    temp.Memory, temp.Size,

    true);*)

    PdfPrinter.DrawPNGFile(adaptedDrawRect.Left, adaptedDrawRect.Top,

    adaptedDrawRect.Right - adaptedDrawRect.Left,

    adaptedDrawRect.Bottom - adaptedDrawRect.Top,

    'picture.png', true);

    finally

    temp.Free;

    end;


    Any hints to solve or maybe workaround this problem ?