nV News Forums

 
 

nV News Forums (http://www.nvnews.net/vbulletin/index.php)
-   NVIDIA Linux (http://www.nvnews.net/vbulletin/forumdisplay.php?f=14)
-   -   290.x, 295.x depend on shader source after compilation (http://www.nvnews.net/vbulletin/showthread.php?t=171608)

snzzbk 01-05-12 10:51 AM

290.x, 295.x depend on shader source after compilation
 
1 Attachment(s)
Beginning with the 290.x series, changing the source string of a shader after compilation causes unpredictable behavior when the shader is applied. For example, setting the source to an empty string (or some other, non-GLSL string) often results in nothing being drawn, but sometimes results in other strange output. This seems to be in violation of the OpenGL 2.1 specification, section 2.15.1, which states, "Changing the source code of a shader object with ShaderSource does not change its compile status or the compiled shader code."

Presumably, this is the result of the driver automatically recompiling the shader for the sake of optimization. In that case, it would be better to use a copy of/reference to the source used at the time of user-initiated compilation rather than whatever the source string happens to be at the time of recompilation.

AaronP 01-09-12 11:58 AM

Re: 290.x, 295.x depend on shader source after compilation
 
Thanks for reporting this, snzzbk. Do you have a sample program that reproduces the problem?


All times are GMT -5. The time now is 04:44 PM.

Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.