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
 loadfromfilebmp displays black image
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

Matthew T

USA
21 Posts

Posted - Jul 19 2012 :  12:22:04  Show Profile  Reply
Hi,

I am loading a .bmp image to TImageEnView:

IEImage.IO.LoadFromFileBMP(CustExamFolder+'\'+Exam2View)

Some of the files are displaying totally black. In windows, the file can be viewed with no problem. Other files display properly.

Any suggestions?

Thanks,
Matthew


Matthew

fab

1310 Posts

Posted - Jul 19 2012 :  14:22:16  Show Profile  Reply
Please could you post a sample file?
Go to Top of Page

fab

1310 Posts

Posted - Jul 22 2012 :  09:46:29  Show Profile  Reply
Hi,
that BMP was unsupported (or malformed?). It specified a color map for 15 (5+5+5) bit RGB image.
In next minor version it will be fixed.

In the meaning time open bmpfilt.pas, replace following code...

if (InfoHead^.biClrUsed > 0) then

...with...

if (InfoHead^.biClrUsed > 0) and (xBitCount <= 8) then


Go to Top of Page

Matthew T

USA
21 Posts

Posted - Jul 22 2012 :  12:54:14  Show Profile  Reply
I am new to ImageEn, what do I need to do to include this change? I have located the bmpfilt.pas in the source folder and changed the line of code.

Thanks

Matthew
Go to Top of Page

fab

1310 Posts

Posted - Jul 22 2012 :  14:36:57  Show Profile  Reply
Now recompile ImageEn packages (actually only runtime packages needs to be recompiled).
Go to Top of Page

Matthew T

USA
21 Posts

Posted - Jul 23 2012 :  07:39:48  Show Profile  Reply
Hi,

I am using Delphi XE2.

I loaded PKIECTRL16.dpk and PKIEDB16.dpk and compiled successfully but on DPKIECTRL16.dpk and DPKIEDB16.dpk I get the following errors:
DPKIECTRL16.DPK

contains
IERegCtrl in 'IERegCtrl.pas';

ERROR:
dcc command line for "DPKIECTRL16.dpk"
[DCC Fatal Error] DPKIECTRL16.dpk(50): F1026 File not found: 'IEREegCtrl.dcu'

DPKIEDB15.DPK

contains
IERegDB in 'IERegDB.pas';
dcc command line for "DPKIEDB16.dpk"
[DCC Fatal Error] DPKIEDB16.dpk(40): F1026 File not found: 'IERegDB.dcu'

If I keep the source folder in the lib path when I compile my app I get another error.

If I remove the source folder in the lib path and recompile my app, when I view the .bmp file it is still black.


Matthew
Go to Top of Page

fab

1310 Posts

Posted - Jul 23 2012 :  07:52:59  Show Profile  Reply
Is there "IERegCtrl.pas" in the same folder of DPKIECTRL16.DPK?
Go to Top of Page

Matthew T

USA
21 Posts

Posted - Jul 23 2012 :  08:06:34  Show Profile  Reply
The structure of the Folder is:

c:\Program files\ImageEn\Source
Folder BCBS
...
FOLDER DelphiXE2
FOLDER DelphiXE2_64
FOLDER libs
(files:)
bmpfilt.pas
...
videocap.pas

The DPKIECTRL16.DPK is in the DelphiXE2 folder
there are no .pas files here, they are in the parent folder (Source)

Matthew
Go to Top of Page

fab

1310 Posts

Posted - Jul 23 2012 :  09:52:25  Show Profile  Reply
Please move the content of "DelphiXE2" and "libs" into "Source" (that is the parent dir), and try to recompile.
Go to Top of Page

Matthew T

USA
21 Posts

Posted - Jul 23 2012 :  11:04:06  Show Profile  Reply
I am missing something. My lib path is
c:\program files\ImageEn\DelphiXE2

Is there another step I need? Is there a specific file which should be updated and put in this folder?



Matthew
Go to Top of Page

fab

1310 Posts

Posted - Jul 23 2012 :  12:09:26  Show Profile  Reply
In this case put "libs" content and "Source" (all .pas and .inc files) into "DelphiXE2", and try to recompile all packages.
Go to Top of Page

Matthew T

USA
21 Posts

Posted - Jul 23 2012 :  12:25:15  Show Profile  Reply
No luck.

I copied all the files to that folder - should I see a bmpfilt.obj file here (I don't)? I am sure I missed a step.

Thanks

Matthew
Go to Top of Page

fab

1310 Posts

Posted - Jul 23 2012 :  22:44:27  Show Profile  Reply
You should see bmpfilt.obj here and also bmpfilt.pas: are there both?
Go to Top of Page

Matthew T

USA
21 Posts

Posted - Jul 24 2012 :  06:48:59  Show Profile  Reply
Hi Fabrizio,

Success! Your prompt responses have been greatly appreciative. Do you ever sleep?

Anyway, the bmpfilt.obj has not been created but I must have missed copying other necessary files. Once I copied the folder it appears to be working. Thanks for all your help.

Matthew
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: