Commit graph

75 commits

Author SHA1 Message Date
James Urquhart 1198932e87 Basic fix for reflections in both stereo rendering modes 2016-09-11 22:42:42 +01:00
James Urquhart de48afc00c USe correct frustum projections in reflections in separate rt mode 2016-09-11 22:42:42 +01:00
James Urquhart 784f6f92d8 Fix lens flare in side-by-side view 2016-09-11 22:42:42 +01:00
James Urquhart f91aa639d6 Remove projection offset, add the hmd head matrix. Also tidy up a few things. 2016-09-11 22:42:42 +01:00
James Urquhart 3dc2100765 Ignore alpha when rendering debug texture 2016-09-11 22:42:42 +01:00
Areloch b7882e7280 Merge pull request #1653 from Areloch/twiLightZone
Corrects culling of point/spot lights
2016-06-21 05:10:53 -05:00
OTHGMars 172e62a8f1 Mount Process Order Fix 2
Added a check to SceneObject::setProcessTick() to prevent objects that have mounts from being removed from the process list so the processAfter chain of the mounted objects is not broken.
2016-06-17 10:36:29 -05:00
Areloch dfb8f4f5e5 Makes point and spot lights be correctly culled with zoning like other objects. 2016-06-17 00:47:46 -05:00
Areloch 3a73344abb Resolves merging-order conflicts for the vehicle physics PR, as well as correcting cmake not blacklisting the componentGroup files if TORQUE_EXPERIMENTAL_EC was flipped off. 2016-06-05 19:17:34 -05:00
Areloch ec8882c3c8 Ensuring all names are the correct casing for Linux 2016-05-26 01:37:14 -05:00
Areloch b04ad52b5d Ensure that inclusion of any entity/component stuff is properly bracketed with the preprocessor check. 2016-05-15 10:11:46 -05:00
Areloch b3b50abd9b Integrates components into the update and render loop. 2016-05-14 12:40:13 -05:00
Azaezel bac14875f4 allows navmeshes to generate for most scene objects, and adds a NavMeshIgnore method for object-instances to filter them out. 2016-04-04 09:38:24 -05:00
rextimmy 41e5caf22b Direct3D11 Engine/source changes 2016-03-20 21:52:11 +10:00
Azaezel 8c5810adad The final step (barring any overlooked missing bits, requested refactors, and of course, rolling in dependencies already submitted as PRs) consists of:
renderPrePassMgr.cpp related:
A) shifting .addFeature( MFT_XYZ); calls from ProcessedShaderMaterial::_determineFeatures to ProcessedPrePassMaterial::_determineFeatures
B) mimicking the "// set the XXX if different" entries from RenderMeshMgr::render in RenderPrePassMgr::render
C) fleshing out ProcessedPrePassMaterial::getNumStages() so that it shares a 1:1 correlation with ProcessedShaderMaterial::getNumStages()
D) causing inline void Swizzle<T, mapLength>::ToBuffer( void *destination, const void *source, const dsize_t size )  to silently fail rather than fatally assert if a source or destination buffer is not yet ready to be filled. (support for #customTarget scripted render targets)

Reflections:
A) removing reflectRenderState.disableAdvancedLightingBins(true); entries. this would otherwise early out from prepass and provide no color data whatsoever.
B) removing the fd.features.addFeature( MFT_ForwardShading ); entry forcing all materials to be forward lit when reflected.
C) 2 things best described bluntly as working hacks:
C1) when reflected, a scattersky is rotated PI along it's z then x axis in order to draw properly.
C2) along similar lines, in terraincellmaterial, we shut off culling if it's a prepass material.

Skies: scattersky is given a pair of rotations for reflection purposes, all sky objects are given a z value for depth testing.
2016-02-16 02:50:49 -06:00
Azaezel 2753f562e8 shadow caching
SPECIAL NOTE: highly suggest https://github.com/GarageGames/Torque3D/pull/1441 or a variation thereof to prevent debug spew and false-postives for occlusion results.

