xray-16
xray-16 copied to clipboard
OpenGL Renderer
Post here all issues you have with OpenGL Renderer.
Current tasks and known bugs:
- [x] Fix crash after second Device restart (type
vid_restart
several times in console to reproduce) (e9427ac939862e103e513a614ee1f9e7ae3c8df4) - [x] Fix bugs with dynamic lighting
- [x] Fix bugs with local lights (lamps, campfires, etc) (06bb7657fad7d6578820cdfbf4aa7701ee732496, 615152e548a309d4dd4df3d7beb982f18af7bae5)
- [x] Rewrite sun lighting calculation from D3DXMath (#463, intersects with #261)
- [ ] Backend
- [ ] Supported OpenGL versions:
- [x] 4.5
- [x] 4.1
- [ ] 3.3
- [x] Implement shader pipeline that can work without
GL_ARB_separate_shader_objects
(b0e4de824046f77b9de378ea5d6f3de4e53b22a4)
- [x] Implement shader pipeline that can work without
- [ ] 3.1/3.0 maybe?
- [ ] 2.2 maybe?
- [ ] 2.0 maybe?
- [ ] Implement OpenGL ES support
- [ ] 3.x (make initial implementation for ES 3.x, if going straight to 2.0 isn't possible)
- [ ] 2.0 (lower requirement to 2.0, if initial implementation was for 3.x)
- [ ] Support for uniform buffer objects
- [ ] Support MSAA
- [ ] Support geometry shaders
- [ ] Support compute shaders
- [ ] Support tesselation shaders
- [ ] Supported OpenGL versions:
- [ ] Shaders ~~(two ways, should be supported both)~~
- [ ] Use cross-compiler to compile shaders from DirectX renderer
- Look into #258 for more info
- [ ] ~~Implement all shaders in GLSL (
shaders/gl
folder)~~- [x] Implement vertex and fragment (pixel) shaders
- [ ] Make implemented shaders work in all situations
- [x] Fix boxy sky textures with enabled Vertex Texture Fetch (#537)
- [x] Fix lighting glitches with G-buffer optimization enabled (
r3_gbuffer_opt on
) - [ ] Fix SSAO
- [ ] Fix HBAO shader
- [ ] Make implemented shaders work in all situations
- [ ] ~~MSAA support~~
- [ ] ~~Implement volumetric fog~~
- [ ] ~~Implement HDAO Ultra (compute shaders)~~
- [ ] ~~Implement tesselation~~
- [x] Implement vertex and fragment (pixel) shaders
- [ ] Use cross-compiler to compile shaders from DirectX renderer
Fix crash after second Device restart
Is this an OpenGL issue? I tried this in Wine and did not get a crash. Does it happen on Windows?
Is this an OpenGL issue? I tried this in Wine and did not get a crash. Does it happen on Windows?
Yes. It reports about OpenGL buffer overflow when it's trying to draw triangles... As far as I remember. Can't do it again at the moment.
I tried this in Wine and did not get a crash.
The important thing: it doesn't crash after the first Device restart.
if posible fix
! shader compilation failed ! dumb ! error: 0:1(10): error: GLSL 4.50 is not supported. Supported versions are: 1.10, 1.20, 1.30, 1.00 ES, and 3.00 ES
happend for all shader. maybe this reason of error
GL_INVALID_OPERATION in glUseProgramStages(program not linked) 76 FATAL ERROR [error] Expression : glUseProgramStages(HW.pPP, GL_FRAGMENT_SHADER_BIT, ps) [error] Function : set_PS [error] File : /home/test/build/game/xray-16/src/Layers/xrRenderPC_GL/../../Layers/xrRenderGL/glR_Backend_Runtime.h [error] Line : 80 [error] Description : (null)
radeon opensource driver
Fix bugs with dynamic sun lighting
Sun lighting doesn't work correctly when r3_gbuffer_opt is enabled. I think we don't need this command for opengl renderer. It has many bugs and from it there is little use.
Btw, need to add info about incorrect msaa, cleaning textures after drawing, rewrite rain/sun calculating on linux, pixelation skybox textures, crash when open menu (Invalid video stream: 0x505)
I suggest this task:
- [x] Log OpenGL vendor and renderer
Starting RENDER device...
Available video modes[0]:
[1920x1080]
* GPU vendor: [X.Org] device: [Radeon RX 550 Series (POLARIS12, DRM 3.27.0, 4.19.10-300.fc29.x86_64, LLVM 7.0.0)]
* GPU OpenGL version: 4.5 (Core Profile) Mesa 18.2.6
* GPU OpenGL shading language version: 4.50
* DVB created: 4096K
* DIB created: 512K
! Renderer doesn't support blender 'effects\shadow_world'
Got it running with OpenGL renderer, started a new game. Is it how it is supposed to look now? Should I submit an issue about it being too dark or is it already submitted? Maybe I can tweak my settings for it to look better?
" too dark" confirmed on Intel, nvidia and amd with the mesa. Ligth only nvidia blob
you can use light
Are SSAO and HBAO shaders actually broken by now or is the task list (in the first comment) outdated? As far as I can see, some kind of ambient occlusion presents (looking at the rendered picture).
SSAO works, but there's issue with SSAO on AMD cards, that's why it is in the task list too. HBAO shader compilation should be broken. HDAO... Not sure, may be broken too.
Update: Both HDAO and HBAO are disabled, because they are broken: https://github.com/OpenXRay/xray-16/blob/dev/src/Layers/xrRender_R2/r2.cpp#L469