how to use drawJpeg

  • Hello,

    the instructions for how to use pdfPrinter.drawJpeg are very unclear. What do I put in the buffer and bufLen parameters.

    Here is a sample

    bmp:=tbitmap.create
    //draw something onbitmap
    jpg:=tjpegImage.create;
    jpg.assign(bmp)
    pdfPrinter.drawJpeg(x,y,w,h,bmp.width,bmp.height,?,?)

    what do I put in place of the question marks?

    • Offizieller Beitrag

    DrawJPEG is useful to draw JPEG data which has not been decompressed yet. It is important that the physical size is known since the PDF engine cannot detect this itself.

    The function is internally used by the DrawTGraphic procedure:

    I hope this makes it clear.

    Julian