With significant research, development and prototyping assistance from both @andr3wmac (shaders and partial hook work), and @LuisAntonRebollo (additional culling)

System operates as follows:
1) materials are given an additional castDynamicShadows boolean entry. (Default at time of writing is true by request. Personal usage at time of writing defaults to false. value is default-initialized in materialDefinition.cpp. script/gui exposed)
2) lights are given a staticRefreshFreq and dynamicRefreshFreq (in milliseconds). script/gui exposed
3) materials are (effectively) sorted into dynamic and static shadowmap render lists based on flag. (see shadowMapPass.cpp)
4) initial shadowmaps are generated for each light and 'list'.
5) as each refreshFreq times out, the relevant shadowmap for a given light is refreshed.

Special notes:
dynamicRefreshFreq for all lights is set to a (script exposed) 8MS refresh timer.
StaticRefreshFreq for the lions share of lights defaults to 250 MS (1/4 of a second)
scattersky's embedded light, which is intended to operate in a mobile manner, defaults to 8
to reiterate, these are all customizable per-light via script/inspector gui in the case of alternate project needs.
2015-10-13 18:12:19 -05:00
Areloch bedc79aacb Merges in Monkey's fixes PR with a resolution for a conflict 2015-09-03 22:58:57 -05:00
Daniel Buckmaster c2e5dc3345 Merge remote-tracking branch 'bpay/clang-cl-build-fixes' into development
Conflicts:
	Engine/source/T3D/shapeBase.h
2015-07-17 16:55:12 +10:00
Areloch 2002d74b78 Issue found with PVS-Studio:
Many instances of a function or expression being used repeatedly, which can lower performance.

Fixed it in these cases by creating on local var, reference or pointer that's used instead.
2015-07-13 22:51:17 -05:00
Raul Ferriz 5ef130d581 Fixed some random Worder warnings 2015-07-03 15:52:38 +02:00
Daniel Buckmaster 6b9e5dd15e Merge pull request #1330 from jamesu/stereo_render_fix
Basic fix for stereo rendering without a display device
2015-07-02 23:45:10 +10:00
Daniel Buckmaster 39f0e269d6 Merge pull request #1328 from GarageGames/release-3.7
Release 3.7
2015-06-24 19:00:57 +10:00
James Urquhart efc47ed757 Basic fix for stereo rendering without a display device 2015-06-21 20:59:41 +01:00
Daniel Buckmaster 49d2ab8bc3 Add more info to fatal assert in SceneContainer. See #1287. 2015-05-16 22:41:20 +10:00
James Urquhart 3a457749ec Oculus VR DK2 Support
- Updated to work with 0.5.x SDK
- Uses Oculus Rendering rather than PostFX
- Stereo rendering refactored so more rendering info is grabbed from the DisplayDevice
- Implements an Offscreen Canvas for in-game gui with oculus
- Message dialogs and metrics display can now go to the OffScreen Canvas (if oculus demo is setup correctly)
2015-05-06 23:09:51 +01:00
Ben Payne 7f1f6a5e8b Fix for link error when building with clang-cl 2015-03-04 19:25:11 -05:00
Ben Payne 0ffd7f5620 Fix member vars left uninitialized in constructors 2015-02-20 18:41:51 -05:00
Nathan Bowhay 87bb479c8c Check now platform independent
Now it uses a Torque function to check so it compiles on Linux.
2015-02-12 11:39:47 -08:00
Nathan Bowhay 7809e595ed Fixed tab vs spaces
Fixed tab vs spaces
2015-02-12 11:05:44 -08:00
Nathan Bowhay 50f875a2f5 Fixed bug with comparison cases of getRenderEnabled
For some reason returning true/false rather that 1/0 from
_getRenderEnabled would cause errors in some comparison cases to see if
it was true or not (would treat it as if it was a string/word rather
than a bool or int).
2015-02-03 14:18:06 -08:00
Nathan Bowhay 1372b4f600 Fixed raycast bug start x position is NaN
Fixed bug in _castRay when the start x position is NaN.
2015-02-03 14:14:02 -08:00
Luis Anton Rebollo 6492028bb2 Merge pull request #1035 from bpay/memfixes
Memfixes
2015-01-25 13:42:32 +01:00
Ben Payne b2b950c84a Add missing include guards to some headers 2015-01-06 00:42:33 -05:00
Daniel Buckmaster ae284a89ec Merge branch 'development' into defineconsolemethod
Conflicts:
	Engine/source/materials/materialDefinition.cpp
