Commit Graph

120 Commits

Author SHA1 Message Date
fabian giesen
7d8781778c Deprecate TVector2 operator <, >, <=, >=
2D vectors are not canonically ordered and having these operators results in very unfortunate interactions with generic code. In particular FMath::{Min,Max,Abs} on TVector2s compile but do not behave as one would expect.

Add explicit comparison methods as a replacement and deprecate uses of TVector2 overloaded relational operators since it's confusing and error-prone. Fix existing uses to avoid deprecation warnings. Several of these fixes are behavioral changes to fix what I am reasonably certain are bugs in the existing code - in particular, uses of FMath::{Min,Max,Abs} on TVector2s that almost certainly actually want TVector2::{Min,Max,GetAbs} instead.

#rb charles.bloom,jeff.roberts
#preflight 62d70a6547779a730aaac04b

#ROBOMERGE-AUTHOR: fabian.giesen
#ROBOMERGE-SOURCE: CL 21168341 via CL 21173069 via CL 21173193
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v972-20964824)

[CL 21192034 by fabian giesen in ue5-main branch]
2022-07-20 18:23:11 -04:00
Andrew Davidson
8d844cd4a6 Improve support for an extended WORLD_MAX
#rb various, trivial
#preflight 62a1cb46f73a01bd981b9978

[CL 20573655 by Andrew Davidson in ue5-main branch]
2022-06-09 07:03:13 -04:00
Jason Nadro
fc3dcee397 Restore backed out CL, with fixes.
Also restores follow-up CLs 19973746, 19973782
FStaticParameterSet::MaterialLayers can't be deprecated, since a property with the same name is included via FStaticParameterSetRuntimeData
So instead, FMaterialLayersFunctionsRuntimeData is updated with SerializeFromMismatchedTag, to allow serializing a full FMaterialLayersFunction.
When this happens, the EditorOnly portion is stored in a separate heap allocation, and then transferred to FStaticParameterSet::EditorOnly::MaterialLayers
#preflight 626c3405e31dbb512cef1e98

[Backout] - CL19973745
#fyi bob.tellez
Original CL Desc
-----------------------------------------------------------------
[Backout] - CL19964485
#fyi Ben.Ingram
Original CL Desc
-----------------------------------------------------------------
Add 'Optional' EditorOnly data for UMaterialInterface and UMaterialFunctionInterface
These are separate UObject hierarchies that store editor-only UPROPERTIES, but can be included with cooked content, which allows full editor support.
In principle, all editor-only properties could be moved over.  So far, this has been limited to UMaterialExpressions, and data related to material parameters.
FStaticParameterSet, FMaterialLayersParameters, and FMaterialCachedExpressionData have all been split into separate editor-only/non-editor-only classes,
which allows the editor-only portion to be stored on the optional editor-only UObject.
#preflight 626ab21dad56c0cbbea32dc4
#rb jason.nadro, francis.hurteau
#jira FORT-463329

[CL 20043286 by Jason Nadro in ue5-main branch]
2022-05-04 12:21:52 -04:00
bob tellez
34d8d5badd [Backout] - CL19964485
#fyi Ben.Ingram
Original CL Desc
-----------------------------------------------------------------
Add 'Optional' EditorOnly data for UMaterialInterface and UMaterialFunctionInterface
These are separate UObject hierarchies that store editor-only UPROPERTIES, but can be included with cooked content, which allows full editor support.
In principle, all editor-only properties could be moved over.  So far, this has been limited to UMaterialExpressions, and data related to material parameters.
FStaticParameterSet, FMaterialLayersParameters, and FMaterialCachedExpressionData have all been split into separate editor-only/non-editor-only classes,
which allows the editor-only portion to be stored on the optional editor-only UObject.
#preflight 626ab21dad56c0cbbea32dc4
#rb jason.nadro, francis.hurteau
#jira FORT-463329

[CL 19973745 by bob tellez in ue5-main branch]
2022-04-28 20:08:12 -04:00
Ben Ingram
448b0a9807 Add 'Optional' EditorOnly data for UMaterialInterface and UMaterialFunctionInterface
These are separate UObject hierarchies that store editor-only UPROPERTIES, but can be included with cooked content, which allows full editor support.
In principle, all editor-only properties could be moved over.  So far, this has been limited to UMaterialExpressions, and data related to material parameters.
FStaticParameterSet, FMaterialLayersParameters, and FMaterialCachedExpressionData have all been split into separate editor-only/non-editor-only classes,
which allows the editor-only portion to be stored on the optional editor-only UObject.
#preflight 626ab21dad56c0cbbea32dc4
#rb jason.nadro, francis.hurteau
#jira FORT-463329

[CL 19964485 by Ben Ingram in ue5-main branch]
2022-04-28 12:56:28 -04:00
sebastien lussier
fb46509564 Fixed static analysis warning in MaterialUtilities.cpp
#jira UE-145139
#rb patrick.enfedaque
#preflight 62278ce67077eb04cf6f6faf
#lockdown simon.tourangeau
#rnx

