Commit graph

58 commits

Author SHA1 Message Date
marauder2k7 11d8604d8e ogl device buffer creation
now ogl mirrors dx side with ubo creation and clearing pushed up to the device level.
2024-03-14 14:23:08 +00:00
marauder2k7 9dc5ae833b opengl ubo setup
opengl can now compile with ubo buffer objects similar to cbuffers on dx side.

cleaned double up of data from both sides, gfxhandles only need to use the desc info instead of holding onto its own.
2024-03-13 22:23:01 +00:00
AtomicWalrus c64c2212ad Fix for MacOS OGL 4.1 support
Workaround: MacOS does not have access to glClipControl.

Because the lower range of the 32F buffer is not available using this workaround, the improvements to depth behavior from depth reversal will be limited on MacOS. Behavior is equivalent to reversed depth on a 24UINT buffer; Better than stock, but not dramatically.
2023-04-15 15:21:49 -06:00
AtomicWalrus 75625dc679 Reverse depth & 32F buffer format
-Adds reversed depth projection model, dramatically increasing depth buffer effective resolution.
-Adds 32F depth 8U stencil format GFXFormatD32FS8X24 (following DX naming conventions). Note this is a 64-bit format, and likely not suitable for mobile platforms. Revert to GFXFormatD24S8 in renderManager.tscript for mobile & "ancient" platforms.
-Corrects alignment of texture type details array.
2023-04-14 20:13:28 -06:00
Areloch cd82186231 Fixes setter issue for image/shape/material custom inspector fields where it was not correctly passing through the changed value from the Asset Browser select
Swapped the water's disableTrueReflections variable to be enableTrueReflections for simplicity and consistency(also fixed a persistent typo)
Swapped disableVerticalSync to be enableVerticalSync for simplicity and consistency
Swapped disableParallaxMapping to be enableParallaxMapping for simplicity and consistency
Fix click detection on slider mode entries for guiGameSettingsCtrl so the click position correctly matches the percentage
Fixed problem where postFX initialization would always exec default.postfxpreset.tscript, even if a level's got it's own preset, which can cause problems
Fixed range field type behavior so that editing the values applies in real time, and also consistently applies between slider and text field
2022-08-30 01:29:39 -05:00
rextimmy e1398895b3 fix opengl device not returning the correct anisotropic value 2021-12-15 20:09:18 +10:00
Jeff Hutchinson 90951b3cc8
Merge pull request #619 from Azaezel/alpha40/glcubefix
fix opengl cubemap display
2021-10-11 21:13:25 -04:00
AzaezelX bce14ab63f fix opengl cubemap display 2021-10-11 20:02:49 -05:00
Robert MacGregor 1385b29f03 * Adjustment: Initial testing with extensions to load GPU VRAM. 2021-10-10 20:53:55 -04:00
Jeff Hutchinson a458c97217 Implement more extensions to get graphics card memory for OpenGL on windows and Linux.
(cherry picked from commit da942cdb79a87b76e629b36415c83067e3620a70)
2021-10-10 20:09:02 -04:00
Robert MacGregor c8a5ccb191 * [OpenGL] BugFix: Correct shader errors being thrown during the load phase due to direct use of glUseProgram causing desync with GFXGLDevice. 2021-09-17 17:39:29 -04:00
rextimmy 5a933c00d3 Removed old fixed function code from GFX. 2021-01-05 12:57:17 +10:00
Lukas Aldershaab 87dd7ffc4a Implement Singlepass Terrain Render 2021-01-01 21:06:01 +01:00
Brian Roberts d86c6aff35
Merge pull request #238 from Azaezel/alpha40_gl_cubemapWipwork
fix cubemap capture for gl
2020-07-05 20:38:53 -05:00
AzaezelX c57205b1f4 from @rextimmy: final fixes 2020-07-03 22:56:44 -05:00
chaigler e2bf5cb8fe Implements missing _captureBackBuffer method for GL gfx layer.
GL layer was missing _captureBackBuffer() implementation which caused screenShot() function to fail. Also caused ScreenShot::capture() to be called every frame afterward which caused significant performance issues.
2020-07-02 16:02:05 -04:00
AzaezelX ce2b05e0e2 a) grab the source mipmap levels not the dest ones for copy. b) lets rely less on trusting sizeof*4 when we've gor a size per pixel lookup already there 2020-06-29 21:26:08 -05:00
AzaezelX 24e6d8c73c partial followup to #202.
largely cleanups, though does include glCopyImageSubData for gl revs that support it
TODOS:
1) non glCopyImageSubData for `void GFXGLCubemapArray::copyTo(GFXCubemapArray *pDstCubemap)`
2) while we don't get corruption showing in >0 mips for irradiance maps using the newer code, it nevertheless renders wrong.
not 100% sure if renderdoc is showing blank mips because it expects it due to size, or if we are in fact generating em even though we don't use em in the end for irradiance references.
2020-06-25 17:34:48 -05:00
AzaezelX 4223a26f05 no message 2020-06-07 18:00:17 -05:00
AzaezelX b9c207765e uninitialized variables-gfx 2020-05-11 15:00:25 -05:00
AzaezelX 059d531b62 linux followup work by tim 2019-08-21 03:12:54 -05:00
Areloch 000c7b2263 GL work 2019-04-15 23:11:18 -05:00
Azaezel 1eed979a9c Merge branch 'method_Unmangle' into PBR_PR 2018-12-12 14:54:22 -06:00
Areloch 1f7cf55204 Add cubemap arrays, as well as control for generation of MIPs on texture targets. 2018-09-16 18:19:04 -05:00
Lukas Joergensen 2bbc716db6 Eliminate unnecessary uses of ConsoleFunction 2018-04-17 21:41:29 +02:00
Areloch 8c807485b1 Reworks the $Core::commonShaderPath variable usage to be a static variable in ShaderGen for efficiency(only one getVariable when shadergen is initialized), as well as implements the ability to set a default value, and ensures that it tries to set a path even if the pref variable is missing which is important for ported projects from older builds. 2017-07-24 00:40:27 -05:00
Areloch 25686ed4be Implementation of sRGB image support. Overhauls the linearization setup to utilize the sRGB image types, as well as refactors the use of ColorF and ColorI to be properly internally consistent. ColorIs are used only for front-facing/editing/UI settings, and ColorFs, now renamed to LinearColorF to reduce confusion of purpose, are used for color info in the engine itself. This avoids confusing and expensive conversions back and forth between types and avoids botches with linearity. Majority work done by @rextimmy 2017-06-23 11:36:20 -05:00
Areloch 1ed8b05169 Initial implementation of the new Base Game Template and some starting modules.
This makes some tweaks to the engine to support this, specifically, it tweaks the hardcoded shaderpaths to defer to a pref variable, so none of the shader paths are hardcoded.

