# Please either change the volumeMapper sampleDistance or its maximum number of samples.

**URL:** https://discourse.vtk.org/t/please-either-change-the-volumemapper-sampledistance-or-its-maximum-number-of-samples/14058
**Category:** vtk.js
**Created:** [June 15, 2024, 2:08pm UTC](https://discourse.vtk.org/t/please-either-change-the-volumemapper-sampledistance-or-its-maximum-number-of-samples/14058 "2024-06-15T14:08:06Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![aleaf2023](https://discourse.vtk.org/letter_avatar_proxy/v4/letter/a/c4cdca/32.png) [@aleaf2023](https://discourse.vtk.org/u/aleaf2023)
#### Post date: [June 15, 2024, 2:08pm UTC](https://discourse.vtk.org/t/please-either-change-the-volumemapper-sampledistance-or-its-maximum-number-of-samples/14058/1 "2024-06-15T14:08:06Z")

</div>

The number of steps required 1479 is larger than the  
specified maximum number of steps 1000.  
Please either change the  
volumeMapper sampleDistance or its maximum number of samples.

---

<div class="post-metadata">

### Author: ![finetjul](https://discourse.vtk.org/user_avatar/discourse.vtk.org/finetjul/32/154_2.png) [@finetjul](https://discourse.vtk.org/u/finetjul)
#### Post date: [June 17, 2024, 6:07am UTC](https://discourse.vtk.org/t/please-either-change-the-volumemapper-sampledistance-or-its-maximum-number-of-samples/14058/2 "2024-06-17T06:07:27Z")

</div>

Can you please create a PR ?

---

<div class="post-metadata">

### Author: ![aleaf2023](https://discourse.vtk.org/letter_avatar_proxy/v4/letter/a/c4cdca/32.png) [@aleaf2023](https://discourse.vtk.org/u/aleaf2023)
#### Post date: [June 17, 2024, 10:35am UTC](https://discourse.vtk.org/t/please-either-change-the-volumemapper-sampledistance-or-its-maximum-number-of-samples/14058/3 "2024-06-17T10:35:12Z")

</div>

Yes。  
Set the parameters “volumeMapper.setMaximumSamplesPerRay(4000)”。  
I have solved the problem. Thanks for your reply!
