# Changing hounsfield units after painting with a different range of masking

**URL:** <https://discourse.slicer.org/t/changing-hounsfield-units-after-painting-with-a-different-range-of-masking/11854>\
**Category:** Support\
**Tags:** dicom\
**Created:** [June 3, 2020, 9:30pm UTC](https://discourse.slicer.org/t/changing-hounsfield-units-after-painting-with-a-different-range-of-masking/11854 "2020-06-03T21:30:28Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mark\_Brahier](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/mark_brahier/32/5934_2.png) [@Mark\_Brahier](https://discourse.slicer.org/u/Mark_Brahier)\
**Post date:** [June 3, 2020, 9:30pm UTC](https://discourse.slicer.org/t/changing-hounsfield-units-after-painting-with-a-different-range-of-masking/11854/1 "2020-06-03T21:30:28Z")

</div>

Hello. I am using Slicer for contrast-enhanced cardiac CT analysis. After a substantial amount of work painting axial views to determine pericardial fat volume under a certain range of HU, I would like to reanalyze by saved files using a different range of HU. Is there a way to change HU for all previously painted slices? Thanks!

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [June 3, 2020, 9:56pm UTC](https://discourse.slicer.org/t/changing-hounsfield-units-after-painting-with-a-different-range-of-masking/11854/2 "2020-06-03T21:56:03Z")

</div>

Would you like to modify the input volume’s voxel values? Or, would you like to adjust the painted regions (e.g, remove regions that are in a certain value range)? Maybe you could explain it better by attaching a screenshot with your annotations.

---

<div class="post-metadata">

**Author:** ![Mark\_Brahier](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/mark_brahier/32/5934_2.png) [@Mark\_Brahier](https://discourse.slicer.org/u/Mark_Brahier)\
**Post date:** [June 3, 2020, 11:25pm UTC](https://discourse.slicer.org/t/changing-hounsfield-units-after-painting-with-a-different-range-of-masking/11854/3 "2020-06-03T23:25:24Z")

</div>

Hi Andras, thanks for your reply. I have included a photo below that I hope will help. I used the Paint feature Masked to -30 to -190 HU and encircled the left atrium for every axial view of the cardiac CT to arrive at a periatrial fat volume. Now, I would like to change the Masking to -50 to -200 HU for every axial slice without re-doing the manual encircling of the entire left atrium. In other words, I want to “re-analyze” the pericardial fat volume for a slightly different range of masking without manually re-doing the whole thing. Is there a way to change that masking range for painting that has already been done?

 ![Screen Shot 2020-06-03 at 7.21.08 PM](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/4/0/40e0a4abdf1e736463f49f05bacb225664d9fda8.jpeg)

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [June 4, 2020, 1:11am UTC](https://discourse.slicer.org/t/changing-hounsfield-units-after-painting-with-a-different-range-of-masking/11854/4 "2020-06-04T01:11:12Z")

</div>

If you just want to change the segmentation in the nerighborhood of the original segmentation with a different intensity range then set “Editable intensity range” to the new range, select “Margin” effect, and set up to how far the segmentation can be expanded in “Margin size”, and click Apply. You can then use “Smoothing” effect to even out the result (remove small speckles, fill small holes).

---

<div class="post-metadata">

**Author:** ![Mark\_Brahier](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/mark_brahier/32/5934_2.png) [@Mark\_Brahier](https://discourse.slicer.org/u/Mark_Brahier)\
**Post date:** [June 4, 2020, 12:01pm UTC](https://discourse.slicer.org/t/changing-hounsfield-units-after-painting-with-a-different-range-of-masking/11854/5 "2020-06-04T12:01:50Z")

</div>

Thank you. Just to make sure I understand what this is doing, does Margin extend all of the “edges” of every slice in the segmentation by the specified amount (i.e. 3mm)? And in doing so, it re-calculates both the original areas for each slice and the new area margins using the new range of HU that I have specified?

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [June 4, 2020, 3:21pm UTC](https://discourse.slicer.org/t/changing-hounsfield-units-after-painting-with-a-different-range-of-masking/11854/6 "2020-06-04T15:21:25Z")

</div>

Everything is done fully in 3D, nothing is limited to specific slices, but otherwise what you described is accurate.

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [June 10, 2020, 6:56pm UTC](https://discourse.slicer.org/t/changing-hounsfield-units-after-painting-with-a-different-range-of-masking/11854/7 "2020-06-10T18:56:15Z")

</div>

A post was split to a new topic: [Why growing segment by 10mm margin is different from growing by 5mm margin twice](https://discourse.slicer.org/t/why-growing-segment-by-10mm-margin-is-different-from-growing-by-5mm-margin-twice/11985)
