Commit Graph

83 Commits

Author SHA1 Message Date
julien stjean
f324e13073 Fixed two issues in the proxy merge tools.
1- The FExportMaterialProxy didn't give the proper static parameters for the materials instance. It always used those from the parent/master material.
2- The mesh description extracted from the static mesh component was sometimes invalid. This occurred when the mesh had an empty section as it first section. This resulted in a mesh with all its polygons being part of the first section when rendered for the proxy mesh.

Also renamed a variable in the create proxy mesh function since its previous name didn't make sense with what it is.

#jira UE-90322
#rb Sebastien.Lussier

#ROBOMERGE-SOURCE: CL 12234869 in //UE4/Release-4.25/... via CL 12234887
#ROBOMERGE-BOT: RELEASE (Release-4.25Plus -> Main) (v664-12234175)

[CL 12237471 by julien stjean in Main branch]
2020-03-17 20:02:37 -04:00
sebastien lussier
9eda8fed2e Merge CL 11587939 - Fix invalid material baking when "Reuse Mesh Lightmap UVs is used with a mirrored (negative scale) mesh.
#jira none
#rb none

#ROBOMERGE-SOURCE: CL 11588027 in //UE4/Release-4.25/... via CL 11588035
#ROBOMERGE-BOT: RELEASE (Release-4.25Plus -> Main) (v654-11333218)

[CL 11588040 by sebastien lussier in Main branch]
2020-02-24 11:12:16 -05:00
Rolando Caloca
5b82f15def Copying //UE4/Dev-RenderPlat-Staging@11388153 to //UE4/Main
#rb none
#rnx

[CL 11388545 by Rolando Caloca in Main branch]
2020-02-12 13:27:19 -05:00
matt kuhlenschmidt
3fa44160fd Improved the details panel root object customization API to support multiple objects in the "root object set". Deprecated old functionality and removed pass through customizations that are no longer needed
#rb none

#ROBOMERGE-OWNER: matt.kuhlenschmidt
#ROBOMERGE-AUTHOR: matt.kuhlenschmidt
#ROBOMERGE-SOURCE: CL 11382968 via CL 11382988 via CL 11382990
#ROBOMERGE-BOT: (v654-11333218)

[CL 11383722 by matt kuhlenschmidt in Main branch]
2020-02-12 09:41:11 -05:00
Josh Adams
aa9705149b Copying Private-LoadTimes-4.24 stream to Main. Biggest changes are in Materials/Shader memory freezing.
#rb none

[CL 11282608 by Josh Adams in Main branch]
2020-02-06 13:13:41 -05:00
sebastien lussier
ba57adfd4b Edigrating 3 CLs to improve HLOD generation time (faster material baking & mesh merging)
CL 10373564 by danny.couture
Optimize Material Baking (Phase 1)
  - Introduce a mecanism to override the vertex/index buffer allocator used for dynamic meshes
  - Avoid GDynamicMesh non-ticked pools build-up by using our own vertex/index buffer pool during baking
  - Reduce reallocation and incurred soft page faults by reusing a single set of vertex/index buffers big enough for the biggest mesh
  - Preemptively detect if smearing would result in monochrome texture to avoid useless work
  - Shrink smeared monochrome textures during the baking process for huge memory savings
  - Move UV smearing in worker threads to avoid blocking the game thread
  - Required shaders are now built asynchronously
  - Add progress bar for material baking
  - 28m23 [at] 150 GB RAM -> 2m14s [at] 45 GB RAM for 6 channels [at] 512x512 when baking materials on ProxyLOD for DATASET-0008a with DDC empty
#rb Jurre.deBaare, Sebastien.Lussier

CL 10516258 by danny.couture
Optimize Material Baking (Phase 2)
  - Implement pipelining with staging buffers to avoid GPU stalls when reading from render targets
  - Reuse the same prepared FMeshBatch instead of rebuilding it for each draw pass
  - Prepare the RenderItem in advance on other threads to reduce work on the game thread
  - Move the staging surface copy out of the render thread
  - Small vertex and index buffers are not reused to avoid dependency locks when mapping them
  - Fix bug in Canvas Flush_RenderThread found while running HLOD rebuild commandlet on Fortnite
  - Delete old and unused MaterialBakingModule.h from public files
  - 4m44s -> 59s for baking 6 channel [at] 1024x1024 when baking materials on ProxyLOD for DATASET-0008a with shaders already compiled
  - Time spent in Material Baking when rebuilding all HLOD on Apollo_POI_Large_HLOD (Phase 1 + 2 combined)
     - 10m18s -> 2m36s for a first rebuild all in editor with no shaders in DDC (cold)
     - 1m23s   -> 20s for a second rebuild all in editor (warm)
