A problem with xImage and JPG

A problem with xImage and JPG

Postby ukoenig » Mon Apr 26, 2021 2:16 pm

A alphablended JPG with xImage how is that possible :?:
The normal formats using transparent are : GIF, PNG, TIF and BMP

Image

the original JPG

Image

regards
Uwe :?:
Last edited by ukoenig on Tue Apr 27, 2021 5:51 am, edited 2 times in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: A problem with xImage and JPG

Postby karinha » Mon Apr 26, 2021 4:08 pm

Example, PRG?

Regards.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7804
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: A problem with xImage and JPG

Postby ukoenig » Mon Apr 26, 2021 4:23 pm

Nothing extra.
It is the original sample xImage01.prg from the sample-folder
You can test it from there.
For the test I added the image to the imagefolder thats all.
Just see the picture above

regards
Uwe
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: A problem with xImage and JPG

Postby karinha » Mon Apr 26, 2021 4:57 pm

Master, this JPG is damaged. I opened it with IRFANVIEW.EXE and the image is not perfect. Try another one please.

Greetings.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7804
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: A problem with xImage and JPG

Postby karinha » Mon Apr 26, 2021 5:16 pm

Look,

Image

Regards.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7804
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: A problem with xImage and JPG

Postby ukoenig » Mon Apr 26, 2021 5:46 pm

I*m using a professional sofware PHOTOSHOP and there is no error.

Most of JPG-files don't use solid colors on the border-area.
That is the reason black is shown transparent.
With my new < cellborder-tool > it is possible to test it as well.
The image-selection from the browser is using xImage.

I tested some more JPG*s

the problem belongs to JPG-images with some SOLID colorspaces from the outside
Next I painted a SOLID freehand-border around image Olga1.jpg
A normal JPG without solid colors doesn*t have any problems

Image

Image

Images can be tested here :

Image

Image

regards
Uwe
Last edited by ukoenig on Tue Apr 27, 2021 12:34 pm, edited 1 time in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: A problem with xImage and JPG

Postby nageswaragunupudi » Tue Apr 27, 2021 6:31 am

Please try chaing oBrw:bChange as
Code: Select all  Expand view
     :bChange       := { || oImage:lBmpTransparent := !( Lower( cFileExt( oBrw:aRow[ 2 ] ) ) $ "jpg,jpeg" ), ;
                             oImage:Refresh() }
 
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10620
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: A problem with xImage and JPG

Postby ukoenig » Tue Apr 27, 2021 12:38 pm

Thank You very much
it is working now :D
solid color-areas are rarely inside JPG-files special on the outline area :roll:

Image

regards
Uwe
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 112 guests