Page 1 of 1

Accessing background layer of transparent PNG in Photoshop

Posted: Sat May 17, 2014 3:04 pm
by pegot
Is it possible in Photoshop to access background layer of transparent PNG when rendered with Alpha Channel and Keep Environment?

When I render with Alpha Channel and Keep Environment and then bring that content into After Effects, I can choose whether to interpret the footage with or without the alpha channel.

This is very handy if I want to keep the background layer, but also add some compositing effects directly to the animated object in a duplicate layer.

MY QUESTION: How do I get access to that background layer if I want to bring those PNGs into Photoshop; where is that information stored and is it at all possible to access it from Photoshop?

Re: Accessing background layer of transparent PNG in Photoshop

Posted: Sat May 17, 2014 3:41 pm
by FrankPooleFloating
You can get a perfect selection of alpha (transparency) in any PS layer (even a 32bit PNG when first opened) by holding down CTRL and clicking the thumbnail in desired layer (which is a perfect selection of contents of layer, including semi-transparency), then invert this selection by doing CTRL+SHIFT+i... do whatever you need with this selection... Hope this helps. ;)

Re: Accessing background layer of transparent PNG in Photoshop

Posted: Sat May 17, 2014 7:32 pm
by pegot
Yes that's how I generally select an object on transparent layer. But what I am asking is where the background layer is (the layer of color produced when using daylight environment, for example).

When I open one of the rendered PNGs in Photoshop it automatically defaults to showing the layer transparency. But how would you instruct Photoshop to use the files "hidden" background daylight environment?

When generating a movie file out of the PNG animation sequence in Quicktime, the resulting file shows the daylight environment background layer but the resulting movie file also contains an optional alpha channel, which can be used when that movie file is then imported into After Effects.

Likewise, when importing one of the rendered PNG's directly into After Effects, one has the option of interpreting the file with its transparency, or "flattened" with the background daylight environment.

I'm just wondering how to do that directly in Photoshop - which only seems to show the file with its transparency. Yet the background layer info is contained somewhere in that file - how does one access it from Photoshop if not using After effects?

Re: Accessing background layer of transparent PNG in Photoshop

Posted: Sun May 18, 2014 8:19 pm
by FrankPooleFloating
Yeah.. that is a weird one. I actually forgot that data was available in AE - which I stumbled upon years ago in Interpret Footage > Main > Alpha... and its never come up since.

Just for shits-n-giggles, I opened a 32bit render in Fireworks CS6 as well, to see if any options are available there... Nope.. Hmmmm. :? It just never, ever, comes up in my workflow -- but after thinking about a bit, I could see myself occasionally using this to open a 2nd copy in PS for background/lighting reference...

Anyone?

Re: Accessing background layer of transparent PNG in Photoshop

Posted: Mon May 19, 2014 7:25 pm
by dionysiusmarquis
I think it's because all transparent pixel still got full rbg data (if alpha is not premultiplied). Meaning if you have a red Pixel with [255, 0, 0, 0] color data you just need to convert this Pixel to [255, 0, 0, 255] to make it visible again. If Photoshop would still support Pixel Bender you could easily write an one row shader to make the transparent pixel data visible again. But unfortunately they killed Pixel Bender for Photoshop which is a great loss if you ask me.

I did a fast Pixel bender test. Here you'll see the magic:

Original Transparency
Bildschirmfoto 2014-05-19 um 21.07.37.png
Boost every Pixel alpha 50% (there is no Pixel with less than 50% transparency). You can already see that there's a blue Square Hidden behind the transparent Pixel
Bildschirmfoto 2014-05-19 um 21.07.43.png
Boost every Pixel 100% (there is no transparent Pixel left). The Original Picture without alpha is revealed: A Blue square on white background.
Bildschirmfoto 2014-05-19 um 21.07.47.png