#rb Jeremy.Moore, Sebastien.Lussier

CL 11135986 by sebastien.lussier
Optimized mesh merging
* Added DeletePolygons() & DeleteTriangles methods to FMeshDescription which rely on TSets<> instead of performing costly TArray::AddUnique() calls()
* Parallelized UV generation and avoided duplicate processing of the same mesh+lod pairs
* Optimized FMeshDescriptionOperations::GenerateUniqueUVsForStaticMesh()
* Goes from 100s to 10s in my test case
#rb danny.couture, jeanfrancois.dube, richard.talbotwatkin



#ROBOMERGE-OWNER: sebastien.lussier
#ROBOMERGE-AUTHOR: sebastien.lussier
#ROBOMERGE-SOURCE: CL 11206337 via CL 11206341 via CL 11206346
#ROBOMERGE-BOT: (v643-11205221)

[CL 11206493 by sebastien lussier in Main branch]
2020-02-03 11:08:35 -05:00
Juan Canada
f396f56a0b Merging //UE4/Dev-Main@11042002 to Dev-RenderPlat-Staging(//UE4/Dev-Rendering)
#rnx
#rb none

[CL 11075443 by Juan Canada in Dev-RenderPlat-Staging branch]
2020-01-21 14:54:20 -05:00
JeanMichel Dignard
7130d293f2 Merging main @ cl 11028482
#rb none
#rnx

[CL 11029060 by JeanMichel Dignard in Dev-Tools-Staging branch]
2020-01-16 10:24:38 -05:00
mickael gilabert
90dc29a2e3 FMaterial::GetStaticParameterSet should not be called when FPlatformProperties::RequiresCookedData() is true. It can create otherwise spikes up to 200ms++
#rnx
#rb ben.ingram, zousar.shaker


#ROBOMERGE-SOURCE: CL 10996668 via CL 10996669 via CL 10996670
#ROBOMERGE-BOT: (v633-10983880)

[CL 10996671 by mickael gilabert in Main branch]
2020-01-15 15:39:20 -05:00
JeanMichel Dignard
70d074639f Merging //UE4/Dev-Main @ 10886849 to Dev-Tools-Staging (//UE4/Dev-Tools-Staging)
#rb none
#rnx

[CL 10906274 by JeanMichel Dignard in Dev-Tools-Staging branch]
2020-01-08 13:26:18 -05:00
Juan Canada
2ecf4f9708 Merging //UE4/Dev-Main@10877709 to Dev-RenderPlat-Staging(//UE4/Dev-Rendering)
#rnx
#rb none

[CL 10895568 by Juan Canada in Dev-RenderPlat-Staging branch]
2020-01-07 13:45:01 -05:00
ryan durand
471d972e62 Updating copyright for Engine Developer.
#rnx
#rb none


#ROBOMERGE-SOURCE: CL 10869240 via CL 10869516 via CL 10869902
#ROBOMERGE-BOT: (v613-10869866)

[CL 10870584 by ryan durand in Main branch]
2019-12-26 15:32:37 -05:00
Chris Gagnon
346a4b05ea Copy up from Dev-Editor @10681378
#rb none

[CL 10837446 by Chris Gagnon in Dev-Tools-Staging branch]
2019-12-19 18:07:47 -05:00
danny couture
8f3036879c Copy up //UE4/Dev-Enterprise/... to //UE4/Dev-Tools-Staging/...
#rb none

[CL 10478662 by danny couture in Dev-Tools-Staging branch]
2019-11-28 10:58:55 -05:00
sebastien lussier
9fb42b5d8a Compare all set of UVs when trying to merge polygons in FMeshDescriptionOperations::GenerateUniqueUVsForStaticMesh
Swap vertices in material baking when mesh is mirrored
#rb none

#ROBOMERGE-OWNER: sebastien.lussier
#ROBOMERGE-AUTHOR: sebastien.lussier
#ROBOMERGE-SOURCE: CL 10285512 via CL 10285513 via CL 10285514
#ROBOMERGE-BOT: (v591-10236483)

