An OpenGL API-based application running on a VMware Linux or Windows guest generates errors, renders incorrectly, or crashes
search cancel

An OpenGL API-based application running on a VMware Linux or Windows guest generates errors, renders incorrectly, or crashes

book

Article ID: 332374

calendar_today

Updated On:

Products

VMware Desktop Hypervisor

Issue/Introduction

Symptoms:
An OpenGL 3.x compatible application does not function as expected on a VMware Linux or Windows guest operating system. The application generates errors, renders improperly, or crashes.


Environment

VMware Fusion 8.x
VMware Fusion Pro 8.x
VMware Fusion 10.x
VMware Workstation Pro 14.x (for Linux)
VMware Workstation Pro 12.x (Windows)
VMware Workstation Pro 12.x (Linux)
VMware Workstation Pro 14.x (for Windows)

Cause

This issue occurs when an OpenGL 3.x compatible application functions as if the compatibility profile is supported even though the profile is not supported.
The following background information is useful for understanding the issue:
The VMware guest operating system OpenGL driver for Windows and Linux supports the OpenGL 3.3 core profile. Understanding the difference between the OpenGL core profile and the compatibility profile is important.

Profiles were introduced in OpenGL 3.1 and are used to describe categories of features. The OpenGL core profile consists of only modern OpenGL features, such as shaders, instanced drawing, and transform feedback, while the compatibility profile also supports legacy OpenGL features, such as display lists and glBegin and glEnd style drawing commands in conjunction with the new features.

Targeting the core profile is the preferred behavior of modern OpenGL applications because the core profile is more concise and is likely to perform better.

OpenGL-based applications are expected to query the level of OpenGL support provided by the system and act accordingly. For example, if a specific OpenGL version or profile is not supported, the application should fall back to an older version of OpenGL or report the issue to the user and simply not run.
However, some OpenGL-based applications are not written properly and act unpredictably if an OpenGL 3.x compatibility profile cannot be used. In this case, some applications generate errors, render incorrectly, or crash.

Resolution

A potential workaround is to disable OpenGL 3.x support in the virtual machine by setting the SVGA_VGPU10 environment variable to 0.
This setting causes the OpenGL driver to report support for OpenGL 2.1 only. Many OpenGL-based applications provide support for OpenGL 2.1 when a newer version is not available.

When an OpenGL 3.x compatible application fails as described, ideally the software developer updates the application so the application checks and selects the appropriate OpenGL version and profile.