How to render alpha maps in Blender 3D and YafaRay for architecture

In one of the articles of the blog I have written about the setup of alpha maps in LuxRender, to render trees and other elements that could be created and rendered with textures, especially vegetation for external architectural visualization. Since then, a lot of people ask me about the same technique applied to YafaRay. Is that possible? Of course it is! But, the workflow to get the same results with 2d cutout trees or people is different in YafaRay. If you don’t remember, in LuxRender we have to use a null material type and there is no support for alpha maps in PNG files.

Since YafaRay can read most of the parameters and options from the Blender textures, those types of things won’t be a problem. In fact, the workflow to add alpha maps in YafaRay is very similar to what we do with the Blender internal render.

Let’s see how it works.

First of all, I have prepared a PNG file with a cutout tree taken from this free texture library. The Image was edited in GIMP.


Create a mesh plane or other object where the texture will be applied, and add a material and then assign an image based texture. At the image texture setup panel, we have only to turn on the Use Alpha button.


Go to the materials panel of Blender, and at the Map Input check the UV button and at the Mat To menu, press the Alpha button to make the texture affect the transparency of the object.


Open a UV/Image Editor window and Unwrap the plane. Open the texture in the editor to adjust the placement of the texture. A nice shortcut here is the ALT+V, which will fit the size of the plane to the proportions of the texture.


Now, open the YafaRay exporter panel and go to the material tab. Choose a shinydiffusemat and the only thing we will have to do here is set the transparency to 1. If you press the “Refresh Preview” button it will already show the result of the alpha map applied to the material.


With everything set, we can render the scene. If you have a 3d model or object, place the planes with the textures in key positions and render an image. In the example below I have the model created for the getting started with YafaRay for external render article.


This types of textures are quite handy for external architectural visualization.

Blender 3D Architect Pro


  • sfepa

    i think it is necessary to say that you have to increase ray depth value in render settings to avoid problems with visibility of the base planes when they are overlapping each other or reflecting in the glass.

  • Felix

    It seems that if there are visually overlapping “flat-trees”, for example a row beside the road. There will be artifacts like that one –

    And the only way to solve them out is to increase raydepht. So it will be more rays then overlapping cases.

    But still, great tutorial.

  • Allan Brito

    Good point sfepa! I totally forgot to mention that!

  • sfepa

    it’s ok. i didn’t knew that thing and had no idea how to remove that black areas, and even what they are 🙂
    and here

  • Ashworth

    I don’t know if this has the same effect in Yafray but with the blender internal renderer click the “Premul”tiply button in the image input channel to let blender know that you want to exclusively use the alpha from the map and not from it’s own internal alpha calculations.

  • julien34

    Hi, just a note about shadows:
    To have shadows cast correctly, you have to select “transparent shadows” in yafaray settings.
    And if you want “black” shadows turn down the “dvar” factor in blender “map to” texture setting, otherwise instead of the shadow, you will have some sort “decal” of your texture (meaning the shadow is texture itself, with color and everything).

    Thanks a lot for all your great tutorials.

  • onction

    hi guys
    I’m a new user in blender and I like these pictures made by blender.
    I need a help to use Yafaray . In fact I want to know how to export it and use it on blender 2.49
    thanks to give me more links ans instructions !!!

  • janaka

    dear sir
    i want to lern alpha map

  • AlphaPrimeSaviour

    Hi guys

    I’ve read this tutorial and I was wondering, if it is possible to create particles that use a plane with a texture on it as the bases. In other words, I’m busy making an emitter that will emit dust puffs. But I can’t get the dust puffs to render the alpha map when its being used as a particle for the emitter.

    Any suggestions?

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Blender 3D Architect Newsletter

Receive free assets, news, and resources for architecture

We respect your privacy and do not tolerate spam and will never sell, rent, lease or give away your information (name, address, email, etc.) to any third party. Nor will we send you unsolicited email.