Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
GL3 Shader Error (could not load gl3 shader)
08-23-2012, 09:49 AM,
GL3 Shader Error (could not load gl3 shader)
Hi everyone!

i get an GL3 Shader Error (see log below) when i start vdrift, so it switches to GL2 for rendering. Is there a way to fix this, so i can use GL3 instead of GL2?
Another problem is that vdrift uses the CPU instead of GPU to render the scene, although it recognises my graphics card.

i have a nvidia quadro 2000 and using driver version 297.03. Vdrift (development version) is running on a windows 7 x64 operating system.

Here's the log:

INFO: Starting VDrift: development-full, Revision: latest, O/S: Windows
INFO: Home directory: C:\Users\student
INFO: Settings file: C:\Users\student\Documents\VDrift/VDrift.config
INFO: Data directory: data
INFO: Temporary directory: C:\Users\student\Documents\VDrift/tmp
INFO: Log file: C:\Users\student\Documents\VDrift/log.txt
INFO: Disabling antialiasing
INFO: Video card information:
      GL Vendor: NVIDIA Corporation
      GL Renderer: Quadro 2000/PCIe/SSE2
      GL Version: 4.2.0
      Texture units: 4 full, 32 partial
      Maximum texture size: 16384
      Maximum varying floats: 124
INFO: Initialized GLEW 1.7.0
INFO: Loading data/shaders/gl3/vdrift1.rhr...
INFO: Loaded data/shaders/gl3/vdrift1.rhr
ERROR: Unable to compile shader deferredaa.frag from file data/shaders/gl3/deferredaa.frag:
       0(903) : error C7532: global function textureGather requires "#version 400" or later
       0(903) : error C0000: ... or #extension GL_ARB_gpu_shader5 : enable
       0(904) : error C7532: global function textureGatherOffset requires "#version 400" or later
       0(904) : error C0000: ... or #extension GL_ARB_gpu_shader5 : enable
ERROR: Initialization of GL3 renderer failed; that's OK, falling back to GL 1 or 2
INFO: Using GLEW 1.7.0
INFO: Maximum color attachments: 8
INFO: Maximum draw buffers (1 required): 8
INFO: Loaded shader package simple
INFO: Loaded shader package simple, variant simple_premult
INFO: Loaded shader package simple, variant simple_gamma_premult
INFO: Loaded shader package simple, variant simple_gamma
INFO: Loaded shader package simple, variant simplecar
INFO: Loaded shader package tonemap
INFO: Loaded shader package gbufferfill
INFO: Loaded shader package gbufferfill, variant gbufferfillcar
INFO: Loaded shader package lightaccumulate, variant lightaccumulate_initial
INFO: Loaded shader package lightaccumulate, variant lightaccumulate_omni
INFO: Loaded shader package depthgen
INFO: Loaded shader package depthgen, variant depthgennoalpha
INFO: Loaded shader package distancefield
INFO: Loaded shader package deferredskybox
INFO: Loaded shader package deferredskyboxblend
INFO: Loaded shader package softparticle
INFO: Loaded shader package ppdepthadjust
INFO: Loaded shader package ppdepthadjust, variant ppcopy
INFO: Loaded shader package ppdepthadjust, variant ppcopy_gamma
INFO: Loaded shader package deferredshadows
INFO: Loaded shader package ssao
INFO: Loaded shader package ssao_blur
INFO: Loaded shader package deferredaa
INFO: Successfully enabled shaders
INFO: Initialized render output: full_scene_depth (FBO)
INFO: Initialized render output: full_scene_color (FBO)
INFO: Initialized render output: full_scene_tonemapped (FBO)
INFO: Initialized render output: normal_xy (FBO)
INFO: Initialized render output: material_properties (FBO)
INFO: Initialized render output: diffuse_albedo (FBO)
INFO: Initialized render output: log_luminance (FBO)
INFO: Initialized render output: log_luminance_tiny (FBO)
INFO: Maximum anisotropy: 16
INFO: 1 joystick found:
INFO:     0. Logitech G27 Racing Wheel USB
INFO: Loading car controls from: C:\Users\student\Documents\VDrift/controls.config
INFO: Update status file C:\Users\student\Documents\VDrift/updates.config will be created
INFO: Update status file C:\Users\student\Documents\VDrift/updates.config will be created
INFO: Sound initialization information:
INFO: Obtained audio device:
      Frequency: 44100
      Format: 32784
      Bits per sample: 16
      Channels: 2
      Silence: 0
      Samples: 2048
      Size: 8192
      Sound initialization successful
INFO: Loaded fonts successfully
INFO: Loaded GUI successfully
INFO: Force feedback enabled.
INFO: Loading track from path: data/tracks/garage
INFO: Loaded surfaces file, 7 surfaces.
INFO: No lap sequence found. Lap timing will not be possible.
INFO: Car loading was successful: Audi TT
INFO: Got quit message from GUI. Shutting down...
INFO: Profiling summary:
      render: 77.6241 %
      scenegraph: 12.1619 %
      sound: 0.185457 %
INFO: Shutting down...
INFO: Exiting

Here's the profiling, where you can see that the rendering is done on the cpu:
[Image: unbenanntyjv.png]

thanks for your help!
08-23-2012, 10:04 AM,
You are running with GL2 renderer on your GPU. The CPU numbers are showing the time spent on the CPU side(render, scene, sound, physics, ai). GL2 doesn't have GPU timing support, there is nothing to show.

About the data/shaders/gl3/deferredaa.frag error. It is funny because the shader is from NVidia it seems:

You could try changing "#version 130" to "#version 400" in deferredaa.frag.
08-23-2012, 10:44 AM,
hi nan!

thanks for your help and the information about the gl2 renderer.
i don't get any errors after changing the version of the dferredaa.frag from 130 to 400. But the profiling still don't show any information about the rendering of the gpu.

edit: debugging vdrift showed me, that vdrift is still using the gl2 renderer...

edit2: okay, just recompiled vdrift and now it works without problems! thank you!

Forum Jump:

Users browsing this thread: 1 Guest(s)