
Last Updated:
08
/
13
/
2008
NVemulate
NVemulate allows you to emulate the functionality of various GPUs (very
slowly) in software. In addition, you can use it to control GLSL
Support and Open GL 3.0 Support.
New in this version of NVemulate:
- Support for OpenGL 3.0 and GLSL 1.30
[Download]
NVemulate (.exe) Built: Aug 11 2008
Controlling OpenGL 3.0 and GLSL 1.30 Support
By default, the NVIDIA drivers support OpenGL 2.1 and GLSL version 1.20. To
enable developers to start coding to OpenGL 3.0, beta support for the
OpenGL 3.0 and GLSL 1.30 feature set can be enabled with nvemulate. NVIDIA
does not recommend releasing an OpenGL 3.0 application based on a beta
driver.
To enable the OpenGL 3.0 and GLSL 1.30 featuers, select the “Enable OpenGL
3.0 / GLSL 1.3 APIs" checkbox and press the "Apply" button. No changes to
NVemulate settings take effect until the “Apply” button is pressed.
Pressing the “Restore” button reverts the display settings to the driver’s
current applied state.
The OpenGL 3.0 and GLSL 1.30 feature set is only available on G80 and later
hardware. This means the following GPUs:
Desktop: GeForce 8000 series or higher; GeForce GTX 260, 280;
Quadro FX 370, 570, 1700, 3700, 4600, 4700x2, 5600
Notebook: GeForce 8000 series or higher;
Quadro FX 360M, 370M, 570M, 770M, 1600M, 1700M, 2700M, 3600M, 3700M
With the OpenGL 3.0 / GLSL 1.30 feature set enabled, the driver will export
the WGL_ARB_create_context WGL extension string. However, the GL_VERSION
string will still show OpenGL 2.1 support. Only when you use the new
wglCreateContextAttribsARB() entrypoint to create an OpenGL 3.0 context,
then query the version string it will return "OpenGL 3.0".
If you do not see the WGL_ARB_create_context extension advertised, make sure of the following:
- You are using a Release 177 driver, version
177.89 or later.
- Check this by going to the NVIDIA Control Panel, selecting "Help", then
"System Information". In the "Details" panel, the "Driver Version"
should be 177.89 or better.
- You can also check this by making sure the version string returned by
glGetString(GL_VERSION) is 3.0.0 or better.
- You are using a Quadro or GeForce card based on G80 or later.
- If you installed a new NVIDIA graphics driver, all nvemulate settings
are reset to their defaults (no OpenGL 3.0 / GLSL 1.30 support) so you
must enable that again with NVemulate.
Controlling GLSL Support with NVemulate
[Download]
Release Notes for NVIDIA OpenGL Shading Language Support (.pdf). Oct 27
2006
GLSL support, including the enhanced G80 GLSL support, is enabled by default
in Release 95 drivers, starting at driver 96.02. You can enable/disable
the enhanced GLSL support as well as manipulate software emulation of GPU
feature sets and control the dumping of GLSL source and assembly text for
debugging, The NVemulate control panel looks like this:
To enable the enhanced GLSL functionality, select the “G80(GeForce 8800
GTS, Quadro FX)” option from the GLSL compiler device support drop box and
press the “Apply” button. No changes to NVemulate settings take
effect until the “Apply” button is pressed. Pressing the “Restore”
button reverts the display settings to the driver’s current applied
state.
With the G80 functionality enabled, the driver will export an additional set
of extension strings exposing the enhanced capabilities. The extensions
string will now include GL_EXT_gpu_shader4, GL_EXT_geometry_shader4, and
GL_EXT_bindable_uniform. Additionally, the GLSL parts of the
GL_NV_transform_feedback extension are now also enabled. Furthermore, all
GLSL shaders not using these capabilities will now be compiled to the more
capable G80 target. This enables better dynamic flow control and array
indexing, among other benefits.
As noted earlier, some graphics cards are not capable of GLSL or enhanced
GLSL in hardware, so this may require enabling a higher hardware emulation
level. (A minimum of NV30 for GLSL and a minimum of G80 for the
enhancements)
NVemulate Troubleshooting
If you do not see the enhanced extensions advertised, make sure of the following:
- You are using a Release 95 driver, preferably version 97.02 or later.
- Check this by going to the NVIDIA Control Panel, selecting "Help", then
"System Information". In the "Details" panel, the "ForceWare version"
should be 97.02 or better.
- You can also check this by making sure the version string returned by
glGetString(GL_VERSION) is 2.1.0 or better.
- You are using a Quadro or GeForce card
- You are using a Quadro or GeForce graphics card (preferably an FX
card).
If you installed a new NVIDIA graphics driver, the GLSL-related settings are
reset to their defaults (GLSL support disabled) so you must enable GLSL
again with NVemulate.
NVemulate Options to Aid Debugging
Other check boxes in the NVemulate control panel are designed to aid
debugging of GLSL programs as well as help developers report GLSL issues so
they can be readily addressed in future drivers.
Writing Program Object Assembly
When the “Write Program Object Assembly” box is checked, the driver outputs
fasm_%d_%d.txt and vasm_%d_%d.txt files into the application's working
directory when fragment and vertex shaders respectively are linked where
the first %d represents the application’s handle number for the linked
program object, and the second %d is a unique integer representing this
link instance. These files are in a form similar to what the standalone Cg
compiler (cgc.exe) outputs. The assembly text conforms to one of the vertex
or fragment program extensions depending on the shader type and hardware
capabilities. For G80 targeted shaders, the output will be in the
NV_gpu_program4 family of languages.
Before you submit a GLSL bug report to NVIDIA, double check that the
assembly generated for your successfully linked program object matches what
you expect. Sometimes you may find bugs in your own shader source code by
seeing how the driver’s Cg compiler technology translated your shader into
assembly form. If the assembly seems correct or it clearly does not
correspond to your high-level shader source, please include the assembly
output with your bug report.
Writing Program Object Source
When the “Write Program Object Source” box is checked, the driver outputs
fsrc_%d_%d_%d.txt and vsrc_%d_%d_%d.txt files into the application's
working directory when fragment and vertex shaders respectively are linked
where the first %d represents the application’s handle number for the
linked program object, the second %d is the shader object handle, and the
third %d is a unique integer representing this link instance. These files
contain the concatenation of all your shader object source text. This is
the actual GLSL source text that is compiled and linked.
These files are generated whether or not the program object links
successfully.
Check that your source code text has been properly transferred to the
driver. If you still suspect an OpenGL driver bug, please send the
source and assembly files.
Writing Info Log
When the “Write Info Log” box is checked, the driver outputs ilog_%d.txt
files when a program object is linked where the %d represents the handle
number for application’s program object being linked. The info log for a
program object contains both vertex and fragment shader related errors so a
single ilog_%d_%d.txt file is generated per program object and link
instance.
If this file is empty (zero length), that typically means no errors were
generated and the program object linked successfully.
Check your source code and fix any errors reported in the info log that
reflect errors or warnings in your shader source code. If you still cannot
resolve the messages in the info log, please send the info log, source, and
assembly files.
Forcing Software Rasterization
Driver bugs in GLSL programs may be due to the compiler translating your
shader incorrectly into a GPU executable form or the problem may be a more
basic driver bug. One way to get a “second opinion” about the behavior of
your application is to force software rasterization. In this mode, all
OpenGL rendering is done with the CPU rather than the GPU. This is
extremely slow, particularly when per-fragment programmability is involved.
However, if the results of hardware rendering and the software rasterizer
do not match, that is an important clue as to the nature of a possible
driver bug.
Additionally, if the hardware rendering and the software rasterizer results
match, you may want to review once more whether the problem lies with your
shader source before reporting a bug.
Strict Shader Portability Warnings
In the past, NVIDIA has provided extensions to GLSL to make the language
more compatible with other high-level shading languages. While this can be
convenient, it also can cause portability problems. To aid developers in
writing portable code, NVIDIA now flags the usage of these capabilities
with warnings by default. This behavior can be strengthened by checking the
“Generate Shader Portability Errors” checkbox in NVemulate. Additionally,
with version 1.20, the GLSL spec has adopted many of these language
extensions. As a result, NVIDIA has further tightened the syntax checking
on the compiler if “#version 120” or “#version 110” are specified in the
shader, such that the use of language extensions not included in version
1.20 will be flagged as an error.
Older Archives
[Download]
NVemulate (.exe) Built: Jan 05 2007
[Download] NVemulate (.exe) Built: Feb 17 2005
[Download] Release Notes for NVIDIA OpenGL Shading Language Support (.pdf) [203 KB] August 30 2004