Display.SimpleGui in WSL2
Opened this issue · 2 comments
Hey all,
I am trying to use Display.SimpleGui using a conda venv in WSL2.
Stacktrace looks like the following:
[INFO:OCC.Display.backend](07/01/2025 15:58:20): backend loaded: qt-pyqt5
3D rendering pipe initialisation
Display3d class initialization starting ...
Aspect_DisplayConnection created.
Graphic_Driver created.
V3d_Viewer created.
AIS_InteractiveContext created.
V3d_View created
Segmentation fault (core dumped)
At first I thought it was a WSL2 to windows display issue. After a lot of google searching, turns out the latest WSL2 distros natively support guis using wslg. See comments here: https://superuser.com/questions/1617298/wsl-2-running-ubuntu-x-server-cant-open-display
I also confirmed its not a wsl2 issue, as xcalc and firefox commands in wsl2 work.
Any insight into the segfault? thanks!
I have no idea, I do not work using windows or wsl
@alex-kramer-12 I am new to OCCT/pythonocc, but I regularly develop in a conda env in WSL2. I do not have this issue, but am happy to provide any help I can.
For reference my startup output looks like this:
####### 3D rendering pipe initialisation #####
Display3d class initialization starting ...
Aspect_DisplayConnection created.
OpenGl_GraphicDriver created.
V3d_Viewer created.
AIS_InteractiveContext created.
V3d_View created
Graphic3d_Camera created
Graphic3d_StructureManager created
Xw_Window created.
Display3d class successfully initialized.
#########################################
OpenGl information:
GLvendor: Microsoft Corporation
GLdevice: D3D12 (NVIDIA GeForce RTX 5070)
GLversion: 4.2 (Compatibility Profile) Mesa 23.2.1-1ubuntu3.1~22.04.3
GLSLversion: 4.20
Max texture size: 16384
Max FBO dump size: 16384x16384
Max combined texture units: 192
Max MSAA samples: 8
Viewport: 1024x768
Window buffer: RGB8 ALPHA8 DEPTH24 STENCIL8
ResolutionRatio: 1
FBO buffer: GL_SRGB8_ALPHA8 GL_DEPTH24_STENCIL8While this maybe isn't directly helpful, I can confirm it does work at least.