[CL 10285554 by sebastien lussier in Main branch]
2019-11-18 09:08:13 -05:00
sebastien lussier
af0eb69a21 #jira UE-83144
Certain texture maps generated by merge actors would be red instead of greyscale

#rb rolando.caloca, uriel.doyon
#rnx

#ROBOMERGE-SOURCE: CL 10073049 in //UE4/Release-4.24/...
#ROBOMERGE-BOT: RELEASE (Release-4.24 -> Main) (v574-10069753)

[CL 10073051 by sebastien lussier in Main branch]
2019-11-07 13:44:43 -05:00
Rex Hill
412191492f Fix up calls to OpenMsgDlgInt to use FMessageDialog::Open instead
#rb jason.stasik

[CL 9389972 by Rex Hill in Dev-Editor branch]
2019-10-03 09:45:37 -04:00
Chris Gagnon
8ab0638182 Copying //UE4/Dev-Editor to Dev-Main (//UE4/Dev-Main) for 4.24
#rb none

[CL 9325047 by Chris Gagnon in Main branch]
2019-10-01 20:41:42 -04:00
Richard TalbotWatkin
1cd94f81c3 Added StaticMeshDescription module for defining attributes and operations required in editor and at runtime for MeshDescriptions for static meshes.
Provided a path for building MeshDescriptions for static meshes at runtime, and supporting API.
Clarified use of attributes for static meshes; now some attributes may be considered optional.
Added FStaticMeshAttributes, used for fetching and registering all the attributes required by a static mesh.
Added Blueprint interface for building meshes.
Deprecated a number of existing APIs:
 - FMeshDescription methods which referred explicitly to static mesh specific attributes
 - StaticMesh attribute registration has been moved to FStaticMeshAttributes
#rb none

[CL 9123037 by Richard TalbotWatkin in Dev-Editor branch]
2019-09-26 05:03:53 -04:00
Marcus Wassmer
6517c68ef5 Copying //UE4/Dev-RenderPlat-Staging@8684824 to Dev-Main (//UE4/Dev-Main)
#rb none

[CL 8684840 by Marcus Wassmer in Main branch]
2019-09-14 09:45:25 -04:00
Chris Gagnon
2e87118a18 Copying //UE4/Dev-Editor to Dev-Main (//UE4/Dev-Main) Interim 4.24.
#rb none

[CL 8614014 by Chris Gagnon in Main branch]
2019-09-10 11:35:20 -04:00
jeremy moore
bb630dc0f6 Add support to material interface for querying RVT paramters
Stubbed out material instance implementation for now
Use the new interface in RVT parameter material expressions


#ROBOMERGE-SOURCE: CL 8556897 via CL 8562562
#ROBOMERGE-BOT: (v406-8472469)

[CL 8562734 by jeremy moore in Main branch]
2019-09-06 18:57:30 -04:00
sebastien lussier
f77413a77c Ensure the material proxy is always freed on the correct thread
#rb jeanfrancois.dube


#ROBOMERGE-SOURCE: CL 8362258 via CL 8364673 via CL 8368019
#ROBOMERGE-BOT: (v402-8361577)

[CL 8368177 by sebastien lussier in Main branch]
2019-08-28 20:49:07 -04:00
sebastien lussier
dd3e62a642 HLOD System - Rebuilding Medium HLODs sometimes results in bad textures
* Fixed stale materials in MaterialProxyPool
* Fixed memory leak
#jira UE-78913
[REVIEW] jeanfrancois.dube
[FYI] bryce.lumpkin


#ROBOMERGE-SOURCE: CL 8126046 via CL 8126053 via CL 8131826
#ROBOMERGE-BOT: (v401-8057353)

[CL 8156535 by sebastien lussier in Main branch]
2019-08-21 08:41:52 -04:00
sebastien lussier
01e45757e5 MaterialBaking: Remove cached materials instances from the material proxy pool when changes are made to one of it's parent material
[FYI] bryce.lumpkin


#ROBOMERGE-SOURCE: CL 7629383 via CL 7629384 via CL 7637104
#ROBOMERGE-BOT: (v372-7473910)

[CL 7637265 by sebastien lussier in Main branch]
2019-07-26 13:44:18 -04:00