Display Alpha channel 32 bit BMP on ButtonBMP (Solved)
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Dear Mr.Antonio,
The BMP is getting displayed on ButtonBMP control without any changes in the original class.
It was my mistake and I am extremely sorry for this.
I used xMate to build my project. Something wrong with my settings in xMate. Till now I am not able to resolve it
I am puzzled and I don't know where I have went wrong with xMate
When I build my project with xMate:-
1) My exe does not display AlphaBMP 32bit BMP on ButtonBMP
2) My exe gives CreateDlgError when I try to open a Dialog created using the resource builder ResEd.
When I used the modified version of .rmk available in the folder \FWH\makes\bormake.zip everything worked fine. ( Only the resource compiler changed to Pelles )
I had opened another topic http://forums.fivetechsupport.com/viewt ... =3&t=14148 regarding the CreateDlgError and ResEd. When I changed xMate to .rmk this problem too got solved.
Any hint what could be wrong ?
Regards
Anser
The BMP is getting displayed on ButtonBMP control without any changes in the original class.
It was my mistake and I am extremely sorry for this.
I used xMate to build my project. Something wrong with my settings in xMate. Till now I am not able to resolve it
I am puzzled and I don't know where I have went wrong with xMate
When I build my project with xMate:-
1) My exe does not display AlphaBMP 32bit BMP on ButtonBMP
2) My exe gives CreateDlgError when I try to open a Dialog created using the resource builder ResEd.
When I used the modified version of .rmk available in the folder \FWH\makes\bormake.zip everything worked fine. ( Only the resource compiler changed to Pelles )
I had opened another topic http://forums.fivetechsupport.com/viewt ... =3&t=14148 regarding the CreateDlgError and ResEd. When I changed xMate to .rmk this problem too got solved.
Any hint what could be wrong ?
Regards
Anser
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Are you certain in your xMate the .rc got compiled and the resultant .res is linked in? Just a thought.
FWH 11.08/FWH 19.03
xHarbour 1.2.1 (Rev 6406) + BCC
Harbour 3.1 (Rev 17062) + BCC
Harbour 3.2.0dev (r1904111533) + BCC
xHarbour 1.2.1 (Rev 6406) + BCC
Harbour 3.1 (Rev 17062) + BCC
Harbour 3.2.0dev (r1904111533) + BCC
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Yes, the .RC is getting compiled and all the images contained in the .RC are getting displayed on other controls except the 32 bit BMP. The Dialog from Resources gives a run time error CreateDlgError.Are you certain in your xMate the .rc got compiled and the resultant .res is linked in? Just a thought.
This happens only when xMate is used to buid the project. If .rmk then everything working fine. I really don't understand where I have went wrong.
Definitely it's my configuration mistake in xMate, because Mr.Fraxzy is able to use xMate with the resource editor ResEd
I have posted the contents of my xMate project file in the following link
http://www.forums.fivetechsupport.com/v ... =3&t=14148
Regards
Anser
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Anser,
Please open you EXE with Pelles and check if all your resources are inside the EXE, when you build it using xMate.
Please open you EXE with Pelles and check if all your resources are inside the EXE, when you build it using xMate.
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Dear Mr.Antonio,
From this I understand that PellesC is compiling the .RC file and creating .RES file.
Other images contained in the same .RC files of this project are displayed on other controls in my EXE.
I have gone really crazy tying to solve this. I think I should take a break.
Regards
Anser
I did not find an option in Pelles to open an EXE to find out it's resources. When I opened .RES file with the ResEdit (Another free resource editor which allows to open .RES file), I found that ResEdit was able to Re-create all the BMPS and even the Dialog from the .RES filePlease open you EXE with Pelles and check if all your resources are inside the EXE, when you build it using xMate.
From this I understand that PellesC is compiling the .RC file and creating .RES file.
Other images contained in the same .RC files of this project are displayed on other controls in my EXE.
I have gone really crazy tying to solve this. I think I should take a break.
Regards
Anser
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Anser,
> I did not find an option in Pelles to open an EXE
Just click the "open" button and select the name of your exe (i.e. MyApp.exe )
Then you will see all the resources embedded into the EXE
> I did not find an option in Pelles to open an EXE
Just click the "open" button and select the name of your exe (i.e. MyApp.exe )
Then you will see all the resources embedded into the EXE
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Dear Mr.Antonio,
Thankyou for the info, I opened the exe with Pelles
You are right the specific BMP and the Dialog does not exist in the Exe
Now what could be wrong ? Is it the Linking part ?
in .RES file it is there ?. Any hint ?
Regards
Anser
Thankyou for the info, I opened the exe with Pelles
You are right the specific BMP and the Dialog does not exist in the Exe
Now what could be wrong ? Is it the Linking part ?
in .RES file it is there ?. Any hint ?
Regards
Anser
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Dear Mr.Antonio,
Screen Snapshots
1. Exe created using \FWH\Bormake and Opened on PellesC All resources exist ie Dialog and AnsTest.BMP
2. Exe created using xMate and Opened on PellesC Missing resources ie Dialog and AnsTest.BMP
3. .RES file created by PellesC. This .RES file is used in xMate All resources exist ie Dialog and AnsTest.BMP
Is there any specific parameters to be taken care while executing the link command ?
I wonder why this particular BMP and DIALOG is missing from the EXE, the rest of the resources are getting added to the EXE
Regards
Anser
Screen Snapshots
1. Exe created using \FWH\Bormake and Opened on PellesC All resources exist ie Dialog and AnsTest.BMP
2. Exe created using xMate and Opened on PellesC Missing resources ie Dialog and AnsTest.BMP
3. .RES file created by PellesC. This .RES file is used in xMate All resources exist ie Dialog and AnsTest.BMP
Is there any specific parameters to be taken care while executing the link command ?
I wonder why this particular BMP and DIALOG is missing from the EXE, the rest of the resources are getting added to the EXE
Regards
Anser
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Anser,
I assume that:
1. You keep your resources in a RC file.
2. You use xMate to create the RES file from the RC file.
if yes, then please use Pelles to inspect the RES file created from xMate, and check what there is inside it.
Is xMate calling Borland brc32.exe to create the RES file ? (sorry, we don't use xMate here, we use UEStudio).
I assume that:
1. You keep your resources in a RC file.
2. You use xMate to create the RES file from the RC file.
if yes, then please use Pelles to inspect the RES file created from xMate, and check what there is inside it.
Is xMate calling Borland brc32.exe to create the RES file ? (sorry, we don't use xMate here, we use UEStudio).
Re: Display Alpha channel 32 bit BMP on ButtonBMP
YesAntonio Linares wrote:Anser,
I assume that:
1. You keep your resources in a RC file.
The 3 rd image which I have posted in my previous post is the screen snapshot of the .RES file created by the PellesC Resource compiler. When Opened with PellesC it shows that the 32 bit BMP "AnsTest" and the DIALOG exists in the .RES fileAntonio Linares wrote:2. You use xMate to create the RES file from the RC file.
if yes, then please use Pelles to inspect the RES file created from xMate, and check what there is inside it.
No, in xMate Environment file I have changed the resource compiler part command from Borland to PellesCAntonio Linares wrote:Is xMate calling Borland brc32.exe to create the RES file ? (sorry, we don't use xMate here, we use UEStudio).
From
Code: Select all
%C_BIN_INSTALL%\Brc32.Exe -r -fo%RES% %RC%
Code: Select all
C:\PellesC\Bin\PORC.EXE %RC% /I C:\pellesc\include /I C:\pellesc\include\win
Regards
Anser
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Dear Antonio,
Problem solved. I deleted the xMate Project and re-created it.
xMate by default will create certain folders inside our project folder. xMate author has adviced not to delete these folders and has asked to leave as it is.
The sub folders created by xMate in our project directory are :-
Backup
Bin
Debug
Include
Lib
Obj
Resource
Source
I don't know how it happened, I found a .RES file copied inside the Resource folder and it was that .RES file getting linked to my EXE . May be a copy made by xMate itslef when some error occured will creating the .RES file, I guess. I understand that if .RES file exists in the RESOURCE folder then xMate will link that .RES file with the EXE and ignores the .RES file compiled and generated in the project folder. I deleted the .RES file from the folder RESOURCE and everything worked as expected.
Anyway it is a good lesson. I am writing it down here so that it may be useful for beginners like me .
Thanks for your effort.
Regards
Anser
Problem solved. I deleted the xMate Project and re-created it.
xMate by default will create certain folders inside our project folder. xMate author has adviced not to delete these folders and has asked to leave as it is.
The sub folders created by xMate in our project directory are :-
Backup
Bin
Debug
Include
Lib
Obj
Resource
Source
I don't know how it happened, I found a .RES file copied inside the Resource folder and it was that .RES file getting linked to my EXE . May be a copy made by xMate itslef when some error occured will creating the .RES file, I guess. I understand that if .RES file exists in the RESOURCE folder then xMate will link that .RES file with the EXE and ignores the .RES file compiled and generated in the project folder. I deleted the .RES file from the folder RESOURCE and everything worked as expected.
Anyway it is a good lesson. I am writing it down here so that it may be useful for beginners like me .
Thanks for your effort.
Regards
Anser
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Anser,
Glad to know that you solved it
Thanks for sharing that valuable info for other xMate users
Glad to know that you solved it
Thanks for sharing that valuable info for other xMate users
- Giovany Vecchi
- Posts: 129
- Joined: Mon Jun 05, 2006 9:39 pm
- Location: Brasil
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Eu fiz algumas alterações na classe pra funcionar com bmps alpha channels
http://www.fivewin.com.br/exibedicas.asp?id=924
ex:
oBtnBmp:lBmpAlpha := .T.
http://www.fivewin.com.br/exibedicas.asp?id=924
ex:
oBtnBmp:lBmpAlpha := .T.
anserkk wrote:Hi,
I understand that Borland Resource Compiler does not support Alpha channel BMP's, I have used "Pelles C" resource compiler to compile the .RC file without any error's.
Unfortunately the ButtonBMP is not displaying the image. (No errors).
I hope ButtonBMP support's 32bit Alpha BMP's.
Any hint?
Regards
Anser
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Here's a good one:
.RC
Thanks Giovany!!!
Regards,
Code: Select all
...
@ 50, 50 BUTTONBMP aBtn1[4] OF oMDIFrame:oWndClient BITMAP 'alpha32' PIXEL
@ 50, 200 BUTTONBMP aBtn1[5] OF oMDIFrame:oWndClient BITMAP 'alpha32' PIXEL
aBtn1[5]:lBmpAlpha := .T.
...
Code: Select all
...
alpha32 BITMAP DISCARDABLE "D:/FWH812/bitmaps/AlphaBmp/world.bmp"
...
Thanks Giovany!!!
Regards,
Kind Regards,
Frances
Fivewin for xHarbour v18.07
xHarbour v1.2.3.x
BCC 7.3 + PellesC8 ( Resource Compiler only)
ADS 10.1 / MariaDB
Crystal Reports 8.5/9.23 DE
xMate v1.15
Frances
Fivewin for xHarbour v18.07
xHarbour v1.2.3.x
BCC 7.3 + PellesC8 ( Resource Compiler only)
ADS 10.1 / MariaDB
Crystal Reports 8.5/9.23 DE
xMate v1.15
Re: Display Alpha channel 32 bit BMP on ButtonBMP
Thanks Giovany!!!
The control is displaying AlphaChannels.
Anser
The control is displaying AlphaChannels.
RegardsEu fiz algumas alterações na classe pra funcionar com bmps alpha channels
http://www.fivewin.com.br/exibedicas.asp?id=924
ex:
oBtnBmp:lBmpAlpha := .T.
Anser