ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Retrieving image information from JPEG2000-compressed PDF pages
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

yoshii

Japan
14 Posts

Posted - Sep 30 2026 :  02:53:50  Show Profile  Reply
I am developing a program to read PDF files and retrieve image information from the pages.
With the code below, I can retrieve image information for JPEG-compressed image objects, but I am unable to do so for JPEG2000-compressed image objects.
Could you please advise me on how to handle this?

procedure TMainForm.OpenImage(DocName: string);
var
  ok: Boolean;
  bmp: TIEBitmap;
  objType: TPdfObjectType;
  haveBMP: Boolean;
  i: Integer;
begin

  //at FormCreate()
  IEGlobalSettings().PDFEngine := ieenDLL;
  IEGlobalSettings().JPEG2000Engine := ieenDLL;
  ImageEnView1.LegacyBitmap := False;
  ImageEnView1.IO.NativePixelFormat := True;
  ImageEnView1.PdfViewer.Enabled := True;


  ok := ImageEnView1.IO.LoadFromFilePDF(DocName);
  ImageEnView1.PdfViewer.PageIndex := 0;
  for i := 0 to ImageEnView1.PdfViewer.Objects.Count - 1 do
  begin
    objType := ImageEnView1.PdfViewer.Objects[i].ObjectType;
    // Image properties
    if objType = ptImage then
    begin
      bmp := TIEBitmap.Create();
      haveBMP := ImageEnView1.PdfViewer.Objects[i].GetImage( bmp );
      if haveBMP then
      begin
        ShowMessage( Format( '  Image Size: %d x %d', [ bmp.Width, bmp.Height ]));
      end;
      bmp.Free();
    end;
  end;
end;


#65288;ImageEn 15.1.1, Delphi 12.3)

xequte

39560 Posts

Posted - Sep 30 2026 :  22:13:27  Show Profile  Reply
Hi Yoshi

Can you attach or forward me a couple of your sample PDF files?

Nigel
Xequte Software
www.imageen.com
Go to Top of Page

yoshii

Japan
14 Posts

Posted - Oct 01 2026 :  00:41:54  Show Profile  Reply
Hello,

I am sending a sample PDF file.
Please review it.

attach/yoshii/20261010401_Sample_Chart_sRGB_400dpi_JP2_Lossy.pdf
Go to Top of Page

xequte

39560 Posts

Posted - Oct 01 2026 :  23:54:55  Show Profile  Reply
Hi Yoshi

That type of PDF is not supported by the PDFium DLL in the shipping version of ImageEn. We have updated to the latest version of PDFium in the current beta. You can email us to test it (it is probably actually enough just to replace the old DLL with the new one).



Nigel
Xequte Software
www.imageen.com
Go to Top of Page

yoshii

Japan
14 Posts

Posted - Oct 02 2026 :  04:16:56  Show Profile  Reply
Hello,

I would like to try out the beta version.

Thank you.
Go to Top of Page

yoshii

Japan
14 Posts

Posted - Oct 16 2026 :  03:23:38  Show Profile  Reply
Hello Nigel,

The issue has been resolved in the pre-release version!
That’s fantastic.
Thank you very much.
Go to Top of Page

xequte

39560 Posts

Posted - Oct 16 2026 :  18:36:11  Show Profile  Reply
Thank you for testing it

Nigel
Xequte Software
www.imageen.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: