# How to get a Semi transparent sphere in Makie?

**URL:** <https://discourse.julialang.org/t/how-to-get-a-semi-transparent-sphere-in-makie/117944>\
**Category:** Visualization\
**Created:** [August 8, 2024, 7:50am UTC](https://discourse.julialang.org/t/how-to-get-a-semi-transparent-sphere-in-makie/117944 "2024-08-08T07:50:16Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![p\_f](https://avatars.discourse-cdn.com/v4/letter/p/45deac/32.png) [@p\_f](https://discourse.julialang.org/u/p_f)\
**Post date:** [August 8, 2024, 9:33am UTC](https://discourse.julialang.org/t/how-to-get-a-semi-transparent-sphere-in-makie/117944/2 "2024-08-08T09:33:14Z")

</div>

You can pass `alpha = x` and `transparency = true` when you call `surface`:

```julia
fig, ax, plt = surface(sx,sy,sz,color = fill(:red, n, n),invert_normals=true,alpha=0.5,transparency=true)
meshscatter!(ax, sx[1:10:end], sy[1:10:end], sz[1:10:end], color = :blue)
fig

```

or just add `transparency=true` if you pass the alpha value to the colour:

```julia
fig, ax, plt = surface(
  sx,sy,sz,
  color = fill((:red,0.5), n, n),invert_normals=true,transparency=true)
meshscatter!(ax, sx[1:10:end], sy[1:10:end], sz[1:10:end], color = :blue)
fig

```

![image](https://global.discourse-cdn.com/julialang/original/3X/5/6/56516ad75a6779741727e1999d97487545c1e4d5.png)

---

_[View the full topic](https://discourse.julialang.org/t/how-to-get-a-semi-transparent-sphere-in-makie/117944)._
