0
$\begingroup$

basically I'm trying to make a plane with a solid colored center and I want it fades out to the edges of the plane (as the image below) on cycles.

Squared plane with faded out edges

Thanks in advance. Regards, Gonzalo

$\endgroup$
1
$\begingroup$

To Blur the Edges you could put a masking Texture (BW) into the fac of a mix node that mixes your prefered shader with an transparent shader.

I did it with a generated radial texture, but you could do it also with a premade texture, from your image editing software.
If you want a blur-node in blender look at Bashis work: https://www.blendswap.com/user/bashi

my Node-Tree: enter image description here

Edit1:
for simple shapes like rect and circle it would be possible via ramp and mapping for complex shapes you could do it possibly via python but its not simple!

So i think the best way for you is to do it with external software like photoshop. I prepared a workflow that creates the map from your shape so you dont have to approximate via drawing:

  1. Render with orthogonal camera topdown, your shape with emission shader and black as color. Worldbackground transparent, so the edge filter from step 3 will work.
  2. unwrap your Mesh-shape from within the orthogonal camera with the option "Project from View" (not with bounds).
  3. Put the rendered image from step one into your image processing software like photoshop and apply an edge-filter like "inner glow" with white as glow color and play with the settings as you wish and add white Background
  4. Import image from step 3 to Blender as fac in Mixshader from my original post and use "UV" in TextureCoordinate node. Because of step 2 your image aligns perfectly.
| improve this answer | |
$\endgroup$
  • $\begingroup$ Yes, I achieved it but I was looking a fade out based on edges (to respect the original form) rather than in a circular way. So the only way is using masks generated externally? $\endgroup$ – GonZ Feb 10 '19 at 11:37
0
$\begingroup$

The most easy way is to activate the build-in add-on "Import images as planes". After that, select File > Import > Images As Planes. This will create a simple plane with all needed material settings, and most important correct alpha nodes.

| improve this answer | |
$\endgroup$
  • $\begingroup$ So, that's mean that image which I'm importing should already fades out, right? I mean, the fade out is not being made by Blender, do not? $\endgroup$ – GonZ Feb 10 '19 at 11:35
  • $\begingroup$ If you use an image like this one the alpha channel (and the alpha fading) is in the image, and blender just displays it. $\endgroup$ – Grimm Feb 10 '19 at 11:49
  • 1
    $\begingroup$ So, and I'm sorry If I'm asking too much, inside blender there is no way to create from the scratch a texture and then make the fade out (edge-based), I should do externally and then import it, does not? $\endgroup$ – GonZ Feb 10 '19 at 12:02
  • $\begingroup$ Sure it's possible – see the other answer. He uses a Color Ramp as factor for a Mix Shader, which mixes green with transparency. You could even use an image texture and mix it with this transparency-mix-shader. May be this is what you want? $\endgroup$ – Grimm Feb 10 '19 at 20:24
  • $\begingroup$ Yes! Sorry for my late answer. For simple shapes that works fine. Finally, I achieved also with complex shapes but using composition layers with erode/dilate node (used to create the mask). Thanks for all! $\endgroup$ – GonZ Feb 22 '19 at 11:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.