Viewport becomes black when assigning materials

Hi @jessesn

The Custom Material Preview component in Grasshopper is causing my viewport to turn black. However, this is actually a problem I’ve already reported before.
Starting from a certain Rhino version, the same issue appears even outside Grasshopper: when I switch to Rendered display mode and try to assign a material to an object, the viewport suddenly becomes completely black.
It seems that this viewport rendering issue is also affecting Grasshopper’s Custom Material Preview component. The behavior is very similar, so I suspect both problems may be related to the same graphics or display pipeline issue.
If I remove the Custom Material Preview component, your ShapeMap script works correctly.


Here, when I assign a material, the viewport turns completely black in Rhino WIP.


While in Rhino 8, this does not happen.


Rhino 9 SR0 2026-6-2 (Rhino WIP, 9.0.26153.12415, Git hash:master @ 6e68e5bb66050c38dc698d4e273cb8b18eff6123)
License type: Commercial, build 2026-06-02
License details: Cloud Zoo
Expires on: 2026-07-17

Windows 10 (10.0.19045 SR0.0) or greater (Physical RAM: 32GB)
.NET 10.0.2

Computer platform: DESKTOP

Standard graphics configuration using DirectX
Primary display: NVIDIA GeForce GTX 1050 Ti (NVidia) Memory: 4GB, Driver date: 1-20-2026 (M-D-Y). DirectX(11)
> Accelerated graphics device with 4 adapter port(s)
- There are no monitors attached to this device!

Secondary graphics devices.
Intel(R) HD Graphics 630 (Intel) Memory: 1GB, Driver date: 11-13-2019 (M-D-Y).
> Integrated graphics device with 3 adapter port(s)
- Windows Main Display attached to adapter port 0

DirectX Settings
Safe mode: Off

OpenBLAS: OpenBLAS 0.3.30 DYNAMIC_ARCH NO_AFFINITY Haswell MAX_THREADS=64.

Rhino plugins that do not ship with Rhino

Rhino plugins that ship with Rhino
C:\Program Files\Rhino 9 WIP\Plug-ins\Commands.rhp “Commands” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\rdk.rhp “Renderer Development Kit”
C:\Program Files\Rhino 9 WIP\Plug-ins\UpdatesAndStatistics\UpdatesAndStatistics.rhp “UpdatesAndStatistics” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\RhinoRenderCycles.rhp “Rhino Render” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\rdk_etoui.rhp “RDK_EtoUI” 9.0.26153.12415
C:\Users\Daniil.PC-DANIIL\AppData\Roaming\McNeel\Rhinoceros\packages\9.0\PanelingTools\2024.8.20.677\PanelingTools.rhp “PanelingTools”
C:\Program Files\Rhino 9 WIP\Plug-ins\NamedSnapshots.rhp “Snapshots”
C:\Program Files\Rhino 9 WIP\Plug-ins\MeshCommands.rhp “MeshCommands” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\IronPython\RhinoDLR_Python.rhp “IronPython” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\RhinoCycles.rhp “RhinoCycles” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\Grasshopper\GrasshopperPlugin.rhp “Grasshopper” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\Displacement.rhp “Displacement”
C:\Program Files\Rhino 9 WIP\Plug-ins\SectionTools.rhp “SectionTools”

The system says that no monitor is connected to this device, but that’s not true.

Thanks for your feedback. Please try connecting your monitor to GTX 1050 Ti port. It looks to be connected to the intergrated card port.

Please try to adjust the setting at Options > View > GPU to OpenGL, and then try it again. Thank you.

Okay, I ran a test with this type of cable. I replaced my HDMI cable with this 4K cable from another PC in the office, and the problem is now resolved.



Rhino 9 SR0 2026-6-2 (Rhino WIP, 9.0.26153.12415, Git hash:master @ 6e68e5bb66050c38dc698d4e273cb8b18eff6123)
License type: Commercial, build 2026-06-02
License details: Cloud Zoo
Expires on: 2026-07-17

Windows 10 (10.0.19045 SR0.0) or greater (Physical RAM: 32GB)
.NET 10.0.2

Computer platform: DESKTOP

Standard graphics configuration using DirectX
Primary display: NVIDIA GeForce GTX 1050 Ti (NVidia) Memory: 4GB, Driver date: 1-20-2026 (M-D-Y). DirectX(11)
> Accelerated graphics device with 4 adapter port(s)
- There are no monitors attached to this device!

Secondary graphics devices.
Intel(R) HD Graphics 630 (Intel) Memory: 1GB, Driver date: 11-13-2019 (M-D-Y).
> Integrated graphics device with 3 adapter port(s)
- Windows Main Display attached to adapter port #0

DirectX Settings
Safe mode: Off

OpenBLAS: OpenBLAS 0.3.30 DYNAMIC_ARCH NO_AFFINITY Haswell MAX_THREADS=64.

Rhino plugins that do not ship with Rhino

Rhino plugins that ship with Rhino
C:\Program Files\Rhino 9 WIP\Plug-ins\Commands.rhp “Commands” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\rdk.rhp “Renderer Development Kit”
C:\Program Files\Rhino 9 WIP\Plug-ins\UpdatesAndStatistics\UpdatesAndStatistics.rhp “UpdatesAndStatistics” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\RhinoRenderCycles.rhp “Rhino Render” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\rdk_etoui.rhp “RDK_EtoUI” 9.0.26153.12415
C:\Users\Daniil.PC-DANIIL\AppData\Roaming\McNeel\Rhinoceros\packages\9.0\PanelingTools\2024.8.20.677\PanelingTools.rhp “PanelingTools”
C:\Program Files\Rhino 9 WIP\Plug-ins\NamedSnapshots.rhp “Snapshots”
C:\Program Files\Rhino 9 WIP\Plug-ins\MeshCommands.rhp “MeshCommands” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\IronPython\RhinoDLR_Python.rhp “IronPython” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\RhinoCycles.rhp “RhinoCycles” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\Grasshopper\GrasshopperPlugin.rhp “Grasshopper” 9.0.26153.12415
C:\Program Files\Rhino 9 WIP\Plug-ins\Displacement.rhp “Displacement”
C:\Program Files\Rhino 9 WIP\Plug-ins\SectionTools.rhp “SectionTools”