Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Shaders
09-01-2011, 02:43 PM,
#1
Shaders
In order to get shaders working on my system, I have had to change fragment.glsl in lightaccumulate and logluminance. The log from before this is here: http://pastebin.com/bug8Fa8f
These are the changes I made:
Line 128 lightaccumulate: vec3 ref_sharpish = textureCube(tu4_cube, refmapdir, reflection_lod).rgb;
Line 24 logluminance: gl_FragColor.rgb = vec3(1.,1.,1.)*texture2D(tu0_2D, tu0coord, lod).r;
This got shaders working, but still with errors: http://pastebin.com/F2HcyxBM
I was wondering if this is just my computer (the intel graphics maybe) and so I should revert the changes before releasing as it will break stuff for others, or if it's alright to check the changes into SVN.
Reply
09-01-2011, 03:00 PM,
#2
 
I don't think you can do this. texture2DLod differs from texture2D. I am sure Joe can tell more.

Btw the last time I've tried to make the shaders work on my intel gpu it was way too slow 2-8fps.
Reply
09-01-2011, 03:28 PM,
#3
 
Ok, cool. I can 30 with everything else low.
Reply
09-02-2011, 10:42 AM,
#4
 
Can you post your GPU info that VDrift spits out? Example:
INFO: GL Renderer: ATI Radeon HD 4800 Series
INFO: GL Vendor: ATI Technologies Inc.
INFO: GL Version: 3.3.10665 Compatibility Profile Context
INFO: Initialized GLEW 1.5.7
Reply
09-02-2011, 01:17 PM,
#5
 
INFO: GL Renderer: Intel HD Graphics 3000 OpenGL Engine
INFO: GL Vendor: Intel Inc.
INFO: GL Version: 2.1 APPLE-7.4.10
INFO: Initialized GLEW 1.6.0
ERROR: Graphics card or driver does not support required GL_VERSION_3_3
ERROR: Initialization of GL3 failed; that's OK, falling back to GL 1 or 2
ERROR: You don't have an NVIDIA or ATI/AMD card. This game may not run correctly or at all.
INFO: Video card information:
Vendor: Intel Inc.
Renderer: Intel HD Graphics 3000 OpenGL Engine
Version: 2.1 APPLE-7.4.10
Maximum texture size: 8192
Maximum varying floats: 60
Using GLEW 1.6.0
Reply
09-03-2011, 12:28 PM,
#6
 
Turns out texture*Lod isn't supported in vanilla GL 2.1 (GLSL 1.2) in fragment shaders. The logluminance shader isn't actually used, so I stopped it from getting loaded. I replaced the textureCubeLod used in lightaccumulate with a textureCube with a bias parameter supplied instead. It's not exactly the same, but for that use, it seems OK. Let me know if R898 works for you.
Reply
09-03-2011, 03:08 PM,
#7
 
Great, that works fine. Thanks.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)