More PNG probs.

Anything beyond the basics in using the LiveCode language. Share your handlers, functions and magic here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9250
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: More PNG probs.

Post by richmond62 » Tue May 18, 2021 11:09 am

Aah: sounds good.

I will not be able to test that until Thursday night as currently away from my Mac Mini.

jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2718
Joined: Sat Dec 22, 2007 5:35 pm
Location: Genève
Contact:

Re: More PNG probs.

Post by jmburnod » Tue May 18, 2021 12:25 pm

Hi Panos,
I tested

Code: Select all

set the paintcompression to "png"
on preopenstack with the same result. Img of cd 1 is displayed correctly but img 1 of cd 2 is whole black
Kind regards
Jean-Marc
https://alternatic.ch

Klaus
Posts: 13793
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: More PNG probs.

Post by Klaus » Tue May 18, 2021 12:43 pm

Panos,

there is no indication that any of these images in question have been modified by the user,
so I don't think that "the paintcompression" is of any importance here.

Richmond just imported the image(s) and they look fine in the IDE but not in the resulting runtime!?


Best

Klaus

LiveCode_Panos
Livecode Staff Member
Livecode Staff Member
Posts: 818
Joined: Fri Feb 06, 2015 4:03 pm

Re: More PNG probs.

Post by LiveCode_Panos » Tue May 18, 2021 1:12 pm

Hello all,

It seems you have a sample stack for testing? Could you please attach it here, and I'll have a quick look.

Just tested with an image attached in p2 ("houseGIMP.png") and seems to work fine for me in both the IDE and the standalone (MacOS Mojave - LC 9.6.2 rc1)

Are you in Big Sur?

Kind regards,
Panos
--

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3975
Joined: Sun Jan 07, 2007 9:12 pm
Location: Bochum, Germany

Re: More PNG probs.

Post by bn » Tue May 18, 2021 1:21 pm

there is a link to a dropbox file with the stack above

That is what I used for testing. I am on MacOS 10.14.6 Mojave and find that images
1,14,15,18,30
do work. The others are black in the standalone.

However in LC when setting the imageData of the image "PB2" of card 2 to the imageData of itself then it shows up in the standalone.

My suspicion is that there is a black alpha channel or somesuch, or again a color profile which somehow is not at work in the IDE.

It would be helpful if Richmond could indicate what the difference between the images that show in the standalone and those that don't is.

Maybe Richmond could make the "master" images available on his dropbox?

Kind regards
Bernd

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3975
Joined: Sun Jan 07, 2007 9:12 pm
Location: Bochum, Germany

Re: More PNG probs.

Post by bn » Tue May 18, 2021 1:22 pm

richmond62 wrote:
Thu Mar 25, 2021 6:49 pm
Here's the whole stack: https://www.dropbox.com/s/5j498gbvuuhyn ... e.zip?dl=0
UTR = Unable To Reproduce
I thought that was called a vasectomy.
that is the link to the dropbox file

Kind regards
Bernd

LiveCode_Panos
Livecode Staff Member
Livecode Staff Member
Posts: 818
Joined: Fri Feb 06, 2015 4:03 pm

Re: More PNG probs.

Post by LiveCode_Panos » Tue May 18, 2021 1:31 pm

Ah thanks Bernd, I missed that link.
However in LC when setting the imageData of the image "PB2" of card 2 to the imageData of itself then it shows up in the standalone.
Interesting. Thanks for the workaround!

Cheers,
Panos
--

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3975
Joined: Sun Jan 07, 2007 9:12 pm
Location: Bochum, Germany

Re: More PNG probs.

Post by bn » Tue May 18, 2021 7:07 pm

I copied the images to" Preview" on my Mac and it idicated as color profile "Gimp build-in" for ones that displayed and also for ones that displayed not.
I change the color profile to "general RGB" and pasted it into the stack and built a standalone. Now that image was showing up.
I stronly suspect that something with the color profile is in play.

I assume that the color profile is overwritten when setting the imageData of an image to the imageData of that image because the image seems to be rebuilt by that command. As additional lead: when setting imagedata to imageData in LC the image reports a color profile of sRGB IEC61966-2.1

I also looked at alphaData and maskData of the images and they where equal and appropriate for some working and non working images: they were plausible.

It does not explain however why some images display and some not. Only hints.

Kind regards
Bernd

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9250
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: More PNG probs.

Post by richmond62 » Tue May 18, 2021 7:23 pm

Maybe Richmond could make the "master" images available on his dropbox?
'My wish is your command' . . . Err . . . :D

https://www.dropbox.com/sh/430gd92p74nc ... nlx2a?dl=0

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3975
Joined: Sun Jan 07, 2007 9:12 pm
Location: Bochum, Germany

Re: More PNG probs.

Post by bn » Tue May 18, 2021 7:47 pm

Richmond,

I have the feeling we are going in circles. The mystery why some of the gimp built-in profiles work in a standalone and some not is not solved.

But assigning a different color profile to the images seems to cure all images for standalone. (see page 2 of this thread and our discussion).

Please also note that it is not only image 1 that is shown when I build a standalone with your "PB" stack but also the ones I listed. Adding to the mystery.
The color profile for all pngs seems to be the same Gimp built-in. I compared them in ColorSync.app.

Kind regards
Bernd

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3975
Joined: Sun Jan 07, 2007 9:12 pm
Location: Bochum, Germany

Re: More PNG probs.

Post by bn » Tue May 18, 2021 7:51 pm

bn wrote:
Tue May 18, 2021 7:47 pm
But assigning a different color profile to the images seems to cure all images for standalone. (see page 2 of this thread and our discussion).
An easy way to change the color profile of an image on a Mac is to open the image in "Preview" You then have the option to change the color profile.

Maybe that is a workaround for your Summer-School.

Kind regards
Bernd

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9250
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: More PNG probs.

Post by richmond62 » Tue May 18, 2021 8:09 pm

My Summer school stuff happens with Xubuntu 18.04 machines so no 'Preview'.

jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2718
Joined: Sat Dec 22, 2007 5:35 pm
Location: Genève
Contact:

Re: More PNG probs.

Post by jmburnod » Fri Jul 09, 2021 2:34 pm

Hi All,
I noticed strange behavior using LC 9.6.3-rc-1 on Big Sur 11.4
As described above, some images (as control, not referenced files) display a black rectangle onto first cd (I have many images onto others cds that works fine).
When i compile a standalone, these images displays correctly. :?
Kind regards
Jean-Marc
https://alternatic.ch

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9250
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: More PNG probs.

Post by richmond62 » Sun Jul 18, 2021 3:18 pm

LC 9.6.3 rc 1 currently screwing up with PNG imports seemingly
randomly under MacOS 12 beta 3

Post Reply

Return to “Talking LiveCode”