Commit Graph

52 Commits

Author SHA1 Message Date
Rolando Caloca
ce168f2846 UE4 - Renamed depth compare enums, changed some checks to static_asserts
[CL 2498658 by Rolando Caloca in Main branch]
2015-04-01 10:53:07 -04:00
Mike Fricker
114458bf0f Clang warning fixes: Fixed missing 'override' specifiers
- Also removed some unreferenced functions that adding 'override' revealed

PR #1002 -- Thank you, Omar007!

[CL 2498415 by Mike Fricker in Main branch]
2015-04-01 07:20:55 -04:00
Rolando Caloca
cb32891b3c UE4 - Added sanity checks for Inverted/Normal Depth Buffers; use ERHIZBuffer::NearPlane & FarPlane to switch from 0-1 to 1-0 on Depth
- Added shader define HAS_INVERTED_Z_BUFFER
- Added RHIHasInvertedZBuffer()
#codereview Martin.Mittring, Brian.Karis, Nick.Penwarden

[CL 2497481 by Rolando Caloca in Main branch]
2015-03-31 14:02:45 -04:00
Nick Penwarden
1c7911eb9d Improve precision in WorldToView and WorldToClip matrices when very far from the origin.
[CL 2426044 by Nick Penwarden in Main branch]
2015-01-30 12:44:24 -05:00
Marcus Wassmer
2cd3355b99 Add MRT clear value binding to the RHI. This allows parallel rendering platforms to propagate clear color values across parallel execution boundaries for platforms which require low level control over hardware clears.
Also add many explicit calls to CopyToResolveTarget to indicate the transition of a render target to be able to be used as an SRV.  Soon to be replaced by a more specific RHI function.
Added r.CheckSRVTransitions for D3D11 on windows to check if any of these transition are missing.
Fixes a bug with RHIThreadFence when using PLATFORM_SUPPORTS_PARALLEL_RHI_EXECUTE
PLATFORM_SUPPORTS_PARALLEL_RHI_EXECUTE on PS4 now supports CMASK and HTILE enabled buffers.
#codereview lee.clark,gil.gribb,rolando.caloca,daniel.wright

[CL 2420986 by Marcus Wassmer in Main branch]
2015-01-27 16:14:50 -05:00
Ben Marsh
149375b14b Update copyright notices to 2015.
[CL 2379638 by Ben Marsh in Main branch]
2014-12-07 19:09:38 -05:00
Martin Mittring
6a0bc3ef5b New feature: Cylindrical projection/distortion
r.Upscale.Cylinder 1
  r.ScreenPercentage.Editor 1

[CL 2347514 by Martin Mittring in Main branch]
2014-11-03 16:17:18 -05:00
Daniel Wright
77145dab19 Sky light capture will initialize scratch targets in GSceneRenderTargets if needed
[CL 2347433 by Daniel Wright in Main branch]
2014-11-03 15:58:12 -05:00
Gil Gribb
6185ae456c UE4 - minor parallel rendering fixes. Improved constructors for Xbox RHI. delete comments and cruft. Turn off parallel shadows. Flush before reflection capture on all platforms.
[CL 2336025 by Gil Gribb in Main branch]
2014-10-21 14:09:38 -04:00
Rolando Caloca
d8a576970e UE4 - Remove Color parameter on draw events (DEC_*)
[CL 2334566 by Rolando Caloca in Main branch]
2014-10-20 10:43:43 -04:00
Graeme Thornton
867467eb6a Mobile Preview - Scene render targets can now allocate forward/deferred targets simultaneously
[CL 2303120 by Graeme Thornton in Main branch]
2014-09-18 17:01:15 -04:00
Rolando Caloca
ff52d17769 UE4 - Fixed reflection captures on ES2
[CL 2298835 by Rolando Caloca in Main branch]
2014-09-15 17:57:54 -04:00
Rolando Caloca
42b7dfcecb UE4 - Revert Reflection captures changes
[CL 2298631 by Rolando Caloca in Main branch]
2014-09-15 15:52:29 -04:00
Rolando Caloca
29c68f2eec UE4 - Cascaded shadow maps on mobile/forward
* Still disabled as Metal requires a horrible workaround/hack
* Remove GSupportsGSRenderTargetLayerSwitchingToMips workaround