Also tweaks how post effects read in texture files, removing a bizzare filepath interpretation choice, where if the file path didn't start with "/" it forcefully appended the script's file path. This made it impossible to have images not in the same dir as the script file defining the post effect.

This was changed and the existing template's post effects tweaked for now to just add "./" to those few paths impacted, as well as the perf vars to support the non-hardcoded shader paths in the engine.
2017-02-24 02:40:56 -06:00
rextimmy 415f4a046e OpenGL vsync fixes. 2016-12-23 13:59:55 +10:00
Jeff Hutchinson 15a10a78cc suppress API_ID_REDUNDANT_FBO on the debug callbacks. This is a temporary fix so that glad can get pushed into devhead. 2016-11-24 12:35:39 -05:00
Jeff Hutchinson 0296e6d3fd Fix merge conflict and add check for unix and not apple for glx
Merge branch 'development-gg' into gladdev

# Conflicts:
#	Tools/CMake/libraries/glad.cmake
2016-11-02 21:55:24 -04:00
Azaezel fbfd3ed8ed clang: constructor initialization order
while not a major issue per-se, the sheer number of times the engine has to jump back in memory and backfill data in a given class can add up. First run of... many.,
2016-10-14 18:16:55 -05:00
RexTimmy dd64004eaf MacOS platform support. 2016-09-28 11:09:48 +10:00
Jeff Hutchinson 11c3314f66 implement glad into torque. 2016-09-11 21:48:42 -04:00
James Urquhart 3496c549b5 Hardware Skinning Support
- Supports GL, D3D9 & D3D11
- Extends vertex formats & shadergen to support blend indices and weights
- Adds basic support for using 4x3 matrices for shader constants
- Supports software fallback
2016-08-21 01:43:30 +01:00
Azaezel 47366068c1 revised torque_nsight_workaround 2016-06-27 19:35:40 -05:00
Areloch f66a14c6e1 Merge pull request #1599 from JeffProgrammer/glprofiling
Added missing OpenGL profiling blocks.
2016-05-24 01:26:39 -05:00
Jeff Hutchinson db6d91925d Added profile blocks for GL. 2016-05-06 23:44:41 -04:00
Jeff Hutchinson a50600afaa tabs->spaces for TRON :) 2016-05-06 22:57:35 -04:00
Jeff Hutchinson f9b2aa397f cache OpenGL extensions that are not part of the 3.3 core profile, and that run more than initialization setup. 2016-05-06 21:50:11 -04:00
Jeff Hutchinson a216b4515b remove old legacy extensions that aren't being used. 2016-05-06 21:24:52 -04:00
Jeff Hutchinson fddc00b39b Merge branch 'development-gg' into epoxy 2016-04-17 23:59:42 -04:00
Jeff Hutchinson 6e692ea9cf torque windows integration of epoxy 2016-03-25 13:41:38 -04:00
rextimmy 41e5caf22b Direct3D11 Engine/source changes 2016-03-20 21:52:11 +10:00
Anis 740c999c19 compile fix 2016-02-25 15:26:52 +01:00
Anis f39f7a80c8 Update gfxGLDevice.cpp 2016-02-25 15:26:25 +01:00
Dušan Jocić 28d303c5ea Added immutable vertex and index buffers. 2016-02-20 21:28:18 +01:00
rextimmy b5f8e9aa70 gfxGLDevice setShader fix. 2015-06-15 21:10:49 +10:00
Daniel Buckmaster 905dd50d36 Merge pull request #980 from Azaezel/gl_debug_callbacks
opengl error reporting formatting
2015-02-22 12:24:30 +11:00
Luis Anton Rebollo 098fa19abb Merge pull request #1014 from Lopuska/patch-1
vSync on opengl
2015-02-15 23:02:32 +01:00