Commit Graph

7 Commits (a627cda5aeee1c7d2714045f5b58b51b57440393)

Author SHA1 Message Date
santorac a627cda5ae Got the unit tests working again.
I made MaterialAsset::Finalize private so I could add some parameters specifically for MaterialAssetCreator to use. Now MaterialAssetCreator::Begin has an option to finalize the material or not.
Moved MaterialAssetCreatorCommon::ValidateDataType to MaterialPropertyDescriptor as "ValidateMaterialPropertyDataType" so that MaterialAsset::Finalize could use it too

Signed-off-by: santorac <55155825+santorac@users.noreply.github.com>
4 years ago
Ken Pruiksma 97920feaf1
Detail material Id texture created from surface weights. (#4984)
* Added some structs for detail materials

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Added some template functions for looking up materials. Added lookups for all the relevant detail material fields in StandardPBR.

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Added some structs for detail materials

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Added some template functions for looking up materials. Added lookups for all the relevant detail material fields in StandardPBR.

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Added support for generating a detail material texture with IDs populated from surface weights.

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Updated TerrainAreaMaterailRequestBus to have separate calls for region vs materials instead of the awkward out parameter
Update MaterialPropertyDescriptor so that you can retrieve enum names by ID
Several bug fixes / updates to the terrain feature processor dealing with detail materials.

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Updating detail material texture based on offsets. Not quite working yet but close. Added visualization for detail material in shader (currently on, will be turned off before final commit)

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Small bugfixes
* Fix compile error in non-unity builds
* Fixed backwards x/y loops causing the wrong pixels to update
* Fixed selection of surface type with multiple surface weights

Signed-off-by: Mike Balfour <82224783+mbalfour-amzn@users.noreply.github.com>

* Adding seam to detail texture debug display. Offseting edges by a half-pixel to avoid bleed. Disabling debugging detail textures by default.

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Missing file from last commit for detail material change.

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Cleanups

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* bug fix

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Bug fix in the terrain fp for TerrainAreaMaterialRequestBus returning incomplete materials on GetSurfaceMaterialMappings

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Some PR updates. Exposing detail material id debugging through a cvar.

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Various updates from review.

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* PR updates dealing with debug texture boundary line.

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Hiding some fields from the terrain material

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

* Fixing type in generic lambda for linux / android

Signed-off-by: Ken Pruiksma <pruiksma@amazon.com>

Co-authored-by: Mike Balfour <82224783+mbalfour-amzn@users.noreply.github.com>
4 years ago
Steve Pham 38261d0800
Shorten copyright headers by splitting into 2 lines (#2213)
* Updated all copyright headers to split the longer original copyright line into 2 shorter lines

Signed-off-by: Steve Pham <spham@amazon.com>
4 years ago
Steve Pham b4a2edec6a
Final update copyright headers to reference license files at the repo root (#1693)
* Final update copyright headers to reference license files at the repo root

Signed-off-by: spham <spham@amazon.com>

* Fix copyright validator unit tests to support the stale O3DE header scenario

Signed-off-by: spham <spham@amazon.com>
5 years ago
Steve Pham 70042fcdcd
O3DE Copyright Updates for Linux Foundation (#1504) 5 years ago
Chris Santora 53188a12da Made StandardMultilayerPBR hide a layer's property groups when that layer is disabled.
ATOM-14688 Disable Individual Layers

- Added new SetMaterialPropertyGroupVisibility functions to the material functors.
- Updated the MaterialFunctor::EditorContext to include parameters for handling material property group metadata.
- Updated the material inspector(s) to apply the property group visiblity changes from the material functor, to hide or show the property groups.
- Moved some code from MaterialPropertyDescriptor.h/cpp to a new MaterialDynamicMetadata.h/cpp, since these aren't really related to the MaterialPropertyDescriptor code. It's more for material functors to use.
- Also fixed the casing for the "GetMaterialPropertyValue_Image" lua function, since I was already in this code (ATOM-14793 "Fix Inconsistent Casing For LuaMaterialFunctorRuntimeContext")

Tested in MaterialEditor and in in the main Editor's MaterialComponent property override inspector.
5 years ago
alexpete a10351f38d Initial commit 5 years ago