2014-12-26 13:22:16 +11:00
Azaezel c6cdfafe4e cleaned up variant of https://github.com/GarageGames/Torque3D/pull/768 alterations: opengl support, in-shader bug-reporting, direction vector fit to material slider-bar. 2014-12-21 14:07:42 -06:00
Daniel Buckmaster 9396ae7176 Merge remote-tracking branch 'Winterleaf/Development-Console' into defineconsolemethod
Conflicts:
	Engine/source/T3D/missionMarker.cpp
2014-12-21 21:23:55 +11:00
Daniel Buckmaster 8a104a5222 Merge pull request #1018 from eightyeight/ghost-scoping
Add the option to limit ghost scoping range
2014-12-21 19:03:02 +11:00
Ben Payne 98e79f3aec Fix uninitialized member vars 2014-12-13 16:08:47 -05:00
Daniel Buckmaster a928d142f7 Made some tweaks so I'm happy with it.
* Removed #defines
 * Fall back to using visible distance if ghost distance is not used
 * Removed ghost distance from level files as it will default
 * Renamed mConnectionVisibleDistance for consistency
2014-12-07 19:14:06 +11:00
LuisAntonRebollo adc7c72caa clean PlaneReflector member variables declaration. 2014-11-30 05:16:56 +01:00
LuisAntonRebollo c0b2e6536b Reduce innecesary changes on Render Target textures. 2014-11-08 18:34:21 +01:00
Vincent Gee 578c4e8f4f Removed Tabs, added check on connection 2014-11-06 08:38:05 -05:00
Vincent Gee 55bdfe5dc3 This adds limiting the ghost data to a specific area around the client.
By default it is not included in the build, you must #define GHOSTSCOPING in the torqueConfig.h to enable it.
The distance can be set via the mission file by adding

visibleGhostDistance = "1000";

Or if it is not set in the mission file it will default to what is defined in torqueConfig.h #defined as GHOSTSCOPING_DEFAULT_DISTANCE_IF_NOT_IN_MISSION

The mission default distance can be overridden on a per connection basis by using gameconnection:setVisibleGhostDistance and gameconnection:getVisibleGhostDistance

The logic for setting the scoping distance was moved from shapebase in the original design to SceneObject so that it will affect cameras, players, etc.
2014-11-05 23:14:39 -05:00
Daniel Buckmaster 3082bb3adc Merge pull request #884 from GarageGames/development-3.6
Version 3.6.2
2014-11-05 20:28:01 +11:00
Vincent Gee acb192e2a5 Replaced a ton of ConsoleMethods with the DefineConsoleMethod Macro. 2014-11-03 22:42:51 -05:00
Daniel Buckmaster 19f91fee2b Added a setPosition function. 2014-10-28 14:10:22 +11:00
bank 62006e8b3c Remove unneeded double-initialization of the vars. 2014-10-19 14:30:46 +11:00
Daniel Buckmaster feec36731e Merge pull request #594 from LuisAntonRebollo/unit-tests-without-crash
Increased stability Torque3D: unit-tests running without a crash.
2014-06-16 10:57:04 +10:00
bank f3fc84738b Use fixed buffer size var when allocating return buffer from console.
Conflicts:
	Engine/source/T3D/missionArea.cpp
	Engine/source/gui/editor/guiDebugger.cpp
2014-06-11 13:09:55 +04:00
LuisAntonRebollo 18ba0646c0 Increased stability Torqu3D: unit-tests running without a crash. See the console.log after ran unitTest_runTests( "", true ). @signmotion 2014-05-25 16:50:19 +02:00