# GPU and CPU rendering on MacBookPro M2 ProMax

**URL:** <https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152>\
**Category:** Support\
**Tags:** bug\
**Created:** [April 26, 2023, 8:58pm UTC](https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152 "2023-04-26T20:58:47Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Adam\_Summers](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/adam_summers/32/65790_2.png) [@Adam\_Summers](https://discourse.slicer.org/u/Adam_Summers)\
**Post date:** [April 26, 2023, 8:58pm UTC](https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152/1 "2023-04-26T20:58:47Z")

</div>

I have the latest Apple MacBook with Apple silicon, 96GB of RAM running Ventura. I am using the most recent build of Slicer for Mac from 2023-4-25. My fairly large data sets are rendering well, though slowly, using the CPU, but when I swap to GPU the volume is a uniform prism of color. Here is an example data set of a clingfish.

> **[Clinger\_genC\_sp3#2\_6.0um\_2k female.nrrd](https://drive.google.com/file/d/1QuvrOBHKEmS8R2eTxm63hN5pN1qB7I5N/view?usp=sharing)**
>
> Google Drive file.

I expect the answer is that Apple silicon is just not working well with Slicer, but if someone has a workaround it would be great.

---

<div class="post-metadata">

**Author:** ![muratmaga](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/muratmaga/32/3622_2.png) [@muratmaga](https://discourse.slicer.org/u/muratmaga)\
**Post date:** [April 26, 2023, 9:07pm UTC](https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152/2 "2023-04-26T21:07:59Z")

</div>

@jcfr @pieper this the screenshot @Adam_Summers sent me earlier, if it helps…

CPU rendering  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/4/b/4b72636af7d9620a021352b4b78c35aa6506d3d7.png)

GPU rendering.  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/e/f/efde0c17e82c73debb3cb04374920ed98b564f72.png)

---

<div class="post-metadata">

**Author:** ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)\
**Post date:** [April 27, 2023, 2:43pm UTC](https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152/3 "2023-04-27T14:43:32Z")

</div>

Thanks for sharing the data. I could use GPU rendering on a mac pro, but on a mac book air m2 I got this error:

```auto
[VTK] Invalid texture dimensions [447, 318, 2308]

[FD] UNSUPPORTED (log once): POSSIBLE ISSUE: unit 1 GLD_TEXTURE_INDEX_3D is unloadable and bound to sampler type (Float) - using zero texture because texture unloadable

```

so it must be a hardware or driver limit, probably to 2048 max dimension

I used CropVolume with a 1.5x multiplier on the spacing and then GPU rendering worked on the m2 machine:

![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/b/9/b98c5caf030a045e663f25fe532aa24ddfe3cce7.jpeg)

---

<div class="post-metadata">

**Author:** ![Adam\_Summers](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/adam_summers/32/65790_2.png) [@Adam\_Summers](https://discourse.slicer.org/u/Adam_Summers)\
**Post date:** [April 27, 2023, 3:20pm UTC](https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152/4 "2023-04-27T15:20:20Z")

</div>

Dear Steve, thanks so much for identifying the issue. You have given me a path to a work around. I really appreciate it.

-Adam

---

<div class="post-metadata">

**Author:** ![muratmaga](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/muratmaga/32/3622_2.png) [@muratmaga](https://discourse.slicer.org/u/muratmaga)\
**Post date:** [April 27, 2023, 4:19pm UTC](https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152/5 "2023-04-27T16:19:52Z")

</div>

> [@pieper](#):
>
> so it must be a hardware or driver limit, probably to 2048 max dimension

This is an unfortunate limitation, particularly if this is true for the top of the line M2 macbook pro @Fishguy has. I don’t have this problem on my 2018 intel macbook pro.

Do you know if there is a way to report this to apple? I am concerned because a lot of biology folks use Slicer on Mac, and that’s a limitation we can’t do much.

---

<div class="post-metadata">

**Author:** ![Adam\_Summers](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/adam_summers/32/65790_2.png) [@Adam\_Summers](https://discourse.slicer.org/u/Adam_Summers)\
**Post date:** [April 27, 2023, 4:33pm UTC](https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152/6 "2023-04-27T16:33:46Z")

</div>

Just to follow up. Steve has found the issue. More than 2048 slices and the GPU won’t work. I have tested this with 5 data sets that were not working, and by cutting down the number of slices they work just fine. The InputStack module in SlicerMorph (which I think Steve wrote) has a ‘Skip Slices’ option that allows you to tune the total slices in the Z direction. That is a work around until Apple gets itself in order on this.

Thanks a lot.

Adam

---

<div class="post-metadata">

**Author:** ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)\
**Post date:** [April 27, 2023, 4:53pm UTC](https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152/7 "2023-04-27T16:53:14Z")

</div>

From what I can tell this is a hardware limit on Apple GPUs. This document says that all the apple GPUs, including the “Metal 3” in the M2 have a max size of 2048 in all dimensions. It’s hard to know if they will relax this in the future. For. now I’m afraid downsampling is the best option.

@Adam_Summers if skipping slices give you okay image quality then that’s a good workaround. Using CropVolume to downsample a larger volume will be less lossy, but more time consuming of course.

> **[Metal-Feature-Set-Tables.pdf](https://developer.apple.com/metal/Metal-Feature-Set-Tables.pdf)**
>
> 2.80 MB

 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/3/5/35a254d0583e36c1838ba1fe5a05e29c859e8529.png)

---

<div class="post-metadata">

**Author:** ![jcfr](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jcfr/32/17825_2.png) [@jcfr](https://discourse.slicer.org/u/jcfr)\
**Post date:** [May 20, 2025, 12:50am UTC](https://discourse.slicer.org/t/gpu-and-cpu-rendering-on-macbookpro-m2-promax/29152/8 "2025-05-20T00:50:26Z")

</div>

As a follow-up, this is being addressed by @lassoan through [PR-8430](https://github.com/Slicer/Slicer/pull/8430):

> On macOS graphics hardware, maximum 3D texture size (along any axis) is typically 2048. This commit sets volume partitioning partitioned to not exceed this size by default.
> 
> On other systems volume is maximum size is set to 4096 by default, which will not split up the volume in most cases (which was the behavior before this commit).
