Platform does not define a GLUT font retrieval function - Fedora 41 Wayland

48 views
Skip to first unread message

Colin Gauvin

unread,
Dec 12, 2024, 11:52:11 AM12/12/24
to EMAN2
I installed/built EMAN2 development version using conda and cmake, following the normal procedure. When I try to start any GUI program, I receive the error (below) basically saying getGLUTFontPointer cannot find a GLUT font retrieval function.

My laptop is running Fedora 41, using Wayland, and Nvidia 565.57.01.

I was able to workaround this problem by installing mesa-libOSMesa-devel and setting PYOPENGL_PLATFORM=osmesa in the command line.

I suspect I can set that variable either in my bashrc file, or directly in the conda env. But I wanted to report this here in case anyone else runs into it, so that they can fix it too.

Best,
Colin Gauvin
Structural Biologist
Superluminal Medicines

Details:

e2version.py output
EMAN 2.99.66 ( GITHUB: 2024-12-12 09:42 - commit: 643d2872c )
Your EMAN2 is running on: Linux-6.11.10-300.fc41.x86_64-x86_64-with-glibc2.40 6.11.10-300.fc41.x86_64
Your Python version is: 3.12.8

Exact command ran to produce failure:
e2display.py

Failure output:
Traceback (most recent call last):
 File "/home/colin/.micromamba/envs/eman2/bin/e2filtertool.py", line 44, in <m
odule>
   from eman2_gui.emimage2d import EMImage2DWidget
 File "/home/colin/.micromamba/envs/eman2/lib/python3.12/site-packages/eman2_g
ui/emimage2d.py", line 39, in <module>
   from OpenGL import GL,GLU,GLUT
 File "/home/colin/.micromamba/envs/eman2/lib/python3.12/site-packages/OpenGL/
GLUT/__init__.py", line 5, in <module>
   from OpenGL.GLUT.fonts import *
 File "/home/colin/.micromamba/envs/eman2/lib/python3.12/site-packages/OpenGL/
GLUT/fonts.py", line 20, in <module>
   p = platform.getGLUTFontPointer( name )
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 File "/home/colin/.micromamba/envs/eman2/lib/python3.12/site-packages/OpenGL/
platform/baseplatform.py", line 350, in getGLUTFontPointer
   raise NotImplementedError(  
   ^^^^^^^^^^^^^^^^^^^^^^^^^^
NotImplementedError: Platform does not define a GLUT font retrieval function


rezaul karim

unread,
Feb 23, 2025, 8:42:33 PMFeb 23
to EMAN2
thank you! I could not figure it out to solve the first GL_FRONT, GL_SHININESS and then GLUT font retrieval function issue with the latest installation. e2display was crashing. But this helped.
system: ubuntu 24.04 Nvidia RTX 3060Ti
I had to do > export PYOPENGL_PLATFORM=glxinfo
followed by rebuilding and installation. It is working great now.

Steve Ludtke

unread,
Feb 23, 2025, 10:00:29 PMFeb 23
to em...@googlegroups.com
Sorry, not sure why you didn't get any response to your original message. Must have slipped between the cracks. My assumption would be that the problem is coming from using Wayland/XWayland, which deals with OpenGL in some strange ways. As far as I've seen, despite being around for well over a decade, Wayland still doesn't work as well as X for most things you'd actually want to do.   Anyway, I'm happy you found a workaround that works, and that you posted it here where others can also find it!

-- 
-- 
----------------------------------------------------------------------------------------------
You received this message because you are subscribed to the Google
Groups "EMAN2" group.
To post to this group, send email to em...@googlegroups.com
To unsubscribe from this group, send email to eman2+un...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/eman2

--- 
You received this message because you are subscribed to the Google Groups "EMAN2" group.
To unsubscribe from this group and stop receiving emails from it, send an email to eman2+un...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/eman2/6f1a4d75-ace8-4a93-9233-660bef0765efn%40googlegroups.com.

Reply all
Reply to author
Forward
0 new messages