[CL 2295640 by Rolando Caloca in Main branch]
2014-09-12 17:21:49 -04:00
Gil Gribb
598cbb659c UE4 - allow draw events to work in parallel rendering, some flush tweaks
[CL 2293700 by Gil Gribb in Main branch]
2014-09-11 09:38:38 -04:00
Gil Gribb
9978428b65 UE4 - RHI thread prototype (PS4 only so far)
[CL 2283021 by Gil Gribb in Main branch]
2014-09-03 10:52:00 -04:00
Daniel Wright
f5238f04e1 Distance Field AO improvements
* Distance field building is now asynchronous and stored in the DDC separately from static mesh data.
* Added OcclusionMaxDistance and Contrast properties to Movable sky light
* Using the GBuffer normal instead of the generated distance field normal, fixes artifacts on two-sided materials and between modular pieces.  Also saves about .7ms / 4.5ms
* Points in the distance field are only considered 'inside' the mesh if > 50% of all rays traced hit a backface.  Most meshes can have a valid distance field generated with this heuristic.  Meshes without a distance field representation can receive occlusion.
* Fortnite two-sided foliage with world position offset animation works fine now
* Using the resulting bent normal for diffuse lighting, improves consistency in occluded corners
* Resulting bent normal is also used to occlude skylight specular using an approximate cone-cone intersection, prevents leaking where SSR is not available
* Fixed stationary skylights not getting lightmap mixing
* Reflection captures now work with the movable skylight, which adds its diffuse contribution to IndirectIrradiance so their lightmap mixing works
* Added new show flag to visualize mesh distance fields, which ray traces through the distance fields and gives a sense of their shape

[CL 2276435 by Daniel Wright in Main branch]
2014-08-28 13:54:31 -04:00
Graeme Thornton
df9dbd5ae3 Continued in-editor mobile preview work
- Removed default shader platform parameter from GetGlobalShaderMap()
 - Added an inline overload of GetGlobalShaderMap() that takes a feature level instead, and translates to the correct shader platform
 - Cached feature level on FSceneView for faster access
 - Cached shader map on FViewInfo for faster access
 - Cached featurelevel/shadermap on rendering composition graph execution context, for faster access

Fixed a couple of crashes when switching feature level dynamically
 - Needed to allow certain shader permutations to be generated if feature level was ES2, but still on a PC platform. (i.e. hitproxy shaders, and basepass shaders used by editor primitives system)

#codereview Nick.Penwarden

[CL 2275937 by Graeme Thornton in Main branch]
2014-08-28 06:22:54 -04:00
Mikolaj Sieluzycki
cfaf45ac58 Header cleanup: Engine module, public headers.
[CL 2265766 by Mikolaj Sieluzycki in Main branch]
2014-08-21 06:03:00 -04:00
Graeme Thornton
bcde0d05c2 Mobile Preview
* More removal of GRHIFeatureLevel and GRHIShaderPlatform

[CL 2262530 by Graeme Thornton in Main branch]
2014-08-19 10:41:34 -04:00
Daniel Wright
bbffb27aaf Fixed specular on movable skylights
* Removed double normalization from stationary skylight specular

[CL 2239230 by Daniel Wright in Main branch]
2014-07-31 19:39:39 -04:00
Graeme Thornton
747d2a9b9d Mobile Preview In Editor
- Material editor preview nodes now work when the editor is in es2 mode
 - Make editor primitives work in ES2 mode
 - Fix slate font rendering in ES2 mode
 - Remove ES2 shader de-gamma when in the editor
 - Add a new linear sampler type for linear textures
 - Various fixes for dynamic feature level switching
 - When in an emulated feature level mode, display some text in the level editor viewport saying what feature level we're running
 - Removed feature level parameter from USkeletalMesh::GetResourceForRendering. Not used for anything
 - ParticleVertexFactoryPool is now creates feature level specific vertex factories.

[CL 2187558 by Graeme Thornton in Main branch]
2014-07-10 10:39:54 -04:00
Gil Gribb
a5e5aef45d UE4 - cleaned up the recursive RHI usage for command lists and added these RHI mthods as queuable RHICopyToResolveTarget, RHICLear, RHIClearMRT, RHIClearUAV
[CL 2181497 by Gil Gribb in Main branch]
2014-07-09 11:02:23 -04:00
Gil Gribb
30f1fe2722 UE4 - further command list work. BoundShaderState, RHISetComputeShader, RHIDispatchComputeShader, RHIDispatchIndirectComputeShader, RHIAutomaticCacheFlushAfterComputeShader, RHIDrawPrimitiveIndirect, RHIDrawIndexedIndirect, RHIDrawIndexedPrimitiveIndirect, RHIEnableDepthBoundsTest
[CL 2175853 by Gil Gribb in Main branch]
2014-07-08 10:43:52 -04:00
Gil Gribb
fa40806ce3 UE4 - More RHI command list work. Remove more cases of GetImmediateCommandList
[CL 2124713 by Gil Gribb in Main branch]
2014-07-02 12:18:30 -04:00