* Other Application Recipes
{anchor: Application_Recipes}

|| 3D Application || Versions Known to Require Recipe || Platform \
	|| Recipe \
	|| Notes \
	||
| Abaqus | v6 | Linux \
	| It is necessary to add \
		{nl}{nl} \
		''import os''{nl} \
		''os.environ['ABAQUS_EMULATE_OVERLAYS'] = "1"'' \
		{nl}{nl} \
		to \
		{file: __abaqus-install-dir__/__abaqus-version__/site/abaqus_v6.env} \
		to make Abaqus v6 work properly with VirtualGL.  If this is not done, \
		then the application may fail to launch, it may fail to display any \
		OpenGL-rendered pixels, or those pixels may become corrupted whenever \
		other windows obscure them. \
	| VirtualGL does not support transparent overlays, since those cannot be \
		rendered in an off-screen buffer.  Setting ''ABAQUS_EMULATE_OVERLAYS'' to \
		''1'' causes the application to emulate overlay rendering instead of \
		using actual transparent overlays.  This workaround is known to be \
		necessary when running Abaqus 6.9 and 6.10. \
	|
| Abaqus | v6 | Linux \
	| {pcode: vglrun -nodl __abaqus-path__/abaqus} \
	| User reports indicate that Abaqus 6.9 will not work properly if \
		VirtualGL's ''dlopen()'' interposer ({file: libdlfaker.so}) is preloaded \
		into it.  This may be true for other versions of Abaqus as well. \
	|
| Cadence Allegro | v16.5 | Linux \
	| ''vglrun +sync allegro'' \
	| Allegro relies on mixed X11/OpenGL rendering, and thus certain features \
		(specifically the ''pcb_cursor_infinite'' cursor style) do not work \
		properly unless ''VGL_SYNC'' is enabled.  If ''VGL_SYNC'' is not enabled, \
		then the crosshairs may remain on the screen.  Since ''VGL_SYNC'' \
		automatically enables the X11 transport and disables frame spoiling, it \
		is highly recommended that you use an X proxy when ''VGL_SYNC'' is \
		enabled.  See {ref prefix="Section ": VGL_SYNC} for further information. \
	|
| Animator | v4 | Linux \
	| Comment out the line that reads \
		{nl}{nl} \
		''unsetenv LD_PRELOAD'' \
		{nl}{nl} \
		in the ''a4'' script, then launch Animator 4 using \
		{nl}{nl} \
		''vglrun -ge a4'' \
		{nl}{nl} \
	| When the ''a4'' script unsets ''LD_PRELOAD'', this prevents VirtualGL \
		from being loaded into the application.  Animator 4 additionally checks \
		the value of ''LD_PRELOAD'' and attempts to unset it from inside \
		the application.  Using ''vglrun -ge'' to launch the application fools \
		Animator 4 into thinking that ''LD_PRELOAD'' is unset. \
	|
| ANSA | v12.1.0 | Linux \
	| Add \
		{nl}{nl} \
		''LD_PRELOAD_SAVE=$LD_PRELOAD''{nl} \
		''export LD_PRELOAD='' \
		{nl}{nl} \
		to the top of the ''ansa.sh'' script, then add \
		{nl}{nl} \
		''export LD_PRELOAD=$LD_PRELOAD_SAVE'' \
		{nl}{nl} \
		just prior to the ''${ANSA_EXEC_DIR}bin/ansa_linux${ext2}'' line. \
	| The ANSA startup script directly invokes ''/lib/libc.so.6'' to query \
		the glibc version.  Since the VirtualGL faker libraries depend on libc, \
		preloading VirtualGL when directly invoking ''libc.so.6'' creates an \
		infinite loop.  Thus, it is necessary to disable the preloading of \
		VirtualGL in the application script and then re-enable it prior to \
		launching the actual application. \
	|
