# RenderingGroupId on edges

**URL:** <https://forum.babylonjs.com/t/renderinggroupid-on-edges/13423>\
**Category:** Questions\
**Created:** [August 17, 2020, 11:16am UTC](https://forum.babylonjs.com/t/renderinggroupid-on-edges/13423 "2020-08-17T11:16:21Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Symlis](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/symlis/32/7350_2.png) [@Symlis](https://forum.babylonjs.com/u/Symlis)\
**Post date:** [August 17, 2020, 11:16am UTC](https://forum.babylonjs.com/t/renderinggroupid-on-edges/13423/1 "2020-08-17T11:16:21Z")

</div>

Hello everyone, I hope u all good!  
I’ve got a small question. I am using `mesh.enableEdgesRendering()` to enable edges for mesh.  
Is it possible or could be possible to change edges renderingGroupId separately from mesh renderingGroupId.

So e.q. in this playground. only edges could be visible through the sphere.

[https://www.babylonjs-playground.com/#TYAHX#137](https://www.babylonjs-playground.com/#TYAHX#137)

I was thinking about creating two the same boxes. One invisible with edges and the second one visible without edges (with renderingGroupId like the sphere or lower) so I’ll have the desired effect but I think maybe it could be done better 🙂

This is the effect I’m talking about: [https://www.babylonjs-playground.com/#TYAHX#139](https://www.babylonjs-playground.com/#TYAHX#139)  
I’m just wondering if it could be done without duplicating the mesh.  
 ![image](https://us1.discourse-cdn.com/flex024/uploads/babylonjs/original/2X/e/efc8433ebd8ea121d35808f4e2a6f802b6ea1354.png)

---

<div class="post-metadata">

**Author:** ![Evgeni\_Popov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/evgeni_popov/32/4432_2.png) [@Evgeni\_Popov](https://forum.babylonjs.com/u/Evgeni_Popov)\
**Post date:** [August 17, 2020, 1:00pm UTC](https://forum.babylonjs.com/t/renderinggroupid-on-edges/13423/2 "2020-08-17T13:00:01Z")

</div>

I’m afraid it’s not possible and won’t be because the edge renderer is really tied to the same rendering group than the mesh.

A solution other than duplicating the box would be to override the edge renderer `render` method to disable depth testing when rendering the edges of the cube:

[https://www.babylonjs-playground.com/#TYAHX#140](https://www.babylonjs-playground.com/#TYAHX#140)

---

<div class="post-metadata">

**Author:** ![Symlis](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/symlis/32/7350_2.png) [@Symlis](https://forum.babylonjs.com/u/Symlis)\
**Post date:** [August 18, 2020, 9:38am UTC](https://forum.babylonjs.com/t/renderinggroupid-on-edges/13423/3 "2020-08-18T09:38:25Z")

</div>

It works great thank you. I had some problems with implementing this in angular (typescript). It occurs that adding @ts-ignore solved my problem

```auto
// @ts-ignore
EdgesRenderer.prototype._render = EdgesRenderer.prototype.render;

```