#ROBOMERGE-AUTHOR: sebastien.lussier
#ROBOMERGE-SOURCE: CL 19306498 in //UE5/Release-5.0/... via CL 19307900
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v926-19321884)

[CL 19347228 by sebastien lussier in ue5-main branch]
2022-03-10 21:09:41 -05:00
sebastien lussier
d26eb84389 #jira UE-142904
* Fixed static analysis warning

#jira UE-132273
* Fixed FSceneViewInitOptions::ShowOnlyPrimitives  (a TOptional) being assigned a value - if no "show only" primitives are provided, we must pass an unset TOptional - otherwise an empty set will mean no primitive should be visible.
** Solves an issue with FMaterialUtilities::ExportLandscapeMaterial() being called by the USDExporter & World Composition LOD level generation

#rb
#preflight 620f2a2ac602491fb81819f0

#ROBOMERGE-AUTHOR: sebastien.lussier
#ROBOMERGE-SOURCE: CL 19081612 in //UE5/Release-5.0/... via CL 19096515
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v921-19075845)

[CL 19140536 by sebastien lussier in ue5-main branch]
2022-02-24 23:17:38 -05:00
Sebastien Hillaire
7c6830b98e Strata - new blending mode.
- works for starta and legacy conversion material
- legacy converted to strata setup the strata blending mode
- strata material also affect legacy blending mode because it is used in multiple places in the engine.
- works for lit and unlit legacy material
- to be fixed:
    - lit with premultiplied alpha
    - materials with multiple shading models

#preflight https://horde.devtools.epicgames.com/job/6214893c3577e44741abf99f
#rb charles.derousiers

[CL 19069633 by Sebastien Hillaire in ue5-main branch]
2022-02-22 02:26:20 -05:00
ryan bickell
687186f6e1 Fix metallic, specular, and roughness packed into a single texture.
#rb sebastien.lussier
#preflight none

[CL 19038372 by ryan bickell in ue5-main branch]
2022-02-17 13:52:22 -05:00
sebastien lussier
2500dc14d0 Fixed static analysis warning
#jira none
#preflight 620abfc4674d5ad0da8f8b75
#rb patrick.enfedaque

#ROBOMERGE-AUTHOR: sebastien.lussier
#ROBOMERGE-SOURCE: CL 18986467 in //UE5/Release-5.0/... via CL 18986954 via CL 18987850
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v917-18934589)

[CL 18988151 by sebastien lussier in ue5-main branch]
2022-02-14 18:36:13 -05:00
sebastien lussier
4875b2627f #jira UE-132273
WP HLOD - Add Landscape support

Changes to support WP landscape material capture
* Moved IsValidBaseMaterial() from MeshMergeUtilities to MaterialUtilities
* Moved CreateProxyMaterialInstance() from MeshMergeUtilities to MaterialUtilities
* Added FCreateTexture2DParameters::bVirtualTexture
* Added FMaterialUtilities::ExportLandscapeMaterial() which doesn't need a list of primitives to hide (will only render the landscape component primitives)
* Added VT primming to ensure the captured textures have the expected resolution

#rb patrick.enfedaque
#preflight 6206a9e454003c49ad44c354

#ROBOMERGE-AUTHOR: sebastien.lussier
#ROBOMERGE-SOURCE: CL 18980162 in //UE5/Release-5.0/... via CL 18980592 via CL 18980979
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v917-18934589)

[CL 18981032 by sebastien lussier in ue5-main branch]
2022-02-14 12:01:24 -05:00
marc audy
6553e6cd0a Remove as much C++ deprecation as possible up to 4.17 (along with a few scattered removals from beyond)
#preflight 61eefc77ba69a4fdb220bf23

#ROBOMERGE-AUTHOR: marc.audy
#ROBOMERGE-SOURCE: CL 18712765 in //UE5/Release-5.0/... via CL 18712784 via CL 18713147
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)

[CL 18713191 by marc audy in ue5-main branch]
2022-01-24 15:07:48 -05:00
sebastien lussier
cf3512c9a5 Added proper ViewExtensions setup to scene captures performed by FMaterialUtilities::ExportLandscapeMaterial()
* Fixes USD export automated test
#rb jonathan.bard, daniel.coelho
#jira none

#ROBOMERGE-AUTHOR: sebastien.lussier
#ROBOMERGE-SOURCE: CL 18406923 in //UE5/Release-5.0/... via CL 18406998
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v897-18405271)

[CL 18407007 by sebastien lussier in ue5-release-engine-test branch]
2021-12-08 11:38:32 -05:00
jon nabozny
cdc65f654f Reland: Fixes motion blur lengths when using time dilation
#rb josie.yang
#lockdown michal.valient
#preflight 614a44526c96990001c47143

#ROBOMERGE-OWNER: jon.nabozny
#ROBOMERGE-AUTHOR: guillaume.abadie
#ROBOMERGE-SOURCE: CL 17606608 via CL 17962735 via CL 18364937 via CL 18364960
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18365023 by jon nabozny in ue5-release-engine-test branch]
2021-12-02 23:53:56 -05:00
jon nabozny
9693ad4915 Undo //UE5/Private-Frosty/Engine/... changelist 17586431
#lockdown michal.valient
#preflight revert for build breakage