| AutoForm | v4.0x | All \
	| {pcode: vglrun +sync xaf\___version__} \
	| AutoForm relies on mixed X11/OpenGL rendering, and thus certain features \
		(particularly the "Dynamic Section" dialog and "Export Image" feature) do \
		not work properly unless ''VGL_SYNC'' is enabled.  Since ''VGL_SYNC'' \
		automatically enables the X11 transport and disables frame spoiling, it \
		is highly recommended that you use an X proxy when ''VGL_SYNC'' is \
		enabled.  See {ref prefix="Section ": VGL_SYNC} for further information. \
	|
| Cedega | v6.0.x | Linux \
	| Add \
		{nl}{nl} \
		''export LD_PRELOAD=libvglfaker.so'' \
		{nl}{nl} \
		to the top of {file: ~/.cedega/.winex_ver/winex-__version__/bin/winex3}, \
		then run Cedega as you would normally (without ''vglrun''.)  Since \
		''vglrun'' is not being used, it is necessary to use environment \
		variables or the VirtualGL Configuration dialog to modify VirtualGL's \
		configuration. \
	| The actual binary (WineX) that uses OpenGL is buried beneath several \
		layers of Python and shell scripts.  The ''LD_PRELOAD'' variable does not \
		get propagated down from the initial shell that invoked ''vglrun''. \
	|
| Google Chrome/Chromium | v85 through v128 | Linux \
	| ''vglrun google-chrome --in-process-gpu --use-gl=egl''{nl} \
		or{nl} \
		''vglrun chromium --in-process-gpu --use-gl=egl'' \
	| The ''--in-process-gpu'' option causes Chrome/Chromium to use a thread \
		rather than a separate process for 3D rendering, which prevents it from \
		complaining about the X11 function calls that the VirtualGL Faker makes. \
		The ''--use-gl=egl'' option forces Chrome/Chromium to use desktop OpenGL \
		rather than ANGLE, which works around the X visual selection issue \
		described below. \
	|
| Google Chrome/Chromium | v129 and later | Linux \
	| Set the ''VGL_CHROMEHACK'' environment variable to ''1'', then launch the \
		application with \
		{nl}{nl} \
		''vglrun google-chrome --in-process-gpu''{nl} \
		or{nl} \
		''vglrun chromium --in-process-gpu'' \
	| Chrome uses ANGLE, an OpenGL ES emulator that translates OpenGL ES \
		function calls into OpenGL, OpenGL ES, or Vulkan function calls.  When \
		using ANGLE's OpenGL back end, Chrome chooses an X visual by sending raw \
		GLX requests to the 2D X server, bypassing VirtualGL.  Thus, the X visual \
		it chooses has rendering attributes that are only relevant for the 2D X \
		server's OpenGL implementation.  Chrome then expects to find a GLX or EGL \
		framebuffer configuration to which the chosen X visual is assigned.  That \
		will normally never happen when using VirtualGL.  ''VGL_CHROMEHACK'' \
		works around this issue by emulating Chrome's X visual selection \
		mechanism and assigning the chosen visual to all GLX and EGL framebuffer \
		configurations that have an 8-bit alpha channel. \
		{nl}{nl} \
		When using nVidia's proprietary Vulkan driver, which does something \
		VirtualGL-like in an X proxy environment, or when using an X proxy that \
		implements the DRI3 X extension, you can also enable GPU acceleration by \
		passing ''--use-angle=vulkan'' to ''google-chrome'' or ''chromium''.  No \
		additional arguments or environment variables are necessary in this case, \
		nor is it necessary to launch the application with ''vglrun''. \
	|
| Compiz | All | Linux \
	| Set the ''VGL_WM'' environment variable to ''1'' prior to launching the \
		window manager with ''vglrun'', or pass an argument of ''+wm'' to \
		''vglrun''. \
	| See {ref prefix="Section ": VGL_WM} for further information. \
	|
