# Plotting a transparent planes/boxes with Makie

**URL:** <https://discourse.julialang.org/t/plotting-a-transparent-planes-boxes-with-makie/21875>\
**Category:** Visualization\
**Tags:** plotting\
**Created:** [March 14, 2019, 4:16pm UTC](https://discourse.julialang.org/t/plotting-a-transparent-planes-boxes-with-makie/21875 "2019-03-14T16:16:59Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cserteGT3](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/csertegt3/32/8283_2.png) [@cserteGT3](https://discourse.julialang.org/u/cserteGT3)\
**Post date:** [March 14, 2019, 4:16pm UTC](https://discourse.julialang.org/t/plotting-a-transparent-planes-boxes-with-makie/21875/1 "2019-03-14T16:16:59Z")

</div>

I’m looking for a way to plot simple planes with Makie.  
The only solution I found so far is this:

```julia
using Makie

p1 = Point3(0.0, 0.0, 0.0)
p2 = Point3(0.0, 1.0, 0.0)
p3 = Point3(0.0, 1.0, 1.0)
p4 = Point3(0.0, 0.0, 1.0)

sc = mesh([p1, p2, p3], color = :blue, shading = false)
mesh!(sc, [p1, p4, p3], color = :blue, shading = false)

```

Which gives me:

 ![plot](https://global.discourse-cdn.com/julialang/original/3X/c/b/cbd608415fa5f58e7baa76f86780190f2a14c666.png)

I would be happy with this result, but I cannot change it’s transparency (the `alpha` keyword doesn’t have any effect). The result I’d like to achieve is something like the picture at the bottom of the [RegionTrees](https://github.com/rdeits/RegionTrees.jl#gallery) package’s page: a couple of transparent planes (or boxes).

As my final goal would be to visualize [octrees](https://en.wikipedia.org/wiki/Octree), another idea came in mind, while writing this post:

```julia
using Makie
using GeometryTypes: HyperRectangle

hr = HyperRectangle(Vec3f0(0), Vec3f0(1))
mesh(hr)

```

The problem with this is also the lack of transparency. Is this a bug in Makie? Or should I plot planes/cubes with other functions?

---

<div class="post-metadata">

**Author:** ![sdanisch](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sdanisch/32/1406_2.png) [@sdanisch](https://discourse.julialang.org/u/sdanisch)\
**Post date:** [March 14, 2019, 4:22pm UTC](https://discourse.julialang.org/t/plotting-a-transparent-planes-boxes-with-makie/21875/2 "2019-03-14T16:22:18Z")

</div>

The bug is, that the alpha keyword isn’t implemented yet 😃  
But you can use `plot(..., color = (:blue, 0.1), transparency = true)`, or any other transparent Colors.Colorant

---

<div class="post-metadata">

**Author:** ![cserteGT3](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/csertegt3/32/8283_2.png) [@cserteGT3](https://discourse.julialang.org/u/cserteGT3)\
**Post date:** [March 14, 2019, 4:37pm UTC](https://discourse.julialang.org/t/plotting-a-transparent-planes-boxes-with-makie/21875/3 "2019-03-14T16:37:59Z")

</div>

> [@sdanisch](#):
>
> The bug is, that the alpha keyword isn’t implemented yet 😃

Ohh, I didn’t expected that 😃. Thanks for the workaround!