#ROBOMERGE-OWNER: jon.nabozny
#ROBOMERGE-AUTHOR: guillaume.abadie
#ROBOMERGE-SOURCE: CL 17587410 via CL 17948832 via CL 18364580 via CL 18364616
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18364712 by jon nabozny in ue5-release-engine-test branch]
2021-12-02 23:34:52 -05:00
jon nabozny
c418c40de0 Fixes motion blur lengths when using time dilation
#rb josie.yang
#lockdown michal.valient
#preflight 614a1e3259380f0001888d92

#ROBOMERGE-OWNER: jon.nabozny
#ROBOMERGE-AUTHOR: guillaume.abadie
#ROBOMERGE-SOURCE: CL 17586431 via CL 17948712 via CL 18364381 via CL 18364522
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18364604 by jon nabozny in ue5-release-engine-test branch]
2021-12-02 23:30:35 -05:00
jeremy moore
9680e3e3e0 #jira UE-125021
Remove skinning pre/post offset functionality.
This were added in 4.26 specifically and temporarily for the MLDeformer prototype. (The public functions have always been marked as deprecated.)
MLDeformer now uses an Optimus deformer.
#rb josie.lang
#preflight 6197f9f1d90987e51d99c6a3

#ROBOMERGE-AUTHOR: jeremy.moore
#ROBOMERGE-SOURCE: CL 18258799 in //UE5/Release-5.0/... via CL 18258814
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18258831 by jeremy moore in ue5-release-engine-test branch]
2021-11-22 10:32:59 -05:00
Marc Audy
0c3be2b6ad Merge Release-Engine-Staging to Test @ CL# 18240298
[CL 18241953 by Marc Audy in ue5-release-engine-test branch]
2021-11-18 14:37:34 -05:00
aurel cordonnier
a12d56ff31 Merge from Release-Engine-Staging @ 17791557 to Release-Engine-Test
This represents UE4/Main @17774255, Release-5.0 @17791557 and Dev-PerfTest @17789485

[CL 17794212 by aurel cordonnier in ue5-release-engine-test branch]
2021-10-12 21:21:22 -04:00
ben ingram
c0a303be42 Continuation of previous material parameter refactor. Replace FMaterialRenderProxy Scalar/Vector/Texture parameter query functions with generic version
#rb none
#jira none

#ROBOMERGE-SOURCE: CL 17378446 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v865-17346139)

[CL 17378452 by ben ingram in ue5-release-engine-test branch]
2021-08-31 17:38:39 -04:00
guillaume abadie
b5a4dfc800 Kills FPostProcessSettings::ScreenPercentage
#rb none

#ROBOMERGE-SOURCE: CL 16848903 via CL 16848904
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v836-16769935)

[CL 16848909 by guillaume abadie in ue5-release-engine-test branch]
2021-07-14 08:25:29 -04:00
sebastien lussier
eac3ae2a6b World Partition HLODs - Added automatic texture size selection based on hints
Supports either:
* From texel density
* From expected mesh screen size
* From expected mesh draw distance

Compute best texture size, taking UV map waste into account.
Currently only supported by the Approximate Actors merge method, to be integrated in the ProxyLOD later.
#rb ryan.schmidt, luc.eygasier

#ROBOMERGE-SOURCE: CL 16635038 via CL 16635077
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v831-16623017)

[CL 16635084 by sebastien lussier in ue5-release-engine-test branch]
2021-06-10 21:50:21 -04:00
jeanfrancois dube
12e850ac12 Reduce the impact of wrapped pointers by 75% from material code.
For example, texture streaming spikes drops from 26.7ms to 16.6ms in PIE.

#rb zousar.shaker


#ROBOMERGE-SOURCE: CL 16571356
#ROBOMERGE-BOT: (v828-16531559)

[CL 16571408 by jeanfrancois dube in ue5-main branch]
2021-06-07 11:35:07 -04:00
sebastien lussier
412cf1d7a1 MaterialBaking - Use correct linear bake for all texture property by default
Providing a new flatten material with the correct texture samplers.
Retrieve texture properties from the default textures in the material (linear vs srgb, compression, vt enabled, lod group...)

Previously generated material instances are unchanged.
All MergeActor engine tests pass successfully.

#rb patrick.enfedaque

#ROBOMERGE-SOURCE: CL 16484038 in //UE5/Private-Frosty/...
#ROBOMERGE-BOT: STARSHIP (Private-Frosty -> Main) (v823-16466674)

[CL 16484318 by sebastien lussier in ue5-main branch]
2021-05-27 10:31:36 -04:00
Andrew Davidson
3ddc3a4da3 Merge up from //UE5/Dev-LargeWorldCoordinates
#rb none

[CL 16211417 by Andrew Davidson in ue5-main branch]
2021-05-05 15:07:25 -04:00