# Call an specifica class frome c++ in python

**URL:** https://discourse.slicer.org/t/call-an-specifica-class-frome-c-in-python/13777
**Category:** Support
**Tags:** volume, labelmap
**Created:** [September 30, 2020, 4:25pm UTC](https://discourse.slicer.org/t/call-an-specifica-class-frome-c-in-python/13777 "2020-09-30T16:25:01Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![aldoSanchez](https://avatars.discourse-cdn.com/v4/letter/a/5f9b8f/32.png) [@aldoSanchez](https://discourse.slicer.org/u/aldoSanchez)
#### Post date: [September 30, 2020, 4:25pm UTC](https://discourse.slicer.org/t/call-an-specifica-class-frome-c-in-python/13777/1 "2020-09-30T16:25:02Z")

</div>

hello  
I’m trying to access to this action:  
vtkMRMLLabelMapVolumeDisplayNode::vtkMRMLLabelMapVolumeDisplayNode()  
{  
this-\>MapToColors = vtkImageMapToColors::New();  
this-\>MapToColors-\>SetOutputFormatToRGBA();

```
 // set a thicker default slice intersection thickness for use when showing
 // the outline of the label map
 this->SliceIntersectionThickness = 3;
}

```

what I want is to call this instruction in python: SliceIntersectionThickness = 3;

---

<div class="post-metadata">

### Author: ![Andinet\_Enquobahrie](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/andinet_enquobahrie/32/75_2.png) [@Andinet\_Enquobahrie](https://discourse.slicer.org/u/Andinet_Enquobahrie)
#### Post date: [September 30, 2020, 4:46pm UTC](https://discourse.slicer.org/t/call-an-specifica-class-frome-c-in-python/13777/2 "2020-09-30T16:46:20Z")

</div>

Hello @aldoSanchez

> [@aldoSanchez](#):
>
> hello  
> I’m trying to access to this action:  
> vtkMRMLLabelMapVolumeDisplayNode::vtkMRMLLabelMapVolumeDisplayNode()  
> {  
> this-\>MapToColors = vtkImageMapToColors::New();  
> this-\>MapToColors-\>SetOutputFormatToRGBA();
> 
> ```
> // set a thicker default slice intersection thickness for use when showing
> // the outline of the label map
> this->SliceIntersectionThickness = 3;
> }
> 
> ```
> 
> what I want is to call this instruction in python: SliceIntersectionThickness = 3;

You can do something like the following

```
  labelMapNode.GetDisplayNode().SetSliceIntersectionThickness(3)

```

-Andinet

---

<div class="post-metadata">

### Author: ![aldoSanchez](https://avatars.discourse-cdn.com/v4/letter/a/5f9b8f/32.png) [@aldoSanchez](https://discourse.slicer.org/u/aldoSanchez)
#### Post date: [September 30, 2020, 5:05pm UTC](https://discourse.slicer.org/t/call-an-specifica-class-frome-c-in-python/13777/3 "2020-09-30T17:05:41Z")

</div>

thanks, it works perfectly  
I leave the code here:

labelMapNode=getNode(‘nameOftheNode’)  
labelMapNode.GetDisplayNode().SetSliceIntersectionThickness(1)
