Christoph Oelckers
5e39890118
- use a uniform buffer for per-scene data like rotation matrices.
2018-09-02 18:40:36 +02:00
Magnus Norddahl
b1468d9dcc
- somehow visual studio 2015 miscompiles this so badly it triggers an out of bounds assert in STL!
2018-07-22 22:51:08 +02:00
Magnus Norddahl
151ed22967
- write OpenGL backend for hw_postprocess (FGLRenderBuffers::RenderEffect)
...
- remove old fxaa and lens shader classes
- render the fxaa and lens effects
2018-06-20 19:56:30 +02:00
Christoph Oelckers
1455111ddc
- removed unused declarations.
2018-06-14 22:57:08 +02:00
Christoph Oelckers
3401876476
- use FShaderProgram through an abstract interface and remove all dependencies on the GL renderer from the shader definition source files.
2018-06-13 22:08:55 +02:00
Christoph Oelckers
ce50b0e46b
- read sampler bindings from the shader instead of tagging along a large amount of support data.
...
Works for most shaders, except SSAO.
2018-06-13 17:44:49 +02:00
Christoph Oelckers
59827cd601
- use layout binding qualifiers on uniform buffers when GLSL version >= 4.2
...
This has no performance benefits but allows checking shader generation correctness without having to implement Vulkan first.
2018-06-13 13:16:07 +02:00
Christoph Oelckers
cb5caa757b
- moved ShaderUniforms to hwrenderer/ .
2018-06-12 22:08:31 +02:00
Christoph Oelckers
f166624eb2
- some fixes to the PP shader interface.
...
The binding point needs to be part of the ShaderUniforms class because Vulkan will need this value to generate the declaration in the shader source.
There's still one issue here: Since OpenGL has no local render state, the buffer must be bound every time it is used. Once the code is better abstracted this should be moved to a higher level class that knows all associated data and how to set it up.
2018-06-12 21:43:35 +02:00
Christoph Oelckers
f33ddd8cce
Made the ScopedViewShifter fully inline
2018-06-12 14:44:58 +02:00
Christoph Oelckers
b8b5802599
Added a uniform buffer abstraction class
...
May get some more methods later, this is just a start to get going.
2018-06-12 10:42:03 +02:00
Christoph Oelckers
496e6e2e8f
- fixed: The vertex height updater was using the index buffer offsets to access the vertex buffer.
...
I missed this part when repurposing the vboindex members to store the index buffer offsets.
However, since both indices are needed, they need another set of variables.
2018-05-24 00:01:56 +02:00
Christoph Oelckers
b612e182b4
Merge branch 'indexbuffer'
...
# Conflicts:
# src/gl/data/gl_vertexbuffer.h
# src/gl/scene/gl_flats.cpp
# src/hwrenderer/data/flatvertices.h
2018-05-22 22:10:21 +02:00
Christoph Oelckers
2514753afb
- make the vertex buffer accessible from the hwrenderer code.
2018-05-22 18:48:10 +02:00
Christoph Oelckers
3e204080ae
- render sector planes in one draw call.
...
On a fast and modern graphics card this is a lot faster than doing it per subsector but it may not be without drawbacks on older hardware so it will require some testing on older hardware.
For me Frozen Time's view over the bridge went from 46 fps to 51 fps with this change, the time saved was roughly 2 ms.
2018-05-19 15:20:46 +02:00
Christoph Oelckers
352279a52f
- removed the non-indexed flat setup.
...
This won't be needed any longer.
2018-05-19 14:44:16 +02:00
Christoph Oelckers
2125f8b9d1
- use triangles instead of triangle fans to render flats.
2018-05-19 14:42:25 +02:00
Christoph Oelckers
fd3681dae2
- use an indexed vertex buffer to render the flats.
...
Right now this has no advantage but it allows optimizing the data, e.g. rendering an entire sector in one go instead of per subsector.
2018-05-19 13:33:28 +02:00
alexey.lysiuk
2ae8d39441
Removed all superfluous #include's
...
Automatically optimized by CLion IDE with manual corrections
2018-04-24 14:30:35 +03:00
Christoph Oelckers
59a08ce0df
- fixed a few warnings and changed the return type of FGLTexture::Bind, because no caller needs the hardware texture.
2018-04-14 12:24:04 +02:00
Christoph Oelckers
0affc119fd
- moved hardware independent part of flat vertex data out of GL folder.
2018-04-14 12:05:31 +02:00