I have the default scene (cube), rendered it and saved the render as PNG with RGBA. Although the render in the Image Editor showed the cube with a gray background (sky color) the saved PNG image had the cube with a transparent background. In the Properties window under the Render tab, Sky was checked to render in the Layers panel and Alpha was set to sky in the Shading panel. So why didn’t the sky render (in the saved image)? Also if I used the RenderLayer as input in the node editor it has a transparent background.
It seems that the sky is only rendered if the output format does not support transparency.
I’m pretty sure the sky color is there, but it is hidden because of the alpha channel. We’re you to ignore the alpha information, you would see the gray. However, without any surfaces, the alpha value still comes up as zero.
Premultiplied alpha causes a black background with anti-aliased edges in the image. Straight alpha has ugly edges (not aliased - something uglier!) but a nice anti-aliased alpha channel, so it all works out. Sky is like premultiplied but with a bg color that matches the sky. Or that’s how I understand it…
Thanks, I must admit I find it all a bit confusing. Why have a sky that you can’t see? I guess if I use a non-trans output I can see it. No biggie really, I suppose.
This (AFAIK) basically is the purpose of that setting: “here is the sky, but I don’t want the sky to show up in the output.” It basically covers the most-common use case.
Now, when I am rendering anything other than the final-final of anything, I’m pretty much always using the “MultiLayer” format. So, if this file is something that you plan to do further things with (e.g. it is the input to another render), that’s the format I would use throughout your entire pipeline. The very last step is to generate a copy of “the final” result in this-format or that-one.
On a related topic, does anyone know how to include the alpha in an image rendered with Cycles? I’ve tried searching for an answer, but couldn’t find anything related.
For some reason, the only thing that happens when using that option in conjunction with a sky map (HDR), is that it gets blanked out by a pitch black background with no alpha information. Without the sky map, it works fine. Furthermore, it’s only the final render that’s being affected by this, the preview works just fine. Any hint on why this happens?
Uhm, you have to switch the renderwindow from RGB to RGBA to show alpha?
3 Small icons next to the “enable image painting mode icon”
If you set the film to transparent with a environmental map, it should show the checkerbackground for alpha in the preview, if you render it’s pitchblack, because the standardview is set to RGB. If you set it to RGBA you see the image with activated alphachannel.
If you save the image in any RGBA format, the alpha is saved obviously, regardless of if you turned it on in the renderwindow or not.
I should have mentioned that I’ve already tried that, but it didn’t work. Again it works when I’m not using a sky map. Perhaps it’s worth mentioning, when I rendered with RGBA the first time, the checkerboard appeared for a fraction of a second only to be replaced by that black background. I didn’t want to yell “Bug!” before I was certain, but this couldn’t be normal behaviour, right?
EDIT: This is weird. I just started preparing a test scene for you to try, when suddenly it worked! I tried with both regular JPGs and HDRIs and they work as expected. So I suppose I’ll have to narrow down the problem in that particular scene.
Anyways, thank you very much for your help! So I guess we’re even now, huh? Haha!