| Mozilla Firefox | v93 and earlier | Linux \
	| Set the ''MOZ_DISABLE_CONTENT_SANDBOX'' environment variable to ''1'' \
		prior to launching the application with ''vglrun'' \
	| The content sandbox in Firefox v93 and earlier prevents VirtualGL from \
		opening an X display connection to the 3D X server, which causes WebGL \
		tabs to crash when using the GLX back end.  Some users have reported that \
		disabling the content sandbox is also necessary when using the EGL back \
		end with certain GPUs. \
	|
| ANSYS Fluent (when launched from ANSYS Workbench) | v16 and later | Linux \
	| Set the ''FLUENT_WB_OPTIONAL_ARGS'' environment variable to \
		''-driver opengl'' and the ''CORTEX_PRE'' environment variable to \
		''/opt/VirtualGL/bin/vglrun''. \
	| If these environment variables are not set, Fluent will use software \
		OpenGL when launched from ANSYS Workbench. \
	|
| Heretic II | All | Linux \
	| ''vglrun heretic2 +set vid_ref glx'' \
	| {:} \
	|
| ANSYS HFSS, ANSYS ICEM CFD, Roxar RMS | All | Linux \
	| Set the ''VGL_SPOILLAST'' environment variable to ''0'' prior to \
		launching the application with ''vglrun'' \
	| These applications draw node highlighting and/or rubber banding directly \
		to the front buffer.  In order for these front buffer operations to be \
		displayed properly, it is necessary to use the "spoil first" frame \
		spoiling algorithm whenever the application calls ''glFlush()''.  See \
		{ref prefix="Section ": VGL_SPOILLAST} for further information. \
	|
| Intel OpenCL ICD | All | Linux \
	| {pcode: vglrun -ld __path-to-Intel-OpenCL-libs__ __application__} \
	| The Intel OpenCL installable client driver (ICD) is linked with a \
		run-time library search path (rpath) of ''$ORIGIN'', which would normally \
		have the same effect as adding the directory in which the ICD is \
		installed (default: {file: /opt/intel/opencl/lib64} on 64-bit systems) to \
		''LD_LIBRARY_PATH''.  However, when VirtualGL is interposing the \
		''dlopen()'' function (which it does by default), this causes the actual \
		''dlopen()'' system calls to come from {file: libdlfaker.so}, so \
		''$ORIGIN'' will resolve to the directory in which the VirtualGL faker \
		libraries are installed.  This causes the ''dlopen()'' calls within the \
		Intel ICD to fail, and because the ICD apparently does not check the \
		return value of those calls, a segfault occurs.  The workaround is simply \
		to add the Intel ICD library path to ''LD_LIBRARY_PATH'', which is most \
		easily accomplished with ''vglrun -ld''. \
	|
| Mathematica | v7 | Linux \
	| Set the ''VGL_ALLOWINDIRECT'' environment variable to ''1'' prior to \
		launching the application with ''vglrun''.  Note that \
		''VGL_ALLOWINDIRECT'' requires the GLX back end. \
	| Mathematica 7 will not draw the axis numbers on 3D charts correctly \
		unless it is allowed to create an indirect OpenGL context.  See \
		{ref prefix="Section ": VGL_ALLOWINDIRECT} for further information. \
	|
| MATLAB | R2024b and earlier | Linux \
	| {pcode: vglrun /usr/local/MATLAB/__version__/bin/matlab \\}{nl} \
		''       -nosoftwareopengl'' \
	| MATLAB will automatically use its built-in (unaccelerated) OpenGL \
		implementation if it detects that it is running in a remote display \
		environment.  More specifically, it will always enable software OpenGL \
		if the X server has an X extension called ''VNC-EXTENSION'', which is \
		the case with TurboVNC, TigerVNC, and RealVNC. \
	|
