# Mesh3d facecolor

**URL:** <https://discourse.julialang.org/t/mesh3d-facecolor/118294>\
**Category:** Visualization\
**Tags:** plotting, plots, makie, meshes\
**Created:** [August 16, 2024, 9:12pm UTC](https://discourse.julialang.org/t/mesh3d-facecolor/118294 "2024-08-16T21:12:30Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![berjine](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/berjine/32/51764_2.png) [@berjine](https://discourse.julialang.org/u/berjine)\
**Post date:** [August 17, 2024, 12:13pm UTC](https://discourse.julialang.org/t/mesh3d-facecolor/118294/3 "2024-08-17T12:13:56Z")

</div>

Sorry if that does not really answer you question but you can do this in Makie :

> [@Makie: Triangle face colour, mesh](https://discourse.julialang.org/t/makie-triangle-face-colour-mesh/18011/2):
>
> You can obtain flat coloured patches by a naive duplication of nodes to ensure that every triangle has different (eventually duplicated) vertices.

```julia
points = [0.0 0.0 0.0; 
          1.0 0.0 0.0; 
          2.0 1.0 0.0; 
          2.0 1.0 0.0;
          0.0 2.0 0.0;
          0.0 0.0 0.0];
faces = [1 2 3;
         4 5 6];
colors = [:red, :red, :red, :blue, :blue, :blue]
# colors = [0.2, 0.2, 0.2, 0.8, 0.8, 0.8] #for use with a colormap
f = Figure()
ax = Axis3(f[1,1], aspect=:data)
mesh!(ax, points, faces, color=colors)
# mesh!(ax, points, faces, color=colors, colormap=:plasma, colorrange=(0.0, 1.0))
f

```

 ![SharedScreenshot](https://global.discourse-cdn.com/julialang/original/3X/5/4/54e178527aee5c9986d80e5e27798e1fcb89f6fa.jpeg)

---

_[View the full topic](https://discourse.julialang.org/t/mesh3d-facecolor/118294)._