| MATLAB | R2025a and later | Linux \
	| Set the ''VGL_CHROMEHACK'' environment variable to ''1'', then launch the \
		application with \
		{nl}{nl} \
		{pcode: vglrun /usr/local/MATLAB/__version__/bin/matlab \\}{nl} \
		''       -nosoftwareopengl'' \
	| MATLAB R2025a and later use the Chromium Embedded Framework (CEF), so \
		''VGL_CHROMEHACK'' is necessary to work around Chrome's X visual \
		selection mechanism.  (Refer to the application recipe for Chrome v129 \
		and later.) \
		{nl}{nl} \
		When using nVidia's proprietary Vulkan driver, which does something \
		VirtualGL-like in an X proxy environment, or when using an X proxy that \
		implements the DRI3 X extension, you can also enable GPU acceleration by \
		setting the ''MW_CEF_STARTUP_OPTIONS'' environment variable to \
		''--use-angle=vulkan'' prior to launching MATLAB.  No additional \
		arguments or environment variables are necessary in this case, nor is it \
		necessary to launch the application with ''vglrun''. \
	|
| PyTorch | All | Linux \
	| {pcode: vglrun -ld __path-to-PyTorch-libs__ __application__}{nl} \
		or{nl} \
		{pcode: vglrun -nodl __application__}{nl} \
	| The PyTorch module and its dependency libraries are linked with a \
		run-time library search path (rpath) of ''$ORIGIN'', which would normally \
		have the same effect as adding the directory in which the module is \
		installed (for instance, \
		{file: /usr/local/lib64/python3.9/site-packages/torch/lib}) to \
		''LD_LIBRARY_PATH''.  However, when VirtualGL is interposing the \
		''dlopen()'' function (which it does by default), this causes the actual \
		''dlopen()'' system calls to come from {file: libdlfaker.so}, so \
		''$ORIGIN'' will resolve to the directory in which the VirtualGL faker \
		libraries are installed.  This causes the ''dlopen()'' calls within the \
		PyTorch module to fail.  The workaround is to add the PyTorch module path \
		to ''LD_LIBRARY_PATH'', which is most easily accomplished with \
		''vglrun -ld'', or to disable VirtualGL's ''dlopen()'' interposer. \
		\
		{note: If you are using CUDA with PyTorch, then it may also be necessary \
		to add one or more of the CUDA module paths (for instance, \
		{file: /usr/local/lib64/python3.9/site-packages/nvidia/cudnn/lib}) to \
		''LD_LIBRARY_PATH''.} \
	|
| Siemens Simcenter STAR-CCM+ | v19.xx | Linux \
	| {pcode: vglrun __path-to-STAR-CCM+-scripts__/starccm+ \\}{nl} \
		''       -clientldpreload libdlfaker.so:libvglfaker.so'' \
	| Failing to pass the aforementioned arguments to the STAR-CCM+ startup \
		script prevents VirtualGL from being loaded into the application, \
		resulting in unaccelerated OpenGL and error messages such as "ERROR: in \
		isDisplayExcluded-- XX: Unexpected NULL condition" \
	|
| Tecplot 360 | 2011 and earlier | Linux \
	| Set the ''VGL_GLFLUSHTRIGGER'' environment variable to ''0'' prior to \
		launching the application with ''vglrun'' \
	| When running Tecplot 360 with VirtualGL in a high-performance X proxy, \
		flashing artifacts will be produced when the user zooms/pans/rotates the \
		scene, unless VirtualGL is instructed not to use ''glFlush()'' as a \
		frame trigger.  This has been fixed in Tecplot 2012 and later.  See \
		{ref prefix="Section ": VGL_GLFLUSHTRIGGER} for further information. \
	|
| Unity Hub / Unity Editor | v3.7.0 / v2021.X and later | Linux \
	| ''vglrun unityhub --use-gl=egl''{nl} \
	| The ''--use-gl=egl'' option forces Unity to use desktop OpenGL rather \
		than ANGLE, which works around an issue whereby, when using ANGLE, Unity \
		assumes that every X visual has an EGL framebuffer configuration \
		associated with it. \
	|
