diff --git a/Assets/Material/Base/Natural/.thumbs/138x108/FlatPatch_3x.thumbnail.usd.auto.png b/Assets/Material/Base/Natural/.thumbs/138x108/FlatPatch_3x.thumbnail.usd.auto.png new file mode 100644 index 0000000000000000000000000000000000000000..e7bfd84807125472ab449af20e82ac367d7b8980 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/138x108/FlatPatch_3x.thumbnail.usd.auto.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89017f498b764ae4bdba518b65bdd6321678f806b816c581d55f16a3f310fb5e +size 9627 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Asphalt.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Asphalt.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..779b2126a14f8edaca8da78f3ebddf8cda44ac9b --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Asphalt.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:47a60ca4a9c7720599a5db59e1d84f94d08aa1f471115ad3a1f06ec7982894e4 +size 180855 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Dirt.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Dirt.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..4d0693b18ee23685c9bb7a614cf4605e3cafb584 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Dirt.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7269fdb0116d0707f44137211b4043d9bb84ae9b9f4399c8e8ba474ee8e49d91 +size 212069 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/FlatPatch_3x.thumbnail.usd.auto.png b/Assets/Material/Base/Natural/.thumbs/256x256/FlatPatch_3x.thumbnail.usd.auto.png new file mode 100644 index 0000000000000000000000000000000000000000..7b2876d17eba2b79f85ea85c440c577cab20a51c --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/FlatPatch_3x.thumbnail.usd.auto.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fcbdbbf0cf5a49b01e1766b1874e3d03d5131a7181b9e1ecb6ce843ecf17ff30 +size 33347 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/FlatPatch_3x.thumbnail.usd.png b/Assets/Material/Base/Natural/.thumbs/256x256/FlatPatch_3x.thumbnail.usd.png new file mode 100644 index 0000000000000000000000000000000000000000..6f4fcc68c9cf4b1bd85f3238b9fa4a2b6e5d783d --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/FlatPatch_3x.thumbnail.usd.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5864a24799fe98c368b578a311df1296fd7fb249ab7c7d4c6c0991355f2327ac +size 104753 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Grass_Countryside.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Grass_Countryside.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..2aaf91c9450c2691f7f801b956799efd46f8c954 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Grass_Countryside.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f28b8e6ef69278b7231bb2f366f66d97745e561aa5b52079ece1bade7359df75 +size 169132 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Grass_Cut.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Grass_Cut.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..273178f7a126568019fd5f97a558fa7c8920a870 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Grass_Cut.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3cb0ab05a1aa45b739ecfb562efeb993905cf0529db193c641f01248fac72c21 +size 170292 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Grass_Winter.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Grass_Winter.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..1c24f2ec464c94279392014b39d0e9133b876f24 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Grass_Winter.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:06b19ff90d0a25c8c1400c91a44849d4cc8891d682186a1c67783386f94cdc59 +size 228319 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Leaves.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Leaves.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..a532b81824b24abd20781549b676198253f34821 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Leaves.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f0105598b57962fa2206336776ff66487ac51a89c6af5ee4e595ee523207d5d1 +size 220076 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Mulch_Brown.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Mulch_Brown.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..6c23d67ed64eb90ce6962350b356e0579d1a0139 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Mulch_Brown.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:287221ef021d73866212fa845f6f1f5773b40f7681689616bac923793cad4fdc +size 211359 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Sand.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Sand.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..87e6496956f374b579e93cc8eec8ff12a3202aeb --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Sand.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8ff9db9cd62ddcf46db8f6f3cc961ca2616ca331a8960051b986272ee596028b +size 150336 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Soil_Rocky.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Soil_Rocky.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..bbc9db1dff7d1b605dd7d9c1f00f6be1de6f7d59 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Soil_Rocky.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dfa0743aba7c4ef9a944c66efca32d95a42ec86fa0be2904bb6cc67fc170d51e +size 195737 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Water.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Water.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..08818971a32b04dcf56ea6e9d1205d21639ed301 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Water.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fb290b516b8707430a264556772d9ab30c22f0b0f3f4820e38908ec6cf745133 +size 40281 diff --git a/Assets/Material/Base/Natural/.thumbs/256x256/Water_Opaque.mdl.png b/Assets/Material/Base/Natural/.thumbs/256x256/Water_Opaque.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..68bde0093c58f8bb7a8959f19f1ac889f9396cf9 --- /dev/null +++ b/Assets/Material/Base/Natural/.thumbs/256x256/Water_Opaque.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17470f9d159029d6c4c25f1a7161c3817286e268b57a125e366ce6ae0537bf9d +size 107651 diff --git a/Assets/Material/Base/Natural/Water/.thumbs/138x108/Water_Normal.png.png b/Assets/Material/Base/Natural/Water/.thumbs/138x108/Water_Normal.png.png new file mode 100644 index 0000000000000000000000000000000000000000..7dc0c2d0b04f4f4f770a947aa4c3ff20ec22a385 --- /dev/null +++ b/Assets/Material/Base/Natural/Water/.thumbs/138x108/Water_Normal.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ffd80974f9fa53e1fb31e881d495d4bb7b1fe78911fba58a28df387ffbc0a3fc +size 14337 diff --git a/Assets/Material/Base/Natural/Water/.thumbs/256x256/Water_Normal.png.png b/Assets/Material/Base/Natural/Water/.thumbs/256x256/Water_Normal.png.png new file mode 100644 index 0000000000000000000000000000000000000000..e40e0d14d0df0f4f6a55979dc3b49da4cacfa0d2 --- /dev/null +++ b/Assets/Material/Base/Natural/Water/.thumbs/256x256/Water_Normal.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e9dd61fb1299a71d2d4365c570e7515c4f8d91d0818ac5e22dc6b24f5c75107e +size 68853 diff --git a/Assets/Material/Base/Natural/Water/Water_Normal.png b/Assets/Material/Base/Natural/Water/Water_Normal.png new file mode 100644 index 0000000000000000000000000000000000000000..8313458a6163b68756e71e7d3213db930e230538 --- /dev/null +++ b/Assets/Material/Base/Natural/Water/Water_Normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:af668cd9f0017237cf52ec4e838928f03c66529c7b293a2bf1fa4626fb271892 +size 1647671 diff --git a/Assets/Material/Base/Textiles/.thumbs/138x108/Textiles_Thick.thumbnail.usd.auto.png b/Assets/Material/Base/Textiles/.thumbs/138x108/Textiles_Thick.thumbnail.usd.auto.png new file mode 100644 index 0000000000000000000000000000000000000000..cf967d7ef6877596d3d67eea797d6b5027c46d99 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/138x108/Textiles_Thick.thumbnail.usd.auto.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c7e958e397e078a3e4c32d2f7114d32fb40d80eb7dec8df33d5a1e019696539e +size 9001 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Cloth_Black.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Cloth_Black.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..348e88f3087cbd434f6c4b0d5e4635766db9eec2 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Cloth_Black.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9f5ea823c706b1d44775dae326fe4fb0f6f0f02d0d860cfa0f815a64f31e75d9 +size 68417 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Cloth_Gray.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Cloth_Gray.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..0c0d17a881c31680a37307f529045744a44b65b3 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Cloth_Gray.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8ecb220268eab2653acc3c8f842befa0871d0275f5e0d476e0ab1020e16ad4a0 +size 83900 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Coth_Gray.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Coth_Gray.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..3c6df0dd27b83545e7900832f9aa35feeccb18a3 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Coth_Gray.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:209d83a20967483fea14f8b2b407aec626acac6d89b4a0e8011d5c8a06ab0e39 +size 102916 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Leather_Black.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Leather_Black.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..16fb0c24754766f56bb281f00beef27036a5bead --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Leather_Black.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:85e14b1e13207b691f9b3636cb5e522fc0ec4415bade9b474e246083ec6d130f +size 85705 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Leather_Brown.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Leather_Brown.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..aa7bb12ff8d384cf7130c77cac10c0fc9d31013b --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Leather_Brown.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:33ee9013c84b2705925322fdc717d29cc6257d58d1f6b8ca9959373e2debe086 +size 93399 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Leather_Pumpkin.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Leather_Pumpkin.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..046b1aec964c8954480fc243b00c96eece6eef07 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Leather_Pumpkin.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:337737faa040309acecb7ff531b7a38f437e8379d290fa9a6ad797e4949db39a +size 6099 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Beige.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Beige.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..5c27219e370d59c71b355c47db19ab97edc61414 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Beige.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bec9f63b2bad9bef7ec42724a89cc19e9f5894dbbd4008d35505b0b21ac70e05 +size 82412 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Black.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Black.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..f80d0e9bbf77c2c386b6a97d55c01d26bfcb5812 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Black.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e7b317d7cd37ca99b2ff1d792295a60473f4b9f57ebeb084fe827deb534db73b +size 70371 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Blue.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Blue.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..7a11b23146b73552b18b81326717ab07d80156f9 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Blue.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6cbf301bae1275ff3f8c2e03dd1566285f6edf8112dbff78e3840fb2d30f6bc3 +size 96085 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Brown.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Brown.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..f80d0e9bbf77c2c386b6a97d55c01d26bfcb5812 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_Brown.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e7b317d7cd37ca99b2ff1d792295a60473f4b9f57ebeb084fe827deb534db73b +size 70371 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_White.mdl.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_White.mdl.png new file mode 100644 index 0000000000000000000000000000000000000000..f2bb06fadb79393ce88384f269412c022e8b651f --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Linen_White.mdl.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:36ba2fa26168f268f44515b949289dd2d88d11c3a07258a31948b4d56260a3c3 +size 78037 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Textiles.thumbnail.usd.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Textiles.thumbnail.usd.png new file mode 100644 index 0000000000000000000000000000000000000000..b17197677623c8ce1a9e67070665c40f4a4c4a4d --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Textiles.thumbnail.usd.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b5f4a935d1c2083203326fc800df93f6e39bf4d2e9c614785b15c51e6a3b341 +size 55349 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Textiles_Thick.thumbnail.usd.auto.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Textiles_Thick.thumbnail.usd.auto.png new file mode 100644 index 0000000000000000000000000000000000000000..340f9c5e115ef248d83d37e214fc35acf0ae6930 --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Textiles_Thick.thumbnail.usd.auto.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6b356cb6a5b73b1475056d0013a8b42d8db770613a1f63073dff9974e9182f33 +size 31291 diff --git a/Assets/Material/Base/Textiles/.thumbs/256x256/Textiles_Thick.thumbnail.usd.png b/Assets/Material/Base/Textiles/.thumbs/256x256/Textiles_Thick.thumbnail.usd.png new file mode 100644 index 0000000000000000000000000000000000000000..8aa8e0d000bbd26b331872e56cde140aa1d6020d --- /dev/null +++ b/Assets/Material/Base/Textiles/.thumbs/256x256/Textiles_Thick.thumbnail.usd.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:74e5e7dc43aa5d0ac6eb13de59100f2320c76c8f12645eb77b24fc2d9c952118 +size 58475 diff --git a/Assets/Material/Base/Textiles/Leather_Black/.thumbs/138x108/Leather_Black_BaseColor.png.png b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/138x108/Leather_Black_BaseColor.png.png new file mode 100644 index 0000000000000000000000000000000000000000..bba2bc80fbdccb61b44234c3ec85764224196a2a --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/138x108/Leather_Black_BaseColor.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:53e5dfe393855b65cfa5cf52a1dbb86e57fc35687e90e50cb9dc9c2874a576d1 +size 8516 diff --git a/Assets/Material/Base/Textiles/Leather_Black/.thumbs/138x108/Leather_Black_N.png.png b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/138x108/Leather_Black_N.png.png new file mode 100644 index 0000000000000000000000000000000000000000..2ebde466c1e979f05f729e5676c39f4a4987e0b9 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/138x108/Leather_Black_N.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6ecbb6aef1fae75e91fc0b097dd859fa45c27a4e3ced817ec086fcbac608b01c +size 6726 diff --git a/Assets/Material/Base/Textiles/Leather_Black/.thumbs/138x108/Leather_Black_ORM.png.png b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/138x108/Leather_Black_ORM.png.png new file mode 100644 index 0000000000000000000000000000000000000000..9b43cb53ee7aa929d15aa842b95dcff10c547ed2 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/138x108/Leather_Black_ORM.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4c473290ce0c073b6c3c29c839b5806e7e2ac87b0b2ea4eb1e2c47895709faf0 +size 6615 diff --git a/Assets/Material/Base/Textiles/Leather_Black/.thumbs/256x256/Leather_Black_BaseColor.png.png b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/256x256/Leather_Black_BaseColor.png.png new file mode 100644 index 0000000000000000000000000000000000000000..8943383e967ebd00d6476d1fa99b0d7c69fd452b --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/256x256/Leather_Black_BaseColor.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:51de10ecbef6cb12a3ef4b1041e34a496bf5159933a8573e33cdaaa95e315311 +size 54211 diff --git a/Assets/Material/Base/Textiles/Leather_Black/.thumbs/256x256/Leather_Black_N.png.png b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/256x256/Leather_Black_N.png.png new file mode 100644 index 0000000000000000000000000000000000000000..422750be8be009eb59966ad184cce74a4cb6404f --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/256x256/Leather_Black_N.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6e8037164154a1dc652433f446c9e8b80a1f8d4606e46b6b757a7ed0a12a1eeb +size 51077 diff --git a/Assets/Material/Base/Textiles/Leather_Black/.thumbs/256x256/Leather_Black_ORM.png.png b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/256x256/Leather_Black_ORM.png.png new file mode 100644 index 0000000000000000000000000000000000000000..dcd9030300bea2cdd280a8a2d590cfdf14a1df57 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Black/.thumbs/256x256/Leather_Black_ORM.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:73fc7c8fdc112350e3e00c5aabcc264166f7c78a6d4198b1ee66ce0d98ea3a8c +size 46833 diff --git a/Assets/Material/Base/Textiles/Leather_Black/Leather_Black_BaseColor.png b/Assets/Material/Base/Textiles/Leather_Black/Leather_Black_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..f45a37152a08606a8553790b37aabc327023199e --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Black/Leather_Black_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ec625975acf04611dd213178c5332a915daf3e21a61b62e5c8d6883c69f6f795 +size 24180197 diff --git a/Assets/Material/Base/Textiles/Leather_Black/Leather_Black_N.png b/Assets/Material/Base/Textiles/Leather_Black/Leather_Black_N.png new file mode 100644 index 0000000000000000000000000000000000000000..c0ad308ed0f0e52861b0dfd4ec9f16bd69e5b5eb --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Black/Leather_Black_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f3f45d7ec9be281a55b0967b648887c11a9e4f7a69e5934bd55a7ff55a44acf +size 22560250 diff --git a/Assets/Material/Base/Textiles/Leather_Black/Leather_Black_ORM.png b/Assets/Material/Base/Textiles/Leather_Black/Leather_Black_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..827c9eb5de5d6ea0c5dae0166ca650edf16af9aa --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Black/Leather_Black_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e494958731c917a6ba5c901392aa3bcc4b535aab3e710c4fcdd2902c79dc1227 +size 11860089 diff --git a/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/138x108/Leather_Brown_BaseColor.png.png b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/138x108/Leather_Brown_BaseColor.png.png new file mode 100644 index 0000000000000000000000000000000000000000..e096ef83981c76f814d8ebb30d8180a4c7307fc3 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/138x108/Leather_Brown_BaseColor.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1e59a3b4b7c1c6827832889023b33948fc8edb68efb7ada5072ea04bd7823686 +size 9529 diff --git a/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/138x108/Leather_Brown_N.png.png b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/138x108/Leather_Brown_N.png.png new file mode 100644 index 0000000000000000000000000000000000000000..96bdaac9fb2e2d930451b83e1c35d21bd1dad2a5 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/138x108/Leather_Brown_N.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2dcec2f5e5499031558888b46d2b5b3f21fdc3cea52ae95bac6b7051e6c4c1d6 +size 7931 diff --git a/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/138x108/Leather_Brown_ORM.png.png b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/138x108/Leather_Brown_ORM.png.png new file mode 100644 index 0000000000000000000000000000000000000000..4a317bea0a2747442ef524fb23670610b8fdaabc --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/138x108/Leather_Brown_ORM.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f94888358cef1eaa129170f08f9eafdf0e46e6d2db701b69df9bc6a775f76848 +size 5775 diff --git a/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/256x256/Leather_Brown_BaseColor.png.png b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/256x256/Leather_Brown_BaseColor.png.png new file mode 100644 index 0000000000000000000000000000000000000000..dc8f0b06928c38aba33f6aebdfb8dcf55fc9a76d --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/256x256/Leather_Brown_BaseColor.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:179d310ca88b78cf0242f312937d3939d0cb7dad0d3caa3da3b4e881049ae6bc +size 58251 diff --git a/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/256x256/Leather_Brown_N.png.png b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/256x256/Leather_Brown_N.png.png new file mode 100644 index 0000000000000000000000000000000000000000..d4002931a5a8b742c0cd028b7cb6e824cfeae18d --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/256x256/Leather_Brown_N.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc186469a31fc88c64099c5fc021d6d7432b96aa970266e0fb55343cbb572be2 +size 68035 diff --git a/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/256x256/Leather_Brown_ORM.png.png b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/256x256/Leather_Brown_ORM.png.png new file mode 100644 index 0000000000000000000000000000000000000000..287183da646b19cc345103497933feb13df38d6c --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Brown/.thumbs/256x256/Leather_Brown_ORM.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:14b1411faad45eec693608d19d9bb2d802e38cdeb41d34b5db27ba22d35948bf +size 40423 diff --git a/Assets/Material/Base/Textiles/Leather_Brown/Leather_Brown_BaseColor.png b/Assets/Material/Base/Textiles/Leather_Brown/Leather_Brown_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..35444fca7381f6414b1813d2b7af68ec897c1b67 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Brown/Leather_Brown_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:03612a9987b68f7c2912d85b33470b24bd3a1f2412ae86c1de213f286294e345 +size 6210642 diff --git a/Assets/Material/Base/Textiles/Leather_Brown/Leather_Brown_N.png b/Assets/Material/Base/Textiles/Leather_Brown/Leather_Brown_N.png new file mode 100644 index 0000000000000000000000000000000000000000..a8e564be0f859d0c7f46fdf7fbb64612c8711b63 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Brown/Leather_Brown_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2fb39c1e82b2965699faca4f47d2022573f90c8d03ef6f4a737a119a10ede870 +size 23691175 diff --git a/Assets/Material/Base/Textiles/Leather_Brown/Leather_Brown_ORM.png b/Assets/Material/Base/Textiles/Leather_Brown/Leather_Brown_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..70a8ae9a51e915e6cf303e715dd5294e872d7f96 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Brown/Leather_Brown_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3d6e543d993bb1f4211aac6c3ee6c7bdaf333f361126caa62323e1044b6fa06b +size 4838867 diff --git a/Assets/Material/Base/Textiles/Leather_Pumpkin/.thumbs/138x108/Leather_Pumpkin_BaseColor.png.png b/Assets/Material/Base/Textiles/Leather_Pumpkin/.thumbs/138x108/Leather_Pumpkin_BaseColor.png.png new file mode 100644 index 0000000000000000000000000000000000000000..6c26b5b0bdcf7fd1fa863b68ef409292da93fc7a --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Pumpkin/.thumbs/138x108/Leather_Pumpkin_BaseColor.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:eaf087e3f23e776fdbe20fccfa816bdf6018155c6d0ae84f44938f4e0922b472 +size 7841 diff --git a/Assets/Material/Base/Textiles/Leather_Pumpkin/.thumbs/256x256/Leather_Pumpkin_BaseColor.png.png b/Assets/Material/Base/Textiles/Leather_Pumpkin/.thumbs/256x256/Leather_Pumpkin_BaseColor.png.png new file mode 100644 index 0000000000000000000000000000000000000000..4fac257e13c89f4b39cbb060fe74a40b3e183e14 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Pumpkin/.thumbs/256x256/Leather_Pumpkin_BaseColor.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:56c693b02ce4b0f5685f7e956f9ecff4ef9c1ea8105ee969e852ee62f595cd77 +size 50512 diff --git a/Assets/Material/Base/Textiles/Leather_Pumpkin/Leather_Brown_N.png b/Assets/Material/Base/Textiles/Leather_Pumpkin/Leather_Brown_N.png new file mode 100644 index 0000000000000000000000000000000000000000..a8e564be0f859d0c7f46fdf7fbb64612c8711b63 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Pumpkin/Leather_Brown_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2fb39c1e82b2965699faca4f47d2022573f90c8d03ef6f4a737a119a10ede870 +size 23691175 diff --git a/Assets/Material/Base/Textiles/Leather_Pumpkin/Leather_Brown_ORM.png b/Assets/Material/Base/Textiles/Leather_Pumpkin/Leather_Brown_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..70a8ae9a51e915e6cf303e715dd5294e872d7f96 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Pumpkin/Leather_Brown_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3d6e543d993bb1f4211aac6c3ee6c7bdaf333f361126caa62323e1044b6fa06b +size 4838867 diff --git a/Assets/Material/Base/Textiles/Leather_Pumpkin/Leather_Pumpkin_BaseColor.png b/Assets/Material/Base/Textiles/Leather_Pumpkin/Leather_Pumpkin_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..045765b947084ad0b1e8a39d4dfcf5cc03841977 --- /dev/null +++ b/Assets/Material/Base/Textiles/Leather_Pumpkin/Leather_Pumpkin_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db5d8d6f502c293a2e53df0caf0281cdbd5870572c2c4df0e5ccf15455dc598b +size 2431331 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_BaseColor.png.png b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_BaseColor.png.png new file mode 100644 index 0000000000000000000000000000000000000000..308112984db0435be99cf4e064db171018cc216f --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_BaseColor.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5d69006d753d34e186287fd4fbe977bbb76be2485f4618283985f4621d268f3a +size 13123 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_DN.png.png b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_DN.png.png new file mode 100644 index 0000000000000000000000000000000000000000..7e8309881a1a36acf356da6f3b06662ebece32e1 --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_DN.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:679fdca1276ac596910c42fab724ac3fdd02d5a82977ed822a9abc7977720b85 +size 2466 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_N.png.png b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_N.png.png new file mode 100644 index 0000000000000000000000000000000000000000..3f1d0c9026e122586f0e258dba5967d51c91ef8c --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_N.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0c1ffa77fd043ad797de64764160ec1ec8e259e9149b84a8603862c48d108f2c +size 14401 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_ORM.png.png b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_ORM.png.png new file mode 100644 index 0000000000000000000000000000000000000000..4d68d287acf39b87bc4011f03853820b3d249a0e --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/138x108/Linen_Blue_ORM.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b1ad2c8a774d1ab0cd6fbdccc9e602a176b431261f8ba55e28059c9429b276be +size 3887 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_BaseColor.png.png b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_BaseColor.png.png new file mode 100644 index 0000000000000000000000000000000000000000..1217772a97989e21d306856d73b917fc85e81989 --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_BaseColor.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ecddee52d79a1d57f5c2dde5892daa1fe921f6cd95abbf5772a9f5000bc66520 +size 66461 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_DN.png.png b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_DN.png.png new file mode 100644 index 0000000000000000000000000000000000000000..473708349a0416d52e6b16448101ed3aea767e4b --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_DN.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00dd8486b7545d889a9ab496f1c12bd43a2fd4c4dc8734d839c5a56249b10a06 +size 31441 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_N.png.png b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_N.png.png new file mode 100644 index 0000000000000000000000000000000000000000..1fd5197fb561ce84d927637d79d34bf1d572542c --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_N.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d4555faf446113db7743e4bcde34dfb04de0fc0098bbc055dfb5d3b199a5c3da +size 97594 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_ORM.png.png b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_ORM.png.png new file mode 100644 index 0000000000000000000000000000000000000000..29786a96edc5d630c9a7beb7e4f46b38565992c9 --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/.thumbs/256x256/Linen_Blue_ORM.png.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6199d917b689acec3e2d9e88cc5525eb225474443b5856816788f9c180107363 +size 18455 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_BaseColor.png b/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..84f0c285a0da55315493b8a82dd24af936dd096e --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:879b88c315491d4d5639dfc2078c79648d9db084c592c7603d1ee689de932901 +size 1259856 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_DN.png b/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_DN.png new file mode 100644 index 0000000000000000000000000000000000000000..9d8b38dd5fe17628cea6fbd21a648fc29222932b --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_DN.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01539c4dc33c314a174e508ed54ad4c6e0cec679c94083e77430d23fa18a89db +size 426540 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_N.png b/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_N.png new file mode 100644 index 0000000000000000000000000000000000000000..0dfe9530f4704d4e3272f139123bd3e0cce62a74 --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fa714886c449b08620be0b21d56b49cbc1a65dbe50a0c6011ffd6178e3813e52 +size 1602817 diff --git a/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_ORM.png b/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..bbf0310b47cd7b3dc04deb01aad1d728436a0267 --- /dev/null +++ b/Assets/Material/Base/Textiles/Linen_Blue/Linen_Blue_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:44086ab0178b69e15a1bef7e53aef40fe64f8aa20c21f7b2508862850df898da +size 4872184 diff --git a/Assets/Material/material_0011/Carpet_Forest_BaseColor.png b/Assets/Material/material_0011/Carpet_Forest_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..2eb7a40967d76b446cc66529a0a0788fe93dd7b1 --- /dev/null +++ b/Assets/Material/material_0011/Carpet_Forest_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c190cfb439ce4102f8c9e937683c75f1d80171a5057c4ca259b682601a7c5e9c +size 1162822 diff --git a/Assets/Material/material_0011/Carpet_Forest_Normal.png b/Assets/Material/material_0011/Carpet_Forest_Normal.png new file mode 100644 index 0000000000000000000000000000000000000000..8672a920df4cee45e26e29f784a9116e2085b057 --- /dev/null +++ b/Assets/Material/material_0011/Carpet_Forest_Normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2fa6d833196f8d57f9b5c9271afdd9a8f7c1e85f0513634222b77ababc65e59c +size 12036161 diff --git a/Assets/Material/material_0011/Carpet_Forest_ORM.png b/Assets/Material/material_0011/Carpet_Forest_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..ef8603085a0387d1808496cc730f765d364adfb9 --- /dev/null +++ b/Assets/Material/material_0011/Carpet_Forest_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:92cf3d89aae778188dff99071d86e1c2ef911748c87f0ecec4eb5ef8d8149935 +size 16901 diff --git a/Assets/Material/material_0030/Aluminum_Anodized_BaseColor.png b/Assets/Material/material_0030/Aluminum_Anodized_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..c00f298ce88eb8d6110af2e167b0a00f676dba20 --- /dev/null +++ b/Assets/Material/material_0030/Aluminum_Anodized_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d1d042502d7d94bca13cee10c63ab5b3801fb0a46e26d79169e13f5b9c7b5a31 +size 16903 diff --git a/Assets/Material/material_0030/Aluminum_Anodized_Normal.png b/Assets/Material/material_0030/Aluminum_Anodized_Normal.png new file mode 100644 index 0000000000000000000000000000000000000000..5df7bc7dfc36971b8fa5314b1a98337d2adb46e5 --- /dev/null +++ b/Assets/Material/material_0030/Aluminum_Anodized_Normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6dc1cb1b23a9abd766188a85ccbad1a2639d0a9a334f284e359c6c5d4438608e +size 3321558 diff --git a/Assets/Material/material_0030/Aluminum_Anodized_ORM.png b/Assets/Material/material_0030/Aluminum_Anodized_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..8e7015d41934f1e97892a5ce339e6ab32b629552 --- /dev/null +++ b/Assets/Material/material_0030/Aluminum_Anodized_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:768f2dbb4f702a9624b912b431efd1a6a8e0ff3e93744cf54f3866ef8f7986e9 +size 637843 diff --git a/Assets/Material/material_0039/CorrugatedMetal_BaseColor.png b/Assets/Material/material_0039/CorrugatedMetal_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..c41ba5e6de6789330b59fcb008084ea414b6df9f --- /dev/null +++ b/Assets/Material/material_0039/CorrugatedMetal_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:933e4987d2cebf1884f7695bbe69ce1c6583b54557b0c36673ec905ebb167a81 +size 32529485 diff --git a/Assets/Material/material_0039/CorrugatedMetal_N.png b/Assets/Material/material_0039/CorrugatedMetal_N.png new file mode 100644 index 0000000000000000000000000000000000000000..1d821f93e1300465cb704e7abe0a1a0b7460f309 --- /dev/null +++ b/Assets/Material/material_0039/CorrugatedMetal_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b585a8fffbdf017ed163b44f0ce1aefd49f248663864a0c85596ae8438394ddb +size 4015125 diff --git a/Assets/Material/material_0039/CorrugatedMetal_ORM.png b/Assets/Material/material_0039/CorrugatedMetal_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..25d7af9028350abecad411477ad5007a6289090c --- /dev/null +++ b/Assets/Material/material_0039/CorrugatedMetal_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:938cd40f75116bbadd0131d9215bf4769972b02f331b39d0ed4b7979c52547cf +size 16576860 diff --git a/Assets/Material/material_0052/Paint_Gloss_Finish.mdl b/Assets/Material/material_0052/Paint_Gloss_Finish.mdl new file mode 100644 index 0000000000000000000000000000000000000000..a3ec46f79a0810fc4f5f6eab45e859f66c66077a --- /dev/null +++ b/Assets/Material/material_0052/Paint_Gloss_Finish.mdl @@ -0,0 +1,42 @@ +mdl 1.4; + +import ::OmniPBR::OmniPBR; +import ::tex::gamma_mode; +import ::state::normal; + +export material Paint_Gloss_Finish(*) + = ::OmniPBR::OmniPBR( + diffuse_color_constant: color(0.200000003f, 0.200000003f, 0.200000003f), + diffuse_texture: texture_2d("./Paint_Gloss_Finish_BaseColor.png" /* tag 2107, version 608438266 */, ::tex::gamma_srgb), + albedo_desaturation: 0.f, + albedo_add: 0.f, + albedo_brightness: 1.f, + diffuse_tint: color(1.f, 1.f, 1.f), + reflection_roughness_constant: 0.5f, + reflection_roughness_texture_influence: 1.f, + reflectionroughness_texture: texture_2d(), + metallic_constant: 0.f, + metallic_texture_influence: 0.f, + metallic_texture: texture_2d(), + specular_level: 0.5f, + enable_ORM_texture: true, + ORM_texture: texture_2d("./Paint_Gloss_Finish_ORM.png" /* tag 2109, version 4089275038 */, ::tex::gamma_linear), + ao_to_diffuse: 0.f, + ao_texture: texture_2d(), + enable_emission: false, + emissive_color: color(1.f, 0.100000001f, 0.100000001f), + emissive_mask_texture: texture_2d(), + emissive_intensity: 40.f, + bump_factor: 1.f, + normalmap_texture: texture_2d("./Paint_Gloss_Finish_N.png" /* tag 2111, version 2879886466 */, ::tex::gamma_linear), + detail_bump_factor: 0.300000012f, + detail_normalmap_texture: texture_2d(), + project_uvw: false, + world_or_object: false, + uv_space_index: 0, + texture_translate: 0.f, + texture_rotate: 0.f, + texture_scale: 1.f, + detail_texture_translate: 0.f, + detail_texture_rotate: 0.f, + detail_texture_scale: 1.f); diff --git a/Assets/Material/material_0059/Grass_Countryside_BaseColor.png b/Assets/Material/material_0059/Grass_Countryside_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..f23f5612324d33de2e783877de83947241b8ff89 --- /dev/null +++ b/Assets/Material/material_0059/Grass_Countryside_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9a3e1188aba15180d8b46d4bb7673f1ad36704f8ab68739d9774e7cff7da17c0 +size 6279031 diff --git a/Assets/Material/material_0059/Grass_Countryside_Normal.png b/Assets/Material/material_0059/Grass_Countryside_Normal.png new file mode 100644 index 0000000000000000000000000000000000000000..772181c423e324275a73e71e31fc39a33f92ff7f --- /dev/null +++ b/Assets/Material/material_0059/Grass_Countryside_Normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26e20bd93b3caa3cb7ca9653137fe3e8166bbd55359584f3aec2b505dcc1bbd3 +size 5981151 diff --git a/Assets/Material/material_0059/Grass_Countryside_ORM.png b/Assets/Material/material_0059/Grass_Countryside_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..7f61d852038a3a2a90564d2f234ab2418284a89a --- /dev/null +++ b/Assets/Material/material_0059/Grass_Countryside_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:78a299b2f5806c48d14ca0978fe45e5009e3dbea1507a11f8d463d509e32492f +size 2328727 diff --git a/Assets/Material/material_0061/Grass_Winter.mdl b/Assets/Material/material_0061/Grass_Winter.mdl new file mode 100644 index 0000000000000000000000000000000000000000..009d1b8b5117571f1f0b3ca8ecc66d5132ddef52 --- /dev/null +++ b/Assets/Material/material_0061/Grass_Winter.mdl @@ -0,0 +1,54 @@ +mdl 1.4; + +import ::OmniPBR::OmniPBR; +import ::anno::author; +import ::anno::description; +import ::anno::display_name; +import ::anno::key_words; +import ::anno::version; +import ::tex::gamma_mode; +import ::state::normal; + +export material Grass_Winter(*) +[[ + ::anno::display_name("Omni PBR "), + ::anno::description("Omni PBR, supports ORM textures"), + ::anno::version(1, 0, 0, ""), + ::anno::author("NVIDIA CORPORATION"), + ::anno::key_words(string[]("omni", "PBR", "omniverse", "generic")) +]] + = ::OmniPBR::OmniPBR( + diffuse_color_constant: color(0.200000003f, 0.200000003f, 0.200000003f), + diffuse_texture: texture_2d("./Grass_Winter_baseColor.png" /* tag 2933, version 88122872 */, ::tex::gamma_srgb), + albedo_desaturation: 0.f, + albedo_add: 0.f, + albedo_brightness: 1.f, + diffuse_tint: color(1.f, 1.f, 1.f), + reflection_roughness_constant: 0.5f, + reflection_roughness_texture_influence: 1.f, + reflectionroughness_texture: texture_2d(), + metallic_constant: 0.f, + metallic_texture_influence: 0.f, + metallic_texture: texture_2d(), + specular_level: 0.5f, + enable_ORM_texture: true, + ORM_texture: texture_2d("./Grass_Winter_ORM.png" /* tag 2937, version 3165875713 */, ::tex::gamma_linear), + ao_to_diffuse: 0.f, + ao_texture: texture_2d(), + enable_emission: false, + emissive_color: color(1.f, 0.100000001f, 0.100000001f), + emissive_mask_texture: texture_2d(), + emissive_intensity: 40.f, + bump_factor: 1.f, + normalmap_texture: texture_2d("./Grass_Winter_N.png" /* tag 2935, version 1019261497 */, ::tex::gamma_linear), + detail_bump_factor: 0.300000012f, + detail_normalmap_texture: texture_2d(), + project_uvw: false, + world_or_object: false, + uv_space_index: 0, + texture_translate: 0.f, + texture_rotate: 0.f, + texture_scale: 2.f, + detail_texture_translate: 0.f, + detail_texture_rotate: 0.f, + detail_texture_scale: 1.f); diff --git a/Assets/Material/material_0070/Veneer_OU_Walnut.mdl b/Assets/Material/material_0070/Veneer_OU_Walnut.mdl new file mode 100644 index 0000000000000000000000000000000000000000..0157698887f7d53a0d74bd6973a85742d06cde2b --- /dev/null +++ b/Assets/Material/material_0070/Veneer_OU_Walnut.mdl @@ -0,0 +1,42 @@ +mdl 1.4; + +using ::OmniPBR import OmniPBR; +import ::tex::gamma_mode; +import ::state::normal; + +export material Veneer_OU_Walnut(*) + = OmniPBR( + diffuse_color_constant: color(1.0, 1.0, 1.0), + diffuse_texture: texture_2d("./Veneer_OU_Walnut_BaseColor.png", ::tex::gamma_srgb), + albedo_desaturation: 0.f, + albedo_add: 0.f, + albedo_brightness: 1.f, + diffuse_tint: color(0.768f, 0.491f, 0.321f), //0.941f, 0.447f, 0.161f + reflection_roughness_constant: 0.55, + reflection_roughness_texture_influence: 0.f, + reflectionroughness_texture: texture_2d(), + metallic_constant: 0.0, + metallic_texture_influence: 0.f, + metallic_texture: texture_2d(), + specular_level: 0.5f, + enable_ORM_texture: false, + ORM_texture: texture_2d(), + ao_to_diffuse: 0.f, + ao_texture: texture_2d(), + enable_emission: false, + emissive_color: color(0.0, 0.0, 0.0), + emissive_mask_texture: texture_2d(), + emissive_intensity: 0.0, + bump_factor: 0.9f, + normalmap_texture: texture_2d("./Veneer_OU_Walnut_Normal.png", ::tex::gamma_linear), + detail_bump_factor: 1.f, + detail_normalmap_texture: texture_2d(), + project_uvw: false, + world_or_object: false, + uv_space_index: 0, + texture_translate: 0.f, + texture_rotate: 0.f, + texture_scale: 1.f, + detail_texture_translate: 0.f, + detail_texture_rotate: 0.f, + detail_texture_scale: 1.f); diff --git a/Assets/Material/material_0074/Ceramic_Smooth_Fired_BaseColor.png b/Assets/Material/material_0074/Ceramic_Smooth_Fired_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..571f52a191559a810946ac3da0ee55283ac3f043 --- /dev/null +++ b/Assets/Material/material_0074/Ceramic_Smooth_Fired_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b436030591d20376a09ddbabbd07490491bd2aff87dc4763cb8abdc9f328c874 +size 154429 diff --git a/Assets/Material/material_0074/Ceramic_Smooth_Fired_N.png b/Assets/Material/material_0074/Ceramic_Smooth_Fired_N.png new file mode 100644 index 0000000000000000000000000000000000000000..1226b31dce73955ed172ba7096a4a66d4545901c --- /dev/null +++ b/Assets/Material/material_0074/Ceramic_Smooth_Fired_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:183c92304188527e54c192943bc44e9d2f17af3a546b1c68b64036c778b126a4 +size 14097751 diff --git a/Assets/Material/material_0074/Ceramic_Smooth_Fired_ORM.png b/Assets/Material/material_0074/Ceramic_Smooth_Fired_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..bac3f5207157fd4025c74233c2108a299b64c779 --- /dev/null +++ b/Assets/Material/material_0074/Ceramic_Smooth_Fired_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d1ac9d9106565a9011df2022708deef35d8e9c15ba54b3445912b13fcea19a67 +size 1099987 diff --git a/Assets/Material/material_0079/Granite_Dark_BaseColor.png b/Assets/Material/material_0079/Granite_Dark_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..a39eb0dd8d6f9e199d7fe2d48a5397b4f734555e --- /dev/null +++ b/Assets/Material/material_0079/Granite_Dark_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:837d8425c491fd99637a1fcf79135c8642d3a498903d1449015d8d28b80f6a4f +size 25515276 diff --git a/Assets/Material/material_0079/Granite_Dark_N.png b/Assets/Material/material_0079/Granite_Dark_N.png new file mode 100644 index 0000000000000000000000000000000000000000..9470e095b524abb7cee9c3ee138f608f2dffa6eb --- /dev/null +++ b/Assets/Material/material_0079/Granite_Dark_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d8eb6e2e5ec1c7899c3b373f3fe34d3d35abe730bac71568c9b2d78ee27bff14 +size 154429 diff --git a/Assets/Material/material_0079/Granite_Dark_ORM.png b/Assets/Material/material_0079/Granite_Dark_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..ccbb54bb30812aa4e71f06b27d9f832f0778ad0e --- /dev/null +++ b/Assets/Material/material_0079/Granite_Dark_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e6db86da61750680be67e3088184eef915208555470ca805ba0f70f9af9f23c0 +size 4905197 diff --git a/Assets/Material/material_0080/Granite_Light_BaseColor.png b/Assets/Material/material_0080/Granite_Light_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..353c216343320f40d043735cff606d2ec63e7fbb --- /dev/null +++ b/Assets/Material/material_0080/Granite_Light_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f3d41e45e0ba7141c8e9acddf099e156d956f9dff4d84fb836fe343d6cb9f586 +size 26651798 diff --git a/Assets/Material/material_0080/Granite_Light_N.png b/Assets/Material/material_0080/Granite_Light_N.png new file mode 100644 index 0000000000000000000000000000000000000000..9470e095b524abb7cee9c3ee138f608f2dffa6eb --- /dev/null +++ b/Assets/Material/material_0080/Granite_Light_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d8eb6e2e5ec1c7899c3b373f3fe34d3d35abe730bac71568c9b2d78ee27bff14 +size 154429 diff --git a/Assets/Material/material_0080/Granite_Light_ORM.png b/Assets/Material/material_0080/Granite_Light_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..762702bcab1335dfcbdf3bf666340203a57c2134 --- /dev/null +++ b/Assets/Material/material_0080/Granite_Light_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cada130251cfff673642c590856682442ab810067da49753bc3e62c640b1cf14 +size 5366462 diff --git a/Assets/Material/material_0091/Porcelain_Tile_6_BaseColor.png b/Assets/Material/material_0091/Porcelain_Tile_6_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..30e31758e09ed17f2fc830d53731f636d1b11ce9 --- /dev/null +++ b/Assets/Material/material_0091/Porcelain_Tile_6_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dc41609566cdb44925cc8fa4b5bac3a085aba60876bb25ccf4ccc8c5b12625e7 +size 2314741 diff --git a/Assets/Material/material_0091/Porcelain_Tile_6_N.png b/Assets/Material/material_0091/Porcelain_Tile_6_N.png new file mode 100644 index 0000000000000000000000000000000000000000..cd8fca8d054c30290689905a79c6148be3b3b29d --- /dev/null +++ b/Assets/Material/material_0091/Porcelain_Tile_6_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:168b73ea460ed44a8b8ef5610522cb9715719343bd4ac559a3cf40d5036976bc +size 16867778 diff --git a/Assets/Material/material_0091/Porcelain_Tile_6_ORM.png b/Assets/Material/material_0091/Porcelain_Tile_6_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..36ae1b12ad20f7a00aa521638fa0bc82c688313d --- /dev/null +++ b/Assets/Material/material_0091/Porcelain_Tile_6_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:feafbd9af6af3efcf98e6fcc915b11da77f3908935a4c21be1b2db3a7ca66df3 +size 10605707 diff --git a/Assets/Material/material_0100/Leather_Black_N.png b/Assets/Material/material_0100/Leather_Black_N.png new file mode 100644 index 0000000000000000000000000000000000000000..c0ad308ed0f0e52861b0dfd4ec9f16bd69e5b5eb --- /dev/null +++ b/Assets/Material/material_0100/Leather_Black_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f3f45d7ec9be281a55b0967b648887c11a9e4f7a69e5934bd55a7ff55a44acf +size 22560250 diff --git a/Assets/Material/material_0100/Leather_Black_ORM.png b/Assets/Material/material_0100/Leather_Black_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..827c9eb5de5d6ea0c5dae0166ca650edf16af9aa --- /dev/null +++ b/Assets/Material/material_0100/Leather_Black_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e494958731c917a6ba5c901392aa3bcc4b535aab3e710c4fcdd2902c79dc1227 +size 11860089 diff --git a/Assets/Material/material_0119/Cherry_Planks_BaseColor.png b/Assets/Material/material_0119/Cherry_Planks_BaseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..4901cd6b704a5f06820b33c36876080cd415c9f5 --- /dev/null +++ b/Assets/Material/material_0119/Cherry_Planks_BaseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a5dfe4c67439daf05738b7aa7b6dc0c58ba1db7ca062a47d83b3e503f9e93b0b +size 8694410 diff --git a/Assets/Material/material_0119/Cherry_Planks_N.png b/Assets/Material/material_0119/Cherry_Planks_N.png new file mode 100644 index 0000000000000000000000000000000000000000..a34c63e01080b2c9198ebe1d2f4ea0d0d7736990 --- /dev/null +++ b/Assets/Material/material_0119/Cherry_Planks_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7287ed6a0f98ccf57ddcec960f3437ca317d4c087433c0a24aae7d1c895ce460 +size 10208974 diff --git a/Assets/Material/material_0119/Cherry_Planks_ORM.png b/Assets/Material/material_0119/Cherry_Planks_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..0322a61793a2e0a5d6d818d173ab0b5e4634bed6 --- /dev/null +++ b/Assets/Material/material_0119/Cherry_Planks_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cb5f7eef6a53d9627ce5bf63f79f6af69a56f33e0c19a0ff8fa14648b83a2da9 +size 6095527 diff --git a/Assets/Material/material_0121/Mahogany_N.png b/Assets/Material/material_0121/Mahogany_N.png new file mode 100644 index 0000000000000000000000000000000000000000..683242f24d74977bb6419a27be8a029590026e06 --- /dev/null +++ b/Assets/Material/material_0121/Mahogany_N.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5447912e5279e94d7d636635fd12ca853646167aaadbfc3c70a6aedf3932d5f9 +size 5290194 diff --git a/Assets/Material/material_0121/Mahogany_ORM.png b/Assets/Material/material_0121/Mahogany_ORM.png new file mode 100644 index 0000000000000000000000000000000000000000..d08d1c8ae8e981f780822180a90bbba2905a0fb6 --- /dev/null +++ b/Assets/Material/material_0121/Mahogany_ORM.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:276bf3e7305b492ba3f180c1e4d2ff644a86d5b61454f8a929aae1622fa26b9c +size 6132342 diff --git a/Assets/Material/material_0121/Mahogany_baseColor.png b/Assets/Material/material_0121/Mahogany_baseColor.png new file mode 100644 index 0000000000000000000000000000000000000000..cc5c4b0b485fc371a7f6d94a0c3eaada55fdf2d5 --- /dev/null +++ b/Assets/Material/material_0121/Mahogany_baseColor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6e06d1e2164d68660bd52770ab83a337b24955e8ced339fe86aca9cee6fa2b77 +size 5516438 diff --git a/Assets/Material/material_0140/noise_scratch2.png b/Assets/Material/material_0140/noise_scratch2.png new file mode 100644 index 0000000000000000000000000000000000000000..42575d188fbaa6cd6d8ec9fbfce69d4c52fda2d8 --- /dev/null +++ b/Assets/Material/material_0140/noise_scratch2.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5fa8edb872eff7882e90c5a683d1c4af1b468633acaa720780327fadee91a3ec +size 29801141 diff --git a/Assets/Material/material_0156/noise_scratch2.png b/Assets/Material/material_0156/noise_scratch2.png new file mode 100644 index 0000000000000000000000000000000000000000..42575d188fbaa6cd6d8ec9fbfce69d4c52fda2d8 --- /dev/null +++ b/Assets/Material/material_0156/noise_scratch2.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5fa8edb872eff7882e90c5a683d1c4af1b468633acaa720780327fadee91a3ec +size 29801141 diff --git a/Assets/Material/material_0166/Fabric_Polyester_01.mdl b/Assets/Material/material_0166/Fabric_Polyester_01.mdl new file mode 100644 index 0000000000000000000000000000000000000000..fe1e3f95fd10e524ef2cf5037ab5637364318172 --- /dev/null +++ b/Assets/Material/material_0166/Fabric_Polyester_01.mdl @@ -0,0 +1,177 @@ +mdl 1.8; + +import ::state::normal; +import ::OmniSurface::OmniShared::emission_mode; +import ..::Templates::OmniUber_Automotive::*; +import ::tex::gamma_mode; + +export material Fabric_Polyester_01(*) + = Templates::OmniUber_Automotive::OmniUber_Automotive( + uvs_mode_01: Templates::OmniUber_Automotive::triplanar, + uv_scale_01: float2(2.f), + uv_offset_01: float2(0.f), + uv_offset_time_01: float2(0.f), + uv_rotation_01: 0.f, + triplanar_blend_range_01: 0.5f, + uvs_mode_02: Templates::OmniUber_Automotive::triplanar, + uv_scale_02: float2(1.f), + uv_offset_02: float2(0.f), + uv_offset_time_02: float2(0.f), + uv_rotation_02: 0.f, + triplanar_blend_range_02: 0.5f, + uvs_mode_03: Templates::OmniUber_Automotive::triplanar, + uv_scale_03: float2(0.200000003f), + uv_offset_03: float2(0.f), + uv_offset_time_03: float2(0.f), + uv_rotation_03: 0.f, + triplanar_blend_range_03: 0.5f, + uvs_mode_04: Templates::OmniUber_Automotive::triplanar, + uv_scale_04: float2(1.f), + uv_offset_04: float2(0.f), + uv_offset_time_04: float2(0.f), + uv_rotation_04: 0.f, + triplanar_blend_range_04: 0.5f, + enable_opacity: false, + uv_set_opacity: Templates::OmniUber_Automotive::uv_set_1, + opacity_image: texture_2d(), + opacity_channel: Templates::OmniUber_Automotive::a, + geometry_opacity_threshold: 0.150000006f, + uv_set_layer_0: Templates::OmniUber_Automotive::uv_set_1, + base_color_image: texture_2d("./ov_fabric_polyester_01_basecolor.png", ::tex::gamma_default, ""), + diffuse_reflection_color: color(1.f, 0.999989986f, 0.999989986f), + base_color_scale: 1.f, + base_color_offset: -0.0199999996f, + base_color_desaturation: 0.f, + metalness_image: texture_2d("./ov_fabric_polyester_01_orm.png", ::tex::gamma_linear, ""), + metalness_channel: Templates::OmniUber_Automotive::b, + metalness: 0.f, + specular_reflection_weight: 1.f, + specular_reflection_color: color(1.f, 1.f, 1.f), + cavity_image: texture_2d("./ov_fabric_polyester_01_orm.png", ::tex::gamma_linear, ""), + cavity_channel: Templates::OmniUber_Automotive::r, + roughness_image: texture_2d("./ov_fabric_polyester_01_orm.png", ::tex::gamma_default, ""), + roughness_channel: Templates::OmniUber_Automotive::g, + roughness_u: 1.f, + roughness_range_position: float2(1.f, 0.899999976f), + normal_image: texture_2d("./ov_fabric_polyester_01_normal.png", ::tex::gamma_linear, ""), + normal_flip_green: true, + normal_scale: 1.f, + enable_layer_1: false, + layer_1_order: Templates::OmniUber_Automotive::above, + layer_1_blend_source: Templates::OmniUber_Automotive::texture, + layer_1_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_3, + layer_1_blend_splatmap: texture_2d("./leather_blend_mask_04.png", ::tex::gamma_linear, ""), + layer_1_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_direction: float3(0.f, 1.f, 0.f), + layer_1_blend_axis: Templates::OmniUber_Automotive::y, + layer_1_blend_object_space: true, + layer_1_blend_scale: 1.f, + layer_1_blend_offset: 0.f, + layer_1_blend_primvar_name: "", + layer_1_uv_set_detail: Templates::OmniUber_Automotive::uv_set_1, + layer_1_blend_detail_image: texture_2d(), + layer_1_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_threshold: 1.f, + layer_1_blend_factor_override: 0.f, + uv_set_layer_1: Templates::OmniUber_Automotive::uv_set_1, + layer_1_base_color_image: texture_2d(), + layer_1_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_1_base_color_offset: 0.f, + layer_1_base_color_scale: 1.f, + layer_1_base_color_desaturation: 0.f, + layer_1_metalness_image: texture_2d(), + layer_1_metalness_channel: Templates::OmniUber_Automotive::b, + layer_1_metalness: 1.f, + layer_1_specular_reflection_weight: 1.f, + layer_1_cavity_image: texture_2d(), + layer_1_cavity_channel: Templates::OmniUber_Automotive::r, + layer_1_roughness_image: texture_2d(), + layer_1_roughness_channel: Templates::OmniUber_Automotive::g, + layer_1_roughness_u: 1.f, + layer_1_roughness_range_position: float2(1.f, 0.5f), + layer_1_normal_image: texture_2d(), + layer_1_normal_flip_green: true, + layer_1_normal_scale: 1.f, + enable_layer_2: false, + layer_2_order: Templates::OmniUber_Automotive::above, + layer_2_blend_source: Templates::OmniUber_Automotive::texture, + layer_2_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_splatmap: texture_2d(), + layer_2_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_direction: float3(0.f, 1.f, 0.f), + layer_2_blend_axis: Templates::OmniUber_Automotive::y, + layer_2_blend_object_space: true, + layer_2_blend_scale: 1.f, + layer_2_blend_offset: 0.f, + layer_2_blend_primvar_name: "", + layer_2_uv_set_detail: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_detail_image: texture_2d(), + layer_2_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_threshold: 0.330000013f, + layer_2_blend_factor_override: 0.f, + uv_set_layer_2: Templates::OmniUber_Automotive::uv_set_2, + layer_2_base_color_image: texture_2d(), + layer_2_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_2_base_color_offset: 0.f, + layer_2_base_color_scale: 1.f, + layer_2_base_color_desaturation: 0.f, + layer_2_metalness_image: texture_2d(), + layer_2_metalness_channel: Templates::OmniUber_Automotive::b, + layer_2_metalness: 1.f, + layer_2_specular_reflection_weight: 1.f, + layer_2_cavity_image: texture_2d(), + layer_2_cavity_channel: Templates::OmniUber_Automotive::r, + layer_2_roughness_image: texture_2d(), + layer_2_roughness_channel: Templates::OmniUber_Automotive::g, + layer_2_roughness_u: 1.f, + layer_2_roughness_range_position: float2(1.f, 0.5f), + layer_2_normal_image: texture_2d(), + layer_2_normal_flip_green: true, + layer_2_normal_scale: 1.f, + enable_anisotropy: false, + uv_set_anisotropy: Templates::OmniUber_Automotive::uv_set_1, + anisotropic_roughness_u: 1.f, + anisotropic_roughness_v: 0.25f, + anisotropic_direction_image: texture_2d(), + anisotropic_direction_channel: Templates::OmniUber_Automotive::r, + anisotropic_direction: 0.f, + enable_detail_normal: true, + uv_set_detail_normal: Templates::OmniUber_Automotive::uv_set_2, + uv_set_detail_weight: Templates::OmniUber_Automotive::uv_set_1, + detail_normal_image: texture_2d("./ov_clouds_01_normal.png", ::tex::gamma_linear, ""), + detail_normal_flip_green: true, + detail_normal_scale: 1.f, + detail_normal_weight_image: texture_2d(), + detail_normal_weight_channel: Templates::OmniUber_Automotive::r, + enable_emission: false, + uv_set_emission: Templates::OmniUber_Automotive::uv_set_1, + uv_set_emission_mask: Templates::OmniUber_Automotive::uv_set_1, + emission_image: texture_2d(), + emission_mask_image: texture_2d(), + emission_mode: OmniSurface::OmniShared::emission_lx, + emission_intensity: 1.f, + emission_color: color(1.f, 1.f, 1.f), + emission_use_temperature: false, + emission_temperature: 6500.f, + enable_coat: false, + coat_color: color(1.f, 1.f, 1.f), + coat_mask_image: texture_2d(), + coat_mask_channel: Templates::OmniUber_Automotive::r, + coat_roughness_image: texture_2d(), + coat_roughness_channel: Templates::OmniUber_Automotive::r, + coat_roughness: 0.f, + coat_ior: 1.60000002f, + coat_anisotropy: 0.f, + coat_anisotropy_rotation: 0.f, + coat_affect_color: 0.f, + coat_affect_roughness: 0.f, + coat_normal_image: texture_2d(), + coat_normal_flip_green: true, + uv_set_coat_roughness_normal: Templates::OmniUber_Automotive::uv_set_1, + uv_set_coat_mask: Templates::OmniUber_Automotive::uv_set_1, + enable_flakes: false, + flake_color: color(1.f, 1.f, 1.f), + flake_size: 0.125f, + flakes_density: 0.25f, + flakes_spread: 0.150000006f, + flake_roughness: 0.0500000007f); diff --git a/Assets/Material/material_0170/Fabric_Weave_01.mdl b/Assets/Material/material_0170/Fabric_Weave_01.mdl new file mode 100644 index 0000000000000000000000000000000000000000..5e6a61f719c570793037e9719a7e33fcc0875df5 --- /dev/null +++ b/Assets/Material/material_0170/Fabric_Weave_01.mdl @@ -0,0 +1,177 @@ +mdl 1.8; + +import ::state::normal; +import ::OmniSurface::OmniShared::emission_mode; +import ..::Templates::OmniUber_Automotive::*; +import ::tex::gamma_mode; + +export material Fabric_Weave_01(*) + = Templates::OmniUber_Automotive::OmniUber_Automotive( + uvs_mode_01: Templates::OmniUber_Automotive::triplanar, + uv_scale_01: float2(2.f), + uv_offset_01: float2(0.f), + uv_offset_time_01: float2(0.f), + uv_rotation_01: 0.f, + triplanar_blend_range_01: 0.5f, + uvs_mode_02: Templates::OmniUber_Automotive::triplanar, + uv_scale_02: float2(1.f), + uv_offset_02: float2(0.f), + uv_offset_time_02: float2(0.f), + uv_rotation_02: 0.f, + triplanar_blend_range_02: 0.5f, + uvs_mode_03: Templates::OmniUber_Automotive::triplanar, + uv_scale_03: float2(0.200000003f), + uv_offset_03: float2(0.f), + uv_offset_time_03: float2(0.f), + uv_rotation_03: 0.f, + triplanar_blend_range_03: 0.5f, + uvs_mode_04: Templates::OmniUber_Automotive::triplanar, + uv_scale_04: float2(1.f), + uv_offset_04: float2(0.f), + uv_offset_time_04: float2(0.f), + uv_rotation_04: 0.f, + triplanar_blend_range_04: 0.5f, + enable_opacity: false, + uv_set_opacity: Templates::OmniUber_Automotive::uv_set_1, + opacity_image: texture_2d(), + opacity_channel: Templates::OmniUber_Automotive::a, + geometry_opacity_threshold: 0.150000006f, + uv_set_layer_0: Templates::OmniUber_Automotive::uv_set_1, + base_color_image: texture_2d("./ov_fabric_weave_01_basecolor.png", ::tex::gamma_default, ""), + diffuse_reflection_color: color(0.910891056f, 0.888269484f, 0.790641427f), + base_color_scale: 1.f, + base_color_offset: 0.f, + base_color_desaturation: 0.f, + metalness_image: texture_2d("./ov_fabric_weave_01_orm.png", ::tex::gamma_linear, ""), + metalness_channel: Templates::OmniUber_Automotive::b, + metalness: 0.f, + specular_reflection_weight: 1.f, + specular_reflection_color: color(1.f, 1.f, 1.f), + cavity_image: texture_2d("./ov_fabric_weave_01_orm.png", ::tex::gamma_linear, ""), + cavity_channel: Templates::OmniUber_Automotive::r, + roughness_image: texture_2d("./ov_fabric_weave_01_orm.png", ::tex::gamma_default, ""), + roughness_channel: Templates::OmniUber_Automotive::g, + roughness_u: 1.f, + roughness_range_position: float2(1.f, 0.75f), + normal_image: texture_2d("./ov_fabric_weave_01_normal.png", ::tex::gamma_linear, ""), + normal_flip_green: true, + normal_scale: 1.f, + enable_layer_1: false, + layer_1_order: Templates::OmniUber_Automotive::above, + layer_1_blend_source: Templates::OmniUber_Automotive::texture, + layer_1_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_3, + layer_1_blend_splatmap: texture_2d("./leather_blend_mask_04.png", ::tex::gamma_linear, ""), + layer_1_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_direction: float3(0.f, 1.f, 0.f), + layer_1_blend_axis: Templates::OmniUber_Automotive::y, + layer_1_blend_object_space: true, + layer_1_blend_scale: 1.f, + layer_1_blend_offset: 0.f, + layer_1_blend_primvar_name: "", + layer_1_uv_set_detail: Templates::OmniUber_Automotive::uv_set_1, + layer_1_blend_detail_image: texture_2d(), + layer_1_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_threshold: 1.f, + layer_1_blend_factor_override: 0.f, + uv_set_layer_1: Templates::OmniUber_Automotive::uv_set_1, + layer_1_base_color_image: texture_2d(), + layer_1_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_1_base_color_offset: 0.f, + layer_1_base_color_scale: 1.f, + layer_1_base_color_desaturation: 0.f, + layer_1_metalness_image: texture_2d(), + layer_1_metalness_channel: Templates::OmniUber_Automotive::b, + layer_1_metalness: 1.f, + layer_1_specular_reflection_weight: 1.f, + layer_1_cavity_image: texture_2d(), + layer_1_cavity_channel: Templates::OmniUber_Automotive::r, + layer_1_roughness_image: texture_2d(), + layer_1_roughness_channel: Templates::OmniUber_Automotive::g, + layer_1_roughness_u: 1.f, + layer_1_roughness_range_position: float2(1.f, 0.5f), + layer_1_normal_image: texture_2d(), + layer_1_normal_flip_green: true, + layer_1_normal_scale: 1.f, + enable_layer_2: false, + layer_2_order: Templates::OmniUber_Automotive::above, + layer_2_blend_source: Templates::OmniUber_Automotive::texture, + layer_2_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_splatmap: texture_2d(), + layer_2_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_direction: float3(0.f, 1.f, 0.f), + layer_2_blend_axis: Templates::OmniUber_Automotive::y, + layer_2_blend_object_space: true, + layer_2_blend_scale: 1.f, + layer_2_blend_offset: 0.f, + layer_2_blend_primvar_name: "", + layer_2_uv_set_detail: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_detail_image: texture_2d(), + layer_2_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_threshold: 0.330000013f, + layer_2_blend_factor_override: 0.f, + uv_set_layer_2: Templates::OmniUber_Automotive::uv_set_2, + layer_2_base_color_image: texture_2d(), + layer_2_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_2_base_color_offset: 0.f, + layer_2_base_color_scale: 1.f, + layer_2_base_color_desaturation: 0.f, + layer_2_metalness_image: texture_2d(), + layer_2_metalness_channel: Templates::OmniUber_Automotive::b, + layer_2_metalness: 1.f, + layer_2_specular_reflection_weight: 1.f, + layer_2_cavity_image: texture_2d(), + layer_2_cavity_channel: Templates::OmniUber_Automotive::r, + layer_2_roughness_image: texture_2d(), + layer_2_roughness_channel: Templates::OmniUber_Automotive::g, + layer_2_roughness_u: 1.f, + layer_2_roughness_range_position: float2(1.f, 0.5f), + layer_2_normal_image: texture_2d(), + layer_2_normal_flip_green: true, + layer_2_normal_scale: 1.f, + enable_anisotropy: false, + uv_set_anisotropy: Templates::OmniUber_Automotive::uv_set_1, + anisotropic_roughness_u: 1.f, + anisotropic_roughness_v: 0.25f, + anisotropic_direction_image: texture_2d(), + anisotropic_direction_channel: Templates::OmniUber_Automotive::r, + anisotropic_direction: 0.f, + enable_detail_normal: true, + uv_set_detail_normal: Templates::OmniUber_Automotive::uv_set_2, + uv_set_detail_weight: Templates::OmniUber_Automotive::uv_set_1, + detail_normal_image: texture_2d("./ov_clouds_01_normal.png", ::tex::gamma_linear, ""), + detail_normal_flip_green: true, + detail_normal_scale: 1.f, + detail_normal_weight_image: texture_2d(), + detail_normal_weight_channel: Templates::OmniUber_Automotive::r, + enable_emission: false, + uv_set_emission: Templates::OmniUber_Automotive::uv_set_1, + uv_set_emission_mask: Templates::OmniUber_Automotive::uv_set_1, + emission_image: texture_2d(), + emission_mask_image: texture_2d(), + emission_mode: OmniSurface::OmniShared::emission_lx, + emission_intensity: 1.f, + emission_color: color(1.f, 1.f, 1.f), + emission_use_temperature: false, + emission_temperature: 6500.f, + enable_coat: false, + coat_color: color(1.f, 1.f, 1.f), + coat_mask_image: texture_2d(), + coat_mask_channel: Templates::OmniUber_Automotive::r, + coat_roughness_image: texture_2d(), + coat_roughness_channel: Templates::OmniUber_Automotive::r, + coat_roughness: 0.f, + coat_ior: 1.60000002f, + coat_anisotropy: 0.f, + coat_anisotropy_rotation: 0.f, + coat_affect_color: 0.f, + coat_affect_roughness: 0.f, + coat_normal_image: texture_2d(), + coat_normal_flip_green: true, + uv_set_coat_roughness_normal: Templates::OmniUber_Automotive::uv_set_1, + uv_set_coat_mask: Templates::OmniUber_Automotive::uv_set_1, + enable_flakes: false, + flake_color: color(1.f, 1.f, 1.f), + flake_size: 0.125f, + flakes_density: 0.25f, + flakes_spread: 0.150000006f, + flake_roughness: 0.0500000007f); diff --git a/Assets/Material/material_0193/Leather_Grain_06.mdl b/Assets/Material/material_0193/Leather_Grain_06.mdl new file mode 100644 index 0000000000000000000000000000000000000000..a1ecee1d408ed970ea4aaf7d14056ba685fcd37a --- /dev/null +++ b/Assets/Material/material_0193/Leather_Grain_06.mdl @@ -0,0 +1,177 @@ +mdl 1.8; + +import ::state::normal; +import ::OmniSurface::OmniShared::emission_mode; +import ..::Templates::OmniUber_Automotive::*; +import ::tex::gamma_mode; + +export material Leather_Grain_06(*) + = Templates::OmniUber_Automotive::OmniUber_Automotive( + uvs_mode_01: Templates::OmniUber_Automotive::triplanar, + uv_scale_01: float2(2.f), + uv_offset_01: float2(0.f), + uv_offset_time_01: float2(0.f), + uv_rotation_01: 0.f, + triplanar_blend_range_01: 0.5f, + uvs_mode_02: Templates::OmniUber_Automotive::triplanar, + uv_scale_02: float2(0.075000003f), + uv_offset_02: float2(0.f), + uv_offset_time_02: float2(0.f), + uv_rotation_02: 0.f, + triplanar_blend_range_02: 0.5f, + uvs_mode_03: Templates::OmniUber_Automotive::triplanar, + uv_scale_03: float2(1.f), + uv_offset_03: float2(0.f), + uv_offset_time_03: float2(0.f), + uv_rotation_03: 0.f, + triplanar_blend_range_03: 0.5f, + uvs_mode_04: Templates::OmniUber_Automotive::triplanar, + uv_scale_04: float2(1.f), + uv_offset_04: float2(0.f), + uv_offset_time_04: float2(0.f), + uv_rotation_04: 0.f, + triplanar_blend_range_04: 0.5f, + enable_opacity: false, + uv_set_opacity: Templates::OmniUber_Automotive::uv_set_1, + opacity_image: texture_2d(), + opacity_channel: Templates::OmniUber_Automotive::a, + geometry_opacity_threshold: 0.150000006f, + uv_set_layer_0: Templates::OmniUber_Automotive::uv_set_1, + base_color_image: texture_2d("./ov_leather_J_01_basecolor.png", ::tex::gamma_default, ""), + diffuse_reflection_color: color(0.528052807f, 0.254143178f, 0.076680921f), + base_color_scale: 1.f, + base_color_offset: 0.f, + base_color_desaturation: 0.f, + metalness_image: texture_2d("./ov_leather_J_01_orm.png", ::tex::gamma_linear, ""), + metalness_channel: Templates::OmniUber_Automotive::b, + metalness: 0.f, + specular_reflection_weight: 1.f, + specular_reflection_color: color(1.f, 1.f, 1.f), + cavity_image: texture_2d("./ov_leather_J_01_orm.png", ::tex::gamma_linear, ""), + cavity_channel: Templates::OmniUber_Automotive::r, + roughness_image: texture_2d("./ov_leather_J_01_orm.png", ::tex::gamma_default, ""), + roughness_channel: Templates::OmniUber_Automotive::g, + roughness_u: 1.f, + roughness_range_position: float2(0.949999988f, 0.75f), + normal_image: texture_2d("./ov_leather_J_01_normal.png", ::tex::gamma_linear, ""), + normal_flip_green: true, + normal_scale: 2.f, + enable_layer_1: true, + layer_1_order: Templates::OmniUber_Automotive::above, + layer_1_blend_source: Templates::OmniUber_Automotive::texture, + layer_1_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_2, + layer_1_blend_splatmap: texture_2d("./perlin1.png", ::tex::gamma_linear, ""), + layer_1_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_direction: float3(0.f, 1.f, 0.f), + layer_1_blend_axis: Templates::OmniUber_Automotive::y, + layer_1_blend_object_space: true, + layer_1_blend_scale: 1.f, + layer_1_blend_offset: 0.f, + layer_1_blend_primvar_name: "", + layer_1_uv_set_detail: Templates::OmniUber_Automotive::uv_set_1, + layer_1_blend_detail_image: texture_2d("./noise_scratch2.png", ::tex::gamma_default, ""), + layer_1_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_threshold: 0.159999996f, + layer_1_blend_factor_override: 0.f, + uv_set_layer_1: Templates::OmniUber_Automotive::uv_set_1, + layer_1_base_color_image: texture_2d("./ov_leather_J_01_basecolor.png", ::tex::gamma_default, ""), + layer_1_diffuse_reflection_color: color(0.528052807f, 0.237807542f, 0.0627389625f), + layer_1_base_color_offset: 0.f, + layer_1_base_color_scale: 1.f, + layer_1_base_color_desaturation: 0.f, + layer_1_metalness_image: texture_2d("./ov_leather_J_01_orm.png", ::tex::gamma_default, ""), + layer_1_metalness_channel: Templates::OmniUber_Automotive::b, + layer_1_metalness: 1.f, + layer_1_specular_reflection_weight: 1.f, + layer_1_cavity_image: texture_2d("./ov_leather_J_01_orm.png", ::tex::gamma_default, ""), + layer_1_cavity_channel: Templates::OmniUber_Automotive::r, + layer_1_roughness_image: texture_2d("./ov_leather_J_01_orm.png", ::tex::gamma_default, ""), + layer_1_roughness_channel: Templates::OmniUber_Automotive::g, + layer_1_roughness_u: 1.f, + layer_1_roughness_range_position: float2(0.949999988f, 0.75f), + layer_1_normal_image: texture_2d("./ov_leather_J_01_normal.png", ::tex::gamma_linear, ""), + layer_1_normal_flip_green: true, + layer_1_normal_scale: 2.f, + enable_layer_2: false, + layer_2_order: Templates::OmniUber_Automotive::above, + layer_2_blend_source: Templates::OmniUber_Automotive::texture, + layer_2_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_splatmap: texture_2d(), + layer_2_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_direction: float3(0.f, 1.f, 0.f), + layer_2_blend_axis: Templates::OmniUber_Automotive::y, + layer_2_blend_object_space: true, + layer_2_blend_scale: 1.f, + layer_2_blend_offset: 0.f, + layer_2_blend_primvar_name: "", + layer_2_uv_set_detail: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_detail_image: texture_2d(), + layer_2_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_threshold: 0.330000013f, + layer_2_blend_factor_override: 0.f, + uv_set_layer_2: Templates::OmniUber_Automotive::uv_set_2, + layer_2_base_color_image: texture_2d(), + layer_2_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_2_base_color_offset: 0.f, + layer_2_base_color_scale: 1.f, + layer_2_base_color_desaturation: 0.f, + layer_2_metalness_image: texture_2d(), + layer_2_metalness_channel: Templates::OmniUber_Automotive::b, + layer_2_metalness: 1.f, + layer_2_specular_reflection_weight: 1.f, + layer_2_cavity_image: texture_2d(), + layer_2_cavity_channel: Templates::OmniUber_Automotive::r, + layer_2_roughness_image: texture_2d(), + layer_2_roughness_channel: Templates::OmniUber_Automotive::g, + layer_2_roughness_u: 1.f, + layer_2_roughness_range_position: float2(1.f, 0.5f), + layer_2_normal_image: texture_2d(), + layer_2_normal_flip_green: true, + layer_2_normal_scale: 1.f, + enable_anisotropy: false, + uv_set_anisotropy: Templates::OmniUber_Automotive::uv_set_1, + anisotropic_roughness_u: 1.f, + anisotropic_roughness_v: 0.25f, + anisotropic_direction_image: texture_2d(), + anisotropic_direction_channel: Templates::OmniUber_Automotive::r, + anisotropic_direction: 0.f, + enable_detail_normal: true, + uv_set_detail_normal: Templates::OmniUber_Automotive::uv_set_2, + uv_set_detail_weight: Templates::OmniUber_Automotive::uv_set_1, + detail_normal_image: texture_2d("./ov_clouds_01_normal.png", ::tex::gamma_linear, ""), + detail_normal_flip_green: true, + detail_normal_scale: 1.f, + detail_normal_weight_image: texture_2d(), + detail_normal_weight_channel: Templates::OmniUber_Automotive::r, + enable_emission: false, + uv_set_emission: Templates::OmniUber_Automotive::uv_set_1, + uv_set_emission_mask: Templates::OmniUber_Automotive::uv_set_1, + emission_image: texture_2d(), + emission_mask_image: texture_2d(), + emission_mode: OmniSurface::OmniShared::emission_lx, + emission_intensity: 1.f, + emission_color: color(1.f, 1.f, 1.f), + emission_use_temperature: false, + emission_temperature: 6500.f, + enable_coat: false, + coat_color: color(1.f, 1.f, 1.f), + coat_mask_image: texture_2d(), + coat_mask_channel: Templates::OmniUber_Automotive::r, + coat_roughness_image: texture_2d(), + coat_roughness_channel: Templates::OmniUber_Automotive::r, + coat_roughness: 0.f, + coat_ior: 1.60000002f, + coat_anisotropy: 0.f, + coat_anisotropy_rotation: 0.f, + coat_affect_color: 0.f, + coat_affect_roughness: 0.f, + coat_normal_image: texture_2d(), + coat_normal_flip_green: true, + uv_set_coat_roughness_normal: Templates::OmniUber_Automotive::uv_set_1, + uv_set_coat_mask: Templates::OmniUber_Automotive::uv_set_1, + enable_flakes: false, + flake_color: color(1.f, 1.f, 1.f), + flake_size: 0.125f, + flakes_density: 0.25f, + flakes_spread: 0.150000006f, + flake_roughness: 0.0500000007f); diff --git a/Assets/Material/material_0198/leather_blend_mask_02.png b/Assets/Material/material_0198/leather_blend_mask_02.png new file mode 100644 index 0000000000000000000000000000000000000000..23d6cb66ee853e1f83c62f606c14079ec6dd4d55 --- /dev/null +++ b/Assets/Material/material_0198/leather_blend_mask_02.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:de134de187316eb5dab649639912046d63f3b757171fdbcf3df51bc7c1d2a257 +size 50123227 diff --git a/Assets/Material/material_0198/ov_clouds_01_normal.png b/Assets/Material/material_0198/ov_clouds_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..b0da2618fec86c95eaf970e40f696f0ed4f0f2c1 --- /dev/null +++ b/Assets/Material/material_0198/ov_clouds_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b26fd13e4aec1c3c1cc82460bef994133a4eb845133a761ae845127d5780ac3f +size 21194805 diff --git a/Assets/Material/material_0198/ov_suede_01_basecolor.png b/Assets/Material/material_0198/ov_suede_01_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..e9cd5bfcef0c21922cfb98bf41c65272a5853198 --- /dev/null +++ b/Assets/Material/material_0198/ov_suede_01_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:72157ae368721138fb4bb52c44af0e6565168b6d2d857ca4d4f363a7e07e2615 +size 114624992 diff --git a/Assets/Material/material_0198/ov_suede_01_normal.png b/Assets/Material/material_0198/ov_suede_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..dd85b19727cb62e2f539cdb65a8c5945f3a1cebc --- /dev/null +++ b/Assets/Material/material_0198/ov_suede_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5f4f15ebad687b9e35508b6a4e5fca14a86136c64a8103cf490afb2669f940a4 +size 101838810 diff --git a/Assets/Material/material_0198/ov_suede_01_orm.png b/Assets/Material/material_0198/ov_suede_01_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..d760128f8bdc6fae5fe245ddde5f58eadacc175b --- /dev/null +++ b/Assets/Material/material_0198/ov_suede_01_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0cf037789af19c777e26547ddfbbbd21f472ddccffb5907ae6d0b0bc3fa3573 +size 83411017 diff --git a/Assets/Material/material_0207/ov_metal_a_01_basecolor.png b/Assets/Material/material_0207/ov_metal_a_01_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..aae2f240a639a17c4c8f9dabd47ede8265eed636 --- /dev/null +++ b/Assets/Material/material_0207/ov_metal_a_01_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:da73706b08ee13c26600233f1f1a2d33734e431bd3df1677ae1ebfb6480a96e1 +size 154427 diff --git a/Assets/Material/material_0207/ov_metal_a_01_normal.png b/Assets/Material/material_0207/ov_metal_a_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..e2d2addfa7bf9bde189203430b0b09b732eeaad1 --- /dev/null +++ b/Assets/Material/material_0207/ov_metal_a_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d7da54a8d75accbf1d08b922a13a5b693afd2b35776aea4f871dc871d5a31629 +size 22463078 diff --git a/Assets/Material/material_0207/ov_metal_a_01_orm.png b/Assets/Material/material_0207/ov_metal_a_01_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..ca8399a62d685a3f660d121cb4773ac9060390e4 --- /dev/null +++ b/Assets/Material/material_0207/ov_metal_a_01_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:59302b2d5f64882f7a62c7a88b78de62b39588f44fc3f26f94db2723ba415653 +size 11787191 diff --git a/Assets/Material/material_0215/ov_metal_machine_polished_01_anisotropy_level.png b/Assets/Material/material_0215/ov_metal_machine_polished_01_anisotropy_level.png new file mode 100644 index 0000000000000000000000000000000000000000..7590474efb469b1f337ba62b68eb4268e0ebb9e7 --- /dev/null +++ b/Assets/Material/material_0215/ov_metal_machine_polished_01_anisotropy_level.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e12c7a4f6d64867a4203b4abab2f273cbaf92ff9e2d1b6fb1419bbbb41517ace +size 923053 diff --git a/Assets/Material/material_0215/ov_metal_machine_polished_01_basecolor.png b/Assets/Material/material_0215/ov_metal_machine_polished_01_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..593dbbfe549a041ed64ab1f7452a9b0f01ed9c5c --- /dev/null +++ b/Assets/Material/material_0215/ov_metal_machine_polished_01_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:192caa8d4e97d8ca272fd769a99fe60809ce4faf64fa0fb7dc2e9728b43fa865 +size 60383 diff --git a/Assets/Material/material_0215/ov_metal_machine_polished_01_normal.png b/Assets/Material/material_0215/ov_metal_machine_polished_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..6cdcbe27d3fcc155430bb8c35457e53cab11f36f --- /dev/null +++ b/Assets/Material/material_0215/ov_metal_machine_polished_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a3a4a9587e3bdc5edb108b006cf1db8855422fc3b6dd9753c9ab0eee3402ec9f +size 16099246 diff --git a/Assets/Material/material_0215/ov_metal_machine_polished_01_orm.png b/Assets/Material/material_0215/ov_metal_machine_polished_01_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..c1900e33611f68221544222710069dd8de0d4db6 --- /dev/null +++ b/Assets/Material/material_0215/ov_metal_machine_polished_01_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:62af391657cf05a695787cb417940bdb34ead9dd040151b48d049ff544ec4c5d +size 4733162 diff --git a/Assets/Material/material_0227/Koenigsegg_Emblem_Color_Glazed_Logo_Clearcoat.mdl b/Assets/Material/material_0227/Koenigsegg_Emblem_Color_Glazed_Logo_Clearcoat.mdl new file mode 100644 index 0000000000000000000000000000000000000000..69f1d9884e94b03f0f367caa8c6870f39a4abbd3 --- /dev/null +++ b/Assets/Material/material_0227/Koenigsegg_Emblem_Color_Glazed_Logo_Clearcoat.mdl @@ -0,0 +1,177 @@ +mdl 1.8; + +import ::state::normal; +import ::OmniSurface::OmniShared::emission_mode; +import ..::Templates::OmniUber_Automotive::*; +import ::tex::gamma_mode; + +export material Koenigsegg_Emblem_Color_Glazed_Logo_Clearcoat(*) + = Templates::OmniUber_Automotive::OmniUber_Automotive( + uvs_mode_01: Templates::OmniUber_Automotive::texture_coord_0, + uv_scale_01: float2(1.f), + uv_offset_01: float2(0.f), + uv_offset_time_01: float2(0.f), + uv_rotation_01: 0.f, + triplanar_blend_range_01: 0.5f, + uvs_mode_02: Templates::OmniUber_Automotive::triplanar, + uv_scale_02: float2(1.f), + uv_offset_02: float2(0.f), + uv_offset_time_02: float2(0.f), + uv_rotation_02: 0.f, + triplanar_blend_range_02: 0.5f, + uvs_mode_03: Templates::OmniUber_Automotive::triplanar, + uv_scale_03: float2(1.f), + uv_offset_03: float2(0.f), + uv_offset_time_03: float2(0.f), + uv_rotation_03: 0.f, + triplanar_blend_range_03: 0.5f, + uvs_mode_04: Templates::OmniUber_Automotive::triplanar, + uv_scale_04: float2(1.f), + uv_offset_04: float2(0.f), + uv_offset_time_04: float2(0.f), + uv_rotation_04: 0.f, + triplanar_blend_range_04: 0.5f, + enable_opacity: false, + uv_set_opacity: Templates::OmniUber_Automotive::uv_set_1, + opacity_image: texture_2d(), + opacity_channel: Templates::OmniUber_Automotive::a, + geometry_opacity_threshold: 0.150000006f, + uv_set_layer_0: Templates::OmniUber_Automotive::uv_set_1, + base_color_image: texture_2d("./ov_car_K_emblem_color_glazed_01_basecolor.png", ::tex::gamma_default, ""), + diffuse_reflection_color: color(1.f, 0.999989986f, 0.999989986f), + base_color_scale: 1.f, + base_color_offset: -0.0700000003f, + base_color_desaturation: 0.f, + metalness_image: texture_2d("./ov_car_K_emblem_color_glazed_01_metallic.png", ::tex::gamma_srgb, ""), + metalness_channel: Templates::OmniUber_Automotive::b, + metalness: 0.48999998f, + specular_reflection_weight: 1.f, + specular_reflection_color: color(1.f, 1.f, 1.f), + cavity_image: texture_2d("./ov_car_K_emblem_color_glazed_01_ambientOcclusion.png", ::tex::gamma_default, ""), + cavity_channel: Templates::OmniUber_Automotive::rgb, + roughness_image: texture_2d("./ov_car_K_emblem_color_glazed_01_roughness.png", ::tex::gamma_default, ""), + roughness_channel: Templates::OmniUber_Automotive::rgb, + roughness_u: 1.f, + roughness_range_position: float2(0.f, 0.25f), + normal_image: texture_2d("./ov_car_K_emblem_color_glazed_01_normal.png", ::tex::gamma_linear, ""), + normal_flip_green: false, + normal_scale: 1.f, + enable_layer_1: false, + layer_1_order: Templates::OmniUber_Automotive::above, + layer_1_blend_source: Templates::OmniUber_Automotive::texture, + layer_1_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_1, + layer_1_blend_splatmap: texture_2d(), + layer_1_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_direction: float3(0.f, 1.f, 0.f), + layer_1_blend_axis: Templates::OmniUber_Automotive::y, + layer_1_blend_object_space: true, + layer_1_blend_scale: 1.f, + layer_1_blend_offset: 0.f, + layer_1_blend_primvar_name: "", + layer_1_uv_set_detail: Templates::OmniUber_Automotive::uv_set_1, + layer_1_blend_detail_image: texture_2d(), + layer_1_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_threshold: 0.330000013f, + layer_1_blend_factor_override: 0.f, + uv_set_layer_1: Templates::OmniUber_Automotive::uv_set_1, + layer_1_base_color_image: texture_2d(), + layer_1_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_1_base_color_offset: 0.f, + layer_1_base_color_scale: 1.f, + layer_1_base_color_desaturation: 0.f, + layer_1_metalness_image: texture_2d(), + layer_1_metalness_channel: Templates::OmniUber_Automotive::b, + layer_1_metalness: 1.f, + layer_1_specular_reflection_weight: 1.f, + layer_1_cavity_image: texture_2d(), + layer_1_cavity_channel: Templates::OmniUber_Automotive::r, + layer_1_roughness_image: texture_2d(), + layer_1_roughness_channel: Templates::OmniUber_Automotive::g, + layer_1_roughness_u: 1.f, + layer_1_roughness_range_position: float2(1.f, 0.5f), + layer_1_normal_image: texture_2d(), + layer_1_normal_flip_green: true, + layer_1_normal_scale: 1.f, + enable_layer_2: false, + layer_2_order: Templates::OmniUber_Automotive::above, + layer_2_blend_source: Templates::OmniUber_Automotive::texture, + layer_2_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_splatmap: texture_2d(), + layer_2_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_direction: float3(0.f, 1.f, 0.f), + layer_2_blend_axis: Templates::OmniUber_Automotive::y, + layer_2_blend_object_space: true, + layer_2_blend_scale: 1.f, + layer_2_blend_offset: 0.f, + layer_2_blend_primvar_name: "", + layer_2_uv_set_detail: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_detail_image: texture_2d(), + layer_2_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_threshold: 0.330000013f, + layer_2_blend_factor_override: 0.f, + uv_set_layer_2: Templates::OmniUber_Automotive::uv_set_1, + layer_2_base_color_image: texture_2d(), + layer_2_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_2_base_color_offset: 0.f, + layer_2_base_color_scale: 1.f, + layer_2_base_color_desaturation: 0.f, + layer_2_metalness_image: texture_2d(), + layer_2_metalness_channel: Templates::OmniUber_Automotive::b, + layer_2_metalness: 1.f, + layer_2_specular_reflection_weight: 1.f, + layer_2_cavity_image: texture_2d(), + layer_2_cavity_channel: Templates::OmniUber_Automotive::r, + layer_2_roughness_image: texture_2d(), + layer_2_roughness_channel: Templates::OmniUber_Automotive::g, + layer_2_roughness_u: 1.f, + layer_2_roughness_range_position: float2(1.f, 0.5f), + layer_2_normal_image: texture_2d(), + layer_2_normal_flip_green: true, + layer_2_normal_scale: 1.f, + enable_anisotropy: false, + uv_set_anisotropy: Templates::OmniUber_Automotive::uv_set_1, + anisotropic_roughness_u: 1.f, + anisotropic_roughness_v: 0.25f, + anisotropic_direction_image: texture_2d(), + anisotropic_direction_channel: Templates::OmniUber_Automotive::r, + anisotropic_direction: 0.f, + enable_detail_normal: false, + uv_set_detail_normal: Templates::OmniUber_Automotive::uv_set_1, + uv_set_detail_weight: Templates::OmniUber_Automotive::uv_set_1, + detail_normal_image: texture_2d(), + detail_normal_flip_green: true, + detail_normal_scale: 1.f, + detail_normal_weight_image: texture_2d(), + detail_normal_weight_channel: Templates::OmniUber_Automotive::r, + enable_emission: false, + uv_set_emission: Templates::OmniUber_Automotive::uv_set_1, + uv_set_emission_mask: Templates::OmniUber_Automotive::uv_set_1, + emission_image: texture_2d(), + emission_mask_image: texture_2d(), + emission_mode: OmniSurface::OmniShared::emission_lx, + emission_intensity: 1.f, + emission_color: color(1.f, 1.f, 1.f), + emission_use_temperature: false, + emission_temperature: 6500.f, + enable_coat: true, + coat_color: color(1.f, 1.f, 1.f), + coat_mask_image: texture_2d(), + coat_mask_channel: Templates::OmniUber_Automotive::r, + coat_roughness_image: texture_2d(), + coat_roughness_channel: Templates::OmniUber_Automotive::r, + coat_roughness: 0.0599999987f, + coat_ior: 1.60000002f, + coat_anisotropy: 0.f, + coat_anisotropy_rotation: 0.f, + coat_affect_color: 0.f, + coat_affect_roughness: 0.f, + coat_normal_image: texture_2d(), + coat_normal_flip_green: true, + uv_set_coat_roughness_normal: Templates::OmniUber_Automotive::uv_set_1, + uv_set_coat_mask: Templates::OmniUber_Automotive::uv_set_1, + enable_flakes: true, + flake_color: color(1.f, 0.999989986f, 0.999989986f), + flake_size: 0.199999988f, + flakes_density: 0.329999983f, + flakes_spread: 0.199999988f, + flake_roughness: 0.119999997f); diff --git a/Assets/Material/material_0231/ov_metal_logo_k_basecolor.png b/Assets/Material/material_0231/ov_metal_logo_k_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..49df9a37121be596eadba7eb08480397c0d2c8c9 --- /dev/null +++ b/Assets/Material/material_0231/ov_metal_logo_k_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a3e7e86c01fc3b6277278c1fcc25b1ddf50b22b1672596d5b0a6f2c10082bfbc +size 35167570 diff --git a/Assets/Material/material_0231/ov_metal_logo_k_normal.png b/Assets/Material/material_0231/ov_metal_logo_k_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..b422f12002437c9de6379440ea58571c2253ddda --- /dev/null +++ b/Assets/Material/material_0231/ov_metal_logo_k_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3ac8fc347197f01dddd0a6d61b4b886a0d87bb49aac4cf32417ec9071def3d25 +size 105160173 diff --git a/Assets/Material/material_0231/ov_metal_logo_k_orm.png b/Assets/Material/material_0231/ov_metal_logo_k_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..2b0e2d1c5dd2d2a20901f910ad824d2ef70c1c30 --- /dev/null +++ b/Assets/Material/material_0231/ov_metal_logo_k_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b3100bfb48ba9a965ca7ff4cae9ed31bf5e1ac2e5f01b19cd8873f47d731c20 +size 40197695 diff --git a/Assets/Material/material_0233/ov_clouds_01_normal.png b/Assets/Material/material_0233/ov_clouds_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..b0da2618fec86c95eaf970e40f696f0ed4f0f2c1 --- /dev/null +++ b/Assets/Material/material_0233/ov_clouds_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b26fd13e4aec1c3c1cc82460bef994133a4eb845133a761ae845127d5780ac3f +size 21194805 diff --git a/Assets/Material/material_0233/ov_plastic_grain_a_01_anisotropylevel.png b/Assets/Material/material_0233/ov_plastic_grain_a_01_anisotropylevel.png new file mode 100644 index 0000000000000000000000000000000000000000..53d43b05edc25f86e4e61f12383aac305ecc55ef --- /dev/null +++ b/Assets/Material/material_0233/ov_plastic_grain_a_01_anisotropylevel.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:090a1e76194baed83f992e4ebba8d91e65e97ce08eedac96183719370cf7d97c +size 7929444 diff --git a/Assets/Material/material_0233/ov_plastic_grain_a_01_basecolor.png b/Assets/Material/material_0233/ov_plastic_grain_a_01_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..f81d46b5334e9e988c43967b190e90fd6d0cd6e4 --- /dev/null +++ b/Assets/Material/material_0233/ov_plastic_grain_a_01_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20161e1195084384c2c0a8b13f9484e5b4efee62a94da6d4fffea4f2ec68e82b +size 60384 diff --git a/Assets/Material/material_0233/ov_plastic_grain_a_01_normal.png b/Assets/Material/material_0233/ov_plastic_grain_a_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..3ff744a125ce18b5a9051543734e7af8caf01095 --- /dev/null +++ b/Assets/Material/material_0233/ov_plastic_grain_a_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6b75d1d261325394d530183338b25fd891b00ca39cd7d3686409caec7dc205fd +size 3686756 diff --git a/Assets/Material/material_0233/ov_plastic_grain_a_01_orm.png b/Assets/Material/material_0233/ov_plastic_grain_a_01_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..4598dceb5d5e013c3e0ed11efd6798a26fce2176 --- /dev/null +++ b/Assets/Material/material_0233/ov_plastic_grain_a_01_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1d7a557aaf22f2141775d1c4b3637f4439769cf9203d1d453592af25dcd1698d +size 6292205 diff --git a/Assets/Material/material_0235/ov_clouds_01_normal.png b/Assets/Material/material_0235/ov_clouds_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..b0da2618fec86c95eaf970e40f696f0ed4f0f2c1 --- /dev/null +++ b/Assets/Material/material_0235/ov_clouds_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b26fd13e4aec1c3c1cc82460bef994133a4eb845133a761ae845127d5780ac3f +size 21194805 diff --git a/Assets/Material/material_0235/ov_plastic_grain_c_01_basecolor.png b/Assets/Material/material_0235/ov_plastic_grain_c_01_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..80951aa95a2ee6e7e46106964eee36da893c3ea8 --- /dev/null +++ b/Assets/Material/material_0235/ov_plastic_grain_c_01_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6a9e43eff687580d7659a39e989d8a0050d0fcf946a459ee57346d707475b28a +size 60383 diff --git a/Assets/Material/material_0235/ov_plastic_grain_c_01_normal.png b/Assets/Material/material_0235/ov_plastic_grain_c_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..8d2750c2f2ea4f0a8a2031185ec30d8297381ff6 --- /dev/null +++ b/Assets/Material/material_0235/ov_plastic_grain_c_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4c8836d64e3885717b417411076af567ffa68c9c41452afae4a45d0ca8076d1e +size 27682902 diff --git a/Assets/Material/material_0235/ov_plastic_grain_c_01_orm.png b/Assets/Material/material_0235/ov_plastic_grain_c_01_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..9dd9ae54692a6dc9ebb37ca09e8210207e9f5992 --- /dev/null +++ b/Assets/Material/material_0235/ov_plastic_grain_c_01_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c5fb6839d7ba6b0af52dc34997a45619b9a6bfb4a3e9f649c26affcd44c3dc02 +size 8471829 diff --git a/Assets/Material/material_0244/Reflectors_01_Glow_Yellow.mdl b/Assets/Material/material_0244/Reflectors_01_Glow_Yellow.mdl new file mode 100644 index 0000000000000000000000000000000000000000..5a177e9d7099ad1ee174bbf05e24dee81284a80d --- /dev/null +++ b/Assets/Material/material_0244/Reflectors_01_Glow_Yellow.mdl @@ -0,0 +1,177 @@ +mdl 1.8; + +import ::state::normal; +import ::OmniSurface::OmniShared::emission_mode; +import ..::Templates::OmniUber_Automotive::*; +import ::tex::gamma_mode; + +export material Reflectors_01_Glow_Yellow(*) + = Templates::OmniUber_Automotive::OmniUber_Automotive( + uvs_mode_01: Templates::OmniUber_Automotive::texture_coord_0, + uv_scale_01: float2(1.f), + uv_offset_01: float2(0.f), + uv_offset_time_01: float2(0.f), + uv_rotation_01: 0.f, + triplanar_blend_range_01: 0.f, + uvs_mode_02: Templates::OmniUber_Automotive::texture_coord_0, + uv_scale_02: float2(1.f), + uv_offset_02: float2(0.f), + uv_offset_time_02: float2(0.f), + uv_rotation_02: 0.f, + triplanar_blend_range_02: 0.f, + uvs_mode_03: Templates::OmniUber_Automotive::texture_coord_0, + uv_scale_03: float2(1.f), + uv_offset_03: float2(0.f), + uv_offset_time_03: float2(0.f), + uv_rotation_03: 0.f, + triplanar_blend_range_03: 0.f, + uvs_mode_04: Templates::OmniUber_Automotive::texture_coord_0, + uv_scale_04: float2(1.f), + uv_offset_04: float2(0.f), + uv_offset_time_04: float2(0.f), + uv_rotation_04: 0.f, + triplanar_blend_range_04: 0.f, + enable_opacity: false, + uv_set_opacity: Templates::OmniUber_Automotive::uv_set_1, + opacity_image: texture_2d(), + opacity_channel: Templates::OmniUber_Automotive::a, + geometry_opacity_threshold: 0.150000006f, + uv_set_layer_0: Templates::OmniUber_Automotive::uv_set_1, + base_color_image: texture_2d("./ov_reflectors_pattern_01_basecolor.png", ::tex::gamma_default, ""), + diffuse_reflection_color: color(1.f, 0.435643554f, 0.f), + base_color_scale: 1.f, + base_color_offset: 0.f, + base_color_desaturation: 0.f, + metalness_image: texture_2d("./ov_reflectors_pattern_01_orm.png", ::tex::gamma_linear, ""), + metalness_channel: Templates::OmniUber_Automotive::b, + metalness: 0.5f, + specular_reflection_weight: 1.f, + specular_reflection_color: color(1.f, 1.f, 1.f), + cavity_image: texture_2d("./ov_reflectors_pattern_01_orm.png", ::tex::gamma_linear, ""), + cavity_channel: Templates::OmniUber_Automotive::r, + roughness_image: texture_2d("./ov_reflectors_pattern_01_orm.png", ::tex::gamma_default, ""), + roughness_channel: Templates::OmniUber_Automotive::g, + roughness_u: 1.f, + roughness_range_position: float2(0.f, 0.125f), + normal_image: texture_2d("./ov_reflectors_pattern_01_normal.png", ::tex::gamma_linear, ""), + normal_flip_green: true, + normal_scale: 1.f, + enable_layer_1: false, + layer_1_order: Templates::OmniUber_Automotive::above, + layer_1_blend_source: Templates::OmniUber_Automotive::texture, + layer_1_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_1, + layer_1_blend_splatmap: texture_2d(), + layer_1_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_direction: float3(0.f, 1.f, 0.f), + layer_1_blend_axis: Templates::OmniUber_Automotive::y, + layer_1_blend_object_space: true, + layer_1_blend_scale: 1.f, + layer_1_blend_offset: 0.f, + layer_1_blend_primvar_name: "", + layer_1_uv_set_detail: Templates::OmniUber_Automotive::uv_set_1, + layer_1_blend_detail_image: texture_2d(), + layer_1_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_threshold: 0.330000013f, + layer_1_blend_factor_override: 0.f, + uv_set_layer_1: Templates::OmniUber_Automotive::uv_set_1, + layer_1_base_color_image: texture_2d(), + layer_1_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_1_base_color_offset: 0.f, + layer_1_base_color_scale: 1.f, + layer_1_base_color_desaturation: 0.f, + layer_1_metalness_image: texture_2d(), + layer_1_metalness_channel: Templates::OmniUber_Automotive::b, + layer_1_metalness: 1.f, + layer_1_specular_reflection_weight: 1.f, + layer_1_cavity_image: texture_2d(), + layer_1_cavity_channel: Templates::OmniUber_Automotive::r, + layer_1_roughness_image: texture_2d(), + layer_1_roughness_channel: Templates::OmniUber_Automotive::g, + layer_1_roughness_u: 1.f, + layer_1_roughness_range_position: float2(0.949999988f, 0.5f), + layer_1_normal_image: texture_2d(), + layer_1_normal_flip_green: true, + layer_1_normal_scale: 1.f, + enable_layer_2: false, + layer_2_order: Templates::OmniUber_Automotive::above, + layer_2_blend_source: Templates::OmniUber_Automotive::texture, + layer_2_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_splatmap: texture_2d(), + layer_2_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_direction: float3(0.f, 1.f, 0.f), + layer_2_blend_axis: Templates::OmniUber_Automotive::y, + layer_2_blend_object_space: true, + layer_2_blend_scale: 1.f, + layer_2_blend_offset: 0.f, + layer_2_blend_primvar_name: "", + layer_2_uv_set_detail: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_detail_image: texture_2d(), + layer_2_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_threshold: 0.330000013f, + layer_2_blend_factor_override: 0.f, + uv_set_layer_2: Templates::OmniUber_Automotive::uv_set_2, + layer_2_base_color_image: texture_2d(), + layer_2_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_2_base_color_offset: 0.f, + layer_2_base_color_scale: 1.f, + layer_2_base_color_desaturation: 0.f, + layer_2_metalness_image: texture_2d(), + layer_2_metalness_channel: Templates::OmniUber_Automotive::b, + layer_2_metalness: 1.f, + layer_2_specular_reflection_weight: 1.f, + layer_2_cavity_image: texture_2d(), + layer_2_cavity_channel: Templates::OmniUber_Automotive::r, + layer_2_roughness_image: texture_2d(), + layer_2_roughness_channel: Templates::OmniUber_Automotive::g, + layer_2_roughness_u: 1.f, + layer_2_roughness_range_position: float2(1.f, 0.5f), + layer_2_normal_image: texture_2d(), + layer_2_normal_flip_green: true, + layer_2_normal_scale: 1.f, + enable_anisotropy: false, + uv_set_anisotropy: Templates::OmniUber_Automotive::uv_set_1, + anisotropic_roughness_u: 1.f, + anisotropic_roughness_v: 0.25f, + anisotropic_direction_image: texture_2d(), + anisotropic_direction_channel: Templates::OmniUber_Automotive::r, + anisotropic_direction: 0.f, + enable_detail_normal: false, + uv_set_detail_normal: Templates::OmniUber_Automotive::uv_set_1, + uv_set_detail_weight: Templates::OmniUber_Automotive::uv_set_1, + detail_normal_image: texture_2d(), + detail_normal_flip_green: true, + detail_normal_scale: 1.f, + detail_normal_weight_image: texture_2d(), + detail_normal_weight_channel: Templates::OmniUber_Automotive::r, + enable_emission: true, + uv_set_emission: Templates::OmniUber_Automotive::uv_set_1, + uv_set_emission_mask: Templates::OmniUber_Automotive::uv_set_1, + emission_image: texture_2d("./ov_reflectors_pattern_01_mask.png", ::tex::gamma_srgb, ""), + emission_mask_image: texture_2d(), + emission_mode: OmniSurface::OmniShared::emission_lx, + emission_intensity: 60000.f, + emission_color: color(1.f, 0.13861382f, 0.f), + emission_use_temperature: false, + emission_temperature: 6500.f, + enable_coat: false, + coat_color: color(1.f, 1.f, 1.f), + coat_mask_image: texture_2d(), + coat_mask_channel: Templates::OmniUber_Automotive::r, + coat_roughness_image: texture_2d(), + coat_roughness_channel: Templates::OmniUber_Automotive::r, + coat_roughness: 0.f, + coat_ior: 1.60000002f, + coat_anisotropy: 0.f, + coat_anisotropy_rotation: 0.f, + coat_affect_color: 0.f, + coat_affect_roughness: 0.f, + coat_normal_image: texture_2d(), + coat_normal_flip_green: true, + uv_set_coat_roughness_normal: Templates::OmniUber_Automotive::uv_set_1, + uv_set_coat_mask: Templates::OmniUber_Automotive::uv_set_1, + enable_flakes: false, + flake_color: color(1.f, 1.f, 1.f), + flake_size: 0.125f, + flakes_density: 0.25f, + flakes_spread: 0.150000006f, + flake_roughness: 0.0500000007f); diff --git a/Assets/Material/material_0245/ov_reflectors_pattern_02_basecolor.png b/Assets/Material/material_0245/ov_reflectors_pattern_02_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..935d5d9072776bbbcbe7b0595dae1d6327a71474 --- /dev/null +++ b/Assets/Material/material_0245/ov_reflectors_pattern_02_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20666fc885dc66c3f7492baf6b2ef94b7e72fde31edf3b55f458578510491c24 +size 231021 diff --git a/Assets/Material/material_0245/ov_reflectors_pattern_02_normal.png b/Assets/Material/material_0245/ov_reflectors_pattern_02_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..3b1551c188fff71e3eeca725f8494506f7310430 --- /dev/null +++ b/Assets/Material/material_0245/ov_reflectors_pattern_02_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:559285217eaa33ef2a864bd3d32f431c2febd617976d61ff2d489395a12cc3c9 +size 4675834 diff --git a/Assets/Material/material_0245/ov_reflectors_pattern_02_orm.png b/Assets/Material/material_0245/ov_reflectors_pattern_02_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..8fcf8fca904e66f1a452f630d76ffba6724847aa --- /dev/null +++ b/Assets/Material/material_0245/ov_reflectors_pattern_02_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:037a6f65f77ea3f3d60901091dc877fde3d1762521b6de592e8fb589ef676d04 +size 16736325 diff --git a/Assets/Material/material_0250/ov_reflectors_pattern_01_basecolor.png b/Assets/Material/material_0250/ov_reflectors_pattern_01_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..935d5d9072776bbbcbe7b0595dae1d6327a71474 --- /dev/null +++ b/Assets/Material/material_0250/ov_reflectors_pattern_01_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20666fc885dc66c3f7492baf6b2ef94b7e72fde31edf3b55f458578510491c24 +size 231021 diff --git a/Assets/Material/material_0250/ov_reflectors_pattern_01_normal.png b/Assets/Material/material_0250/ov_reflectors_pattern_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..c0f9f019368e78f3c98ae35a96f49f9f354db03b --- /dev/null +++ b/Assets/Material/material_0250/ov_reflectors_pattern_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:68541b96e46dcfd4dcbc7e3fb0fcf32f1c5d842ac25c4db2d8396ac68a566c7d +size 3129795 diff --git a/Assets/Material/material_0250/ov_reflectors_pattern_01_orm.png b/Assets/Material/material_0250/ov_reflectors_pattern_01_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..b8a9c0f3f4fd841d3dc92f1ca440b09583b4d021 --- /dev/null +++ b/Assets/Material/material_0250/ov_reflectors_pattern_01_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6d697b8ffe7b4d298c7091b5eba48f358761efe3f29da1cdff6ae288ce093f52 +size 16736324 diff --git a/Assets/Material/material_0255/noise_scratch2.png b/Assets/Material/material_0255/noise_scratch2.png new file mode 100644 index 0000000000000000000000000000000000000000..42575d188fbaa6cd6d8ec9fbfce69d4c52fda2d8 --- /dev/null +++ b/Assets/Material/material_0255/noise_scratch2.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5fa8edb872eff7882e90c5a683d1c4af1b468633acaa720780327fadee91a3ec +size 29801141 diff --git a/Assets/Material/material_0267/ov_tire_rubber_01_basecolor.png b/Assets/Material/material_0267/ov_tire_rubber_01_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..c6b1b130fb92a8f99b5b8c1046ca7296e7ad8585 --- /dev/null +++ b/Assets/Material/material_0267/ov_tire_rubber_01_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ea7abcb525d365e7a2305b931dcd88bacbc3fe008e988def4e32610d002180f4 +size 231020 diff --git a/Assets/Material/material_0267/ov_tire_rubber_01_normal.png b/Assets/Material/material_0267/ov_tire_rubber_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..52eda925040efd4bb74ed33c7bd7b3c101acd4f7 --- /dev/null +++ b/Assets/Material/material_0267/ov_tire_rubber_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ef3c4aad393ad915480d788d2fab0504775a377732b0fa89c217190d097df8ae +size 107167709 diff --git a/Assets/Material/material_0267/ov_tire_rubber_01_orm.png b/Assets/Material/material_0267/ov_tire_rubber_01_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..a07117bea327d0887963a4b627d66a11a82152d1 --- /dev/null +++ b/Assets/Material/material_0267/ov_tire_rubber_01_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ace5e3beef99190ac59a3a2b917fc2502c53facb6b35f493344011de27b381ec +size 34186526 diff --git a/Assets/Material/material_0275/ov_clouds_01_normal.png b/Assets/Material/material_0275/ov_clouds_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..b0da2618fec86c95eaf970e40f696f0ed4f0f2c1 --- /dev/null +++ b/Assets/Material/material_0275/ov_clouds_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b26fd13e4aec1c3c1cc82460bef994133a4eb845133a761ae845127d5780ac3f +size 21194805 diff --git a/Assets/Material/material_0275/ov_tire_rubber_trim_truck_02_sbs_basecolor.png b/Assets/Material/material_0275/ov_tire_rubber_trim_truck_02_sbs_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..70b59872a7ffe4460ee7ac44c12e709d342ddd20 --- /dev/null +++ b/Assets/Material/material_0275/ov_tire_rubber_trim_truck_02_sbs_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9d22561fc67dbc61d6591998b26eb9e744f8d71035d67e397cef79de68a0ab30 +size 58850584 diff --git a/Assets/Material/material_0275/ov_tire_rubber_trim_truck_02_sbs_normal.png b/Assets/Material/material_0275/ov_tire_rubber_trim_truck_02_sbs_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..949ab9119eed5e925c4c2e10bdf6ae183ca71111 --- /dev/null +++ b/Assets/Material/material_0275/ov_tire_rubber_trim_truck_02_sbs_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f1346e9e7c35482ad6acb15d4b2825ec7fa6005fd59e205b001582f749e35ac1 +size 438749021 diff --git a/Assets/Material/material_0275/ov_tire_rubber_trim_truck_02_sbs_orm.png b/Assets/Material/material_0275/ov_tire_rubber_trim_truck_02_sbs_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..483f2157763d957a58ecd36883b80f347c961573 --- /dev/null +++ b/Assets/Material/material_0275/ov_tire_rubber_trim_truck_02_sbs_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8c8449c5a9d4ae412dfac1fe5763902f48f6ee35f2d6a4f301f61e3fdd4d9320 +size 113822400 diff --git a/Assets/Material/material_0282/Wood_Grain_Raw_04.mdl b/Assets/Material/material_0282/Wood_Grain_Raw_04.mdl new file mode 100644 index 0000000000000000000000000000000000000000..f4e2e95d6ef2cdf45c2478cd4d4733a4ce99179f --- /dev/null +++ b/Assets/Material/material_0282/Wood_Grain_Raw_04.mdl @@ -0,0 +1,177 @@ +mdl 1.8; + +import ::state::normal; +import ::OmniSurface::OmniShared::emission_mode; +import ..::Templates::OmniUber_Automotive::*; +import ::tex::gamma_mode; + +export material Wood_Grain_Raw_04(*) + = Templates::OmniUber_Automotive::OmniUber_Automotive( + uvs_mode_01: Templates::OmniUber_Automotive::triplanar, + uv_scale_01: float2(2.5f), + uv_offset_01: float2(0.f), + uv_offset_time_01: float2(0.f), + uv_rotation_01: 0.f, + triplanar_blend_range_01: 0.f, + uvs_mode_02: Templates::OmniUber_Automotive::triplanar, + uv_scale_02: float2(0.0500000007f), + uv_offset_02: float2(0.f), + uv_offset_time_02: float2(0.f), + uv_rotation_02: 0.f, + triplanar_blend_range_02: 0.5f, + uvs_mode_03: Templates::OmniUber_Automotive::triplanar, + uv_scale_03: float2(1.f), + uv_offset_03: float2(0.f), + uv_offset_time_03: float2(0.f), + uv_rotation_03: 0.f, + triplanar_blend_range_03: 0.5f, + uvs_mode_04: Templates::OmniUber_Automotive::triplanar, + uv_scale_04: float2(1.f), + uv_offset_04: float2(0.f), + uv_offset_time_04: float2(0.f), + uv_rotation_04: 0.f, + triplanar_blend_range_04: 0.5f, + enable_opacity: false, + uv_set_opacity: Templates::OmniUber_Automotive::uv_set_1, + opacity_image: texture_2d(), + opacity_channel: Templates::OmniUber_Automotive::a, + geometry_opacity_threshold: 0.150000006f, + uv_set_layer_0: Templates::OmniUber_Automotive::uv_set_1, + base_color_image: texture_2d("./ov_wood_grain_d_01_basecolor.png", ::tex::gamma_default, ""), + diffuse_reflection_color: color(1.f, 0.999989986f, 0.999989986f), + base_color_scale: 1.25999999f, + base_color_offset: 0.f, + base_color_desaturation: 0.269999981f, + metalness_image: texture_2d("./ov_wood_grain_d_01_orm.png", ::tex::gamma_linear, ""), + metalness_channel: Templates::OmniUber_Automotive::b, + metalness: 0.f, + specular_reflection_weight: 1.f, + specular_reflection_color: color(1.f, 1.f, 1.f), + cavity_image: texture_2d("./ov_wood_grain_d_01_orm.png", ::tex::gamma_linear, ""), + cavity_channel: Templates::OmniUber_Automotive::r, + roughness_image: texture_2d("./ov_wood_grain_d_01_orm.png", ::tex::gamma_default, ""), + roughness_channel: Templates::OmniUber_Automotive::g, + roughness_u: 1.f, + roughness_range_position: float2(0.850000024f, 0.649999976f), + normal_image: texture_2d("./ov_wood_grain_d_01_normal.png", ::tex::gamma_linear, ""), + normal_flip_green: true, + normal_scale: 1.f, + enable_layer_1: false, + layer_1_order: Templates::OmniUber_Automotive::above, + layer_1_blend_source: Templates::OmniUber_Automotive::texture, + layer_1_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_1, + layer_1_blend_splatmap: texture_2d(), + layer_1_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_direction: float3(0.f, 1.f, 0.f), + layer_1_blend_axis: Templates::OmniUber_Automotive::y, + layer_1_blend_object_space: true, + layer_1_blend_scale: 1.f, + layer_1_blend_offset: 0.f, + layer_1_blend_primvar_name: "", + layer_1_uv_set_detail: Templates::OmniUber_Automotive::uv_set_1, + layer_1_blend_detail_image: texture_2d(), + layer_1_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_1_blend_threshold: 0.330000013f, + layer_1_blend_factor_override: 0.f, + uv_set_layer_1: Templates::OmniUber_Automotive::uv_set_1, + layer_1_base_color_image: texture_2d(), + layer_1_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_1_base_color_offset: 0.f, + layer_1_base_color_scale: 1.f, + layer_1_base_color_desaturation: 0.f, + layer_1_metalness_image: texture_2d(), + layer_1_metalness_channel: Templates::OmniUber_Automotive::b, + layer_1_metalness: 1.f, + layer_1_specular_reflection_weight: 1.f, + layer_1_cavity_image: texture_2d(), + layer_1_cavity_channel: Templates::OmniUber_Automotive::r, + layer_1_roughness_image: texture_2d(), + layer_1_roughness_channel: Templates::OmniUber_Automotive::g, + layer_1_roughness_u: 1.f, + layer_1_roughness_range_position: float2(0.949999988f, 0.5f), + layer_1_normal_image: texture_2d(), + layer_1_normal_flip_green: true, + layer_1_normal_scale: 1.f, + enable_layer_2: false, + layer_2_order: Templates::OmniUber_Automotive::above, + layer_2_blend_source: Templates::OmniUber_Automotive::texture, + layer_2_uv_set_blend_factor: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_splatmap: texture_2d(), + layer_2_blend_splatmap_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_direction: float3(0.f, 1.f, 0.f), + layer_2_blend_axis: Templates::OmniUber_Automotive::y, + layer_2_blend_object_space: true, + layer_2_blend_scale: 1.f, + layer_2_blend_offset: 0.f, + layer_2_blend_primvar_name: "", + layer_2_uv_set_detail: Templates::OmniUber_Automotive::uv_set_2, + layer_2_blend_detail_image: texture_2d(), + layer_2_blend_detail_image_channel: Templates::OmniUber_Automotive::r, + layer_2_blend_threshold: 0.330000013f, + layer_2_blend_factor_override: 0.f, + uv_set_layer_2: Templates::OmniUber_Automotive::uv_set_2, + layer_2_base_color_image: texture_2d(), + layer_2_diffuse_reflection_color: color(1.f, 1.f, 1.f), + layer_2_base_color_offset: 0.f, + layer_2_base_color_scale: 1.f, + layer_2_base_color_desaturation: 0.f, + layer_2_metalness_image: texture_2d(), + layer_2_metalness_channel: Templates::OmniUber_Automotive::b, + layer_2_metalness: 1.f, + layer_2_specular_reflection_weight: 1.f, + layer_2_cavity_image: texture_2d(), + layer_2_cavity_channel: Templates::OmniUber_Automotive::r, + layer_2_roughness_image: texture_2d(), + layer_2_roughness_channel: Templates::OmniUber_Automotive::g, + layer_2_roughness_u: 1.f, + layer_2_roughness_range_position: float2(1.f, 0.5f), + layer_2_normal_image: texture_2d(), + layer_2_normal_flip_green: true, + layer_2_normal_scale: 1.f, + enable_anisotropy: false, + uv_set_anisotropy: Templates::OmniUber_Automotive::uv_set_1, + anisotropic_roughness_u: 1.f, + anisotropic_roughness_v: 0.25f, + anisotropic_direction_image: texture_2d(), + anisotropic_direction_channel: Templates::OmniUber_Automotive::r, + anisotropic_direction: 0.f, + enable_detail_normal: true, + uv_set_detail_normal: Templates::OmniUber_Automotive::uv_set_2, + uv_set_detail_weight: Templates::OmniUber_Automotive::uv_set_1, + detail_normal_image: texture_2d("./ov_clouds_01_normal.png", ::tex::gamma_linear, ""), + detail_normal_flip_green: true, + detail_normal_scale: 0.5f, + detail_normal_weight_image: texture_2d(), + detail_normal_weight_channel: Templates::OmniUber_Automotive::r, + enable_emission: false, + uv_set_emission: Templates::OmniUber_Automotive::uv_set_1, + uv_set_emission_mask: Templates::OmniUber_Automotive::uv_set_1, + emission_image: texture_2d(), + emission_mask_image: texture_2d(), + emission_mode: OmniSurface::OmniShared::emission_lx, + emission_intensity: 1.f, + emission_color: color(1.f, 1.f, 1.f), + emission_use_temperature: false, + emission_temperature: 6500.f, + enable_coat: false, + coat_color: color(1.f, 1.f, 1.f), + coat_mask_image: texture_2d(), + coat_mask_channel: Templates::OmniUber_Automotive::r, + coat_roughness_image: texture_2d(), + coat_roughness_channel: Templates::OmniUber_Automotive::r, + coat_roughness: 0.f, + coat_ior: 1.60000002f, + coat_anisotropy: 0.f, + coat_anisotropy_rotation: 0.f, + coat_affect_color: 0.f, + coat_affect_roughness: 0.f, + coat_normal_image: texture_2d(), + coat_normal_flip_green: true, + uv_set_coat_roughness_normal: Templates::OmniUber_Automotive::uv_set_1, + uv_set_coat_mask: Templates::OmniUber_Automotive::uv_set_1, + enable_flakes: false, + flake_color: color(1.f, 1.f, 1.f), + flake_size: 0.125f, + flakes_density: 0.25f, + flakes_spread: 0.150000006f, + flake_roughness: 0.0500000007f); diff --git a/Assets/Material/material_0284/ov_clouds_01_normal.png b/Assets/Material/material_0284/ov_clouds_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..b0da2618fec86c95eaf970e40f696f0ed4f0f2c1 --- /dev/null +++ b/Assets/Material/material_0284/ov_clouds_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b26fd13e4aec1c3c1cc82460bef994133a4eb845133a761ae845127d5780ac3f +size 21194805 diff --git a/Assets/Material/material_0284/ov_wood_grain_a_01_basecolor.png b/Assets/Material/material_0284/ov_wood_grain_a_01_basecolor.png new file mode 100644 index 0000000000000000000000000000000000000000..83d6ad0d9e379d45b3af138cdd4fab4472aa732e --- /dev/null +++ b/Assets/Material/material_0284/ov_wood_grain_a_01_basecolor.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c3f3546f28fc881ffa960030208b20e9d84ef397d43c55fca9b061256aafd82d +size 4232986 diff --git a/Assets/Material/material_0284/ov_wood_grain_a_01_normal.png b/Assets/Material/material_0284/ov_wood_grain_a_01_normal.png new file mode 100644 index 0000000000000000000000000000000000000000..62a95eaad39339c033bc0e495804027fd1b54025 --- /dev/null +++ b/Assets/Material/material_0284/ov_wood_grain_a_01_normal.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aa270c739d354779eda76537913b961e184b252d8ea6e3c6b6378e075967ad36 +size 20598369 diff --git a/Assets/Material/material_0284/ov_wood_grain_a_01_orm.png b/Assets/Material/material_0284/ov_wood_grain_a_01_orm.png new file mode 100644 index 0000000000000000000000000000000000000000..84b466f4aaefee42f7077096b699618d3fe7e702 --- /dev/null +++ b/Assets/Material/material_0284/ov_wood_grain_a_01_orm.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b3955584d57c7f0df549481df3e7a7738bc0fb0faf5703024de70025dd073871 +size 8580463 diff --git a/Assets/Material/material_0293/diamond_alternated_R_id_G_offs_B_color.png b/Assets/Material/material_0293/diamond_alternated_R_id_G_offs_B_color.png new file mode 100644 index 0000000000000000000000000000000000000000..4c1e022474cd28f11dcde7d40dda615d01867aee --- /dev/null +++ b/Assets/Material/material_0293/diamond_alternated_R_id_G_offs_B_color.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ba27354ba790e74374989d2577061906f32f9ba12ed8e1ca0c94a873dc5c97f3 +size 23138 diff --git a/Assets/Material/material_0293/diamond_alternated_multi_R_height_G_edgefade_B_ao.jpg b/Assets/Material/material_0293/diamond_alternated_multi_R_height_G_edgefade_B_ao.jpg new file mode 100644 index 0000000000000000000000000000000000000000..255e4ac50fd9d9652586aeca7acdef64ca7704b7 --- /dev/null +++ b/Assets/Material/material_0293/diamond_alternated_multi_R_height_G_edgefade_B_ao.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dc55acb5abf1c9baf322ea219ddbb0ce2556744cb81ef0de1bcbbdd56a6d0de5 +size 1492477 diff --git a/Assets/Material/material_0293/diamond_alternated_norm.jpg b/Assets/Material/material_0293/diamond_alternated_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..3502a52c8ba49061714d2e5f4a69743221645a08 --- /dev/null +++ b/Assets/Material/material_0293/diamond_alternated_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:34b029653c38da0acc5916f7f70bbea0dfda04046a009868ac595e6fb758b204 +size 843179 diff --git a/Assets/Material/material_0293/diamond_multi_R_noise1_G_noise2_B_craquelure.jpg b/Assets/Material/material_0293/diamond_multi_R_noise1_G_noise2_B_craquelure.jpg new file mode 100644 index 0000000000000000000000000000000000000000..d06e52b5a71f876dd991ee9e31da1cc4351aaabc --- /dev/null +++ b/Assets/Material/material_0293/diamond_multi_R_noise1_G_noise2_B_craquelure.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ba8e6b9eecbed2c1814167afb8e3a893524332b776da6f822043f75ae08acd4c +size 4231676 diff --git a/Assets/Material/material_0293/diamond_multi_R_rough_G_thickness_B_drops.jpg b/Assets/Material/material_0293/diamond_multi_R_rough_G_thickness_B_drops.jpg new file mode 100644 index 0000000000000000000000000000000000000000..61f3b530fe1d00b792bb91195d718acdab1d4982 --- /dev/null +++ b/Assets/Material/material_0293/diamond_multi_R_rough_G_thickness_B_drops.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e21b9af4d88920cb9e75892473bab0906d79f091cad7153fb2e2d7c2783be416 +size 6882962 diff --git a/Assets/Material/material_0293/mortar_diff.jpg b/Assets/Material/material_0293/mortar_diff.jpg new file mode 100644 index 0000000000000000000000000000000000000000..217c8b38b3dfae5abbe3bef2911d40a736fa1ed3 --- /dev/null +++ b/Assets/Material/material_0293/mortar_diff.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4ba01f0c53f3ab271c4765611a65cf2bd72c4c7e273bb7e7ab1b64023c991d28 +size 1973915 diff --git a/Assets/Material/material_0293/mortar_norm.jpg b/Assets/Material/material_0293/mortar_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..0c65aff8e016ed23e3f3be71a1a098b24bda1434 --- /dev/null +++ b/Assets/Material/material_0293/mortar_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a51e470390be20256a8859e6b87b2c32eca24bf79f9685fb57f65ff89d5fb2c +size 4323469 diff --git a/Assets/Material/material_0295/mortar_diff.jpg b/Assets/Material/material_0295/mortar_diff.jpg new file mode 100644 index 0000000000000000000000000000000000000000..217c8b38b3dfae5abbe3bef2911d40a736fa1ed3 --- /dev/null +++ b/Assets/Material/material_0295/mortar_diff.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4ba01f0c53f3ab271c4765611a65cf2bd72c4c7e273bb7e7ab1b64023c991d28 +size 1973915 diff --git a/Assets/Material/material_0295/mortar_norm.jpg b/Assets/Material/material_0295/mortar_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..0c65aff8e016ed23e3f3be71a1a098b24bda1434 --- /dev/null +++ b/Assets/Material/material_0295/mortar_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a51e470390be20256a8859e6b87b2c32eca24bf79f9685fb57f65ff89d5fb2c +size 4323469 diff --git a/Assets/Material/material_0295/paseo_R_id_G_offs_B_rotation.png b/Assets/Material/material_0295/paseo_R_id_G_offs_B_rotation.png new file mode 100644 index 0000000000000000000000000000000000000000..2afc2ea0983656356a7844e0f394423b3b43c8b3 --- /dev/null +++ b/Assets/Material/material_0295/paseo_R_id_G_offs_B_rotation.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:19d63bd593e1334220c8de7582dc711920094842c418c5e8e42a8f772680041d +size 15467 diff --git a/Assets/Material/material_0295/paseo_multi_R_height_G_edgefade_B_ao.jpg b/Assets/Material/material_0295/paseo_multi_R_height_G_edgefade_B_ao.jpg new file mode 100644 index 0000000000000000000000000000000000000000..5093580d31f5bf540861dabe2d119c45cccf9ddb --- /dev/null +++ b/Assets/Material/material_0295/paseo_multi_R_height_G_edgefade_B_ao.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2bac1d0942dbb9211bc1a0ac296e014878cc6771d601abb940d1a896c2e4ad12 +size 1408330 diff --git a/Assets/Material/material_0295/paseo_norm.jpg b/Assets/Material/material_0295/paseo_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..0c8aba1ccc7fe106ce18cc31f623e9766097fc03 --- /dev/null +++ b/Assets/Material/material_0295/paseo_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a44307f8e84b6de99d3728526dc13da9f0635f4cd77f845ccfefe2d94722cf50 +size 122945 diff --git a/Assets/Material/material_0295/tiles_multi_R_noise1_G_noise2_B_craquelure.jpg b/Assets/Material/material_0295/tiles_multi_R_noise1_G_noise2_B_craquelure.jpg new file mode 100644 index 0000000000000000000000000000000000000000..16add2fe202477572040ab7acf91fe4e6f0766db --- /dev/null +++ b/Assets/Material/material_0295/tiles_multi_R_noise1_G_noise2_B_craquelure.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:688fbe975352e89b4edb7e0bbd735fd8efd3b2feefc12547ac592537d1b1ac1a +size 2057934 diff --git a/Assets/Material/material_0295/tiles_multi_R_rough_G_thickness_B_drops.jpg b/Assets/Material/material_0295/tiles_multi_R_rough_G_thickness_B_drops.jpg new file mode 100644 index 0000000000000000000000000000000000000000..7071ccf60ebc0ba4a1dacd71ecb1c3d7ecb9b6ea --- /dev/null +++ b/Assets/Material/material_0295/tiles_multi_R_rough_G_thickness_B_drops.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:10dbddb4d6b704222a03102fc75e8279bf8e037384eb043752109c504ad41f32 +size 4405716 diff --git a/Assets/Material/material_0307/conrete_formed_ORM.jpg b/Assets/Material/material_0307/conrete_formed_ORM.jpg new file mode 100644 index 0000000000000000000000000000000000000000..eec43b0b161096f1a2217cb6e8c30c04041e1aba --- /dev/null +++ b/Assets/Material/material_0307/conrete_formed_ORM.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cac58ae205131edbd832083e2d264810cdec24e26e76d850da3ae7762366a9b +size 1403095 diff --git a/Assets/Material/material_0307/conrete_formed_diff.jpg b/Assets/Material/material_0307/conrete_formed_diff.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9d5e5e7d42669d83255b7e8dfad4f23a36a155da --- /dev/null +++ b/Assets/Material/material_0307/conrete_formed_diff.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:139ffc7f4255c47ee75b5b1ef0da6b6caec09d4f81eec59e086e97a1be4d3d65 +size 665448 diff --git a/Assets/Material/material_0307/conrete_formed_norm.jpg b/Assets/Material/material_0307/conrete_formed_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..35a1619a72be56ac87102e88c07ea09ec989c2c8 --- /dev/null +++ b/Assets/Material/material_0307/conrete_formed_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bf1e488cd6174e74667eb69ec666f9909b30dd078e4457153d4477e452c344b2 +size 908661 diff --git a/Assets/Material/material_0310/Concrete_Rough.mdl b/Assets/Material/material_0310/Concrete_Rough.mdl new file mode 100644 index 0000000000000000000000000000000000000000..6fbd40bb4037aa5e32fed149469570fe7c81ee2d --- /dev/null +++ b/Assets/Material/material_0310/Concrete_Rough.mdl @@ -0,0 +1,457 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. * + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + +mdl 1.5; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + + + +float remap_xy_to_0_1(float input, float x, float y) +{ + return (input - x)/(y - x); +} + +float histogram_scan_big(float input, float width, float position) +{ + return ::math::clamp( + remap_xy_to_0_1(input, + ::math::lerp(-width, 1.0, position), + ::math::lerp(0.0, 1.0 + width, position)), + 0.0, + 1.0); +} + +float histogram_scan_small(float input, float width, float position) +{ + return ::math::clamp( + remap_xy_to_0_1(input, + ::math::lerp(0.0, 1.0 - width, position), + ::math::lerp(width, 1.0 , position)), + 0.0, + 1.0); +} + +::base::texture_coordinate_info vmat_transform( + uniform float2 translation = float2(0.0, 0.0), + uniform float rotation = 0.0, + uniform float2 scaling = float2(1.0, 1.0), + uniform ::base::texture_coordinate_system system = ::base::texture_coordinate_uvw, + uniform int uv_space = 0 +) +{ + float rotation_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + + float4x4 scale = + float4x4(1.0 /scaling.x, 0. , 0. , 0., + 0. , 1.0 /scaling.y , 0. , 0., + 0. , 0. , 1.0, 0., + translation.x , translation.y , 0.0, 1.); + + float s = ::math::sin(rotation_rad); + float c = ::math::cos(rotation_rad); + float4x4 rotate = + float4x4( c , -s , 0.0 , 0.0, + s , c , 0.0 , 0.0, + 0.0, 0.0 , 1.0 , 0.0, + 0. , 0.0 , 0.0 , 1.); + + return ::base::transform_coordinate(scale*rotate, ::base::coordinate_source(system, uv_space)); +} + + +float histogram_range(float input, float range, float position) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(::math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + + + +float uint2float(int x) +{ + return float(x & 0x7FFFFFFF) + (x < 0 ? 2147483648.0 : 0.0); +} + +int lowbias32(int x) +{ + x ^= x >>> 16; + x *= 0x7feb352d; + x ^= x >>> 15; + x *= 0x846ca68b; + x ^= x >>> 16; + return x; +} + +float2 rnd22(int2 p) { + float2 ret_val = float2( + uint2float(lowbias32(p[0] + lowbias32(p[1]))) / 4294967296.f, + uint2float(lowbias32(p[0] + 32000 + lowbias32(p[1]))) / 4294967296.f + ); + return ret_val; +} + +float3 srgb2rgb(float3 val) +{ + return ::math::pow(::math::max(val, float3(0.0f)), 2.2); +} + +float2x2 invert_2x2(float2x2 M) +{ + float det = M[0][0]*M[1][1] - M[0][1]*M[1][0]; + //https://www.chilimath.com/lessons/advanced-algebra/inverse-of-a-2x2-matrix/ + return (1.0 / det) * float2x2(M[1][1], -M[0][1], -M[1][0], M[0][0]); +} + +float3 nonrepeat_lookup( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5), + float patch_size = 8.0 +) +{ + + float2 uv_in = float2(uvw.position[0], uvw.position[1]) * texture_scale; + float Z = patch_size; // patch scale inside example texture + float CON = 1.0f; + + float3 O = float3(0.f); + float2x2 M0 = float2x2(1.f,0.f, 0.5f, ::math::sqrt(3.f)/2.f); + float2x2 M = invert_2x2(M0); // transform matrix <-> tilted space + + float2 U = uv_in; + float2 V = M * uv_in; //pre-tilted hexa coordinates + int2 I = int2(::math::floor(V)); // hexa-tile id + + // The mean color needs to be determined in Photoshop then to make the + // average color work out, take the float value and calculate the apropriate + // mean value as (value^(1/2.2)) + + float3 m = average_color; + + float3 F = float3(::math::frac(V)[0], ::math::frac(V)[1], 0.f), W; + F[2] = 1.0 - F[0] - F[1]; // local hexa coordinates + + if( F[2] > 0.f ) + + O = (W[0] = F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I))) - m*float(CON)) + + (W[1] = F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0,1)))) - m*float(CON)) + + (W[2] = F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1,0)))) - m*float(CON)); + else + O = (W[0] = -F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1)))) - m*float(CON)) + + (W[1] = 1.f - F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1, 0)))) - m*float(CON)) + + (W[2] = 1.f - F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0, 1)))) - m*float(CON)); + O = m + O/::math::length(W); + O = ::math::clamp( (O), 0.0, 1.0); + + return float3(O); +} + +color endless_texture( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 10.0, + float3 average_color = float3(0.5, 0.5, 1.0), + float patch_size = 8.0, + bool gamma_correct_lookup = true +) +{ + return gamma_correct_lookup ? color(srgb2rgb( + nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )) + ) : color(nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )); +} + +float3 endless_normal( + uniform texture_2d texture = texture_2d(), + float factor = 1.0, + bool flip_tangent_u = false, + bool flip_tangent_v = false, + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5, 0.5, 1.0), + float patch_size = 8.0 +) +{ + float3 transformed_tangent_u = flip_tangent_u ? uvw.tangent_u : - uvw.tangent_u; + float3 transformed_tangent_v = flip_tangent_v ? uvw.tangent_v : - uvw.tangent_v; + + if (flip_tangent_u) + transformed_tangent_u=-transformed_tangent_u; + if (flip_tangent_v) + transformed_tangent_v=-transformed_tangent_v; + + // normalized Lookup + float3 tangent_space_normal = + (nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + ) - 0.5) * (2.0 * factor); + + return ::math::normalize(uvw.tangent_u * tangent_space_normal.x + + uvw.tangent_v * tangent_space_normal.y + + ::state::normal()*1.0); +} + +float3 normalmap_normal( + uniform texture_2d texture, + float factor = 1.0, + ::base::texture_coordinate_info uvw = ::base::texture_coordinate_info() +) +{ + float3 lookup = (::tex::lookup_float3(texture, float2(uvw.position.x, uvw.position.y)) - float3(0.5)) * (factor * 2.0); + return ::math::normalize(uvw.tangent_u * lookup.x + uvw.tangent_v * lookup.y + ::state::normal() * (lookup.z + (1.0 - factor))); +} + + +export material Concrete_Rough( + uniform bool infinite_tiling = true [[ + ::anno::description("Enables infinite tiling feature which removes repeating texture patterns. Note that depending on the material this feature changes the appearance of the material slightly."), + ::anno::display_name("Infinite Tiling"), + ::anno::in_group("Appearance") + ]], + float diffuse_brightness = 1.f [[ + ::anno::description("Adjusts the lightness of the material."), + ::anno::display_name("Diffuse Brightness"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance") + ]], + float roughness = 0.f [[ + ::anno::description("Higher values lead to blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance") + ]], + float reflectivity = 1.f [[ + ::anno::description("Higher values make the surface more reflective."), + ::anno::display_name("Reflectivity"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance") + ]], + float moss_growth = 0.f [[ + ::anno::description("Grows a layer of moss on top of the material."), + ::anno::display_name("Moss Growth"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance") + ]], + uniform float bump_strength = 1.f [[ + ::anno::description("Determines the degree of bumpiness."), + ::anno::display_name("Bump Strength"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::in_group("Appearance") + ]], + float dirt = 0.f [[ + ::anno::description("The strength of the dirtlayer."), + ::anno::display_name("Dirt Strength"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance", "Dirt") + ]], + color dirt_color = color(0.f, 0.f, 0.f) [[ + ::anno::description("Adjust the color of the dirt layer."), + ::anno::display_name("Dirt Color"), + ::anno::in_group("Appearance", "Dirt") + ]], + uniform float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform") + ]], + uniform float texture_rotate = 0.f [[ + ::anno::description("Rotation of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform") + ]], + uniform float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::nvidia::core_definitions::dimension(float2(1.0, 1.0)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Advanced") + ]] +) +[[ + ::anno::description("A rough concrete material with a dirt and moss layer."), + ::anno::in_group("Concrete"), + ::anno::display_name("Concrete Rough"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Concrete_Rough.Concrete_Rough.png"), + ::anno::key_words(string[]("floor", "wall", "concrete", "construction", "exterior", "cement", "unfinished", "rough", "worn", "gray")), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Ruediger Raab"), + ::anno::contributor("Maik Rohland") +]] + = + let { + bool tmp0 = false; + material_surface tmp1(::df::custom_curve_layer(0.0399999991f, 1.f, 5.f, ::math::pow(histogram_scan_small(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], ::math::lerp(0.0340000018f, 1.f, reflectivity), 1.f), 2.20000005f), ::df::microfacet_ggx_smith_bsdf(::math::lerp(::math::lerp(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 0.635890067f, ::math::lerp(0.465000033f, 0.852000058f, roughness)), ::math::lerp(0.709000051f, histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 0.635890067f, ::math::lerp(0.465000033f, 0.852000058f, roughness)), histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.417000026f, 0.747000039f)), dirt), float3(::base::file_texture(texture_2d("./moss_multi_R_rough_G_ao_B_height.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.478000015f, ::base::texture_coordinate_uvw, 0), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.334000021f, ::math::lerp(1.f, 0.584000051f, moss_growth))) * ::math::lerp(::math::lerp(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 0.635890067f, ::math::lerp(0.465000033f, 0.852000058f, roughness)), ::math::lerp(0.709000051f, histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 0.635890067f, ::math::lerp(0.465000033f, 0.852000058f, roughness)), histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.417000026f, 0.747000039f)), dirt), float3(::base::file_texture(texture_2d("./moss_multi_R_rough_G_ao_B_height.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.478000015f, ::base::texture_coordinate_uvw, 0), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.334000021f, ::math::lerp(1.f, 0.584000051f, moss_growth))), ::math::lerp(::math::lerp(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 0.635890067f, ::math::lerp(0.465000033f, 0.852000058f, roughness)), ::math::lerp(0.709000051f, histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 0.635890067f, ::math::lerp(0.465000033f, 0.852000058f, roughness)), histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.417000026f, 0.747000039f)), dirt), float3(::base::file_texture(texture_2d("./moss_multi_R_rough_G_ao_B_height.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.478000015f, ::base::texture_coordinate_uvw, 0), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.334000021f, ::math::lerp(1.f, 0.584000051f, moss_growth))) * ::math::lerp(::math::lerp(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 0.635890067f, ::math::lerp(0.465000033f, 0.852000058f, roughness)), ::math::lerp(0.709000051f, histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 0.635890067f, ::math::lerp(0.465000033f, 0.852000058f, roughness)), histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.417000026f, 0.747000039f)), dirt), float3(::base::file_texture(texture_2d("./moss_multi_R_rough_G_ao_B_height.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.478000015f, ::base::texture_coordinate_uvw, 0), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.334000021f, ::math::lerp(1.f, 0.584000051f, moss_growth))), color(1.f, 1.f, 1.f), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(1.f, ::df::diffuse_reflection_bsdf(nvidia::core_definitions::blend_colors(nvidia::core_definitions::blend_colors(nvidia::core_definitions::blend_colors(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_diff.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.705882013f, 0.705882013f, 0.678430974f), 2.02700019f, true) : ::base::file_texture(texture_2d("./concrete_rough_diff.jpg", ::tex::gamma_srgb), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint, color(0.f, 0.f, 0.f), ::base::color_layer_multiply, ::math::lerp(0.356000006f, 0.f, diffuse_brightness)).tint, nvidia::core_definitions::blend_colors(dirt_color, color(1.f, 1.f, 1.f), ::base::color_layer_blend, ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 2.20000005f)).tint, ::base::color_layer_multiply, dirt * 0.699999988f).tint, ::base::file_texture(texture_2d("./moss_diff.jpg", ::tex::gamma_srgb), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.478000015f, ::base::texture_coordinate_uvw, 0), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint, ::base::color_layer_multiply, histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.334000021f, ::math::lerp(1.f, 0.584000051f, moss_growth))).tint, 0.f), bsdf(), ::state::normal()), ::state::normal()), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(1.f, 1.f, 1.f); + material_volume tmp4 = material_volume(scattering: vdf(), absorption_coefficient: color(0.f, 0.f, 0.f), scattering_coefficient: color(0.f, 0.f, 0.f)); + material_geometry tmp5(float3(0.f), 1.f, ::math::normalize(::math::lerp(infinite_tiling ? endless_normal(texture_2d("./concrete_rough_norm.jpg", ::tex::gamma_linear), bump_strength, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.5f, 0.5f, 1.f), 2.02700019f) : ::base::tangent_space_normal_texture(texture_2d("./concrete_rough_norm.jpg", ::tex::gamma_linear), bump_strength, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 1.f, 0.f), normalmap_normal(texture_2d("./moss_norm.jpg", ::tex::gamma_linear), 2.f, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.478000015f, ::base::texture_coordinate_uvw, 0)), histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.2670002f, float3(0.647059023f, 0.721569002f, 0.464740992f), 2.02700019f, false) : ::base::file_texture(texture_2d("./concrete_rough_ORM.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.334000021f, ::math::lerp(1.f, 0.584000051f, moss_growth))))); + hair_bsdf tmp6 = hair_bsdf(); + } in + material( + thin_walled: tmp0, + surface: tmp1, + backface: tmp2, + ior: tmp3, + volume: tmp4, + geometry: tmp5, + hair: tmp6); + + +export material Concrete_Rough_Dirty(*) +[[ + ::anno::description("A rough concrete material with a dirt and moss layer."), + ::anno::in_group("Concrete"), + ::anno::display_name("Concrete Rough Dirty"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Concrete_Rough.Concrete_Rough_Dirty.png"), + ::anno::key_words(string[]("floor", "wall", "concrete", "construction", "exterior", "cement", "unfinished", "rough", "worn", "dirty", "gray")), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Ruediger Raab"), + ::anno::contributor("Maik Rohland") +]] + = Concrete_Rough( + infinite_tiling: true, + diffuse_brightness: 1.0f, + roughness: 0.5f, + reflectivity: 1.0f, + moss_growth: 0.0f, + bump_strength: 1.0f, + dirt: 1.0f, + dirt_color: color(0.0f), + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + +export material Concrete_Rough_Mossy(*) +[[ + ::anno::description("A rough concrete material with a dirt and moss layer."), + ::anno::in_group("Concrete"), + ::anno::display_name("Concrete Rough Mossy"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Concrete_Rough.Concrete_Rough_Mossy.png"), + ::anno::key_words(string[]("floor", "wall", "concrete", "construction", "exterior", "cement", "unfinished", "rough", "worn", "dirty", "decayed", "gray")), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Ruediger Raab"), + ::anno::contributor("Maik Rohland") +]] + = Concrete_Rough( + infinite_tiling: true, + diffuse_brightness: 1.0f, + roughness: 0.5f, + reflectivity: 1.0f, + moss_growth: 0.5f, + bump_strength: 1.0f, + dirt: 0.0f, + dirt_color: color(0.0f), + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + +export material Concrete_Rough_Heavy_Decay(*) +[[ + ::anno::description("A rough concrete material with a dirt and moss layer."), + ::anno::in_group("Concrete"), + ::anno::display_name("Concrete Rough Heavy Decay"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Concrete_Rough.Concrete_Rough_Heavy_Decay.png"), + ::anno::key_words(string[]("floor", "wall", "concrete", "construction", "exterior", "cement", "unfinished", "rough", "worn", "dirty", "decayed", "gray")), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Ruediger Raab"), + ::anno::contributor("Maik Rohland") +]] + = Concrete_Rough( + infinite_tiling: true, + diffuse_brightness: 1.0f, + roughness: 0.75f, + reflectivity: 1.0f, + moss_growth: 0.80f, + bump_strength: 1.0f, + dirt: 0.0f, + dirt_color: color(0.0f), + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); \ No newline at end of file diff --git a/Assets/Material/material_0312/Concrete_Wall_Aged_Scratched.mdl b/Assets/Material/material_0312/Concrete_Wall_Aged_Scratched.mdl new file mode 100644 index 0000000000000000000000000000000000000000..d065db366024a727174b430b8dc5ff812fb3a237 --- /dev/null +++ b/Assets/Material/material_0312/Concrete_Wall_Aged_Scratched.mdl @@ -0,0 +1,462 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. * + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA’s Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + +mdl 1.5; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + + + +::base::texture_coordinate_info transform_coordinate_2( + float4x4 transform + [[ ::anno::description("A transformation to be applied to the source coordinates. rotation_translation_scale() is a suggested means to compute the transformation matrix.") ]], + ::base::texture_coordinate_info coordinate = ::base::texture_coordinate_info() + [[ ::anno::description("Coordinate, typically sourced from coordinate_source or coordinate_projection.") ]] +) [[ + ::anno::description("Transform a texture coordinate by a matrix.") , + ::anno::noinline() + ]] +{ + // Version 2 + float4 r_position = transform * float4(coordinate.position.x,coordinate.position.y,coordinate.position.z,1); + //Try aproximating it for the case that the rotation is only aroud z and assuming the texture layout is nice and z is ~constant. + //just pretend there is no other rotation happening + //get rid of scaling and translation. Then extract fields where sin and cos would be in a simple 2d transform around z. + float4 u = transform[0]; + float3 ru = ::math::normalize(float3(u.x,u.y,u.z)); + float cos = ru.x; + float sin = -ru.y; + //TODO: at least also handle sign of z? + //TODO: handle tangent becoming 0 + + return ::base::texture_coordinate_info( + float3(r_position.x,r_position.y,r_position.z), + ::math::normalize(cos * coordinate.tangent_u - sin * coordinate.tangent_v), + ::math::normalize(cos * coordinate.tangent_v + sin * coordinate.tangent_u)); +} + +::base::texture_coordinate_info vmat_transform( + float2 translation = float2(0.0, 0.0), + float rotation = 0.0, // rotation in degrees + float2 scaling = float2(1.0, 1.0), + uniform ::base::texture_coordinate_system system = ::base::texture_coordinate_uvw, + uniform int uv_space = 0 +) +{ + float rotation_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + float4x4 scale = + float4x4(1.0 /scaling.x, 0. , 0. , 0., + 0. , 1.0 /scaling.y , 0. , 0., + 0. , 0. , 1.0, 0., + translation.x , translation.y , 0.0, 1.); + + float s = ::math::sin(rotation_rad); + float c = ::math::cos(rotation_rad); + float4x4 rotate = + float4x4( c , -s , 0.0 , 0.0, + s , c , 0.0 , 0.0, + 0.0, 0.0 , 1.0 , 0.0, + 0. , 0.0 , 0.0 , 1.); + + return transform_coordinate_2(scale*rotate, ::base::coordinate_source(system, uv_space)); +} + +float remap_xy_to_0_1(float input, float x, float y) +{ + return (input - x)/(y - x); +} + +float histogram_scan_big(float input, float width, float position) +{ + return ::math::clamp( + remap_xy_to_0_1(input, + ::math::lerp(-width, 1.0, position), + ::math::lerp(0.0, 1.0 + width, position)), + 0.0, + 1.0); +} + + +float histogram_range(float input, float range, float position) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(::math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + + + +float uint2float(int x) +{ + return float(x & 0x7FFFFFFF) + (x < 0 ? 2147483648.0 : 0.0); +} + +int lowbias32(int x) +{ + x ^= x >>> 16; + x *= 0x7feb352d; + x ^= x >>> 15; + x *= 0x846ca68b; + x ^= x >>> 16; + return x; +} + +float2 rnd22(int2 p) { + float2 ret_val = float2( + uint2float(lowbias32(p[0] + lowbias32(p[1]))) / 4294967296.f, + uint2float(lowbias32(p[0] + 32000 + lowbias32(p[1]))) / 4294967296.f + ); + return ret_val; +} + +float3 srgb2rgb(float3 val) +{ + return ::math::pow(::math::max(val, float3(0.0f)), 2.2); +} + +float2x2 invert_2x2(float2x2 M) +{ + float det = M[0][0]*M[1][1] - M[0][1]*M[1][0]; + //https://www.chilimath.com/lessons/advanced-algebra/inverse-of-a-2x2-matrix/ + return (1.0 / det) * float2x2(M[1][1], -M[0][1], -M[1][0], M[0][0]); +} + +float3 nonrepeat_lookup( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5), + float patch_size = 8.0 +) +{ + + float2 uv_in = float2(uvw.position[0], uvw.position[1]) * texture_scale; + float Z = patch_size; // patch scale inside example texture + float CON = 1.0f; + + float3 O = float3(0.f); + float2x2 M0 = float2x2(1.f,0.f, 0.5f, ::math::sqrt(3.f)/2.f); + float2x2 M = invert_2x2(M0); // transform matrix <-> tilted space + + float2 U = uv_in; + float2 V = M * uv_in; //pre-tilted hexa coordinates + int2 I = int2(::math::floor(V)); // hexa-tile id + + // The mean color needs to be determined in Photoshop then to make the + // average color work out, take the float value and calculate the apropriate + // mean value as (value^(1/2.2)) + + float3 m = average_color; + + float3 F = float3(::math::frac(V)[0], ::math::frac(V)[1], 0.f), W; + F[2] = 1.0 - F[0] - F[1]; // local hexa coordinates + + if( F[2] > 0.f ) + + O = (W[0] = F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I))) - m*float(CON)) + + (W[1] = F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0,1)))) - m*float(CON)) + + (W[2] = F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1,0)))) - m*float(CON)); + else + O = (W[0] = -F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1)))) - m*float(CON)) + + (W[1] = 1.f - F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1, 0)))) - m*float(CON)) + + (W[2] = 1.f - F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0, 1)))) - m*float(CON)); + O = m + O/::math::length(W); + O = ::math::clamp( (O), 0.0, 1.0); + + return float3(O); +} + +color endless_texture( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 10.0, + float3 average_color = float3(0.5, 0.5, 1.0), + float patch_size = 8.0, + bool gamma_correct_lookup = true +) +{ + return gamma_correct_lookup ? color(srgb2rgb( + nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )) + ) : color(nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )); +} + +float3 endless_normal( + uniform texture_2d texture = texture_2d(), + float factor = 1.0, + bool flip_tangent_u = false, + bool flip_tangent_v = false, + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5, 0.5, 1.0), + float patch_size = 8.0 +) +{ + float3 transformed_tangent_u = flip_tangent_u ? uvw.tangent_u : - uvw.tangent_u; + float3 transformed_tangent_v = flip_tangent_v ? uvw.tangent_v : - uvw.tangent_v; + + if (flip_tangent_u) + transformed_tangent_u=-transformed_tangent_u; + if (flip_tangent_v) + transformed_tangent_v=-transformed_tangent_v; + + // normalized Lookup + float3 tangent_space_normal = + (nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + ) - 0.5) * (2.0 * factor); + + return ::math::normalize(uvw.tangent_u * tangent_space_normal.x + + uvw.tangent_v * tangent_space_normal.y + + ::state::normal()*1.0); +} + +export material Concrete_Wall_Aged_Scratched( + uniform bool infinite_tiling = false [[ + ::anno::description("Enables infinite tiling feature which removes repeating texture patterns. Note that depending on the material this feature changes the appearance of the material slightly."), + ::anno::display_name("Infinite Tiling"), + ::anno::in_group("Appearance") + ]], + float diffuse_brightness = 1.f [[ + ::anno::description("Adjusts the lightness of the material."), + ::anno::display_name("Diffuse Brightness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f) + ]], + float roughness = 1.f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f) + ]], + float grunge = 0.f [[ + ::anno::description("Adds a layer of grunge on top of the material."), + ::anno::display_name("Grunge"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float bump_strength = 1.f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::soft_range(0.f, 2.f), + ::anno::hard_range(0.f, 3.f) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::nvidia::core_definitions::dimension(float2(1.5, 1.5)), + ::anno::in_group("Transform") + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorners_radius_mm = 1.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners") + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Advanced") + ]] +) +[[ + ::anno::description("A worn painted concrete wall that shows signs of damage."), + ::anno::in_group("Concrete"), + ::anno::display_name("Concrete Wall Aged Scratched - Rough"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Concrete_Wall_Aged_Scratched.Concrete_Wall_Aged_Scratched.png"), + ::anno::key_words(string[]("concrete", "infinite tiling", "wall", "outdoor", "old", "construction", "aged", "paint", "worn", "scratched", "gray")), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Ruediger Raab"), + ::anno::contributor("Maik Rohland") +]] + = + let { + material_surface tmp1(::df::custom_curve_layer(0.0399999991f, 1.f, 5.f, histogram_scan_big(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.396077991f, 0.858824015f, 0.894118011f), 3.5999999f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 1.f, 0.649999976f), ::df::microfacet_ggx_smith_bsdf(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.396077991f, 0.858824015f, 0.894118011f), 3.5999999f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] + (1.f - float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.6f, float3(0.396f, 0.858f, 0.894f), 3.6f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2]) * (grunge * 0.299999982f), 1.f, roughness * 0.370000005f + 0.400000006f) * histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.396077991f, 0.858824015f, 0.894118011f), 3.5999999f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] + (1.f - float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.396077991f, 0.858824015f, 0.894118011f), 3.5999999f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2]) * (grunge * 0.299999982f), 1.f, roughness * 0.370000005f + 0.400000006f), histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.396077991f, 0.858824015f, 0.894118011f), 3.5999999f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] + (1.f - float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.396077991f, 0.858824015f, 0.894118011f), 3.5999999f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2]) * (grunge * 0.299999982f), 1.f, roughness * 0.370000005f + 0.400000006f) * histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.396077991f, 0.858824015f, 0.894118011f), 3.5999999f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] + (1.f - float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.396077991f, 0.858824015f, 0.894118011f), 3.5999999f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2]) * (grunge * 0.299999982f), 1.f, roughness * 0.370000005f + 0.400000006f), color(1.f, 1.f, 1.f), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(1.f, ::df::diffuse_reflection_bsdf(nvidia::core_definitions::blend_colors(nvidia::core_definitions::blend_colors(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_diff.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.596077979f, 0.568627f, 0.541176021f), 3.5999999f, true) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_diff.jpg", ::tex::gamma_srgb), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint, color(::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.396077991f, 0.858824015f, 0.894118011f), 3.5999999f, false) : ::base::file_texture(texture_2d("./concrete_wall_aged_scratched_R_rough_G_ao_B_grunge.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 2.20000005f)), ::base::color_layer_multiply, grunge * 0.699999988f).tint, color(0.f, 0.f, 0.f), ::base::color_layer_multiply, diffuse_brightness * -0.300000012f + 0.300000012f).tint, 0.f), bsdf(), infinite_tiling ? endless_normal(texture_2d("./concrete_wall_aged_scratched_norm.jpg", ::tex::gamma_linear), bump_strength, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.501960993f, 0.505882025f, 0.988234997f), 3.5999999f) : ::base::tangent_space_normal_texture(texture_2d("./concrete_wall_aged_scratched_norm.jpg", ::tex::gamma_linear), bump_strength, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 1.f, 0.f)), infinite_tiling ? endless_normal(texture_2d("./concrete_wall_aged_scratched_norm.jpg", ::tex::gamma_linear), bump_strength, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 3.5999999f, float3(0.501960993f, 0.505882025f, 0.988234997f), 3.5999999f) : ::base::tangent_space_normal_texture(texture_2d("./concrete_wall_aged_scratched_norm.jpg", ::tex::gamma_linear), bump_strength, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 1.f, 0.f)), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(1.f, 1.f, 1.f); + material_volume tmp4 = material_volume(scattering: vdf(), absorption_coefficient: color(0.f, 0.f, 0.f), scattering_coefficient: color(0.f, 0.f, 0.f)); + material_geometry tmp5(float3(0.f), 1.f, roundcorners_enable ? ::state::rounded_corner_normal(roundcorners_radius_mm * 0.00100000005f, roundcorners_across_materials, 1.f) : ::state::normal()); + } in + material( + thin_walled: false, + surface: tmp1, + backface: tmp2, + ior: tmp3, + volume: tmp4, + geometry: tmp5); + + + +export material Concrete_Wall_Aged_Scratched_Shiny(*) +[[ + ::anno::description("A worn painted concrete wall that shows signs of damage."), + ::anno::in_group("Concrete"), + ::anno::display_name("Concrete Wall Aged Scratched - Shiny"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Concrete_Wall_Aged_Scratched.Concrete_Wall_Aged_Scratched_Shiny.png"), + ::anno::key_words(string[]("concrete", "infinite tiling", "wall", "outdoor", "old", "construction", "aged", "paint", "worn", "scratched", "gray")), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Ruediger Raab"), + ::anno::contributor("Maik Rohland") +]] = Concrete_Wall_Aged_Scratched +( + infinite_tiling: true, + diffuse_brightness: 1.0f, + roughness: 0.03f, + grunge: 0.0f, + bump_strength: 1.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + roundcorners_enable: false, + roundcorners_radius_mm: 1.5f, + roundcorners_across_materials: false, + uv_space_index: 0 +); + + +export material Concrete_Wall_Aged_Scratched_Medium_Grime(*) +[[ + ::anno::description("A worn painted concrete wall that shows signs of damage."), + ::anno::in_group("Concrete"), + ::anno::display_name("Concrete Wall Aged Scratched - Medium Grime"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Concrete_Wall_Aged_Scratched.Concrete_Wall_Aged_Scratched_Medium_Grime.png"), + ::anno::key_words(string[]("concrete", "infinite tiling", "wall", "outdoor", "old", "construction", "aged", "paint", "worn", "scratched", "gray")), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Ruediger Raab"), + ::anno::contributor("Maik Rohland") +]] = Concrete_Wall_Aged_Scratched +( + infinite_tiling: true, + diffuse_brightness: 1.0f, + roughness: 0.8f, + grunge: 0.52f, + bump_strength: 1.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + roundcorners_enable: false, + roundcorners_radius_mm: 1.5f, + roundcorners_across_materials: false, + uv_space_index: 0 +); + + +export material Concrete_Wall_Aged_Scratched_Heavy_Grime(*) +[[ + ::anno::description("A worn painted concrete wall that shows signs of damage."), + ::anno::in_group("Concrete"), + ::anno::display_name("Concrete Wall Aged Scratched - Heavy Grime"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Concrete_Wall_Aged_Scratched.Concrete_Wall_Aged_Scratched_Heavy_Grime.png"), + ::anno::key_words(string[]("concrete", "infinite tiling", "wall", "outdoor", "old", "construction", "aged", "paint", "dirty", "worn", "scratched", "gray")), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Ruediger Raab"), + ::anno::contributor("Maik Rohland") +]] = Concrete_Wall_Aged_Scratched +( + infinite_tiling: true, + diffuse_brightness: .56f, + roughness: 0.71f, + grunge: 0.85f, + bump_strength: 1.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + roundcorners_enable: false, + roundcorners_radius_mm: 1.5f, + roundcorners_across_materials: false, + uv_space_index: 0 +); \ No newline at end of file diff --git a/Assets/Material/material_0314/mortar_diff.jpg b/Assets/Material/material_0314/mortar_diff.jpg new file mode 100644 index 0000000000000000000000000000000000000000..217c8b38b3dfae5abbe3bef2911d40a736fa1ed3 --- /dev/null +++ b/Assets/Material/material_0314/mortar_diff.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4ba01f0c53f3ab271c4765611a65cf2bd72c4c7e273bb7e7ab1b64023c991d28 +size 1973915 diff --git a/Assets/Material/material_0314/mortar_multi_R_rough_G_ao_B_noise.jpg b/Assets/Material/material_0314/mortar_multi_R_rough_G_ao_B_noise.jpg new file mode 100644 index 0000000000000000000000000000000000000000..1b779a8e899b357f9d2a17888f63d6b97f22e2e2 --- /dev/null +++ b/Assets/Material/material_0314/mortar_multi_R_rough_G_ao_B_noise.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f169403a99ae882c446f4148816c5a7e95be54d8aa798a83010b4234a3a3e627 +size 5753857 diff --git a/Assets/Material/material_0314/mortar_norm.jpg b/Assets/Material/material_0314/mortar_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..0c65aff8e016ed23e3f3be71a1a098b24bda1434 --- /dev/null +++ b/Assets/Material/material_0314/mortar_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a51e470390be20256a8859e6b87b2c32eca24bf79f9685fb57f65ff89d5fb2c +size 4323469 diff --git a/Assets/Material/material_0316/spongy_concrete_dirt_mask.jpg b/Assets/Material/material_0316/spongy_concrete_dirt_mask.jpg new file mode 100644 index 0000000000000000000000000000000000000000..a7baae5972e1b107961100e4a84372873d43d303 --- /dev/null +++ b/Assets/Material/material_0316/spongy_concrete_dirt_mask.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:07825eb906b0ca4e7990ee507b0b93afd9fc317606bc8db526ae477b870121ca +size 2961888 diff --git a/Assets/Material/material_0316/spongy_concrete_weatheredMoss_diff.jpg b/Assets/Material/material_0316/spongy_concrete_weatheredMoss_diff.jpg new file mode 100644 index 0000000000000000000000000000000000000000..befd0547372318d02292c10ea361191a9434a2a9 --- /dev/null +++ b/Assets/Material/material_0316/spongy_concrete_weatheredMoss_diff.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:74f7cb29ee8996f77714c9c4875c38d47aa50b9d6db7322056b19210b90f86a0 +size 5261075 diff --git a/Assets/Material/material_0316/spongy_concrete_weatheredMoss_multi_R_rough_G_ao_B_height.jpg b/Assets/Material/material_0316/spongy_concrete_weatheredMoss_multi_R_rough_G_ao_B_height.jpg new file mode 100644 index 0000000000000000000000000000000000000000..42b083d515cb29a55c41af3b256abcc9d1b6e667 --- /dev/null +++ b/Assets/Material/material_0316/spongy_concrete_weatheredMoss_multi_R_rough_G_ao_B_height.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0e075e665f9abcde6cbf5d9e74dbf33c0ba5a372d69c6c9d08bd182d3dfc36f +size 4807673 diff --git a/Assets/Material/material_0316/spongy_concrete_weatheredMoss_norm.jpg b/Assets/Material/material_0316/spongy_concrete_weatheredMoss_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..c7e1f32452bae646562379a9c0b4f34f8c40929c --- /dev/null +++ b/Assets/Material/material_0316/spongy_concrete_weatheredMoss_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a7000203e495a74f602e4d2caf10e1b6f98b7966cb0af37ddefd657742503b4f +size 2985036 diff --git a/Assets/Material/material_0322/cotton_roughly_woven_diff.jpg b/Assets/Material/material_0322/cotton_roughly_woven_diff.jpg new file mode 100644 index 0000000000000000000000000000000000000000..12a24af4a95123850326b6562922202749403257 --- /dev/null +++ b/Assets/Material/material_0322/cotton_roughly_woven_diff.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:54ccb07992d9bb10a06b4644c896d7db1ff2c1aab2e3381c1be7190af6a2bc36 +size 3181154 diff --git a/Assets/Material/material_0322/cotton_roughly_woven_norm.jpg b/Assets/Material/material_0322/cotton_roughly_woven_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..8d36cbce118302dbe871dd5fdb0e2a4eada36874 --- /dev/null +++ b/Assets/Material/material_0322/cotton_roughly_woven_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b82a2b5a0f66e93dffeeafbbc95fe76a795439618467b964968286d40eaa6c50 +size 2530570 diff --git a/Assets/Material/material_0322/cotton_roughly_woven_rough.jpg b/Assets/Material/material_0322/cotton_roughly_woven_rough.jpg new file mode 100644 index 0000000000000000000000000000000000000000..6ee9d4a037820b71e105b888b30e1c3405185d05 --- /dev/null +++ b/Assets/Material/material_0322/cotton_roughly_woven_rough.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0c179bcd2733135af67d8f473a8b3f49aea758df987ed4745683684b649c9586 +size 3727699 diff --git a/Assets/Material/material_0338/velvet_diff.jpg b/Assets/Material/material_0338/velvet_diff.jpg new file mode 100644 index 0000000000000000000000000000000000000000..4bd9a7c388cb3854c35d9a352ab8b863827d5552 --- /dev/null +++ b/Assets/Material/material_0338/velvet_diff.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5fe6a544cd302f0f3fd7bb9fb6ccd6c8bac98a3472158eb5813fcdfa5b68f095 +size 2749962 diff --git a/Assets/Material/material_0338/velvet_imperfections.jpg b/Assets/Material/material_0338/velvet_imperfections.jpg new file mode 100644 index 0000000000000000000000000000000000000000..90d94ba81fd415dae0a32261713b41ac01f06dbd --- /dev/null +++ b/Assets/Material/material_0338/velvet_imperfections.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0862089ef822953fff76e05a450eb66365b805c98ad1551ad4a543d8d9ed6448 +size 1532720 diff --git a/Assets/Material/material_0338/velvet_norm.jpg b/Assets/Material/material_0338/velvet_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..45951cdb23f0af6549d9e862f02d6957c71465b7 --- /dev/null +++ b/Assets/Material/material_0338/velvet_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:392465b13662f01827b79af8d1611d288b51dcd18967be9ef9a2d6e4a608b3c5 +size 2519779 diff --git a/Assets/Material/material_0361/Rough_Gravel.mdl b/Assets/Material/material_0361/Rough_Gravel.mdl new file mode 100644 index 0000000000000000000000000000000000000000..f0562dfc42652a7057d4408be666f0648709e438 --- /dev/null +++ b/Assets/Material/material_0361/Rough_Gravel.mdl @@ -0,0 +1,139 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + +mdl 1.5; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::state::*; +import ::tex::*; +import ::math::*; +import ::nvidia::core_definitions::dimension; + + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +float histogram_range(float input, float range, float position) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(::math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + +export material Rough_Gravel( + float diffuse_brightness = 1.f [[ + ::anno::display_name("Diffuse Brightness"), + ::anno::description("Adjust the overall brightness of the texture."), + ::anno::hard_range(0.f, 1.f), + ::anno::usage("") + ]], + uniform float bump_factor = 1.f [[ + ::anno::description("Determines the degree of bumpiness."), + ::anno::display_name("Bump Factor") + ]], + + // Adjustments Group + uniform float2 texture_translate = 0.0f + [[ + ::anno::display_name("Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + uniform float texture_rotate = 0.f + [[ + ::anno::display_name("Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + uniform float2 texture_scale = 2.0f + [[ + ::anno::display_name("Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.2f, 1.2f)), + ::anno::in_group("Transform") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Rough Gravel"), + ::anno::description("A floor material of rough an uneven gravel and dust."), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Rough_Gravel.Rough_Gravel.png"), + ::anno::key_words(string[]("gravel", "pebbles", "ground", "outdoor", "construction", "gray")) +]] + = + let { + + uniform texture_2d DIFFTEX = texture_2d("./rough_gravel_diff.jpg", ::tex::gamma_srgb); + uniform texture_2d NORMTEX = texture_2d("./rough_gravel_norm.jpg", ::tex::gamma_linear); + uniform texture_2d ROUGHTEX = texture_2d("./rough_gravel_rough.jpg", ::tex::gamma_linear); + + ::base::texture_coordinate_info UVW = ::base::transform_coordinate(::base::rotation_translation_scale(float3(0.0, 0.0, texture_rotate/180.*::math::PI ), float3(texture_translate.x, texture_translate.y, 0.f), float3(texture_scale.x, texture_scale.y, 1.0)), ::base::texture_coordinate_info(::state::texture_coordinate(0), ::state::texture_tangent_u(0), ::state::texture_tangent_v(0))); + + float hist_position = 0.9f; + + float tt = histogram_range(::base::file_texture(ROUGHTEX, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, UVW, float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).mono, 1.f, hist_position); + + + material_surface tmp1( + ::df::custom_curve_layer(0.04f, 1.f, 3.31f, 0.3f, ::df::microfacet_ggx_smith_bsdf(tt * tt, tt * tt, color(1.f, 1.f, 1.f), ::state::texture_tangent_u(0), ::df::scatter_reflect, ""), ::df::diffuse_reflection_bsdf(::base::file_texture(DIFFTEX, color(0.f, 0.f, 0.f), color(diffuse_brightness), ::base::mono_alpha, UVW, float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint, 0.600000024f, ""), ::state::normal()), + material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(1.f, 1.f, 1.f); + material_volume tmp4 = material_volume(scattering: vdf(), absorption_coefficient: color(0.f, 0.f, 0.f), scattering_coefficient: color(0.f, 0.f, 0.f)); + material_geometry tmp5( + float3(0.f), + 1.f, + ::base::tangent_space_normal_texture(NORMTEX, bump_factor, false, true, UVW, float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 1.f, 0.f)); + } in + material( + thin_walled: false, + surface: tmp1, + backface: tmp2, + ior: tmp3, + volume: tmp4, + geometry: tmp5); diff --git a/Assets/Material/material_0362/Small_Cobblestone.mdl b/Assets/Material/material_0362/Small_Cobblestone.mdl new file mode 100644 index 0000000000000000000000000000000000000000..a11efa4be1217c7bd0056b05fca607e0d85d7705 --- /dev/null +++ b/Assets/Material/material_0362/Small_Cobblestone.mdl @@ -0,0 +1,335 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. * + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA’s Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + + +mdl 1.5; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +const string DESCRIPTION = "A ground stone material"; + + + + +float histogram_range(float input, float range = 1.0f, float position = 0.5f) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(::math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + +float remap_xy_to_0_1(float input, float x, float y) +{ + return (input - x)/(y - x); +} + +float histogram_scan_big(float input, float width, float position) +{ + return ::math::clamp( + remap_xy_to_0_1(input, + ::math::lerp(-width, 1.0, position), + ::math::lerp(0.0, 1.0 + width, position)), + 0.0, + 1.0); +} + +::base::texture_coordinate_info transform_coordinate_2( + float4x4 transform + [[ ::anno::description("A transformation to be applied to the source coordinates. rotation_translation_scale() is a suggested means to compute the transformation matrix.") ]], + ::base::texture_coordinate_info coordinate = ::base::texture_coordinate_info() + [[ ::anno::description("Coordinate, typically sourced from coordinate_source or coordinate_projection.") ]] +) [[ + ::anno::description("Transform a texture coordinate by a matrix.") , + ::anno::noinline() + ]] +{ + // Version 2 + float4 r_position = transform * float4(coordinate.position.x,coordinate.position.y,coordinate.position.z,1); + //Try aproximating it for the case that the rotation is only aroud z and assuming the texture layout is nice and z is ~constant. + //just pretend there is no other rotation happening + //get rid of scaling and translation. Then extract fields where sin and cos would be in a simple 2d transform around z. + float4 u = transform[0]; + float3 ru = ::math::normalize(float3(u.x,u.y,u.z)); + float cos = ru.x; + float sin = -ru.y; + + + return ::base::texture_coordinate_info( + float3(r_position.x,r_position.y,r_position.z), + ::math::normalize(cos * coordinate.tangent_u - sin * coordinate.tangent_v), + ::math::normalize(cos * coordinate.tangent_v + sin * coordinate.tangent_u)); +} + +float3 normalmap_normal( + uniform texture_2d texture, + float factor = 1.0, + ::base::texture_coordinate_info uvw = ::base::texture_coordinate_info() +) +{ + float3 lookup = (::tex::lookup_float3(texture, float2(uvw.position.x, uvw.position.y)) - float3(0.5)) * (factor * 2.0); + return ::math::normalize(uvw.tangent_u * lookup.x + uvw.tangent_v * lookup.y + ::state::normal() * (lookup.z + (1.0 - factor))); +} + +::base::texture_coordinate_info vmat_transform( + float2 translation = float2(0.0, 0.0), + float rotation = 0.0, // rotation in degrees + float2 scaling = float2(1.0, 1.0), + uniform ::base::texture_coordinate_system system = ::base::texture_coordinate_uvw, + uniform int uv_space = 0 +) +{ + float rotation_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + float4x4 scale = + float4x4(1.0 /scaling.x, 0. , 0. , 0., + 0. , 1.0 /scaling.y , 0. , 0., + 0. , 0. , 1.0, 0., + translation.x , translation.y , 0.0, 1.); + + float s = ::math::sin(rotation_rad); + float c = ::math::cos(rotation_rad); + float4x4 rotate = + float4x4( c , -s , 0.0 , 0.0, + s , c , 0.0 , 0.0, + 0.0, 0.0 , 1.0 , 0.0, + 0. , 0.0 , 0.0 , 1.); + + return transform_coordinate_2(scale*rotate, ::base::coordinate_source(system, uv_space)); +} + + +export material Small_Cobblestone( + float brightness = .65f [[ + ::anno::description("Adjusts the general brightness of the material."), + ::anno::display_name("Brightness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(0) + ]], + float bricks_roughness = .8f [[ + ::anno::description("Adjusts the roughness of the paving blocks."), + ::anno::display_name("Paving Blocks Roughness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float water_height = 0.f [[ + ::anno::description("Raise the level of water surrounding the bricks."), + ::anno::display_name("Water Level"), + ::anno::in_group("Appearance", "Water"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float water_transition_softness = 0.f [[ + ::anno::description("Adjusts the softness of the transition from dry material to water. A softer transition will show areas, where the material gets moist first before being submerged in water."), + ::anno::display_name("Water Transition Softness"), + ::anno::in_group("Appearance", "Water"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(3) + ]], + float bump_strength = 1.f [[ + ::anno::description("Specifies the strength of the bump, lowering this value males the surface appear flat."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(4) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(5) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(6) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(.3f, .3f)), + ::anno::ui_order(7) + ]], + uniform int uv_space_index_1 = 0 [[ + ::anno::description("Use selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Advanced"), + ::anno::ui_order(8) + ]]) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Small Cobblestone"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "stone", "nature", "weathered", "water", "exterior", "rough", "urban", "city", "bright", "shiny", "paving", "level", "cobblestone", "small", "rock", "yellow", "brown", "grey")), + ::anno::thumbnail("./.thumbs/Small_Cobblestone.Small_Cobblestone.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] + = + let { + bool tmp0 = false; + material_surface tmp1(::df::custom_curve_layer(0.0399999991f, 1.f, 5.f, ::math::lerp(1.f, histogram_scan_big(::math::pow(float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 3.30900025f), 0.971000075f, 0.506000042f), ::math::smoothstep(::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f - (water_transition_softness * 0.859999955f + 0.00999999978f), ::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f + (water_transition_softness * 0.859999955f + 0.00999999978f), float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2])), ::df::microfacet_ggx_vcavities_bsdf(::math::lerp(0.f, ::math::lerp(histogram_range(float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, 0.855000019f), histogram_range(float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 0.408000022f, bricks_roughness * 0.519999981f + 0.479999989f), ::base::file_texture(texture_2d("./cobblestone_tiny_mask.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).mono), ::math::smoothstep(::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f - (water_transition_softness * 0.859999955f + 0.00999999978f), ::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f + (water_transition_softness * 0.859999955f + 0.00999999978f), float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2])) * ::math::lerp(0.f, ::math::lerp(histogram_range(float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, 0.855000019f), histogram_range(float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 0.408000022f, bricks_roughness * 0.519999981f + 0.479999989f), ::base::file_texture(texture_2d("./cobblestone_tiny_mask.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).mono), ::math::smoothstep(::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f - (water_transition_softness * 0.859999955f + 0.00999999978f), ::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f + (water_transition_softness * 0.859999955f + 0.00999999978f), float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2])), ::math::lerp(0.f, ::math::lerp(histogram_range(float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, 0.855000019f), histogram_range(float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 0.408000022f, bricks_roughness * 0.519999981f + 0.479999989f), ::base::file_texture(texture_2d("./cobblestone_tiny_mask.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).mono), ::math::smoothstep(::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f - (water_transition_softness * 0.859999955f + 0.00999999978f), ::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f + (water_transition_softness * 0.859999955f + 0.00999999978f), float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2])) * ::math::lerp(0.f, ::math::lerp(histogram_range(float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, 0.855000019f), histogram_range(float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 0.408000022f, bricks_roughness * 0.519999981f + 0.479999989f), ::base::file_texture(texture_2d("./cobblestone_tiny_mask.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).mono), ::math::smoothstep(::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f - (water_transition_softness * 0.859999955f + 0.00999999978f), ::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f + (water_transition_softness * 0.859999955f + 0.00999999978f), float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2])), color(1.f, 1.f, 1.f), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::diffuse_reflection_bsdf(nvidia::core_definitions::blend_colors(nvidia::core_definitions::blend_colors(::base::file_texture(texture_2d("./cobblestone_tiny_diff.jpg", ::tex::gamma_srgb), color(0.f, 0.f, 0.f), ::math::lerp(color(0.507079005f, 0.507079005f, 0.507079005f), color(1.f, 1.f, 1.f), ::math::smoothstep(::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f - (water_transition_softness * 0.859999955f + 0.00999999978f), ::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f + (water_transition_softness * 0.859999955f + 0.00999999978f), float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2])), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint, color(0.f, 0.f, 0.f), ::base::color_layer_multiply, ::math::lerp(0.620000005f, -0.239999995f, brightness)).tint, color(0.284646988f, 0.245784f, 0.231759995f), ::base::color_layer_screen, ::math::smoothstep(::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f - (water_transition_softness * 0.859999955f + 0.00999999978f), ::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f + (water_transition_softness * 0.859999955f + 0.00999999978f), float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2]) * (1.f - ::base::file_texture(texture_2d("./cobblestone_tiny_mask.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).mono) * 0.f).tint, 0.f), ::state::normal()), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(1.f, 1.f, 1.f); + material_geometry tmp5(float3(0.f), 1.f, normalmap_normal(texture_2d("./cobblestone_tiny_norm.jpg", ::tex::gamma_linear), ::math::lerp(0.f, bump_strength * 2.f, ::math::smoothstep(::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f - (water_transition_softness * 0.859999955f + 0.00999999978f), ::math::lerp(0.359999985f, 1.f, water_height) * 0.98999995f + (water_transition_softness * 0.859999955f + 0.00999999978f), float3(::base::file_texture(texture_2d("./cobblestone_tiny_multi.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2])), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index_1))); + } in + material( + thin_walled: tmp0, + surface: tmp1, + backface: tmp2, + ior: tmp3, + geometry: tmp5); + + +export material Small_Cobblestone_Bright(*) +[[ + ::anno::display_name("Small Cobblestone Bright"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "stone", "nature", "weathered", "water", "exterior", "rough", "urban", "city", "bright", "shiny", "paving", "level" , "cobblestone", "small", "rock", "yellow", "brown", "grey")), + ::anno::thumbnail("./.thumbs/Small_Cobblestone.Small_Cobblestone_Bright.png"), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += Small_Cobblestone +( + brightness: 1.f, + bricks_roughness: .2f, + water_height: 0.f, + water_transition_softness: 0.f, + bump_strength: 1.f, + texture_translate: 0.0f, + texture_rotate: 0.f, + texture_scale: 1.0f, + uv_space_index_1: 0 +); + +export material Small_Cobblestone_Wet_Grouts(*) +[[ + ::anno::display_name("Small Cobblestone Wet Grouts"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "stone", "nature", "weathered", "water", "exterior", "rough", "urban", "city", "bright", "shiny", "paving", "level", "wet", "grouts", "cobblestone", "small", "rock", "yellow", "brown", "grey")), + ::anno::thumbnail("./.thumbs/Small_Cobblestone.Small_Cobblestone_Wet_Grouts.png"), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += Small_Cobblestone +( + brightness: 1.f, + bricks_roughness: .2f, + water_height: .35f, + water_transition_softness: 0.f, + bump_strength: 1.f, + texture_translate: 0.0f, + texture_rotate: 0.f, + texture_scale: 1.0f, + uv_space_index_1: 0 +); + +export material Small_Cobblestone_Flooded_Grouts(*) +[[ + ::anno::display_name("Small Cobblestones Flooded Grouts"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "stone", "nature", "weathered", "water", "exterior", "rough", "urban", "city", "bright", "shiny", "paving", "level", "wet", "grouts", "cobblestone", "flooded", "small", "rock", "yellow", "brown", "grey")), + ::anno::thumbnail("./.thumbs/Small_Cobblestone.Small_Cobblestone_Flooded_Grouts.png"), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += Small_Cobblestone +( + brightness: 1.f, + bricks_roughness: .2f, + water_height: .75f, + water_transition_softness: 0.2f, + bump_strength: 1.f, + texture_translate: 0.0f, + texture_rotate: 0.f, + texture_scale: 1.0f, + uv_space_index_1: 0 +); + +export material Small_Cobblestone_Water_Flooded(*) +[[ + ::anno::display_name("Small Cobblestone Water Flooded"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "stone", "nature", "weathered", "water", "exterior", "rough", "urban", "city", "bright", "shiny", "paving", "level", "wet", "grouts", "cobblestone", "flooded", "water", "small", "rock", "yellow", "brown", "grey")), + ::anno::thumbnail("./.thumbs/Small_Cobblestone.Small_Cobblestone_Water_Flooded.png"), + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += Small_Cobblestone +( + brightness: 1.f, + bricks_roughness: 0.f, + water_height: 1.f, + water_transition_softness: 0.3f, + bump_strength: 1.f, + texture_translate: 0.0f, + texture_rotate: 0.f, + texture_scale: 1.0f, + uv_space_index_1: 0 +); diff --git a/Assets/Material/material_0363/abs_hard_leather_multi_R_rough_G_height_B_ao.jpg b/Assets/Material/material_0363/abs_hard_leather_multi_R_rough_G_height_B_ao.jpg new file mode 100644 index 0000000000000000000000000000000000000000..cf5bfc5881fd7e4985a3077ae74818a0ee538d18 --- /dev/null +++ b/Assets/Material/material_0363/abs_hard_leather_multi_R_rough_G_height_B_ao.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4eb820a71736199ae56d2cfaba55c0368b8d2b8eabf8282d969b4368e6fd17ed +size 6137000 diff --git a/Assets/Material/material_0363/abs_hard_leather_norm.jpg b/Assets/Material/material_0363/abs_hard_leather_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..47e455308115f7dfe8e9c783d30283e7d2b2ef46 --- /dev/null +++ b/Assets/Material/material_0363/abs_hard_leather_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1f7d79c325719f7576cd005047666285990ae1ee506ef95a8f8131dc369c3841 +size 5230267 diff --git a/Assets/Material/material_0363/leather_punch_atlas_01.png b/Assets/Material/material_0363/leather_punch_atlas_01.png new file mode 100644 index 0000000000000000000000000000000000000000..327339cd61c7bc11e5be2b4990b79b47968cb352 --- /dev/null +++ b/Assets/Material/material_0363/leather_punch_atlas_01.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:10af36556209f50d6b5b04182df33a977fed9ff959e772284e516332a33daac9 +size 2050660 diff --git a/Assets/Material/material_0364/ABS_Quilted_Leather.mdl b/Assets/Material/material_0364/ABS_Quilted_Leather.mdl new file mode 100644 index 0000000000000000000000000000000000000000..e1be4e3f679033d96c121bc08bd5739c3b0a2873 --- /dev/null +++ b/Assets/Material/material_0364/ABS_Quilted_Leather.mdl @@ -0,0 +1,620 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. * + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + + +mdl 1.6; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +const string DESCRIPTION = "A synthetic leather material."; + + + +float remap(float input, float low, float high) +{ + //return low + input * (high - low); + return ::math::lerp(low, high, input); +} + +int lowbias32(int x) +{ + x ^= x >>> 16; + x *= 0x7feb352d; + x ^= x >>> 15; + x *= 0x846ca68b; + x ^= x >>> 16; + return x; +} + +float uint2float(int x) +{ + return float(x & 0x7FFFFFFF) + (x < 0 ? 2147483648.0 : 0.0); +} + + + +float2 rnd22(int2 p) { + float2 ret_val = float2( + uint2float(lowbias32(p[0] + lowbias32(p[1]))) / 4294967296.f, + uint2float(lowbias32(p[0] + 32000 + lowbias32(p[1]))) / 4294967296.f + ); + return ret_val; +} + +float2x2 invert_2x2(float2x2 M) +{ + float det = M[0][0]*M[1][1] - M[0][1]*M[1][0]; + //https://www.chilimath.com/lessons/advanced-algebra/inverse-of-a-2x2-matrix/ + return (1.0 / det) * float2x2(M[1][1], -M[0][1], -M[1][0], M[0][0]); +} + +float3 srgb2rgb(float3 val) +{ + return ::math::pow(::math::max(val, float3(0.0f)), 2.2); +} + +float3 rgb2srgb(float3 val) [[ anno::unused() ]] { + return ::math::pow( ::math::max(val, float3(0.f)), float3(1./2.2) ); +} + + +float3 nonrepeat_lookup( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5), + float patch_size = 8.0 +) +{ + + float2 uv_in = float2(uvw.position[0], uvw.position[1]) * texture_scale; + float Z = patch_size; // patch scale inside example texture + + float3 O = float3(0.f); + float2x2 M0 = float2x2(1.f,0.f, 0.5f, ::math::sqrt(3.f)/2.f); + float2x2 M = invert_2x2(M0); // transform matrix <-> tilted space + + float2 U = uv_in; + float2 V = M * uv_in; //pre-tilted hexa coordinates + int2 I = int2(::math::floor(V)); // hexa-tile id + + // The mean color needs to be determined in Photoshop then to make the + // average color work out, take the float value and calculate the apropriate + // mean value as (value^(1/2.2)) + + float3 m = average_color; + + float3 F = float3(::math::frac(V)[0], ::math::frac(V)[1], 0.f), W; + F[2] = 1.0 - F[0] - F[1]; // local hexa coordinates + + if( F[2] > 0.f ) + O = (W[0] = F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I))) - m) + + (W[1] = F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0,1)))) - m) + + (W[2] = F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1,0)))) - m); + else + O = (W[0] = -F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1)))) - m) + + (W[1] = 1.f - F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1, 0)))) - m) + + (W[2] = 1.f - F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0, 1)))) - m); + O = m + O/::math::length(W); + O = ::math::clamp( (O), 0.0, 1.0); + + return float3(O); +} + +float histogram_range(float input, float range = 1.0f, float position = 0.5f) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + +float remap_xy_to_0_1(float input, float x, float y) +{ + return (input - x)/(y - x); +} + +float histogram_scan_big(float input, float width, float position) +{ + return ::math::clamp( + remap_xy_to_0_1(input, + ::math::lerp(-width, 1.0, position), + ::math::lerp(0.0, 1.0 + width, position)), + 0.0, + 1.0); +} + +::base::texture_coordinate_info transform_coordinate_2( + float4x4 transform + [[ anno::description("A transformation to be applied to the source coordinates. rotation_translation_scale() is a suggested means to compute the transformation matrix.") ]], + ::base::texture_coordinate_info coordinate = ::base::texture_coordinate_info() + [[ anno::description("Coordinate, typically sourced from coordinate_source or coordinate_projection.") ]] +) [[ + ::anno::description("Transform a texture coordinate by a matrix.") , + ::anno::noinline() + ]] +{ + // Version 2 + float4 r_position = transform * float4(coordinate.position.x,coordinate.position.y,coordinate.position.z,1); + //Try aproximating it for the case that the rotation is only aroud z and assuming the texture layout is nice and z is ~constant. + //just pretend there is no other rotation happening + //get rid of scaling and translation. Then extract fields where sin and cos would be in a simple 2d transform around z. + float4 u = transform[0]; + float3 ru = ::math::normalize(float3(u.x,u.y,u.z)); + float cos = ru.x; + float sin = -ru.y; + + + return ::base::texture_coordinate_info( + float3(r_position.x,r_position.y,r_position.z), + math::normalize(cos * coordinate.tangent_u - sin * coordinate.tangent_v), + math::normalize(cos * coordinate.tangent_v + sin * coordinate.tangent_u)); +} + +::base::texture_coordinate_info vmat_transform( + float2 translation = float2(0.0, 0.0), + float rotation = 0.0, // rotation in degrees + float2 scaling = float2(1.0, 1.0), + uniform ::base::texture_coordinate_system system = ::base::texture_coordinate_uvw, + uniform int uv_space = 0 +) +{ + float rotation_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + float4x4 scale = + float4x4(1.0 /scaling.x, 0. , 0. , 0., + 0. , 1.0 /scaling.y , 0. , 0., + 0. , 0. , 1.0, 0., + translation.x , translation.y , 0.0, 1.); + + float s = ::math::sin(rotation_rad); + float c = ::math::cos(rotation_rad); + float4x4 rotate = + float4x4( c , -s , 0.0 , 0.0, + s , c , 0.0 , 0.0, + 0.0, 0.0 , 1.0 , 0.0, + 0. , 0.0 , 0.0 , 1.); + + return transform_coordinate_2(scale*rotate, ::base::coordinate_source(system, uv_space)); +} + + +color endless_texture( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 10.0, + float3 average_color = float3(0.5, 0.5, .5), + float patch_size = 8.0, + bool gamma_correct_lookup = true +) +{ + return gamma_correct_lookup ? color(srgb2rgb( + nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )) + ) : color(nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )); +} + +export material ABS_Quilted_Leather( + color leather_color = color(0.366253f, 0.226966f, 0.012983f) [[ + ::anno::description("Choose the color of the leather."), + ::anno::display_name("Leather Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + color seam_color = color(0.238398f, 0.097587f, 0.029557f) [[ + ::anno::description("Choose the color of the seam."), + ::anno::display_name("Seam Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(1) + ]], + float brightness_ao_cavity = 0.45f [[ + ::anno::description("Adjusts the lightness of the cavity."), + ::anno::display_name("Cavity Brightness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float roughness = .25f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(3) + ]], + float roughness_variation = .1f [[ + ::anno::description("Amount of variation applied to the roughness, higher numbers lead to non uniform reflections of the material."), + ::anno::display_name("Roughness Variation"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(4) + ]], + uniform float bump_strength = .5f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(5) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(7) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(8) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(9) + ]], + uniform bool enable_round_corners = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(10) + ]], + uniform float radius = 1.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(11) + ]], + uniform bool across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(12) + ]]) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Mustard"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "mustard", "soft", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] + = + let { + bool tmp0 = false; + material_surface tmp1(df::custom_curve_layer(0.0399999991f, 1.f, 5.f, math::pow(histogram_scan_big(float3(endless_texture(texture_2d("./abs_quilted_leather_multi_R_rough_G_ao_B_seam.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), 3.f, float3(0.698038995f, 0.815685987f, 0.686275005f), 3.f, false))[0], 1.f, math::lerp(0.f, 0.729999959f, math::pow(roughness_variation, 0.289999992f))), 1.49000001f), df::microfacet_ggx_smith_bsdf(nvidia::core_definitions::blend_colors(color(float3(base::file_texture(texture_2d("./abs_quilted_leather_multi_R_rough_G_ao_B_seam.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), tex::wrap_repeat, tex::wrap_repeat, false, 0.f, int2(0), tex::wrap_repeat, 30.f).tint)[2]), color(histogram_range(math::lerp(1.f, 0.f, float3(base::file_texture(texture_2d("./abs_quilted_leather_multi_R_rough_G_ao_B_seam.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), tex::wrap_repeat, tex::wrap_repeat, false, 0.f, int2(0), tex::wrap_repeat, 30.f).tint)[1]), 0.769999981f, math::lerp(0.400000006f, 0.969999969f, roughness))), base::color_layer_add, 1.f, true).mono, nvidia::core_definitions::blend_colors(color(float3(base::file_texture(texture_2d("./abs_quilted_leather_multi_R_rough_G_ao_B_seam.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), tex::wrap_repeat, tex::wrap_repeat, false, 0.f, int2(0), tex::wrap_repeat, 30.f).tint)[2]), color(histogram_range(math::lerp(1.f, 0.f, float3(base::file_texture(texture_2d("./abs_quilted_leather_multi_R_rough_G_ao_B_seam.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), tex::wrap_repeat, tex::wrap_repeat, false, 0.f, int2(0), tex::wrap_repeat, 30.f).tint)[1]), 0.769999981f, math::lerp(0.400000006f, 0.969999969f, roughness))), base::color_layer_add, 1.f, true).mono, color(1.f, 1.f, 1.f), color(0.f, 0.f, 0.f), state::texture_tangent_u(0), df::scatter_reflect), df::weighted_layer(1.f, df::diffuse_reflection_bsdf(nvidia::core_definitions::blend_colors(nvidia::core_definitions::blend_colors(leather_color, color(histogram_range(0.140000001f, 1.f, float3(base::file_texture(texture_2d("./abs_quilted_leather_multi_R_rough_G_ao_B_seam.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), tex::wrap_repeat, tex::wrap_repeat, false, 0.f, int2(0), tex::wrap_repeat, 30.f).tint)[1])), base::color_layer_multiply, math::lerp(0.930000007f, 0.149999991f, remap(math::pow(brightness_ao_cavity, 3.f), 0.f, 10.f)), true).tint, nvidia::core_definitions::blend_colors(color(histogram_range(float3(base::file_texture(texture_2d("./abs_quilted_leather_multi_R_rough_G_ao_B_seam.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), tex::wrap_repeat, tex::wrap_repeat, false, 0.f, int2(0), tex::wrap_repeat, 30.f).tint)[2], 1.f, 0.469999999f)), seam_color, base::color_layer_multiply, 1.f, true).tint, base::color_layer_blend, float3(base::file_texture(texture_2d("./abs_quilted_leather_multi_R_rough_G_ao_B_seam.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), tex::wrap_repeat, tex::wrap_repeat, false, 0.f, int2(0), tex::wrap_repeat, 30.f).tint)[2], false).tint, 0.f), bsdf(), base::tangent_space_normal_texture(texture_2d("./abs_quilted_leather_norm.jpg", ::tex::gamma_linear), math::lerp(0.f, 1.89999998f, bump_strength), false, false, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), tex::wrap_repeat, tex::wrap_repeat, false, 1.f, 0.f, 0.f, int2(0), tex::wrap_repeat, 30.f)), base::tangent_space_normal_texture(texture_2d("./abs_quilted_leather_norm.jpg", ::tex::gamma_linear), math::lerp(0.f, 1.89999998f, bump_strength), false, false, vmat_transform(texture_translate, texture_rotate, texture_scale * 0.5f, base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), tex::wrap_repeat, tex::wrap_repeat, false, 1.f, 0.f, 0.f, int2(0), tex::wrap_repeat, 30.f)), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(1.f, 1.f, 1.f); + material_geometry tmp5(float3(0.f), 1.f, enable_round_corners ? state::rounded_corner_normal(radius, across_materials, 1.f) : state::normal()); + + } in + material( + thin_walled: tmp0, + surface: tmp1, + backface: tmp2, + ior: tmp3, + geometry: tmp5); + +export material ABS_Quilted_Leather_Radish(*) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Radish"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "radish", "dark", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather_Radish.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += ABS_Quilted_Leather +( + leather_color: color(0.027321f, 0.004777f, 0.012983f), + seam_color: color(0.034340f, 0.076185f, 0.034340f), + brightness_ao_cavity: .45f, + roughness: .25f, + roughness_variation: .1f, + bump_strength: 1.f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.f, + uv_space_index: 0, + enable_round_corners: false, + radius: 1.5f, + across_materials: false +); + +export material ABS_Quilted_Leather_Purple(*) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Purple"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "purple", "dark", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather_Purple.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += ABS_Quilted_Leather +( + leather_color: color(0.025187f, 0.004777f, 0.027321f), + seam_color: color(0.034340f, 0.076185f, 0.034340f), + brightness_ao_cavity: .45f, + roughness: .25f, + roughness_variation: .1f, + bump_strength: .5f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.f, + uv_space_index: 0, + enable_round_corners: false, + radius: 1.5f, + across_materials: false +); + +export material ABS_Quilted_Leather_Dark_Purple(*) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Dark Purple"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "purple", "dark", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather_Dark_Purple.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += ABS_Quilted_Leather +( + leather_color: color(0.010960f, 0.004777f, 0.026241f), + seam_color: color(0.034340f, 0.076185f, 0.034340f), + brightness_ao_cavity: .45f, + roughness: .25f, + roughness_variation: .1f, + bump_strength: .5f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.f, + uv_space_index: 0, + enable_round_corners: false, + radius: 1.5f, + across_materials: false +); + +export material ABS_Quilted_Leather_Dark_Blue(*) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Dark Blue"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "blue", "cool", "dark", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather_Dark_Blue.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += ABS_Quilted_Leather +( + leather_color: color(0.004777f, 0.009721f, 0.027321f), + seam_color: color(0.715694f, 0.610496f, 0.004025f), + brightness_ao_cavity: .45f, + roughness: .25f, + roughness_variation: .1f, + bump_strength: .5f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.f, + uv_space_index: 0, + enable_round_corners: false, + radius: 1.5f, + across_materials: false +); + +export material ABS_Quilted_Leather_Dark_Turquoise(*) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Dark Turquoise"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "turquoise", "cool", "dark", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather_Dark_Turquoise.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += ABS_Quilted_Leather +( + leather_color: color(0.004777f, 0.019382f, 0.027321f), + seam_color: color(0.337164f, 0.262251f, 0.012983f), + brightness_ao_cavity: .45f, + roughness: .25f, + roughness_variation: .1f, + bump_strength: .5f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.f, + uv_space_index: 0, + enable_round_corners: false, + radius: 1.5f, + across_materials: false +); + +export material ABS_Quilted_Leather_Moss(*) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Moss"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "moss", "cool", "dark", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather_Moss.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += ABS_Quilted_Leather +( + leather_color: color(0.017642f, 0.027321f, 0.004777f), + seam_color: color(0.337164f, 0.099899f, 0.012983f), + brightness_ao_cavity: .45f, + roughness: .25f, + roughness_variation: .1f, + bump_strength: .5f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.f, + uv_space_index: 0, + enable_round_corners: false, + radius: 1.5f, + across_materials: false +); + +export material ABS_Quilted_Leather_Brown(*) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Brown"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "brown", "warm", "dark", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather_Brown.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += ABS_Quilted_Leather +( + leather_color: color(0.026241f, 0.012983f, 0.012983f), + seam_color: color(0.012983f, 0.012983f, 0.012983f), + brightness_ao_cavity: .45f, + roughness: .25f, + roughness_variation: .1f, + bump_strength: .5f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.f, + uv_space_index: 0, + enable_round_corners: false, + radius: 1.5f, + across_materials: false +); + +export material ABS_Quilted_Leather_Black(*) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Black"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "black", "dark", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather_Black.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += ABS_Quilted_Leather +( + leather_color: color(0.012983f, 0.012983f, 0.012983f), + seam_color: color(0.564712f, 0.552011f, 0.361307f), + brightness_ao_cavity: .45f, + roughness: .25f, + roughness_variation: .1f, + bump_strength: .5f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.f, + uv_space_index: 0, + enable_round_corners: false, + radius: 1.5f, + across_materials: false +); + +export material ABS_Quilted_Leather_Red(*) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("ABS Quilted Leather - Red"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("dielectric", "automotive", "ABS", "quilted", "artifical", "red", "warm", "leather", "car", "dashboard", "cloth", "furniture")), + ::anno::thumbnail("./.thumbs/ABS_Quilted_Leather.ABS_Quilted_Leather_Red.png"), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab") +]] += ABS_Quilted_Leather +( + leather_color: color(0.201556f, 0.012983f, 0.012983f), + seam_color: color(0.791298f, 0.693872f, 0.012983f), + brightness_ao_cavity: .45f, + roughness: .25f, + roughness_variation: .1f, + bump_strength: .5f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.f, + uv_space_index: 0, + enable_round_corners: false, + radius: 1.5f, + across_materials: false +); \ No newline at end of file diff --git a/Assets/Material/material_0369/Pigmented_Smooth_Leather.mdl b/Assets/Material/material_0369/Pigmented_Smooth_Leather.mdl new file mode 100644 index 0000000000000000000000000000000000000000..e84ab353a317d019f63b57669dbc8af8d2b7e64e --- /dev/null +++ b/Assets/Material/material_0369/Pigmented_Smooth_Leather.mdl @@ -0,0 +1,1644 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. * + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + + +mdl 1.5; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +const string DESCRIPTION = "A pigmented smooth leather material"; +const string DESCRIPTION_PUNCHED = "A pigmented smooth leather material with punched holes. Various shapes for the punching such as circles, lines, rectangles and squares can be chosen."; + +annotation preview_scale( float f); + + +// returns the min-max coordinates of a 2x2 atlas tile +float4 tile_select_2x2(uniform int select = 0) +{ + switch(select) + { + case 2: return float4(0.0f, 0.5f, 0.0f, 0.5f); + case 3: return float4(0.5f, 1.0f, 0.0f, 0.5f); + case 0: return float4(0.0f, 0.5f, 0.5f, 1.0f); + case 1: return float4(0.5f, 1.0f, 0.5f, 1.0f); + + default: return float4(0.0f, 0.5f, 0.0f, 0.5f); + } +} + + +export struct vm_coordinates +[[ + ::anno::hidden() +]] +{ + float2 uv; + float rotation; + int uv_space_index; + float4 carry; +}; + +enum vm_mono_select +[[ + anno::description("Modes for the creation of a gray-scale value from a color."), + anno::hidden() +]] +{ + mono_r = 0, + mono_g = 1, + mono_b = 2, + mono_a = 3, + mono_average = 4 +}; + +vm_coordinates vm_coord +( + float2 translation = float2(0.0f, 0.0) [[ + ::anno::display_name("Translation"), + ::anno::description("Translates the coordinates.") + ]], + float rotation = 0.0f [[ + ::anno::display_name("Rotation"), + ::anno::description("Rotates the coordinates in degrees.") + ]], + float2 scaling = float2(1.0f, 1.0f) [[ + ::anno::display_name("Scaling"), + ::anno::description("Scales the coordinates.") + ]], + uniform int uv_space = 0 [[ + ::anno::display_name("UV Space"), + ::anno::description("Choose the UV space.") + ]] +) +[[ + ::anno::display_name("vm Transform"), + ::anno::description("Generates coordinates to be used in vm_lookup functions.") +]] +{ + vm_coordinates uv; + ::base::texture_coordinate_info info = ::base::coordinate_source( ::base::texture_coordinate_uvw, uv_space); + uv.rotation = (rotation * 3.1415926535897932384626433832f) / 180.f; + uv.uv = float2(info.position.x, info.position.y); + float sine = ::math::sin(uv.rotation); + float cosine = ::math::cos(uv.rotation); + float2x2 rot = float2x2(cosine, -sine, sine, cosine); + uv.uv = rot * uv.uv; + uv.uv /= scaling; + uv.uv += translation; + return uv; +} + + +vm_coordinates vm_coord_hex( + vm_coordinates uv, + float scale = 1.0f, + float rotation = 45.0f + + //,float2 rot_center=0.5f +) +{ + vm_coordinates uv_return; + float2 uv_ = float2(uv.uv.x, uv.uv.y); + float rot_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + + float sine = ::math::sin(rot_rad); + float cosine = ::math::cos(rot_rad); + float2x2 rot = float2x2(cosine, -sine, sine, cosine); + + // same as from function get_hex above + float2 s = float2(1.0f, 1.7320508f); + float2 n = uv_ - float2(0.5f, 1.0f); + float4 c = ::math::floor(float4(uv_.x, uv_.y, n.x, n.y)/float4(s.x, s.y, s.x, s.y)) + 0.5f; + float2 h_1 = uv_ - float2(c.x, c.y) * s; + float2 h_2 = uv_ - (float2(c.z, c.w) + 0.5f) * s; + float4 uv_id = ::math::dot(h_1, h_1) < ::math::dot(h_2, h_2) ? float4(h_1.x, h_1.y, c.x, c.y) : float4(h_2.x, h_2.y, c.z, c.w); + + float2 id_xy = float2(uv_id.x, uv_id.y); + + //uv_return.uv = float2(id_xy.x*scale+.5f, id_xy.y*scale+.5f); + uv_return.uv = rot*float2(id_xy.x*scale, id_xy.y*scale); + uv_return.uv += 0.5f; + + + // unless we introduce random cell rotations where we need to compensate for this in the rotation + // we can just plain copy the rotation value + uv_return.rotation = uv.rotation + rot_rad; + return uv_return; +} + +// Offsets a set of uv coordinates in either row (u) or column (v) direction +vm_coordinates vm_coord_rowcol_offset( + vm_coordinates uv, + float offset, + bool horizontal_offset = true +) +{ + int index = horizontal_offset ? 0 : 1; + uv.uv[index] += ::math::floor(uv.uv[index ^ 1]) * offset; + return uv; +} + +vm_coordinates vm_coord_grid( + vm_coordinates uv, + float scale = 1.0f, + float rotation = 45.0f +) +{ + float rot_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + float sine = ::math::sin(rot_rad); + float cosine = ::math::cos(rot_rad); + float2x2 rot = float2x2(cosine, -sine, sine, cosine); + + float2x2 scal = float2x2(scale, 0., 0., scale); + uv.uv = ::math::frac(uv.uv); + uv.uv -= 0.5f; + uv.uv = rot*(scal * uv.uv); + uv.uv = uv.uv + 0.5f; + uv.rotation += rot_rad; + return uv; +} + +::base::texture_return vm_tex_lookup( + uniform texture_2d tex, + vm_coordinates uv = vm_coord(), + uniform vm_mono_select mono_source = mono_a, + float4 scale = float4(1.0f), + + uniform ::tex::wrap_mode wrap_u = ::tex::wrap_repeat, + uniform ::tex::wrap_mode wrap_v = ::tex::wrap_repeat, + uniform float2 crop_u = float2(0.0, 1.0), + uniform float2 crop_v = float2(0.0, 1.0) +) +{ + float mono; + float4 lookup = ::tex::lookup_float4(tex, uv.uv, wrap_u, wrap_v, crop_u, crop_v) * scale; + switch( mono_source ) { + case mono_r: mono = lookup.x; + break; + case mono_g: mono = lookup.y; + break; + case mono_b: mono = lookup.z; + break; + case mono_a: mono = lookup.w; + break; + case mono_average: mono = ::math::average(float3(lookup.x, lookup.y, lookup.z)); + break; + } + return ::base::texture_return(color(lookup.x, lookup.y, lookup.z), mono); +} + +// *** SET CUTOUT ENUM NAMES *** +export enum cutout_pattern +[[ + ::anno::description("Cutout Pattern"), + ::anno::hidden() +]] +{ + pattern_circle = 0 + [[ ::anno::display_name("Circle")]], + pattern_hexagon = 1 + [[ ::anno::display_name("Square")]], + pattern_line = 2 + [[ ::anno::display_name("Line") ]], + + pattern_square = 3 + [[ ::anno::display_name("Rectangle")]] +}; + +float2x2 invert_2x2(float2x2 M) +{ + float det = M[0][0]*M[1][1] - M[0][1]*M[1][0]; + //https://www.chilimath.com/lessons/advanced-algebra/inverse-of-a-2x2-matrix/ + return (1.0 / det) * float2x2(M[1][1], -M[0][1], -M[1][0], M[0][0]); +} + +float uint2float(int x) +{ + return float(x & 0x7FFFFFFF) + (x < 0 ? 2147483648.0 : 0.0); +} + +int lowbias32(int x) +{ + x ^= x >>> 16; + x *= 0x7feb352d; + x ^= x >>> 15; + x *= 0x846ca68b; + x ^= x >>> 16; + return x; +} + +float2 rnd22(int2 p) { + float2 ret_val = float2( + uint2float(lowbias32(p[0] + lowbias32(p[1]))) / 4294967296.f, + uint2float(lowbias32(p[0] + 32000 + lowbias32(p[1]))) / 4294967296.f + ); + return ret_val; +} + +float3 srgb2rgb(float3 val) +{ + return ::math::pow(::math::max(val, float3(0.0f)), 2.2); +} + +float3 nonrepeat_lookup( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5), + float patch_size = 8.0 +) +{ + + float2 uv_in = float2(uvw.position[0], uvw.position[1]) * texture_scale; + float Z = patch_size; // patch scale inside example texture + float CON = 1.0f; + + float3 O = float3(0.f); + float2x2 M0 = float2x2(1.f,0.f, 0.5f, ::math::sqrt(3.f)/2.f); + float2x2 M = invert_2x2(M0); // transform matrix <-> tilted space + + float2 U = uv_in; + float2 V = M * uv_in; //pre-tilted hexa coordinates + int2 I = int2(::math::floor(V)); // hexa-tile id + + // The mean color needs to be determined in Photoshop then to make the + // average color work out, take the float value and calculate the apropriate + // mean value as (value^(1/2.2)) + + float3 m = average_color; + + float3 F = float3(::math::frac(V)[0], ::math::frac(V)[1], 0.f), W; + F[2] = 1.0 - F[0] - F[1]; // local hexa coordinates + + if( F[2] > 0.f ) + + O = (W[0] = F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I))) - m*float(CON)) + + (W[1] = F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0,1)))) - m*float(CON)) + + (W[2] = F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1,0)))) - m*float(CON)); + else + O = (W[0] = -F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1)))) - m*float(CON)) + + (W[1] = 1.f - F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1, 0)))) - m*float(CON)) + + (W[2] = 1.f - F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0, 1)))) - m*float(CON)); + O = m + O/::math::length(W); + O = ::math::clamp( (O), 0.0, 1.0); + + return float3(O); +} + + float3 endless_normal( + uniform texture_2d texture = texture_2d(), + float factor = 1.0, + bool flip_tangent_u = false, + bool flip_tangent_v = false, + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5, 0.5, 1.0), + float patch_size = 8.0 + //bool srgb2rgb = false, + //bool rgb2srgb = false +) +{ + float3 transformed_tangent_u = flip_tangent_u ? uvw.tangent_u : - uvw.tangent_u; + float3 transformed_tangent_v = flip_tangent_v ? uvw.tangent_v : - uvw.tangent_v; + + if (flip_tangent_u) + transformed_tangent_u=-transformed_tangent_u; + if (flip_tangent_v) + transformed_tangent_v=-transformed_tangent_v; + + // normalized Lookup + float3 tangent_space_normal = + (nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + ) - 0.5) * (2.0 * factor); + + + return ::math::normalize(uvw.tangent_u * tangent_space_normal.x + + uvw.tangent_v * tangent_space_normal.y + + ::state::normal()*1.0); + //return ::state::normal(); +} + + color endless_texture( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 10.0, + float3 average_color = float3(0.5, 0.5, 1.0), + float patch_size = 8.0, + bool gamma_correct_lookup = true +) +{ + return gamma_correct_lookup ? color(srgb2rgb( + nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )) + ) : color(nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )); +} + + float histogram_range(float input, float range = 1.0f, float position = 0.5f) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(::math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + +float remap_xy_to_0_1(float input, float x, float y) +{ + return (input - x)/(y - x); +} + +float histogram_scan_big(float input, float width, float position) +{ + return ::math::clamp( + remap_xy_to_0_1(input, + ::math::lerp(-width, 1.0, position), + ::math::lerp(0.0, 1.0 + width, position)), + 0.0, + 1.0); +} + +float3 normalmap_normal( + uniform texture_2d texture, + float factor = 1.0, + ::base::texture_coordinate_info uvw = ::base::texture_coordinate_info() +) +{ + float3 lookup = (::tex::lookup_float3(texture, float2(uvw.position.x, uvw.position.y)) - float3(0.5)) * (factor * 2.0); + return ::math::normalize(uvw.tangent_u * lookup.x + uvw.tangent_v * lookup.y + ::state::normal() * (lookup.z + (1.0 - factor))); +} + +::base::texture_coordinate_info transform_coordinate_2( + float4x4 transform + [[ ::anno::description("A transformation to be applied to the source coordinates. rotation_translation_scale() is a suggested means to compute the transformation matrix.") ]], + ::base::texture_coordinate_info coordinate = ::base::texture_coordinate_info() + [[ ::anno::description("Coordinate, typically sourced from coordinate_source or coordinate_projection.") ]] +) [[ + ::anno::description("Transform a texture coordinate by a matrix.") , + ::anno::noinline() + ]] +{ + // Version 2 + float4 r_position = transform * float4(coordinate.position.x,coordinate.position.y,coordinate.position.z,1); + //Try aproximating it for the case that the rotation is only aroud z and assuming the texture layout is nice and z is ~constant. + //just pretend there is no other rotation happening + //get rid of scaling and translation. Then extract fields where sin and cos would be in a simple 2d transform around z. + float4 u = transform[0]; + float3 ru = ::math::normalize(float3(u.x,u.y,u.z)); + float cos = ru.x; + float sin = -ru.y; + + return ::base::texture_coordinate_info( + float3(r_position.x,r_position.y,r_position.z), + ::math::normalize(cos * coordinate.tangent_u - sin * coordinate.tangent_v), + ::math::normalize(cos * coordinate.tangent_v + sin * coordinate.tangent_u)); +} + +::base::texture_coordinate_info vmat_transform( + float2 translation = float2(0.0, 0.0), + float rotation = 0.0, // rotation in degrees + float2 scaling = float2(1.0, 1.0), + uniform ::base::texture_coordinate_system system = ::base::texture_coordinate_uvw, + uniform int uv_space = 0 +) +{ + float rotation_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + float4x4 scale = + float4x4(1.0 /scaling.x, 0. , 0. , 0., + 0. , 1.0 /scaling.y , 0. , 0., + 0. , 0. , 1.0, 0., + translation.x , translation.y , 0.0, 1.); + + float s = ::math::sin(rotation_rad); + float c = ::math::cos(rotation_rad); + float4x4 rotate = + float4x4( c , -s , 0.0 , 0.0, + s , c , 0.0 , 0.0, + 0.0, 0.0 , 1.0 , 0.0, + 0. , 0.0 , 0.0 , 1.); + + return transform_coordinate_2(scale*rotate, ::base::coordinate_source(system, uv_space)); +} + +export material Pigmented_Smooth_Leather( + uniform bool infinite_tiling = true [[ + ::anno::description("Enables infinite tiling feature which removes repeating texture patterns. Note that depending on the material this feature changes the appearance of the material slightly."), + ::anno::display_name("Infinite Tiling"), + ::anno::in_group("Appearance") + ]], + float bump_strength = 0.3f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f) + ]], + color color_front = color(0.078057f, 0.049433f, 0.012664f) [[ + ::anno::description("Choose the color of the front side."), + ::anno::display_name("Color Front"), + ::anno::in_group("Appearance", "Front") + ]], + float diffuse_brightness_front = 0.5f [[ + ::anno::description("Adjusts the lightness of the material."), + ::anno::display_name("Brightness Front"), + ::anno::in_group("Appearance", "Front"), + ::anno::hard_range(0.f, 1.f) + ]], + float reflection_roughness_front = 0.25f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness Front"), + ::anno::in_group("Appearance", "Front"), + ::anno::hard_range(0.f, 1.f) + ]], + float imperfection_dust = 0.6f [[ + ::anno::description("Adds specular variation to the roughness."), + ::anno::display_name("Imperfection Dust"), + ::anno::in_group("Appearance", "Front", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + float imperfection_grunge = 0.1f [[ + ::anno::description("Adds specular variation to the roughness."), + ::anno::display_name("Imperfection Grunge"), + ::anno::in_group("Appearance", "Front", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + float imperfection_smudges = 0.3f [[ + ::anno::description("Adds specular variation to the roughness."), + ::anno::display_name("Imperfection Smudges"), + ::anno::in_group("Appearance", "Front", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + color color_back = color(0.151058f, 0.119264f, 0.063815f) [[ + ::anno::description("Choose the color of the back side."), + ::anno::display_name("Color Back"), + ::anno::in_group("Appearance", "Back") + ]], + float diffuse_brightness_back = 0.7f [[ + ::anno::description("Adjusts the lightness of the material."), + ::anno::display_name("Brightness Back"), + ::anno::in_group("Appearance", "Back"), + ::anno::hard_range(0.f, 1.f) + ]], + float reflection_roughness_back = 0.4f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness Back"), + ::anno::in_group("Appearance", "Back"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform bool dirt_back_on_off = true [[ + ::anno::description("Switch on and off the dirt layer on the backside."), + ::anno::display_name("Dirt Back"), + ::anno::in_group("Appearance", "Dirt") + ]], + color dirt_color = color(0.023f, 0.023f, 0.023f) [[ + ::anno::description("Choose the color of the dirt layer."), + ::anno::display_name("Color Dirt"), + ::anno::in_group("Appearance", "Dirt") + ]], + float dirt_softness = 0.8f [[ + ::anno::description("Adjust the transition between dirt and leather. From hard to soft."), + ::anno::display_name("Dirt Softness"), + ::anno::in_group("Appearance", "Dirt"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_amount = 0.2f [[ + ::anno::description("Adjust the intensity through position."), + ::anno::display_name("Dirt Amount"), + ::anno::in_group("Appearance", "Dirt"), + ::anno::hard_range(0.f, 1.f) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Translate"), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Rotate"), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Scale"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::preview_scale(3.5f), + ::anno::in_group("Transform") + ]], + uniform float radius = 1.5f [[ + ::anno::description("Radius of the rounded corners."), + ::anno::display_name("Radius mm"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool round_corners = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Round Corners"), + ::anno::in_group("Round Corners") + ]], + uniform bool across_materials = true [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners") + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Use selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Advanced") + ]]) +[[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Smooth Leather - Brown Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::author("NVIDIA vMaterials"), + ::anno::key_words(string[]("leather", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "brown", "warm")), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather.png") +]] + = + let { + float2 texture_scale_rescaled = texture_scale / 8.0f; + bool tmp0 = true; + + texture_2d rough_dirty_height_tex = texture_2d("./pigmented_smooth_leather_front_multi_rough_dirt_height.jpg", ::tex::gamma_linear); + texture_2d dust_grunge_leather_tex = texture_2d("./multi_R_dust_G_grunge_B_leather.jpg", ::tex::gamma_linear); + texture_2d front_diff_lin_tex = texture_2d("./pigmented_smooth_leather_front_diff.jpg", ::tex::gamma_linear); + texture_2d front_diff_srgb_tex = texture_2d("./pigmented_smooth_leather_front_diff.jpg", ::tex::gamma_srgb); + texture_2d front_norm_tex = texture_2d("./pigmented_smooth_leather_front_norm.jpg", ::tex::gamma_linear); + texture_2d back_rough_ao_height_tex = texture_2d("./pigmented_smooth_leather_back_multi_rough_ao_height.jpg", ::tex::gamma_linear); + texture_2d back_diff_lin_tex = texture_2d("./pigmented_smooth_leather_back_diff.jpg", ::tex::gamma_linear); + texture_2d back_diff_srgb_tex = texture_2d("./pigmented_smooth_leather_back_diff.jpg", ::tex::gamma_srgb); + texture_2d back_norm_tex = texture_2d("./pigmented_smooth_leather_back_norm.jpg", ::tex::gamma_linear); + + material_surface tmp1(::df::weighted_layer(::math::pow(::math::lerp(0.f, 1.f, ::math::smoothstep(::math::lerp(1.f, 0.f, dirt_amount) - dirt_softness, ::math::lerp(1.f, 0.f, dirt_amount) + dirt_softness, float3(infinite_tiling ? endless_texture(rough_dirty_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.753000021f, 0.409999996f, 0.698000014f), 8.f, false) : ::base::file_texture(rough_dirty_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1])), 2.43300009f), ::df::diffuse_reflection_bsdf(dirt_color, 0.800000012f), ::df::custom_curve_layer(0.0399999991f, 1.f, 5.f, histogram_scan_big(float3(infinite_tiling ? endless_texture(rough_dirty_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.753000021f, 0.409999996f, 0.698000014f), 8.f, false) : ::base::file_texture(rough_dirty_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.5f, 0.379999995f), ::df::microfacet_ggx_smith_bsdf(((float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[0] * imperfection_dust + histogram_range(float3(infinite_tiling ? endless_texture(rough_dirty_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.753000021f, 0.409999996f, 0.698000014f), 8.f, false) : ::base::file_texture(rough_dirty_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 0.701000035f, ::math::lerp(0.300000012f, 0.600000024f, reflection_roughness_front)) + (float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[1] * imperfection_grunge + (float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[2] * imperfection_smudges) * ((float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[0] * imperfection_dust + histogram_range(float3(infinite_tiling ? endless_texture(rough_dirty_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.753000021f, 0.409999996f, 0.698000014f), 8.f, false) : ::base::file_texture(rough_dirty_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 0.701000035f, ::math::lerp(0.300000012f, 0.600000024f, reflection_roughness_front)) + (float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[1] * imperfection_grunge + (float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[2] * imperfection_smudges), ((float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[0] * imperfection_dust + histogram_range(float3(infinite_tiling ? endless_texture(rough_dirty_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.753000021f, 0.409999996f, 0.698000014f), 8.f, false) : ::base::file_texture(rough_dirty_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 0.701000035f, ::math::lerp(0.300000012f, 0.600000024f, reflection_roughness_front)) + (float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[1] * imperfection_grunge + (float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[2] * imperfection_smudges) * ((float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[0] * imperfection_dust + histogram_range(float3(infinite_tiling ? endless_texture(rough_dirty_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.753000021f, 0.409999996f, 0.698000014f), 8.f, false) : ::base::file_texture(rough_dirty_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 0.701000035f, ::math::lerp(0.300000012f, 0.600000024f, reflection_roughness_front)) + (float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[1] * imperfection_grunge + (float3(infinite_tiling ? endless_texture(dust_grunge_leather_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 10.f, float3(0.453999996f, 0.832000017f, 0.513999999f), 8.f, false) : ::base::file_texture(dust_grunge_leather_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) - 0.5f)[2] * imperfection_smudges), color(1.f, 1.f, 1.f), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(1.f, ::df::diffuse_reflection_bsdf(nvidia::core_definitions::blend_colors(color_front, (infinite_tiling ? endless_texture(front_diff_lin_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.597000003f), 8.f, true) : ::base::file_texture(front_diff_srgb_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) * color(::math::lerp(0.f, 3.f, diffuse_brightness_front)), ::base::color_layer_overlay, histogram_range(float3(infinite_tiling ? endless_texture(rough_dirty_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.753000021f, 0.409999996f, 0.698000014f), 8.f, false) : ::base::file_texture(rough_dirty_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.796000063f, 0.784000039f)).tint, 0.f), bsdf(), infinite_tiling ? endless_normal(front_norm_tex, ::math::lerp(0.f, 2.5f, bump_strength), false, false, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.485000014f, 0.513999999f, 0.987999976f), 8.f) : normalmap_normal(front_norm_tex, ::math::lerp(0.f, 2.5f, bump_strength), vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index))), infinite_tiling ? endless_normal(front_norm_tex, ::math::lerp(0.f, 2.5f, bump_strength), false, false, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.485000014f, 0.513999999f, 0.987999976f), 8.f) : normalmap_normal(front_norm_tex, ::math::lerp(0.f, 2.5f, bump_strength), vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index))), ::state::normal()), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2(dirt_back_on_off ? ::df::weighted_layer(::math::pow(::math::lerp(0.f, 1.f, ::math::smoothstep(::math::lerp(1.f, 0.f, dirt_amount) - dirt_softness, ::math::lerp(1.f, 0.f, dirt_amount) + dirt_softness, float3(infinite_tiling ? endless_texture(rough_dirty_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.753000021f, 0.409999996f, 0.698000014f), 8.f, false) : ::base::file_texture(rough_dirty_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1])), 2.43300009f), ::df::diffuse_reflection_bsdf(dirt_color, 0.800000012f), ::df::custom_curve_layer(0.0399999991f, 1.f, 5.f, histogram_scan_big(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.421000034f, 0.625f), ::df::microfacet_ggx_smith_bsdf(histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, ::math::lerp(0.337000012f, 0.559000015f, reflection_roughness_back)) * histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, ::math::lerp(0.337000012f, 0.559000015f, reflection_roughness_back)), histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, ::math::lerp(0.337000012f, 0.559000015f, reflection_roughness_back)) * histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, ::math::lerp(0.337000012f, 0.559000015f, reflection_roughness_back)), color(1.f, 1.f, 1.f), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(1.f, ::df::diffuse_reflection_bsdf(nvidia::core_definitions::blend_colors(color_back, (infinite_tiling ? endless_texture(back_diff_lin_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.488000005f), 8.f, true) : ::base::file_texture(back_diff_srgb_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) * color(::math::lerp(0.f, 2.f, diffuse_brightness_back)), ::base::color_layer_overlay, histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 1.f, 0.754000008f)).tint, 0.f), bsdf(), infinite_tiling ? endless_normal(back_norm_tex, 1.f, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.490999997f, 0.503000021f, 0.989000022f), 8.f) : normalmap_normal(back_norm_tex, ::math::lerp(0.f, 2.5f, bump_strength), vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index))), infinite_tiling ? endless_normal(back_norm_tex, 1.f, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.490999997f, 0.503000021f, 0.989000022f), 8.f) : normalmap_normal(back_norm_tex, ::math::lerp(0.f, 2.5f, bump_strength), vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index))), ::state::normal()) : ::df::custom_curve_layer(0.0399999991f, 1.f, 5.f, histogram_scan_big(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.421000034f, 0.625f), ::df::microfacet_ggx_smith_bsdf(histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, ::math::lerp(0.337000012f, 0.559000015f, reflection_roughness_back)) * histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, ::math::lerp(0.337000012f, 0.559000015f, reflection_roughness_back)), histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, ::math::lerp(0.337000012f, 0.559000015f, reflection_roughness_back)) * histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0], 1.f, ::math::lerp(0.337000012f, 0.559000015f, reflection_roughness_back)), color(1.f, 1.f, 1.f), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(1.f, ::df::diffuse_reflection_bsdf(nvidia::core_definitions::blend_colors(color_back, (infinite_tiling ? endless_texture(back_diff_lin_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.488000005f), 8.f, false) : ::base::file_texture(back_diff_lin_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint) * color(::math::lerp(0.f, 2.f, diffuse_brightness_back)), ::base::color_layer_overlay, histogram_range(float3(infinite_tiling ? endless_texture(back_rough_ao_height_tex, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.792999983f, 0.924000025f, 0.683000028f), 8.f, false) : ::base::file_texture(back_rough_ao_height_tex, color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 1.f, 0.754000008f)).tint, 0.f), bsdf(), infinite_tiling ? endless_normal(back_norm_tex, 1.f, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.490999997f, 0.503000021f, 0.989000022f), 8.f) : normalmap_normal(back_norm_tex, ::math::lerp(0.f, 2.5f, bump_strength), vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index))), infinite_tiling ? endless_normal(back_norm_tex, 1.f, false, false, vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index), 8.f, float3(0.490999997f, 0.503000021f, 0.989000022f), 8.f) : normalmap_normal(back_norm_tex, ::math::lerp(0.f, 2.5f, bump_strength), vmat_transform(texture_translate, texture_rotate, texture_scale_rescaled, ::base::texture_coordinate_uvw, uv_space_index))), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(1.f, 1.f, 1.f); + material_geometry tmp5(float3(0.f), 1.f, round_corners ? ::state::rounded_corner_normal(radius * 0.00150000001f, across_materials, 1.f) : ::state::normal()); + } in + material( + thin_walled: tmp0, + surface: tmp1, + backface: tmp2, + ior: tmp3, + geometry: tmp5); + +export material Pigmented_Smooth_Leather_Black(*) + [[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Smooth Leather - Black Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "black", "dark", "neutral")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Black.png") +]] += Pigmented_Smooth_Leather +( + infinite_tiling: true, + bump_strength: 0.4f, + color_front: color(0.009021f, 0.009021f, 0.009021f), + diffuse_brightness_front: 0.1f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.034230f, 0.034230f, 0.034230f), + diffuse_brightness_back: 0.5f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.067725f, 0.067725f, 0.067725f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.00f, + round_corners: false, + radius: 1.5f, + across_materials: true, + uv_space_index: 0 +); + +export material Pigmented_Smooth_Leather_Green(*) + [[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Smooth Leather - Green Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "green", "cool", "cold")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Green.png") +]] += Pigmented_Smooth_Leather +( + infinite_tiling: true, + bump_strength: 0.4f, + color_front: color(0.271577f, 0.250840f, 0.061907f), + diffuse_brightness_front: 0.1f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.271577f,0.259027f,0.124741f), + diffuse_brightness_back: 0.5f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + round_corners: false, + radius: 1.5f, + across_materials: true, + uv_space_index: 0 +); + +export material Pigmented_Smooth_Leather_Gray(*) + [[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Smooth Leather - Grey Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft","grey", "gray", "neutral")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Gray.png") +]] += Pigmented_Smooth_Leather +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.464741f, 0.459080f, 0.431340f), + diffuse_brightness_front: 0.1f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.535642f,0.535642f,0.535642f), + diffuse_brightness_back: 0.4f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + round_corners: false, + radius: 1.5f, + across_materials: true, + uv_space_index: 0 +); + +export material Pigmented_Smooth_Leather_Turquoise(*) + [[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Smooth Leather - Turquoise Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "turquoise", "cool", "cold")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Turquoise.png") +]] += Pigmented_Smooth_Leather +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.108711f, 0.212044f, 0.254916f), + diffuse_brightness_front: 0.125f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.163641f,0.238828f,0.263175f), + diffuse_brightness_back: 0.6f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + round_corners: false, + radius: 1.5f, + across_materials: true, + uv_space_index: 0 +); + +export material Pigmented_Smooth_Leather_Light_Blue(*) + [[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Smooth Leather - Light Blue Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "blue", "light", "cool", "cold")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Light_Blue.png") +]] += Pigmented_Smooth_Leather +( + infinite_tiling: true, + bump_strength: 0.4f, + color_front: color(0.404541f, 0.505432f, 0.579547f), + diffuse_brightness_front: 0.1f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.297653f,0.339223f,0.404541f), + diffuse_brightness_back: 0.5f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + round_corners: false, + radius: 1.5f, + across_materials: true, + uv_space_index: 0 +); + +export material Pigmented_Smooth_Leather_Dark_Grey(*) + [[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Smooth Leather - Dark Grey Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "dark", "grey", "gray", "neutral")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Dark_Grey.png") +]] += Pigmented_Smooth_Leather +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.151058f, 0.151058f, 0.144972f), + diffuse_brightness_front: 0.2f, + reflection_roughness_front: 0.5f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.470440f,0.464741f,0.493616f), + diffuse_brightness_back: 0.2f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + round_corners: false, + radius: 1.5f, + across_materials: true, + uv_space_index: 0 +); + +export material Pigmented_Smooth_Leather_Ash_Brown(*) + [[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Pigmented Smooth Leather - Ash Brown"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "ash", "brown", "warm")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Ash_Brown.png") +]] += Pigmented_Smooth_Leather +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.069727f, 0.061907f, 0.046149f), + diffuse_brightness_front: 0.2f, + reflection_roughness_front: 0.5f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.101145f,0.093876f,0.073828f), + diffuse_brightness_back: 0.7f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.154152f, 0.106156f, 0.069727f), + dirt_softness: 0.905f, + dirt_amount: 0.3f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + round_corners: false, + radius: 1.5f, + across_materials: true, + uv_space_index: 0 +); + +export material Pigmented_Smooth_Leather_Red_Yellow(*) + [[ + ::anno::description(DESCRIPTION), + ::anno::display_name("Smooth Leather - Red Yellow Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "red", "yellow", "warm")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Red_Yellow.png") +]] += Pigmented_Smooth_Leather +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.505432f, 0.037029f, 0.009696f), + diffuse_brightness_front: 0.125f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.462f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.453456f,0.183549f,0.011126f), + diffuse_brightness_back: 0.362f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.464741f, 0.163641f, 0.012664f), + dirt_softness: 0.816f, + dirt_amount: 0.23f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + round_corners: false, + radius: 1.5f, + across_materials: true, + uv_space_index: 0 +); + +// ----------------- Punched Leather ----------------- +export material Pigmented_Smooth_Leather_Punched( + +// Leather parameters + uniform bool infinite_tiling = true [[ + ::anno::description("Enables infinite tiling feature which removes repeating texture patterns. Note that depending on the material this feature changes the appearance of the material slightly."), + ::anno::display_name("Infinite Tiling"), + ::anno::in_group("Appearance") + ]], + float bump_strength = 0.3f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f) + ]], + color color_front = color(0.078057f, 0.049433f, 0.012664f) [[ + ::anno::description("Choose the color of the front side."), + ::anno::display_name("Color Front"), + ::anno::in_group("Appearance", "Front") + ]], + float diffuse_brightness_front = 0.5f [[ + ::anno::description("Adjusts the lightness of the material."), + ::anno::display_name("Brightness Front"), + ::anno::in_group("Appearance", "Front"), + ::anno::hard_range(0.f, 1.f) + ]], + float reflection_roughness_front = 0.25f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness Front"), + ::anno::in_group("Appearance", "Front"), + ::anno::hard_range(0.f, 1.f) + ]], + float imperfection_dust = 0.6f [[ + ::anno::description("Adds specular variation to the roughness."), + ::anno::display_name("Imperfection Dust"), + ::anno::in_group("Appearance", "Front", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + float imperfection_grunge = 0.1f [[ + ::anno::description("Adds specular variation to the roughness."), + ::anno::display_name("Imperfection Grunge"), + ::anno::in_group("Appearance", "Front", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + float imperfection_smudges = 0.3f [[ + ::anno::description("Adds specular variation to the roughness."), + ::anno::display_name("Imperfection Smudges"), + ::anno::in_group("Appearance", "Front", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + color color_back = color(0.151058f, 0.119264f, 0.063815f) [[ + ::anno::description("Choose the color of the back side."), + ::anno::display_name("Color Back"), + ::anno::in_group("Appearance", "Back") + ]], + float diffuse_brightness_back = 0.7f [[ + ::anno::description("Adjusts the lightness of the material."), + ::anno::display_name("Brightness Back"), + ::anno::in_group("Appearance", "Back"), + ::anno::hard_range(0.f, 1.f) + ]], + float reflection_roughness_back = 0.4f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness Back"), + ::anno::in_group("Appearance", "Back"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform bool dirt_back_on_off = true [[ + ::anno::description("Switch on and off the dirt layer on the backside."), + ::anno::display_name("Dirt Back"), + ::anno::in_group("Appearance", "Dirt") + ]], + color dirt_color = color(0.023f, 0.023f, 0.023f) [[ + ::anno::description("Choose the color of the dirt layer."), + ::anno::display_name("Color Dirt"), + ::anno::in_group("Appearance", "Dirt") + ]], + float dirt_softness = 0.8f [[ + ::anno::description("Adjust the transition between dirt and leather. From hard to soft."), + ::anno::display_name("Dirt Softness"), + ::anno::in_group("Appearance", "Dirt"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_amount = 0.2f [[ + ::anno::description("Adjust the intensity through position."), + ::anno::display_name("Dirt Amount"), + ::anno::in_group("Appearance", "Dirt"), + ::anno::hard_range(0.f, 1.f) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(5) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(6) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::preview_scale(3.5f), + ::anno::ui_order(7) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(8) + ]], +// Punching parameters + uniform cutout_pattern shape_select = pattern_circle //select atlas tile here + [[ + ::anno::description("Select a cutout shape."), + ::anno::display_name("Cutout Shape"), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(9) + ]], + float punching_grid_size = 1.0f + [[ + ::anno::description("Scales the size of the punching grid."), + ::anno::display_name("Punching Grid Size"), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(10) + ]], + float cutout_rotation = 45.0f + [[ + ::anno::description("Rotates the cutout shape."), + ::anno::display_name("Cutout Rotation"), + ::anno::hard_range(0.f, 360.0f), + ::anno::soft_range(0.f, 360.0f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(11) + ]], + float cutout_size = .4f + [[ + ::anno::description("Scales the size of the cutout pattern independently from the base material."), + ::anno::display_name("Cutout Size"), + ::anno::hard_range(0.f, 1.2f), + ::anno::soft_range(0.f, 1.0f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(12) + ]], + float cutout_roundness = .5f + [[ + ::anno::description("At low values it makes the cutouts sharper. Higher values give the shapes a more rounded look."), + ::anno::display_name("Cutout Roundness"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(13) + ]], + float cutout_bump_strength = 1.0f + [[ + ::anno::description("Sets the strength of the bevelled normal around the cutout."), + ::anno::display_name("Cutout Bevel Strength"), + ::anno::soft_range(0.0f, 1.0f), + ::anno::hard_range(0.0f, 2.0f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(14) + ]], +// Grid Layout parameters + bool hexagonal_grid = true + [[ + ::anno::description("When enabled, the punching will occur on a hexagonal grid, otherwise a square grid."), + ::anno::display_name("Enable Hexagonal Grid"), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(15) + ]], + float square_grid_offset = 0.0f + [[ + ::anno::description("Offsets each row of the grid by a certain amount. Applies only when hexagonal grid is disabled."), + ::anno::display_name("Square Grid Offset"), + ::anno::in_group("Appearance", "Cutout"), + ::anno::enable_if("hexagonal_grid==false"), + ::anno::ui_order(16) + ]], + uniform bool round_corners = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(17) + ]], + uniform float radius = 1.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius"), + ::anno::in_group("Round Corners"), + ::anno::enable_if("round_corners==true"), + ::anno::ui_order(18) + ]], + uniform bool across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners"), + ::anno::enable_if("round_corners==true"), + ::anno::ui_order(19) + ]] +) +[[ + ::anno::description(DESCRIPTION_PUNCHED), + ::anno::display_name("Smooth Leather - Brown Punched Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::author("NVIDIA vMaterials"), + ::anno::key_words(string[]("leather", "punched", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "brown", "warm")), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Punched.png") +]] = let +{ + bool horizontal_offset = true; + float cutout_bevel_width = 0.7f; + float cutout_bump_strength_2 = cutout_bump_strength * 5.0f; + + material base_mat = Pigmented_Smooth_Leather( + infinite_tiling: infinite_tiling, + bump_strength: bump_strength, + color_front: color_front, + diffuse_brightness_front: diffuse_brightness_front, + reflection_roughness_front: reflection_roughness_front, + imperfection_dust: imperfection_dust, + imperfection_grunge: imperfection_grunge, + imperfection_smudges: imperfection_smudges, + color_back: color_back, + diffuse_brightness_back: diffuse_brightness_back, + reflection_roughness_back: reflection_roughness_back, + dirt_back_on_off: dirt_back_on_off, + dirt_color: dirt_color, + dirt_softness: dirt_softness, + dirt_amount: dirt_amount, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + round_corners: round_corners, + radius: radius, + across_materials: across_materials + ); + + // remap range of slider to avoid artifacts in the bevelling + float2 punching_scale = texture_scale * 0.01f * float2(punching_grid_size); + float cutout_roundness_ = cutout_roundness*0.6f+0.4f; + float cutout_size_lin = (1.0f/cutout_size); + texture_2d punching_cutout = texture_2d("./leather_punch_atlas_01.png", ::tex::gamma_linear); + + vm_coordinates uv = vm_coord( + translation: texture_translate, + rotation: texture_rotate, + scaling: punching_scale, + uv_space: uv_space_index + ); + + vm_coordinates punching_uv = hexagonal_grid ? vm_coord_hex( + uv: uv, + scale: cutout_roundness_ * cutout_size_lin, + rotation: cutout_rotation + ) : vm_coord_grid( + uv: vm_coord_rowcol_offset( + uv: uv, + offset: square_grid_offset, + horizontal_offset: horizontal_offset + ), + scale: cutout_roundness_ * cutout_size_lin, + rotation: cutout_rotation + ); + // select the correct subtile from the atlas + float4 crop = tile_select_2x2(shape_select); + + ::base::texture_return lookup = vm_tex_lookup( + tex: punching_cutout, + uv: punching_uv, + mono_source: mono_a, + scale: float4(1.0f), + crop_u: float2(crop.x, crop.y), + crop_v: float2(crop.z, crop.w), + wrap_u: ::tex::wrap_clamp, + wrap_v: ::tex::wrap_clamp + ); + + float low = (1.0 - cutout_roundness_); + float high = (cutout_size_lin * (cutout_bevel_width * 0.2f) * cutout_roundness_) + (1.0 - cutout_roundness_); + // remap x...y to (clamped) 0...1 + float x = ::math::clamp((lookup.mono - low)/(high - low), 0.0, 1.0); + // spherical falloff + float falloff=::math::sqrt(1.0-x*x); + // masking falloff as the center of the cutout is flat + float masked_falloff=falloff<=0.0?1.0:falloff; + + // where base material is still there, use the value of the base material + float cutout= ::math::min(falloff<=0.0?0.0:1.0, base_mat.geometry.cutout_opacity); + + // bring in -.5 ... +.5 range and lerp between lookup and flat normal + float3 remap_norm = ::math::lerp(float3(lookup.tint), float3(0.5, 0.5, 1.0), masked_falloff) - float3(0.5); + float3 t_norm = ::math::normalize(remap_norm * float3(cutout_bump_strength_2, cutout_bump_strength_2, 1.0)); + + float3 rotfix_norm = float3(::math::cos(punching_uv.rotation) * t_norm.x - ::math::sin(punching_uv.rotation) * t_norm.y, + ::math::sin(punching_uv.rotation) * t_norm.x + ::math::cos(punching_uv.rotation) * t_norm.y, + t_norm.z); + + float3 normal = ::state::texture_tangent_u(punching_uv.uv_space_index) * rotfix_norm.x + + ::state::texture_tangent_v(punching_uv.uv_space_index) * rotfix_norm.y + + ::state::normal() * rotfix_norm.z; + + float3 final_normal = ::base::blend_normals( + base_normal: normal, + base_normal_weight: 1.0f, + detail_normal: base_mat.geometry.normal, + detail_normal_weight: 1.0f + ); + +} in material( + surface: material_surface( + scattering: base_mat.surface.scattering + ), + backface: material_surface( + scattering: base_mat.backface.scattering + ), + volume: base_mat.volume, + ior: base_mat.ior, + thin_walled: true, + geometry: material_geometry( + displacement: base_mat.geometry.displacement, + normal: final_normal, + cutout_opacity: cutout + ) +); + +export material Pigmented_Smooth_Leather_Black_Punched(*) + [[ + ::anno::description(DESCRIPTION_PUNCHED), + ::anno::display_name("Smooth Leather - Black Punched Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "punched", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "black", "dark", "neutral")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Black_Punched.png") +]] += Pigmented_Smooth_Leather_Punched +( + infinite_tiling: true, + bump_strength: 0.4f, + color_front: color(0.009021f, 0.009021f, 0.009021f), + diffuse_brightness_front: 0.1f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.034230f, 0.034230f, 0.034230f), + diffuse_brightness_back: 0.5f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.067725f, 0.067725f, 0.067725f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + + shape_select: pattern_circle, + punching_grid_size: 0.7f, + cutout_size: 0.4f, + cutout_roundness: 0.8f, + cutout_bump_strength: 2.0f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + + round_corners: false, + radius: 1.5f, + across_materials: true +); + +export material Pigmented_Smooth_Leather_Green_Punched(*) + [[ + ::anno::description(DESCRIPTION_PUNCHED), + ::anno::display_name("Smooth Leather - Green Punched Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "punched", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "green", "cool", "cold")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Green_Punched.png") +]] += Pigmented_Smooth_Leather_Punched +( + infinite_tiling: true, + bump_strength: 0.4f, + color_front: color(0.271577f, 0.250840f, 0.061907f), + diffuse_brightness_front: 0.1f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.271577f,0.259027f,0.124741f), + diffuse_brightness_back: 0.5f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + + shape_select: pattern_circle, + punching_grid_size: 0.7f, + cutout_size: 0.4f, + cutout_roundness: 0.8f, + cutout_bump_strength: 2.0f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + + round_corners: false, + radius: 1.5f, + across_materials: true +); + +export material Pigmented_Smooth_Leather_Gray_Punched(*) + [[ + ::anno::description(DESCRIPTION_PUNCHED), + ::anno::display_name("Smooth Leather - Grey Punched Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "punched", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft","grey", "gray", "neutral")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Gray_Punched.png") +]] += Pigmented_Smooth_Leather_Punched +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.464741f, 0.459080f, 0.431340f), + diffuse_brightness_front: 0.1f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.535642f,0.535642f,0.535642f), + diffuse_brightness_back: 0.4f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + + shape_select: pattern_circle, + punching_grid_size: 0.7f, + cutout_size: 0.4f, + cutout_roundness: 0.8f, + cutout_bump_strength: 2.0f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + + round_corners: false, + radius: 1.5f, + across_materials: true +); + +export material Pigmented_Smooth_Leather_Turquoise_Punched(*) + [[ + ::anno::description(DESCRIPTION_PUNCHED), + ::anno::display_name("Smooth Leather - Turquoise Punched Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "punched", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "turquoise", "cool", "cold")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Turquoise_Punched.png") +]] += Pigmented_Smooth_Leather_Punched +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.108711f, 0.212044f, 0.254916f), + diffuse_brightness_front: 0.125f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.163641f,0.238828f,0.263175f), + diffuse_brightness_back: 0.6f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + + shape_select: pattern_circle, + punching_grid_size: 0.7f, + cutout_size: 0.4f, + cutout_roundness: 0.8f, + cutout_bump_strength: 2.0f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + + round_corners: false, + radius: 1.5f, + across_materials: true +); + +export material Pigmented_Smooth_Leather_Light_Blue_Punched(*) + [[ + ::anno::description(DESCRIPTION_PUNCHED), + ::anno::display_name("Smooth Leather - Light Blue Punched Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "punched", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "blue", "light", "cool", "cold")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Light_Blue_Punched.png") +]] += Pigmented_Smooth_Leather_Punched +( + infinite_tiling: true, + bump_strength: 0.4f, + color_front: color(0.404541f, 0.505432f, 0.579547f), + diffuse_brightness_front: 0.1f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.297653f,0.339223f,0.404541f), + diffuse_brightness_back: 0.5f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + + shape_select: pattern_circle, + punching_grid_size: 0.7f, + cutout_size: 0.4f, + cutout_roundness: 0.8f, + cutout_bump_strength: 2.0f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + + round_corners: false, + radius: 1.5f, + across_materials: true +); + + +export material Pigmented_Smooth_Leather_Dark_Grey_Punched(*) + [[ + ::anno::description(DESCRIPTION_PUNCHED), + ::anno::display_name("Smooth Leather - Dark Grey Punched Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "punched", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "dark", "grey", "gray", "neutral")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Dark_Grey_Punched.png") +]] += Pigmented_Smooth_Leather_Punched +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.151058f, 0.151058f, 0.144972f), + diffuse_brightness_front: 0.2f, + reflection_roughness_front: 0.5f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.470440f,0.464741f,0.493616f), + diffuse_brightness_back: 0.2f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.023104f, 0.023104f, 0.023104f), + dirt_softness: 0.816f, + dirt_amount: 0.2f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + + shape_select: pattern_circle, + punching_grid_size: 0.7f, + cutout_size: 0.4f, + cutout_roundness: 0.8f, + cutout_bump_strength: 2.0f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + + round_corners: false, + radius: 1.5f, + across_materials: true +); + +export material Pigmented_Smooth_Leather_Ash_Brown_Punched(*) + [[ + ::anno::description(DESCRIPTION_PUNCHED), + ::anno::display_name("Smooth Leather - Ash Brown Punched Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "punched", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "ash", "brown", "warm")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Ash_Brown_Punched.png") +]] += Pigmented_Smooth_Leather_Punched +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.069727f, 0.061907f, 0.046149f), + diffuse_brightness_front: 0.2f, + reflection_roughness_front: 0.5f, + imperfection_dust: 0.103f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.101145f,0.093876f,0.073828f), + diffuse_brightness_back: 0.7f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.154152f, 0.106156f, 0.069727f), + dirt_softness: 0.905f, + dirt_amount: 0.3f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + + shape_select: pattern_circle, + punching_grid_size: 0.7f, + cutout_size: 0.4f, + cutout_roundness: 0.8f, + cutout_bump_strength: 2.0f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + + round_corners: false, + radius: 1.5f, + across_materials: true +); + +export material Pigmented_Smooth_Leather_Red_Yellow_Punched(*) + [[ + ::anno::description(DESCRIPTION_PUNCHED), + ::anno::display_name("Smooth Leather - Red Yellow Punched Pigmented"), + ::anno::copyright_notice(COPYRIGHT), + ::anno::key_words(string[]("leather", "punched", "infinite", "tiling", "new", "natural", "bumped", "interior", "cloth", "soft", "red", "yellow", "warm")), + ::anno::author("Nvidia vMaterials"), + ::anno::contributor("Maik Rohland"), + ::anno::contributor("Ruediger Raab"), + ::anno::thumbnail("./.thumbs/Pigmented_Smooth_Leather.Pigmented_Smooth_Leather_Red_Yellow_Punched.png") +]] += Pigmented_Smooth_Leather_Punched +( + infinite_tiling: true, + bump_strength: 0.5f, + color_front: color(0.505432f, 0.037029f, 0.009696f), + diffuse_brightness_front: 0.125f, + reflection_roughness_front: 0.3f, + imperfection_dust: 0.462f, + imperfection_grunge: 0.467f, + imperfection_smudges: 0.072f, + color_back: color(0.453456f,0.183549f,0.011126f), + diffuse_brightness_back: 0.362f, + reflection_roughness_back: 0.75f, + dirt_back_on_off: true, + dirt_color: color(0.464741f, 0.163641f, 0.012664f), + dirt_softness: 0.816f, + dirt_amount: 0.23f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + + shape_select: pattern_circle, + punching_grid_size: 0.7f, + cutout_size: 0.4f, + cutout_roundness: 0.8f, + cutout_bump_strength: 2.0f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + + round_corners: false, + radius: 1.5f, + across_materials: true +); \ No newline at end of file diff --git a/Assets/Material/material_0384/Aluminum_Sheet.mdl b/Assets/Material/material_0384/Aluminum_Sheet.mdl new file mode 100644 index 0000000000000000000000000000000000000000..8c37ed9a1f756762bd86e0f9b81571606573ce3f --- /dev/null +++ b/Assets/Material/material_0384/Aluminum_Sheet.mdl @@ -0,0 +1,1330 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + + +mdl 1.5; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +const string DESCRIPTION = "A sheet metal material with adjustable imperfections"; +const string DESCRIPTION_PUNCH = "Punched aluminum sheet metal material with adjustable imperfections and punchings."; + + +float4 tile_select(uniform int select = 0) +{ + switch (select) + { + case 0: return float4(0.000, 0.333, 0.666, 1.000); + case 1: return float4(0.333, 0.666, 0.666, 1.000); + case 2: return float4(0.666, 1.000, 0.666, 1.000); + + case 3: return float4(0.000, 0.333, 0.333, 0.666); + case 4: return float4(0.333, 0.666, 0.333, 0.666); + case 5: return float4(0.666, 1.000, 0.333, 0.666); + + case 6: return float4(0.000, 0.333, 0.000, 0.333); + case 7: return float4(0.333, 0.666, 0.000, 0.333); + case 8: return float4(0.666, 1.000, 0.000, 0.333); + + default: return float4(0.000, 0.333, 0.000, 0.333); + } +} + +export struct vm_coordinates +[[ + ::anno::hidden() +]] +{ + float2 uv; + float rotation; + int uv_space_index; + float4 carry; +}; + +enum vm_mono_select +[[ + anno::description("Modes for the creation of a gray-scale value from a color"), + anno::hidden() +]] +{ + mono_r = 0, + mono_g = 1, + mono_b = 2, + mono_a = 3, + mono_average = 4 +}; + +vm_coordinates vm_coord +( + float2 translation = float2(0.0f, 0.0) [[ + ::anno::display_name("Translation"), + ::anno::description("Translates the coordinates.") + ]], + float rotation = 0.0f [[ + ::anno::display_name("Rotation"), + ::anno::description("Rotates the coordinates in degrees.") + ]], + float2 scaling = float2(1.0f, 1.0f) [[ + ::anno::display_name("Scaling"), + ::anno::description("Scales the coordinates.") + ]], + uniform int uv_space = 0 [[ + ::anno::display_name("UV Space"), + ::anno::description("Chose the UV space.") + ]] +) +[[ + ::anno::display_name("vm Transform"), + ::anno::description("Generates coordinates to be used in vm_lookup functions.") +]] +{ + vm_coordinates uv; + ::base::texture_coordinate_info info = ::base::coordinate_source( ::base::texture_coordinate_uvw, uv_space); + uv.rotation = (rotation * 3.1415926535897932384626433832f) / 180.f; + uv.uv = float2(info.position.x, info.position.y); + float sine = ::math::sin(uv.rotation); + float cosine = ::math::cos(uv.rotation); + float2x2 rot = float2x2(cosine, -sine, sine, cosine); + uv.uv = rot * uv.uv; + uv.uv /= scaling; + uv.uv += translation; + return uv; +} + + +vm_coordinates vm_coord_hex( + vm_coordinates uv, + float scale = 1.0f) +{ + vm_coordinates uv_return; + float2 uv_ = float2(uv.uv.x, uv.uv.y); + + // same as from function get_hex above + float2 s = float2(1.0f, 1.7320508f); + float2 n = uv_ - float2(0.5f, 1.0f); + float4 c = ::math::floor(float4(uv_.x, uv_.y, n.x, n.y)/float4(s.x, s.y, s.x, s.y)) + 0.5f; + float2 h_1 = uv_ - float2(c.x, c.y) * s; + float2 h_2 = uv_ - (float2(c.z, c.w) + 0.5f) * s; + float4 uv_id = ::math::dot(h_1, h_1) < ::math::dot(h_2, h_2) ? float4(h_1.x, h_1.y, c.x, c.y) : float4(h_2.x, h_2.y, c.z, c.w); + + uv_return.uv = float2(uv_id.x*scale+0.5, uv_id.y*scale+0.5); + // unless we introduce random cell rotations where we need to compensate for this in the rotation + // we can just plain copy the rotation value + uv_return.rotation = uv.rotation; + return uv_return; +} + +// Offsets a set of uv coordinates in either row (u) or column (v) direction +vm_coordinates vm_coord_rowcol_offset( + vm_coordinates uv, + float offset, + bool horizontal_offset = true +) +{ + int index = horizontal_offset ? 0 : 1; + uv.uv[index] += ::math::floor(uv.uv[index ^ 1]) * offset; + return uv; +} + +vm_coordinates vm_coord_grid( + vm_coordinates uv, + float scale = 1.0f +) +{ + float2x2 scal = float2x2(scale, 0., 0., scale); + uv.uv = ::math::frac(uv.uv); + uv.uv -= 0.5f; + uv.uv = scal * uv.uv; + uv.uv = uv.uv + 0.5f; + return uv; +} + +::base::texture_return vm_tex_lookup( + uniform texture_2d tex, + vm_coordinates uv = vm_coord(), + uniform vm_mono_select mono_source = mono_a, + float4 scale = float4(1.0f), + + uniform ::tex::wrap_mode wrap_u = ::tex::wrap_repeat, + uniform ::tex::wrap_mode wrap_v = ::tex::wrap_repeat, + uniform float2 crop_u = float2(0.0, 1.0), + uniform float2 crop_v = float2(0.0, 1.0) +) +{ + float mono; + float4 lookup = ::tex::lookup_float4(tex, uv.uv, wrap_u, wrap_v, crop_u, crop_v) * scale; + switch( mono_source ) { + case mono_r: mono = lookup.x; + break; + case mono_g: mono = lookup.y; + break; + case mono_b: mono = lookup.z; + break; + case mono_a: mono = lookup.w; + break; + case mono_average: mono = ::math::average(float3(lookup.x, lookup.y, lookup.z)); + break; + } + return ::base::texture_return(color(lookup.x, lookup.y, lookup.z), mono); +} + +// *** SET CUTOUT ENUM NAMES *** +export enum cutout_pattern +[[ + ::anno::description("Cutout Pattern."), + ::anno::hidden() +]] +{ + pattern_circle = 0 + [[ ::anno::display_name("Circle")]], + pattern_hexagon = 1 + [[ ::anno::display_name("Hexagon")]], + pattern_line = 2 + [[ ::anno::display_name("Line") ]], + + pattern_square = 3 + [[ ::anno::display_name("Square")]], + pattern_rectangle = 4 + [[ ::anno::display_name("Rectangle")]], + pattern_cross = 5 + [[ ::anno::display_name("Cross")]], + + pattern_rhombus = 6 + [[ ::anno::display_name("Rhombus")]], + pattern_triangle = 7 + [[ ::anno::display_name("Triangle")]], + pattern_star = 8 + [[ ::anno::display_name("Star")]] +}; + +float remap_xy_to_0_1(float input, float x, float y) +{ + return (input - x)/(y - x); +} + +float histogram_scan_big(float input, float width, float position) +{ + return ::math::clamp( + remap_xy_to_0_1(input, + ::math::lerp(-width, 1.0, position), + ::math::lerp(0.0, 1.0 + width, position)), + 0.0, + 1.0); +} + + +::base::texture_coordinate_info vmat_transform( + uniform float2 translation = float2(0.0, 0.0), + uniform float rotation = 0.0, + uniform float2 scaling = float2(1.0, 1.0), + uniform ::base::texture_coordinate_system system = ::base::texture_coordinate_uvw, + uniform int uv_space = 0 +) +{ + float rotation_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + + float4x4 scale = + float4x4(1.0 /scaling.x, 0. , 0. , 0., + 0. , 1.0 /scaling.y , 0. , 0., + 0. , 0. , 1.0, 0., + translation.x , translation.y , 0.0, 1.); + + float s = ::math::sin(rotation_rad); + float c = ::math::cos(rotation_rad); + float4x4 rotate = + float4x4( c , -s , 0.0 , 0.0, + s , c , 0.0 , 0.0, + 0.0, 0.0 , 1.0 , 0.0, + 0. , 0.0 , 0.0 , 1.); + + return ::base::transform_coordinate(scale*rotate, ::base::coordinate_source(system, uv_space)); +} + +float uint2float(int x) +{ + return float(x & 0x7FFFFFFF) + (x < 0 ? 2147483648.0 : 0.0); +} + +int lowbias32(int x) +{ + x ^= x >>> 16; + x *= 0x7feb352d; + x ^= x >>> 15; + x *= 0x846ca68b; + x ^= x >>> 16; + return x; +} + +float2 rnd22(int2 p) { + float2 ret_val = float2( + uint2float(lowbias32(p[0] + lowbias32(p[1]))) / 4294967296.f, + uint2float(lowbias32(p[0] + 32000 + lowbias32(p[1]))) / 4294967296.f + ); + return ret_val; +} + +float3 srgb2rgb(float3 val) +{ + return ::math::pow(::math::max(val, float3(0.0f)), 2.2); +} + +float2x2 invert_2x2(float2x2 M) +{ + float det = M[0][0]*M[1][1] - M[0][1]*M[1][0]; + //https://www.chilimath.com/lessons/advanced-algebra/inverse-of-a-2x2-matrix/ + return (1.0 / det) * float2x2(M[1][1], -M[0][1], -M[1][0], M[0][0]); +} + +float3 nonrepeat_lookup( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5), + float patch_size = 8.0 +) +{ + + float2 uv_in = float2(uvw.position[0], uvw.position[1]) * texture_scale; + float Z = patch_size; // patch scale inside example texture + float CON = 1.0f; + + float3 O = float3(0.f); + float2x2 M0 = float2x2(1.f,0.f, 0.5f, ::math::sqrt(3.f)/2.f); + float2x2 M = invert_2x2(M0); // transform matrix <-> tilted space + + float2 U = uv_in; + float2 V = M * uv_in; //pre-tilted hexa coordinates + int2 I = int2(::math::floor(V)); // hexa-tile id + + // The mean color needs to be determined in Photoshop then to make the + // average color work out, take the float value and calculate the apropriate + // mean value as (value^(1/2.2)) + + float3 m = average_color; + + float3 F = float3(::math::frac(V)[0], ::math::frac(V)[1], 0.f), W; + F[2] = 1.0 - F[0] - F[1]; // local hexa coordinates + + if( F[2] > 0.f ) + + O = (W[0] = F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I))) - m*float(CON)) + + (W[1] = F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0,1)))) - m*float(CON)) + + (W[2] = F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1,0)))) - m*float(CON)); + else + O = (W[0] = -F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1)))) - m*float(CON)) + + (W[1] = 1.f - F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1, 0)))) - m*float(CON)) + + (W[2] = 1.f - F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0, 1)))) - m*float(CON)); + O = m + O/::math::length(W); + O = ::math::clamp( (O), 0.0, 1.0); + + return float3(O); +} + +color endless_texture( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 10.0, + float3 average_color = float3(0.5, 0.5, 1.0), + float patch_size = 8.0, + bool gamma_correct_lookup = true +) +{ + return gamma_correct_lookup ? color(srgb2rgb( + nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )) + ) : color(nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )); +} + + +export material Aluminum_Sheet( + uniform bool infinite_tiling = false [[ + ::anno::description("Enables infinite tiling feature which removes repeating texture patterns. Note that depending on the material this feature changes the appearance of the material slightly."), + ::anno::display_name("Infinite Tiling"), + ::anno::in_group("Appearance", "Main") + ]], + float sheet_brightness = 0.5f [[ + ::anno::display_name("Brightness"), + ::anno::description("Controls the brightness of the material."), + ::anno::in_group("Appearance", "Main"), + ::anno::hard_range(0.f, 1.f) + ]], + float roughness = 0.2f [[ + ::anno::display_name("Roughness"), + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::in_group("Appearance", "Main"), + ::anno::hard_range(0.f, 1.f) + ]], + float streaks = 0.0f [[ + ::anno::display_name("Streaks Weight"), + ::anno::description("Adds directional streaks that occur as part of the sheet manufacturing process."), + ::anno::in_group("Appearance", "Main"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float scratch_bump_factor = 0.0f [[ + ::anno::description("Determines the degree of bumpiness."), + ::anno::display_name("Bump Factor Streaks"), + ::anno::in_group("Appearance", "Main"), + ::anno::hard_range(0.f, 1.f) + ]], + float imperfections_amount = 0.6f [[ + ::anno::description("Balances between a perfectly smooth metal and a surface that has various imperfections."), + ::anno::display_name("Imperfections Amount"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float impurities_weight_1 = 0.f [[ + ::anno::display_name("Washed Imperfections Ratio"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float impurities_weight_2 = 0.939f [[ + ::anno::display_name("Noisy Imperfections Ratio"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float impurities_weight_3 = 0.0 [[ + ::anno::display_name("Splotchy Imperfection Ratio"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform bool enable_round_corners = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius = 0.01f [[ + ::anno::description("Radius of the rounded corners."), + ::anno::display_name("Round Corner Radius"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 0.1f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners") + ]], + uniform float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform") + ]], + uniform float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f) + ]], + uniform float2 texture_scale = 1.0f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::nvidia::core_definitions::dimension(float2(0.75f, 0.75f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Aluminum Sheet - New Clean"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "automotive", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "neutral")) +]] + = + let { + color normal_reflectivity = color(0.911810895428f,0.914089043421f,0.920152876196f); + color grazing_reflectivity = color(0.99942f, 1.f, 1.f); + + bool tmp0 = false; + material_surface tmp1( + ::df::color_custom_curve_layer(normal_reflectivity, grazing_reflectivity, 5.f, color(::math::lerp(0.400000006f, 1.f, sheet_brightness) * ::math::lerp(1.f, ::math::pow(float3(::base::file_texture(texture_2d("./sheet_metal_R_rough_G_ao_B_streaks.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1], 2.20000005f), ::math::lerp(0.f, 0.300000012f, streaks))), ::df::weighted_layer(0.0700000003f, ::df::microfacet_ggx_smith_bsdf(0.150000006f, 0.150000006f, color(1.f, 1.f, 1.f), ::state::texture_tangent_u(0), ::df::scatter_reflect, ""), ::df::microfacet_ggx_smith_bsdf((::math::lerp(roughness * 0.5f, (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_1 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] + (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_2 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1] + (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_3 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], imperfections_amount) + (float3(::base::file_texture(texture_2d("./sheet_metal_R_rough_G_ao_B_streaks.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] - 0.5f) * (streaks * 0.5f * 0.5f)) * (::math::lerp(roughness * 0.5f, (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_1 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] + (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_2 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1] + (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_3 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], imperfections_amount) + (float3(::base::file_texture(texture_2d("./sheet_metal_R_rough_G_ao_B_streaks.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] - 0.5f) * (streaks * 0.5f * 0.5f)), (::math::lerp(roughness * 0.5f, (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_1 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] + (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_2 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1] + (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_3 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], imperfections_amount) + (float3(::base::file_texture(texture_2d("./sheet_metal_R_rough_G_ao_B_streaks.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] - 0.5f) * (streaks * 0.5f * 0.5f)) * (::math::lerp(roughness * 0.5f, (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_1 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] + (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_2 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[1] + (impurities_weight_1 + impurities_weight_2 + impurities_weight_3 > 0.f ? impurities_weight_3 / (impurities_weight_1 + impurities_weight_2 + impurities_weight_3) : 0.333299994f) * roughness * float3(infinite_tiling ? endless_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), 2.f, float3(0.633000016f, 0.495000005f, 0.542999983f), 2.f, false) : ::base::file_texture(texture_2d("./sheet_metal_multi_rough.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], imperfections_amount) + (float3(::base::file_texture(texture_2d("./sheet_metal_R_rough_G_ao_B_streaks.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[0] - 0.5f) * (streaks * 0.5f * 0.5f)), color(1.f, 1.f, 1.f), ::state::texture_tangent_u(0), ::df::scatter_reflect, ""), ::math::normalize(::math::lerp(::state::normal(), ::base::tangent_space_normal_texture(texture_2d("./sheet_metal_norm.jpg", ::tex::gamma_linear), scratch_bump_factor, false, false, ::base::texture_coordinate_info(::state::texture_coordinate(0), ::state::texture_tangent_u(0), ::state::texture_tangent_v(0)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 1.f, 0.f), histogram_scan_big(float3(::base::file_texture(texture_2d("./sheet_metal_R_rough_G_ao_B_streaks.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.242000014f, 0.850000024f)))), bsdf(), ::math::normalize(::math::lerp(::state::normal(), ::base::tangent_space_normal_texture(texture_2d("./sheet_metal_norm.jpg", ::tex::gamma_linear), scratch_bump_factor, false, false, ::base::texture_coordinate_info(::state::texture_coordinate(0), ::state::texture_tangent_u(0), ::state::texture_tangent_v(0)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 1.f, 0.f), histogram_scan_big(float3(::base::file_texture(texture_2d("./sheet_metal_R_rough_G_ao_B_streaks.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_average, vmat_transform(texture_translate, texture_rotate, texture_scale, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false).tint)[2], 0.242000014f, 0.850000024f)))), + material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(1.f, 1.f, 1.f); + material_volume tmp4 = material_volume(scattering: vdf(), absorption_coefficient: color(0.f, 0.f, 0.f), scattering_coefficient: color(0.f, 0.f, 0.f)); + material_geometry tmp5( + float3(0.f), + 1.f, + enable_round_corners ? ::state::rounded_corner_normal(roundcorner_radius, across_materials, 1.f) : ::state::normal()); + } in + material( + thin_walled: tmp0, + surface: tmp1, + backface: tmp2, + ior: tmp3, + volume: tmp4, + geometry: tmp5); + + + +export material Aluminum_Sheet_Punched( + // Cutout parameters + + uniform cutout_pattern shape_select = pattern_circle //select atlas tile here + [[ + ::anno::description("Select a cutout shape."), + ::anno::display_name("Cutout Shape"), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(0) + ]], + float2 punching_grid_size = float2(.5f, .5f) + [[ + ::anno::description("Scales the size of the punching grid."), + ::anno::display_name("Punching Grid Size"), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(1) + ]], + float cutout_size = .92f + [[ + ::anno::description("Scales the size of the cutout pattern independently from the base material."), + ::anno::display_name("Cutout Size"), + ::anno::hard_range(0.f, 1.2f), + ::anno::soft_range(0.f, 1.0f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(2) + ]], + float cutout_roundness = .4f + [[ + ::anno::description("At low values it makes the cutouts sharper. Higher values give the shapes a more rounded look."), + ::anno::display_name("Cutout Roundness"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(3) + ]], + float cutout_bevel_width = 0.5f + [[ + ::anno::description("Adjusts the width of the bevel transition."), + ::anno::display_name("Cutout Bevel Width"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(4) + ]], + float cutout_bump_strength = .8f + [[ + ::anno::description("Sets the strength of the bevelled normal around the cutout."), + ::anno::display_name("Cutout Bevel Strength"), + ::anno::soft_range(0.0f, 1.0f), + ::anno::hard_range(0.0f, 2.0f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(5) + ]], +// Grid Layout parameters + bool hexagonal_grid = true + [[ + ::anno::description("When enabled, the punching will occur on a hexagonal grid, otherwise a square grid."), + ::anno::display_name("Enable Hexagonal Grid"), + ::anno::in_group("Appearance", "Cutout Layout"), + ::anno::ui_order(6) + ]], + float square_grid_offset = 0.0f + [[ + ::anno::description("Offsets each row of the grid by a certain amount."), + ::anno::display_name("Square Grid Offset"), + ::anno::in_group("Appearance", "Cutout Layout"), + ::anno::enable_if("hexagonal_grid==false"), + ::anno::ui_order(7) + ]], + bool horizontal_offset = true + [[ + ::anno::description("Choose whether to offset either in row or column direction."), + ::anno::display_name("Horizontal Offset"), + ::anno::in_group("Appearance", "Cutout Layout"), + ::anno::enable_if("hexagonal_grid==false"), + ::anno::ui_order(8) + ]], + + + +// Aluminum Sheet parameters + uniform bool infinite_tiling = false [[ + ::anno::description("Enables infinite tiling feature which removes repeating texture patterns. Note that depending on the material this feature changes the appearance of the material slightly."), + ::anno::display_name("Infinite Tiling"), + ::anno::in_group("Appearance", "Main") + ]], + float sheet_brightness = 0.5f [[ + ::anno::display_name("Brightness"), + ::anno::description("Controls the brightness of the material."), + ::anno::in_group("Appearance", "Main"), + ::anno::hard_range(0.f, 1.f) + ]], + float roughness = 0.2f [[ + ::anno::display_name("Roughness"), + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::in_group("Appearance", "Main"), + ::anno::hard_range(0.f, 1.f) + ]], + float streaks = 0.0f [[ + ::anno::display_name("Streaks Weight"), + ::anno::description("Adds directional streaks that occur as part of the sheet manufacturing process."), + ::anno::in_group("Appearance", "Main"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float scratch_bump_factor = 0.0f [[ + ::anno::description("Determines the degree of bumpiness."), + ::anno::display_name("Bump Factor Streaks"), + ::anno::in_group("Appearance", "Main"), + ::anno::hard_range(0.f, 1.f) + ]], + float imperfections_amount = 0.6f [[ + ::anno::description("Balances between a perfectly smooth metal and a surface that has various imperfections."), + ::anno::display_name("Imperfections Amount"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float impurities_weight_1 = 0.f [[ + ::anno::display_name("Washed Imperfections Ratio"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float impurities_weight_2 = 0.939f [[ + ::anno::display_name("Noisy Imperfections Ratio"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float impurities_weight_3 = 0.0 [[ + ::anno::display_name("Splotchy Imperfection Ratio"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform bool enable_round_corners = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius = 0.01f [[ + ::anno::description("Radius of the rounded corners."), + ::anno::display_name("Round Corner Radius"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 0.1f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners") + ]], + uniform float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform") + ]], + uniform float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f) + ]], + uniform float2 texture_scale = 1.0f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::nvidia::core_definitions::dimension(float2(0.75f, 0.75f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Circular Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "circular", "gray")) +]] = let +{ + material base_mat = Aluminum_Sheet( + infinite_tiling: infinite_tiling, + sheet_brightness: sheet_brightness, + roughness: roughness, + streaks: streaks, + scratch_bump_factor: scratch_bump_factor, + imperfections_amount: imperfections_amount, + impurities_weight_1: impurities_weight_1, + impurities_weight_2: impurities_weight_2, + impurities_weight_3: impurities_weight_3, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + enable_round_corners: enable_round_corners, + roundcorner_radius: roundcorner_radius, + across_materials: across_materials + ); + texture_2d punching_cutout = texture_2d("./atlas_02_norm_dist.png", ::tex::gamma_linear); + + // remap range of slider to avoid artifacts in the bevelling + float2 punching_scale = texture_scale * 0.01f * punching_grid_size; + float cutout_roundness_ = cutout_roundness*0.6f+0.4f; + float cutout_size_lin = (1.0f/cutout_size); + float cutout_bevel_width_ = 0.1 + cutout_bevel_width * 0.9f; + + vm_coordinates uv = vm_coord( + translation: texture_translate, + rotation: texture_rotate, + scaling: punching_scale, + uv_space: uv_space_index + ); + + vm_coordinates punching_uv = hexagonal_grid ? vm_coord_hex( + uv: uv, + scale: cutout_roundness_ * cutout_size_lin + ) : vm_coord_grid( + uv: vm_coord_rowcol_offset( + uv: uv, + offset: square_grid_offset, + horizontal_offset: horizontal_offset + ), + scale: cutout_roundness_ * cutout_size_lin + ); + // select the correct subtile from the atlas + float4 crop = tile_select(shape_select); + + ::base::texture_return lookup = vm_tex_lookup( + tex: punching_cutout, + uv: punching_uv, + mono_source: mono_a, + scale: float4(1.0f), + crop_u: float2(crop.x, crop.y), + crop_v: float2(crop.z, crop.w), + wrap_u: ::tex::wrap_clamp, + wrap_v: ::tex::wrap_clamp + ); + + float low = (1.0 - cutout_roundness_); + float high = (cutout_size_lin * (cutout_bevel_width_ * 0.2f) * cutout_roundness_) + (1.0 - cutout_roundness_); + // remap x...y to (clamped) 0...1 + float x = ::math::clamp((lookup.mono - low)/(high - low), 0.0, 1.0); + // spherical falloff + float falloff=::math::sqrt(1.0-x*x); + // masking falloff as the center of the cutout is flat + float masked_falloff=falloff<=0.0?1.0:falloff; + + // where base material is still there, use the value of the base material + float cutout= ::math::min(falloff<=0.0?0.0:1.0, base_mat.geometry.cutout_opacity); + + // bring in -.5 ... +.5 range and lerp between lookup and flat normal + float3 remap_norm = ::math::lerp(float3(lookup.tint), float3(0.5, 0.5, 1.0), masked_falloff) - float3(0.5); + float3 t_norm = ::math::normalize(remap_norm * float3(cutout_bump_strength, cutout_bump_strength, 1.0)); + + float3 rotfix_norm = float3(::math::cos(punching_uv.rotation) * t_norm.x - ::math::sin(punching_uv.rotation) * t_norm.y, + ::math::sin(punching_uv.rotation) * t_norm.x + ::math::cos(punching_uv.rotation) * t_norm.y, + t_norm.z); + + float3 normal = ::state::texture_tangent_u(punching_uv.uv_space_index) * rotfix_norm.x + + ::state::texture_tangent_v(punching_uv.uv_space_index) * rotfix_norm.y + + ::state::normal() * rotfix_norm.z; + + float3 final_normal = ::base::blend_normals( + base_normal: normal, + base_normal_weight: 1.0f, + detail_normal: base_mat.geometry.normal, + detail_normal_weight: 1.0f + ); + +} in material( + surface: material_surface( + scattering: base_mat.surface.scattering + ), + volume: base_mat.volume, + ior: base_mat.ior, + thin_walled: true, + geometry: material_geometry( + displacement: base_mat.geometry.displacement, + normal: final_normal, + cutout_opacity: cutout + ) +); + +// ------------------------ Aluminum Sheet Presets ------------------------ +export material Aluminum_Sheet_Soft_Splotches(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Aluminum Sheet - Soft Splotches"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Soft_Splotches.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "automotive", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "neutral", "gray")) +]] += Aluminum_Sheet( + infinite_tiling: false, + sheet_brightness: 0.5f, + roughness: 0.3f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.75f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.01f, + impurities_weight_3: 0.98f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + + + +export material Aluminum_Sheet_Matte_Imperfections(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Aluminum Sheet - Matte Imperfections"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Matte_Imperfections.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "automotive", "new", "matte", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "neutral")) +]]= Aluminum_Sheet( + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.75f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.265f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 0.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + + + +export material Aluminum_Sheet_Glossy_Imperfections(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Aluminum Sheet - Glossy Imperfections"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Glossy_Imperfections.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "automotive", "new", "glossy", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "neutral")) +]] += Aluminum_Sheet( + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.3f, + streaks: 0.1f, + scratch_bump_factor: 0.15f, + imperfections_amount: 0.1f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.89f, + impurities_weight_3: 0.86f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + + + +export material Aluminum_Sheet_Splotchy_Streaks(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Aluminum Sheet - Splotchy Streaks"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Splotchy_Streaks.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "automotive", "new", "glossy", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "neutral")) +]]= Aluminum_Sheet( + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.6f, + streaks: 0.1f, + scratch_bump_factor: 0.2f, + imperfections_amount: 0.26f, + impurities_weight_1: 1.0f, + impurities_weight_2: 0.76f, + impurities_weight_3: 0.13f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + +export material Aluminum_Sheet_Glossy_Streaks(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Aluminum Sheet - Glossy Streaks"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Glossy_Streaks.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "automotive", "new", "glossy", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "neutral")) +]] += Aluminum_Sheet( + infinite_tiling: false, + sheet_brightness: 0.65f, + roughness: 0.25f, + streaks: 0.8f, + scratch_bump_factor: 0.88f, + imperfections_amount: 0.86f, + impurities_weight_1: 1.0f, + impurities_weight_2: 0.75f, + impurities_weight_3: 0.125f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + +// ------------------------ Punched Aluminum Sheet Presets ------------------------ + +export material Aluminum_Sheet_Punched_Small_Circular(*)[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Small Circular Punch"), + ::anno::description(DESCRIPTION_PUNCH), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched_Small_Circular.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "circular", "gray")) +]] = Aluminum_Sheet_Punched( + // Punching parameters + shape_select: pattern_circle, + punching_grid_size: 1.0f, + cutout_size: 0.5f, + cutout_roundness: 0.4f, + cutout_bevel_width: 0.5f, + cutout_bump_strength: 0.8f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + // Material Parameters + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.55f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.33f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 1.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + +export material Aluminum_Sheet_Punched_Hexagonal(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Hexagonal Punch"), + ::anno::description(DESCRIPTION_PUNCH), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched_Hexagonal.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "hexagonal", "gray")) +]] = Aluminum_Sheet_Punched( + // Punching parameters + shape_select: pattern_hexagon, + punching_grid_size: 1.5f, + cutout_size: .95f, + cutout_roundness: 0.4f, + cutout_bevel_width: 0.5f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + // Material Parameters + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.55f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.33f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 1.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + +export material Aluminum_Sheet_Punched_Hexagonal_Small(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Small Hexagonal Punch"), + ::anno::description(DESCRIPTION_PUNCH), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched_Hexagonal_Small.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "hexagonal", "gray")) +]] = Aluminum_Sheet_Punched( + // Punching parameters + shape_select: pattern_hexagon, + punching_grid_size: float2(.75f), + cutout_size: .58f, + cutout_roundness: 0.4f, + cutout_bevel_width: 0.3f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + // Material Parameters + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.55f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.33f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 1.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + +export material Aluminum_Sheet_Punched_Square(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Square Punch"), + ::anno::description(DESCRIPTION_PUNCH), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched_Square.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "square", "gray")) +]] = Aluminum_Sheet_Punched( + // Punching parameters + shape_select: pattern_square, + punching_grid_size: 1.2f, + cutout_size: 0.56f, + cutout_roundness: 0.1f, + cutout_bevel_width: 0.5f, + cutout_bump_strength: 1.5f, + hexagonal_grid: false, + square_grid_offset: 0.5f, + horizontal_offset: true, + + // Material Parameters + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.55f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.33f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 1.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + +export material Aluminum_Sheet_Punched_Line(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Line Punch"), + ::anno::description(DESCRIPTION_PUNCH), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched_Line.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "line", "gray")) +]] = Aluminum_Sheet_Punched( + // Punching parameters + shape_select: pattern_line, + punching_grid_size: 1.3f, + cutout_size: 0.59f, + cutout_roundness: 0.4f, + cutout_bevel_width: 0.3f, + cutout_bump_strength: 1.5f, + hexagonal_grid: false, + square_grid_offset: 0.3333f, + horizontal_offset: true, + + // Material Parameters + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.55f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.33f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 1.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + +export material Aluminum_Sheet_Punched_Cross(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Cross Punch"), + ::anno::description(DESCRIPTION_PUNCH), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched_Cross.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "cross", "gray")) +]] = Aluminum_Sheet_Punched( + // Punching parameters + shape_select: pattern_cross, + punching_grid_size: 2.0f, + cutout_size: 0.59f, + cutout_roundness: 0.1f, + cutout_bevel_width: 0.44f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + // Material Parameters + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.55f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.33f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 1.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + +export material Aluminum_Sheet_Punched_Rhombus(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Rhombus Punch"), + ::anno::description(DESCRIPTION_PUNCH), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched_Rhombus.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "rhombus", "gray")) +]] = Aluminum_Sheet_Punched( + // Punching parameters + shape_select: pattern_rhombus, + punching_grid_size: 1.4f, + cutout_size: 1.0f, + cutout_roundness: 0.8f, + cutout_bevel_width: 0.5f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + // Material Parameters + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.55f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.33f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 1.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + +export material Aluminum_Sheet_Punched_Triangle(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Triangle Punch"), + ::anno::description(DESCRIPTION_PUNCH), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched_Triangle.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "triangle", "gray")) +]] = Aluminum_Sheet_Punched( + // Punching parameters + shape_select: pattern_triangle, + punching_grid_size: 1.3f, + cutout_size: 1.08f, + cutout_roundness: 1.0f, + cutout_bevel_width: 1.0f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + // Material Parameters + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.55f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.33f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 1.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); + + +export material Aluminum_Sheet_Punched_Star(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Aluminum Sheet - Star Punch"), + ::anno::description(DESCRIPTION_PUNCH), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Aluminum_Sheet.Aluminum_Sheet_Punched_Star.png"), + ::anno::key_words(string[]("metal", "sheet", "aluminum", "aluminium", "imperfections", "interior", "exterior", "new", "unfinished", "reflective", "oxidized", "construction", "design", "infinite tiling", "punched", "punching", "star", "gray")) +]] = Aluminum_Sheet_Punched( + // Punching parameters + shape_select: pattern_star, + punching_grid_size: 1.5f, + cutout_size: 0.68f, + cutout_roundness: 0.5f, + cutout_bevel_width: 0.44f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + // Material Parameters + infinite_tiling: false, + sheet_brightness: 0.85f, + roughness: 0.55f, + streaks: 0.0f, + scratch_bump_factor: 0.0f, + imperfections_amount: 0.33f, + impurities_weight_1: 0.75f, + impurities_weight_2: 0.43f, + impurities_weight_3: 1.0f, + enable_round_corners: false, + roundcorner_radius: 0.01f, + across_materials: false, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0 +); \ No newline at end of file diff --git a/Assets/Material/material_0390/brass_gradients_yellow_gold_red.png b/Assets/Material/material_0390/brass_gradients_yellow_gold_red.png new file mode 100644 index 0000000000000000000000000000000000000000..d2284d8dced0e95612b370d75d70ce3633cf0b6a --- /dev/null +++ b/Assets/Material/material_0390/brass_gradients_yellow_gold_red.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4ad026bc24f01f7e6ca1b22707a00a3234e61024b06e737b09af97aa9f186f7 +size 334 diff --git a/Assets/Material/material_0390/brass_hammered_multi_R_pit_G_ao_rough.jpg b/Assets/Material/material_0390/brass_hammered_multi_R_pit_G_ao_rough.jpg new file mode 100644 index 0000000000000000000000000000000000000000..68a33ff0c9ac6e8b95886e44a482c1384e1ed594 --- /dev/null +++ b/Assets/Material/material_0390/brass_hammered_multi_R_pit_G_ao_rough.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:90e1b87b66d9db6f593b094aaaee8fdc4b7934c25e9938a2eff1503e0cd5a29d +size 5691375 diff --git a/Assets/Material/material_0390/hammered_multi_R_rough_G_corrspots_B_metal.jpg b/Assets/Material/material_0390/hammered_multi_R_rough_G_corrspots_B_metal.jpg new file mode 100644 index 0000000000000000000000000000000000000000..cccfca6bbb9ddb9f4e772de5043c7e00fd5c0e1e --- /dev/null +++ b/Assets/Material/material_0390/hammered_multi_R_rough_G_corrspots_B_metal.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e836ac0230fa8594460f0844ef74516703022a37fe94dddbea062e78103523 +size 5385252 diff --git a/Assets/Material/material_0390/hammered_norm.jpg b/Assets/Material/material_0390/hammered_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9a55c2399242940681430d12e039a5ed6595d85c --- /dev/null +++ b/Assets/Material/material_0390/hammered_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb48b2cb24f46a05332ceca017de260955eb87524c5c2b6864a392c7c65b9dbe +size 1435260 diff --git a/Assets/Material/material_0393/brass_gradients_yellow_gold_red.png b/Assets/Material/material_0393/brass_gradients_yellow_gold_red.png new file mode 100644 index 0000000000000000000000000000000000000000..d2284d8dced0e95612b370d75d70ce3633cf0b6a --- /dev/null +++ b/Assets/Material/material_0393/brass_gradients_yellow_gold_red.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4ad026bc24f01f7e6ca1b22707a00a3234e61024b06e737b09af97aa9f186f7 +size 334 diff --git a/Assets/Material/material_0393/scratched_multi_R_dents_G_crust_B_rough.jpg b/Assets/Material/material_0393/scratched_multi_R_dents_G_crust_B_rough.jpg new file mode 100644 index 0000000000000000000000000000000000000000..7ba5a23e7a3fa371ce7f6a87acbd62d8b36ab92a --- /dev/null +++ b/Assets/Material/material_0393/scratched_multi_R_dents_G_crust_B_rough.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:454906861d0edc95498071bba0453e5acff4cab7ee9fcf209c4532eaa46857e5 +size 10917898 diff --git a/Assets/Material/material_0393/scratched_multi_R_scratchA_G_scratchB_B_ABblur.jpg b/Assets/Material/material_0393/scratched_multi_R_scratchA_G_scratchB_B_ABblur.jpg new file mode 100644 index 0000000000000000000000000000000000000000..a4eeff412961fbc5996f0c335d284609923b3b5d --- /dev/null +++ b/Assets/Material/material_0393/scratched_multi_R_scratchA_G_scratchB_B_ABblur.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d70db4dd56e5307f6c86c1a11f24f05581b1876499ff0a4f838022e9e2aeedb0 +size 9683102 diff --git a/Assets/Material/material_0393/scratched_normal.jpg b/Assets/Material/material_0393/scratched_normal.jpg new file mode 100644 index 0000000000000000000000000000000000000000..23bccd19228c94a6ed278d7040a2ad8987f4d3f5 --- /dev/null +++ b/Assets/Material/material_0393/scratched_normal.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:07ddddeea1bd74d48aee7d92f975bc041bcfd0633eecf42dd73bea897b76f76e +size 5076504 diff --git a/Assets/Material/material_0405/hammered_multi_R_pit_G_ao_B_hammer.jpg b/Assets/Material/material_0405/hammered_multi_R_pit_G_ao_B_hammer.jpg new file mode 100644 index 0000000000000000000000000000000000000000..f7a8dbefc7467a4f1dc41dc4d8881e82a9337eb0 --- /dev/null +++ b/Assets/Material/material_0405/hammered_multi_R_pit_G_ao_B_hammer.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c1fb0ee77664fdefbafb111ea2600cbc7054753a7ef7e836a6d16186f7adf35a +size 4822565 diff --git a/Assets/Material/material_0405/hammered_multi_R_rough_G_corrspots_B_metal.jpg b/Assets/Material/material_0405/hammered_multi_R_rough_G_corrspots_B_metal.jpg new file mode 100644 index 0000000000000000000000000000000000000000..cccfca6bbb9ddb9f4e772de5043c7e00fd5c0e1e --- /dev/null +++ b/Assets/Material/material_0405/hammered_multi_R_rough_G_corrspots_B_metal.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e836ac0230fa8594460f0844ef74516703022a37fe94dddbea062e78103523 +size 5385252 diff --git a/Assets/Material/material_0405/hammered_norm.jpg b/Assets/Material/material_0405/hammered_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9a55c2399242940681430d12e039a5ed6595d85c --- /dev/null +++ b/Assets/Material/material_0405/hammered_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb48b2cb24f46a05332ceca017de260955eb87524c5c2b6864a392c7c65b9dbe +size 1435260 diff --git a/Assets/Material/material_0430/hammered_multi_R_pit_G_ao_B_hammer.jpg b/Assets/Material/material_0430/hammered_multi_R_pit_G_ao_B_hammer.jpg new file mode 100644 index 0000000000000000000000000000000000000000..f7a8dbefc7467a4f1dc41dc4d8881e82a9337eb0 --- /dev/null +++ b/Assets/Material/material_0430/hammered_multi_R_pit_G_ao_B_hammer.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c1fb0ee77664fdefbafb111ea2600cbc7054753a7ef7e836a6d16186f7adf35a +size 4822565 diff --git a/Assets/Material/material_0430/hammered_multi_R_rough_G_corrspots_B_metal.jpg b/Assets/Material/material_0430/hammered_multi_R_rough_G_corrspots_B_metal.jpg new file mode 100644 index 0000000000000000000000000000000000000000..cccfca6bbb9ddb9f4e772de5043c7e00fd5c0e1e --- /dev/null +++ b/Assets/Material/material_0430/hammered_multi_R_rough_G_corrspots_B_metal.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e836ac0230fa8594460f0844ef74516703022a37fe94dddbea062e78103523 +size 5385252 diff --git a/Assets/Material/material_0430/hammered_norm.jpg b/Assets/Material/material_0430/hammered_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9a55c2399242940681430d12e039a5ed6595d85c --- /dev/null +++ b/Assets/Material/material_0430/hammered_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb48b2cb24f46a05332ceca017de260955eb87524c5c2b6864a392c7c65b9dbe +size 1435260 diff --git a/Assets/Material/material_0431/metal_knurling_multi_R_diff_G_rough_B_grunge.jpg b/Assets/Material/material_0431/metal_knurling_multi_R_diff_G_rough_B_grunge.jpg new file mode 100644 index 0000000000000000000000000000000000000000..f773c9cafdd2fa71939326f23ba94520cda6be24 --- /dev/null +++ b/Assets/Material/material_0431/metal_knurling_multi_R_diff_G_rough_B_grunge.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:827f0cf47b4356493fba016b6e9ddbcc6bfab0224b99a4e6a9c6ab69e24189a9 +size 5944332 diff --git a/Assets/Material/material_0431/metal_knurling_multi_heights.jpg b/Assets/Material/material_0431/metal_knurling_multi_heights.jpg new file mode 100644 index 0000000000000000000000000000000000000000..3090c2e09a72cf7551ca2608f3c7be2a475b07c8 --- /dev/null +++ b/Assets/Material/material_0431/metal_knurling_multi_heights.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b4d7b7feb8921eed2081b4eb60a08bbce49aab76ac17f74cc564eeb7c7a4c11 +size 2076774 diff --git a/Assets/Material/material_0431/metal_knurling_norm.jpg b/Assets/Material/material_0431/metal_knurling_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9036d8679b5c63892eb665576e748b66afef3088 --- /dev/null +++ b/Assets/Material/material_0431/metal_knurling_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dc9e78477fee20785975eb0b93ae5e861e135591998a89d624ce80fd779128f2 +size 1900541 diff --git a/Assets/Material/material_0440/metal_scratched_R_diff_G_scratchvar_B_dirt.jpg b/Assets/Material/material_0440/metal_scratched_R_diff_G_scratchvar_B_dirt.jpg new file mode 100644 index 0000000000000000000000000000000000000000..1e5130fa5a243fd255a37ff6099a38a6a6e41d52 --- /dev/null +++ b/Assets/Material/material_0440/metal_scratched_R_diff_G_scratchvar_B_dirt.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:51a6eb57877fc78f9da063bc7eedfb417ccde0726015712d400dbe84ea03fa46 +size 3114776 diff --git a/Assets/Material/material_0440/metal_scratched_R_scratch1_G_scratch2_B_scratch3.jpg b/Assets/Material/material_0440/metal_scratched_R_scratch1_G_scratch2_B_scratch3.jpg new file mode 100644 index 0000000000000000000000000000000000000000..30f1a268fffa7e0b70da8c2e3a04396b75b75e0e --- /dev/null +++ b/Assets/Material/material_0440/metal_scratched_R_scratch1_G_scratch2_B_scratch3.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:22a432baddf95f05140af2f8fb47d763439f06e84648e89eddc9d9b726d59867 +size 6891717 diff --git a/Assets/Material/material_0440/metal_scratched_scratch_norm.jpg b/Assets/Material/material_0440/metal_scratched_scratch_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..b5b09ebf9955e03dfc4ab47f095f7380cd485197 --- /dev/null +++ b/Assets/Material/material_0440/metal_scratched_scratch_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fef50be8c23dabfbd7a799a3434ba6c39122d058140dd9c11cb0c3da1da5b537 +size 3254868 diff --git a/Assets/Material/material_0445/metalweave_03_AO.jpg b/Assets/Material/material_0445/metalweave_03_AO.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9991bf416978aebe65d616781b42d023378fbf1b --- /dev/null +++ b/Assets/Material/material_0445/metalweave_03_AO.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ae55840b61564eb926f1355c05c2e6750ac5d047484faf8ff15c45f6fbec318c +size 394535 diff --git a/Assets/Material/material_0445/metalweave_03_color_mask.png b/Assets/Material/material_0445/metalweave_03_color_mask.png new file mode 100644 index 0000000000000000000000000000000000000000..17ab486e4b4d56ba4943c1ab50f07b8be50a741a --- /dev/null +++ b/Assets/Material/material_0445/metalweave_03_color_mask.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:307e02b87c7cf81b0f05f223b3e6c81bb93d06b851d887e2fa5dfb01190a49d9 +size 2198 diff --git a/Assets/Material/material_0445/metalweave_03_detail_norm.jpg b/Assets/Material/material_0445/metalweave_03_detail_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9ac97e77601efbc84d5d945ed8612223393aa70a --- /dev/null +++ b/Assets/Material/material_0445/metalweave_03_detail_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ff862bc6859b0854eecc72c402cd5d9975af6b034796cd3376b3e5787ab7463c +size 607086 diff --git a/Assets/Material/material_0445/metalweave_03_detail_scratches_norm.jpg b/Assets/Material/material_0445/metalweave_03_detail_scratches_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..0af3dbfadfc783d2c6345cc3e4aaa78f30b3d6dd --- /dev/null +++ b/Assets/Material/material_0445/metalweave_03_detail_scratches_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2abff067df8109e3b1cb12631b4df6b9259be8b0ce68666836af7a792d70e90f +size 298665 diff --git a/Assets/Material/material_0445/metalweave_03_metal.jpg b/Assets/Material/material_0445/metalweave_03_metal.jpg new file mode 100644 index 0000000000000000000000000000000000000000..ae74a413b565125e6037d348b55742cbb2a1ef81 --- /dev/null +++ b/Assets/Material/material_0445/metalweave_03_metal.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e86cdf5e8dccd1f4bb4d7aaffbc21ea51ba140c848ddac8549e97bf98214929a +size 711344 diff --git a/Assets/Material/material_0445/metalweave_03_norm.jpg b/Assets/Material/material_0445/metalweave_03_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..2f575fcbfefe08b74ab3a042a2c4b501bfab88ad --- /dev/null +++ b/Assets/Material/material_0445/metalweave_03_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9a0f3460be4d7f3a8cf5e68583e993591a465f53993bd2b4fae6e1bd4bafafb3 +size 197435 diff --git a/Assets/Material/material_0445/metalweave_03_rough.jpg b/Assets/Material/material_0445/metalweave_03_rough.jpg new file mode 100644 index 0000000000000000000000000000000000000000..c78f4760e962a8e264c6d83e1c41b3a0a977144e --- /dev/null +++ b/Assets/Material/material_0445/metalweave_03_rough.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:96557914625b8ce449059aa3542ac4ca69b64e82b3c253202aac04bf63aceddd +size 3441599 diff --git a/Assets/Material/material_0450/hammered_multi_R_pit_G_ao_B_hammer.jpg b/Assets/Material/material_0450/hammered_multi_R_pit_G_ao_B_hammer.jpg new file mode 100644 index 0000000000000000000000000000000000000000..f7a8dbefc7467a4f1dc41dc4d8881e82a9337eb0 --- /dev/null +++ b/Assets/Material/material_0450/hammered_multi_R_pit_G_ao_B_hammer.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c1fb0ee77664fdefbafb111ea2600cbc7054753a7ef7e836a6d16186f7adf35a +size 4822565 diff --git a/Assets/Material/material_0450/hammered_multi_R_rough_G_corrspots_B_metal.jpg b/Assets/Material/material_0450/hammered_multi_R_rough_G_corrspots_B_metal.jpg new file mode 100644 index 0000000000000000000000000000000000000000..cccfca6bbb9ddb9f4e772de5043c7e00fd5c0e1e --- /dev/null +++ b/Assets/Material/material_0450/hammered_multi_R_rough_G_corrspots_B_metal.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e836ac0230fa8594460f0844ef74516703022a37fe94dddbea062e78103523 +size 5385252 diff --git a/Assets/Material/material_0450/hammered_norm.jpg b/Assets/Material/material_0450/hammered_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9a55c2399242940681430d12e039a5ed6595d85c --- /dev/null +++ b/Assets/Material/material_0450/hammered_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb48b2cb24f46a05332ceca017de260955eb87524c5c2b6864a392c7c65b9dbe +size 1435260 diff --git a/Assets/Material/material_0456/metal_smudges_rough.jpg b/Assets/Material/material_0456/metal_smudges_rough.jpg new file mode 100644 index 0000000000000000000000000000000000000000..32000971764b8a672817ea01556d39a62461ab7b --- /dev/null +++ b/Assets/Material/material_0456/metal_smudges_rough.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f9e82f8ea8c39d649173c220617eedab68f68a38c749ffe8b7c6c8195ee3254 +size 2901291 diff --git a/Assets/Material/material_0463/Punched_Circular_Plate.mdl b/Assets/Material/material_0463/Punched_Circular_Plate.mdl new file mode 100644 index 0000000000000000000000000000000000000000..20c368b0da5458c9de4a98567ca34ad11c483cd8 --- /dev/null +++ b/Assets/Material/material_0463/Punched_Circular_Plate.mdl @@ -0,0 +1,512 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. * + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + +mdl 1.6; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +const string DESCRIPTION = "A diamont metal plate material. The added texture reduces the risk of slipping, " +"making diamond plate a solution for stairs, catwalks, walkways, and ramps in industrial settings"; + + +int lowbias32(int x) +{ + x ^= x >>> 16; + x *= 0x7feb352d; + x ^= x >>> 15; + x *= 0x846ca68b; + x ^= x >>> 16; + return x; +} + +float uint2float(int x) +{ + return float(x & 0x7FFFFFFF) + (x < 0 ? 2147483648.0 : 0.0); +} + +float2x2 invert_2x2(float2x2 M) +{ + float det = M[0][0]*M[1][1] - M[0][1]*M[1][0]; + //https://www.chilimath.com/lessons/advanced-algebra/inverse-of-a-2x2-matrix/ + return (1.0 / det) * float2x2(M[1][1], -M[0][1], -M[1][0], M[0][0]); +} + +float2 rnd22(int2 p) { + float2 ret_val = float2( + uint2float(lowbias32(p[0] + lowbias32(p[1]))) / 4294967296.f, + uint2float(lowbias32(p[0] + 32000 + lowbias32(p[1]))) / 4294967296.f + ); + return ret_val; +} + +float contrast_brightness( + float input = 0.5f, + float contrast = 0.5f, + float brightness = 0.5f +) +{ + float return_value = contrast > 0.5 ? + float(math::clamp((input - 0.5) * 1/(1.000001 - (contrast - 0.5)*2.0) + 0.5, 0.0, 1.0) + (brightness - 0.5) * 2.0) + : + float(math::clamp((input - 0.5) * contrast * 2.0 + 0.5 + (brightness - 0.5)*2.0, 0.0, 1.0)); + + return return_value; +} + +float3 transform_internal_to_tangent(float3 n) +[[ + anno::hidden() +]] +{ + return + n.x* float3(state::texture_tangent_u(0).x,state::texture_tangent_v(0).x,state::normal().x)+ + n.y* float3(state::texture_tangent_u(0).y,state::texture_tangent_v(0).y,state::normal().y)+ + n.z* float3(state::texture_tangent_u(0).z,state::texture_tangent_v(0).z,state::normal().z); +} + +// Returns the normal n in internal space, given n is in tangent space. +float3 transform_tangent_to_internal(float3 n) +[[ + anno::hidden() +]] +{ + return state::texture_tangent_u(0) * n.x + + state::texture_tangent_v(0) * n.y + + state::normal() * n.z ; +} + +// Returns a normal by adding a detail normal to a global normal. +// If detail blending of two normal maps gives visual artifacts, check if texture_2d are loaded +// correctly with tex::gamma_linear +float3 add_detail_normal(float3 nd = state::normal(), float3 n = state::normal()) +{ + // http://blog.selfshadow.com/publications/blending-in-detail/ + float3 n_t = transform_internal_to_tangent(n); + float3 nd_t = transform_internal_to_tangent(nd); + + n_t=n_t + float3(0.,0.,1.); + nd_t = nd_t * float3(-1.,-1.,1.); + n = n_t*math::dot(n_t, nd_t)/n_t.z - nd_t; + return ::math::normalize(transform_tangent_to_internal(n)); +} + +float histogram_range(float input, float range = 1.0f, float position = 0.5f) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + +float remap_xy_to_0_1(float input, float x, float y) +{ + return (input - x)/(y - x); +} + +float histogram_scan_big(float input, float width, float position) +{ + return ::math::clamp( + remap_xy_to_0_1(input, + ::math::lerp(-width, 1.0, position), + ::math::lerp(0.0, 1.0 + width, position)), + 0.0, + 1.0); +} + +struct vm_coordinates{ + float2 uv; + float rotation; + int uv_space_index; + float4 carry; +}; + +enum vm_mono_select +[[ + ::anno::description("Modes for the creation of a gray-scale value from a color."), + ::anno::hidden() +]] +{ + mono_r = 0, + mono_g = 1, + mono_b = 2, + mono_a = 3, + mono_average = 4 +}; + +vm_coordinates vm_coord +( + float2 translation = float2(0.0f, 0.0) [[ + ::anno::display_name("Translation"), + ::anno::description("Translates the coordinates.") + ]], + float rotation = 0.0f [[ + ::anno::display_name("Rotation"), + ::anno::description("Rotates the coordinates in degrees.") + ]], + float2 scaling = float2(1.0f, 1.0f) [[ + ::anno::display_name("Scaling"), + ::anno::description("Scales the coordinates.") + ]], + uniform int uv_space = 0 [[ + ::anno::display_name("UV Space"), + ::anno::description("Chose the UV space.") + ]] +) +[[ + ::anno::display_name("vm Transform"), + ::anno::description("Generates coordinates to be used in vm_lookup functions.") +]] +{ + vm_coordinates uv; + ::base::texture_coordinate_info info = ::base::coordinate_source( ::base::texture_coordinate_uvw, uv_space); + uv.rotation = (rotation * 3.1415926535897932384626433832f) / 180.f; + uv.uv = float2(info.position.x, info.position.y); + float sine = ::math::sin(uv.rotation); + float cosine = ::math::cos(uv.rotation); + float2x2 rot = float2x2(cosine, -sine, sine, cosine); + uv.uv = rot * uv.uv; + uv.uv /= scaling; + uv.uv += translation; + // Translation before or after rotation? + return uv; +} + +vm_coordinates vm_coord_post_scale( + vm_coordinates uv = vm_coord(), + float2 scale = 1.0f +) +{ + uv.uv /= scale; + return uv; +} + +float3 vm_tex_infinite( + uniform texture_2d tex = texture_2d(), + vm_coordinates uv = vm_coord(), + float3 average_color = float3(0.5f, 0.5f, 1.0f), + float patch_size = 1.0, + bool gamma_correct = true, + float gamma = 2.2f +) +{ + float2 uv_in = uv.uv; + + float3 O = float3(0.f); + float2x2 M0 = float2x2(1.f,0.f, 0.5f, ::math::sqrt(3.f)/2.f); + float2x2 M = invert_2x2(M0); // transform matrix <-> tilted space + + float2 U = uv_in; + float2 V = M * (uv.uv / patch_size); //pre-tilted hexa coordinates + int2 I = int2(::math::floor(V))+int2(800); // hexa-tile id + + // The mean color needs to be determined in Photoshop then to make the + // average color work out, take the float value and calculate the apropriate + // mean value as (value^(1/2.2)) + + float3 m = average_color; + + float3 F = float3(::math::frac(V)[0], ::math::frac(V)[1], 0.f), W; + F[2] = 1.0 - F[0] - F[1]; // local hexa coordinates + + if( F[2] > 0.f ) + O = (W[0] = F[2]) * (( ::tex::lookup_float3(tex, U-rnd22(I))) - m) + + (W[1] = F[1]) * (( ::tex::lookup_float3(tex, U-rnd22(I+int2(0,1)))) - m) + + (W[2] = F[0]) * (( ::tex::lookup_float3(tex, U-rnd22(I+int2(1,0)))) - m); + else + O = (W[0] = -F[2]) * (( ::tex::lookup_float3(tex, U-rnd22(I+int2(1)))) - m) + + (W[1] = 1.f - F[1]) * (( ::tex::lookup_float3(tex, U-rnd22(I+int2(1, 0)))) - m) + + (W[2] = 1.f - F[0]) * (( ::tex::lookup_float3(tex, U-rnd22(I+int2(0, 1)))) - m); + O = m + O/::math::length(W); + O = ::math::clamp( (O), 0.0f, 1.0f); + + return gamma_correct? ::math::pow(::math::max(O, float3(0.0f)), gamma) : float3(O); +} + +::base::texture_return vm_tex_lookup( + uniform texture_2d tex, + vm_coordinates uv = vm_coord(), + uniform vm_mono_select mono_source = mono_a, + float4 scale = float4(1.0f)) +{ + float mono; + float4 lookup = ::tex::lookup_float4(tex, uv.uv, ::tex::wrap_repeat, ::tex::wrap_repeat) * scale; + switch( mono_source ) { + case mono_r: mono = lookup.x; + break; + case mono_g: mono = lookup.y; + break; + case mono_b: mono = lookup.z; + break; + case mono_a: mono = lookup.w; + break; + case mono_average: mono = ::math::average(float3(lookup.x, lookup.y, lookup.z)); + break; + } + return ::base::texture_return(color(lookup.x, lookup.y, lookup.z), mono); +} + +float3 vm_tex_normal_lookup( + uniform texture_2d tex, + vm_coordinates uv = vm_coord(), + float strength = 1.0f +) +{ + float rot = uv.rotation; + // Lookup and convert normal texture to -1 ... 1 range + float3 norm = (::tex::lookup_float3(tex, uv.uv, ::tex::wrap_repeat, ::tex::wrap_repeat) - float3(.5f)) * 2.0f; + norm = ::math::normalize(norm * float3(strength, strength, 1.0)); + // if any rotation happened prior to the lookup, compensate for it + norm = float3(::math::cos(rot) * norm.x - ::math::sin(rot) * norm.y, + ::math::sin(rot) * norm.x + ::math::cos(rot) * norm.y, + norm.z); + return norm.x * ::state::texture_tangent_u(uv.uv_space_index) + + norm.y * ::state::texture_tangent_v(uv.uv_space_index) + + norm.z * ::state::normal(); +} + +export material Punched_Circular_Plate( + float metal_roughness = 0.27f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Metal Roughness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(0) + ]], + float roughness_variation = 0.06f [[ + ::anno::description("Amount of variation applied to the roughness, higher numbers lead to non-uniform reflections of the material."), + ::anno::display_name("Roughness Variation"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float dirt_amount = 0.f [[ + ::anno::description("The amount of dirt applied to the material."), + ::anno::display_name("Dirt Amount"), + ::anno::in_group("Appearance", "Dirt"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(3) + ]], + float dirt_weight = 1.f [[ + ::anno::description("Makes the dirt transition sharper and more defined."), + ::anno::display_name("Dirt Weight"), + ::anno::in_group("Appearance", "Dirt"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(4) + ]], + float dirt_brightness = 0.38f [[ + ::anno::description("Amkes the dirt arker or brighter."), + ::anno::display_name("Dirt Brightness"), + ::anno::in_group("Appearance", "Dirt"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(5) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::ui_order(7) + ]], + float2 texture_scale = 1.0f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(8) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Advanced"), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(10) + ]], + uniform float roundcorners_radius_mm = 1.f [[ + ::anno::description("Radius of the rounded corners."), + ::anno::display_name("Round Corner Radius"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(11) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(12) + ]]) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Punched Circular Plate - New Shiny"), + ::anno::contributor("Rüdiger Raab"), + ::anno::description(DESCRIPTION), + ::anno::key_words(string[]("metal", "plate", "diamond", "reflective", "pattern", "safety", "bumped", "embossed", "infinite tiling", "architecture", "construction", "naval", "exterior", "new", "shiny", "gray")), + ::anno::thumbnail("./.thumbs/Punched_Circular_Plate.Punched_Circular_Plate.png"), + ::anno::copyright_notice(COPYRIGHT) +]] + = + let { + + bool tmp0 = false; + float pattern_shininess = 0.f; + float2 texture_rescale = texture_scale * 0.13f; + + // replace the textures here for different punched cutout shapes + texture_2d shape_multi_ao_height = texture_2d("./circle_shape_multi_R_ao_G_height_B_opacity.jpg", ::tex::gamma_linear); + texture_2d shape_norm = texture_2d("./circle_shape_norm.jpg", ::tex::gamma_linear); + + material_surface tmp1(::df::weighted_layer(contrast_brightness(::math::clamp(::math::lerp(1.f, histogram_scan_big(vm_tex_infinite(texture_2d("./transition_noise.jpg", ::tex::gamma_linear), vm_coord_post_scale(vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 5.f), float3(0.50999999f), 1.f, true, 2.20000005f).x, 0.620000005f, dirt_amount) + ::math::max(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y, ::math::pow(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 0.680000007f) * ::math::pow(1.f - vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, 0.969999969f)), ::math::pow(dirt_weight, 0.280000001f)), 0.f, 1.f), 0.659999967f, 0.5f), ::df::microfacet_ggx_smith_bsdf(::math::lerp(0.639999986f, histogram_range(vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, roughness_variation * 0.400000006f, metal_roughness * 0.629999995f + 0.0500000007f) + roughness_variation * 0.299999982f * ::math::pow(1.f - float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 1.26999998f), ::math::clamp(::math::lerp(1.f, histogram_scan_big(vm_tex_infinite(texture_2d("./transition_noise.jpg", ::tex::gamma_linear), vm_coord_post_scale(vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 5.f), float3(0.50999999f), 1.f, true, 2.20000005f).x, 0.620000005f, dirt_amount) + ::math::max(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y, ::math::pow(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 0.680000007f) * ::math::pow(1.f - vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, 0.969999969f)), ::math::pow(dirt_weight, 0.280000001f)), 0.f, 1.f)) * (1.f - pattern_shininess * float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y) * (::math::lerp(0.639999986f, histogram_range(vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, roughness_variation * 0.400000006f, metal_roughness * 0.629999995f + 0.0500000007f) + roughness_variation * 0.299999982f * ::math::pow(1.f - float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 1.26999998f), ::math::clamp(::math::lerp(1.f, histogram_scan_big(vm_tex_infinite(texture_2d("./transition_noise.jpg", ::tex::gamma_linear), vm_coord_post_scale(vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 5.f), float3(0.50999999f), 1.f, true, 2.20000005f).x, 0.620000005f, dirt_amount) + ::math::max(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y, ::math::pow(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 0.680000007f) * ::math::pow(1.f - vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, 0.969999969f)), ::math::pow(dirt_weight, 0.280000001f)), 0.f, 1.f)) * (1.f - pattern_shininess * float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y)), ::math::lerp(0.639999986f, histogram_range(vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, roughness_variation * 0.400000006f, metal_roughness * 0.629999995f + 0.0500000007f) + roughness_variation * 0.299999982f * ::math::pow(1.f - float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 1.26999998f), ::math::clamp(::math::lerp(1.f, histogram_scan_big(vm_tex_infinite(texture_2d("./transition_noise.jpg", ::tex::gamma_linear), vm_coord_post_scale(vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 5.f), float3(0.50999999f), 1.f, true, 2.20000005f).x, 0.620000005f, dirt_amount) + ::math::max(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y, ::math::pow(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 0.680000007f) * ::math::pow(1.f - vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, 0.969999969f)), ::math::pow(dirt_weight, 0.280000001f)), 0.f, 1.f)) * (1.f - pattern_shininess * float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y) * (::math::lerp(0.639999986f, histogram_range(vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, roughness_variation * 0.400000006f, metal_roughness * 0.629999995f + 0.0500000007f) + roughness_variation * 0.299999982f * ::math::pow(1.f - float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 1.26999998f), ::math::clamp(::math::lerp(1.f, histogram_scan_big(vm_tex_infinite(texture_2d("./transition_noise.jpg", ::tex::gamma_linear), vm_coord_post_scale(vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 5.f), float3(0.50999999f), 1.f, true, 2.20000005f).x, 0.620000005f, dirt_amount) + ::math::max(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y, ::math::pow(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 0.680000007f) * ::math::pow(1.f - vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, 0.969999969f)), ::math::pow(dirt_weight, 0.280000001f)), 0.f, 1.f)) * (1.f - pattern_shininess * float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y)), color(0.387622833f, 0.387622833f, 0.387622833f), color(0.387622833f, 0.387622833f, 0.387622833f), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(1.f, ::df::diffuse_reflection_bsdf(vm_tex_lookup(texture_2d("./dirt.jpg", ::tex::gamma_srgb), vm_coord_post_scale(vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 0.5f), mono_average, float4(dirt_brightness * 0.620000005f + 0.0599999987f)).tint, 0.f), bsdf(), add_detail_normal(::math::lerp(vm_tex_normal_lookup(texture_2d("./plate_dirt_norm.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 1.f), ::state::normal(), contrast_brightness(::math::pow(::math::clamp(::math::lerp(1.f, histogram_scan_big(vm_tex_infinite(texture_2d("./transition_noise.jpg", ::tex::gamma_linear), vm_coord_post_scale(vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 5.f), float3(0.50999999f), 1.f, true, 2.20000005f).x, 0.620000005f, dirt_amount) + ::math::max(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y, ::math::pow(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 0.680000007f) * ::math::pow(1.f - vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, 0.969999969f)), ::math::pow(dirt_weight, 0.280000001f)), 0.f, 1.f), 0.229999989f), 0.699999988f, 0.5f)), vm_tex_normal_lookup(shape_norm, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 1.f))), add_detail_normal(::math::lerp(vm_tex_normal_lookup(texture_2d("./plate_dirt_norm.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 1.f), ::state::normal(), contrast_brightness(::math::pow(::math::clamp(::math::lerp(1.f, histogram_scan_big(vm_tex_infinite(texture_2d("./transition_noise.jpg", ::tex::gamma_linear), vm_coord_post_scale(vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 5.f), float3(0.50999999f), 1.f, true, 2.20000005f).x, 0.620000005f, dirt_amount) + ::math::max(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y, ::math::pow(float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).x, 0.680000007f) * ::math::pow(1.f - vm_tex_infinite(texture_2d("./plate_dirt.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), float3(0.647000015f), 1.f, false, 2.20000005f).x, 0.969999969f)), ::math::pow(dirt_weight, 0.280000001f)), 0.f, 1.f), 0.229999989f), 0.699999988f, 0.5f)), vm_tex_normal_lookup(shape_norm, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), 1.f))), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(1.f, 1.f, 1.f); + material_volume tmp4 = material_volume(scattering: vdf(), absorption_coefficient: color(0.f, 0.f, 0.f), scattering_coefficient: color(0.f, 0.f, 0.f)); + material_geometry tmp5(float3(0.f), float3(vm_tex_lookup(shape_multi_ao_height, vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).z, roundcorners_enable ? ::state::rounded_corner_normal(roundcorners_radius_mm * 0.00100000005f, roundcorners_across_materials, 1.f) : ::state::normal()); + } in + material( + thin_walled: tmp0, + surface: tmp1, + backface: tmp2, + ior: tmp3, + volume: tmp4, + geometry: tmp5); + + + +// 2 +export material Punched_Circular_Plate_Glossy(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Punched Circular Plate - Glossy"), + ::anno::contributor("Rüdiger Raab"), + ::anno::description(DESCRIPTION), + ::anno::key_words(string[]("metal", "plate", "diamond", "pattern", "safety", "bumped", "embossed", "infinite tiling", "architecture", "construction", "naval", "exterior", "gray", "glossy")), + ::anno::thumbnail("./.thumbs/Punched_Circular_Plate.Punched_Circular_Plate_Glossy.png"), + ::anno::copyright_notice(COPYRIGHT) +]] += Punched_Circular_Plate ( + metal_roughness: 0.4f, + roughness_variation: 0.47f, + dirt_amount: 0.0f, + dirt_weight: 1.0f, + dirt_brightness: 0.38f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 1.5f, + roundcorners_across_materials: false +); + + + +// 3 +export material Punched_Circular_Plate_Matte_Aged(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Punched Circular Plate - Matte Aged"), + ::anno::contributor("Rüdiger Raab"), + ::anno::description(DESCRIPTION), + ::anno::key_words(string[]("metal", "plate", "diamond", "pattern", "safety", "bumped", "embossed", "infinite tiling", "architecture", "construction", "naval", "exterior", "matte", "aged", "gray")), + ::anno::thumbnail("./.thumbs/Punched_Circular_Plate.Punched_Circular_Plate_Matte_Aged.png"), + ::anno::copyright_notice(COPYRIGHT) +]] += Punched_Circular_Plate ( + metal_roughness: 0.63f, + roughness_variation: 0.72f, + dirt_amount: 0.0f, + dirt_weight: 1.0f, + dirt_brightness: 0.4f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 1.5f, + roundcorners_across_materials: false +); + + +// 4 +export material Punched_Circular_Plate_Dirty_Worn(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Punched Circular Plate - Dirty Worn"), + ::anno::contributor("Rüdiger Raab"), + ::anno::description(DESCRIPTION), + ::anno::key_words(string[]("metal", "plate", "diamond", "pattern", "safety", "bumped", "embossed", "infinite tiling", "architecture", "construction", "naval", "exterior", "gray", "worn", "old", "dirty", "decayed")), + ::anno::thumbnail("./.thumbs/Punched_Circular_Plate.Punched_Circular_Plate_Dirty_Worn.png"), + ::anno::copyright_notice(COPYRIGHT) +]] += Punched_Circular_Plate ( + metal_roughness: 0.38f, + roughness_variation: 0.53f, + dirt_amount: 0.38f, + dirt_weight: 1.0f, + dirt_brightness: 0.4f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 1.5f, + roundcorners_across_materials: false +); \ No newline at end of file diff --git a/Assets/Material/material_0468/Silver_Knurling.mdl b/Assets/Material/material_0468/Silver_Knurling.mdl new file mode 100644 index 0000000000000000000000000000000000000000..22e7baa8b2c8eea9e7064133296847633aa1930b --- /dev/null +++ b/Assets/Material/material_0468/Silver_Knurling.mdl @@ -0,0 +1,359 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. * + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + + +mdl 1.5; + +import ::df::*; +import ::tex::*; +import ::math::*; +import ::base::*; +import ::state::*; +import ::anno::*; +import ::nvidia::core_definitions::*; + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +const string DESCRIPTION = "Metal with a diamond knurling finish"; + +float histogram_range(float input, float range = 1.0f, float position = 0.5f) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(::math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + +::base::texture_coordinate_info transform_coordinate_2( + float4x4 transform + [[ ::anno::description("A transformation to be applied to the source coordinates. rotation_translation_scale() is a suggested means to compute the transformation matrix.") ]], + ::base::texture_coordinate_info coordinate = ::base::texture_coordinate_info() + [[ ::anno::description("Coordinate, typically sourced from coordinate_source or coordinate_projection.") ]] +) [[ + ::anno::description("Transform a texture coordinate by a matrix.") , + ::anno::noinline() + ]] +{ + // Version 2 + float4 r_position = transform * float4(coordinate.position.x,coordinate.position.y,coordinate.position.z,1); + //Try aproximating it for the case that the rotation is only aroud z and assuming the texture layout is nice and z is ~constant. + //just pretend there is no other rotation happening + //get rid of scaling and translation. Then extract fields where sin and cos would be in a simple 2d transform around z. + float4 u = transform[0]; + float3 ru = ::math::normalize(float3(u.x,u.y,u.z)); + float cos = ru.x; + float sin = -ru.y; + //TODO: at least also handle sign of z? + //TODO: handle tangent becoming 0 + + + return ::base::texture_coordinate_info( + float3(r_position.x,r_position.y,r_position.z), + ::math::normalize(cos * coordinate.tangent_u - sin * coordinate.tangent_v), + ::math::normalize(cos * coordinate.tangent_v + sin * coordinate.tangent_u)); +} + +::base::texture_coordinate_info vmat_transform( + float2 translation = float2(0.0, 0.0), + float rotation = 0.0, // rotation in degrees + float2 scaling = float2(1.0, 1.0), + uniform ::base::texture_coordinate_system system = ::base::texture_coordinate_uvw, + uniform int uv_space = 0 +) +{ + float rotation_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + float4x4 scale = + float4x4(1.0 /scaling.x, 0. , 0. , 0., + 0. , 1.0 /scaling.y , 0. , 0., + 0. , 0. , 1.0, 0., + translation.x , translation.y , 0.0, 1.); + + float s = ::math::sin(rotation_rad); + float c = ::math::cos(rotation_rad); + float4x4 rotate = + float4x4( c , -s , 0.0 , 0.0, + s , c , 0.0 , 0.0, + 0.0, 0.0 , 1.0 , 0.0, + 0. , 0.0 , 0.0 , 1.); + + return transform_coordinate_2(scale*rotate, ::base::coordinate_source(system, uv_space)); +} + +export material Silver_Knurling( + //Appearance + float brightness = float(0.7f) [[ + ::anno::description("Adjusts the brightness of the material."), + ::anno::display_name("Brightness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.0f, 1.0f) + ]], + float roughness = float(0.5f) [[ + ::anno::description("Higher values lead to a rougher appearance of the material."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.0f, 1.0f) + ]], + float grooves_dirt = float(0.4f) [[ + ::anno::description("Adds dirt in the grooves of the knurling pattern."), + ::anno::display_name("Grooves Dirt"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.0f, 1.0f) + ]], + uniform float bump_strength = float(0.8f) [[ + ::anno::description("Adds dirt in the grooves of the knurling pattern."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::soft_range(0.0f, 1.0f) + ]], + + // Round Corners + uniform bool enable_round_corners = false [[ + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius = 0.01f [[ + ::anno::display_name("Round Corner Radius"), + ::anno::description("Sets the radius of the round corners in millimeters."), + ::anno::soft_range(0.0f, 0.1f), + ::anno::in_group("Round Corners") + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the rounded corner effect also between other materials."), + ::anno::in_group("Round Corners") + ]], + //Transform + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(0.35f, .35f)), + ::anno::soft_range(0.f, 2.f) + ]], + + // Advanced + uniform int uv_space_index = 0 [[ + ::anno::description("Uses the selected UV space index."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Advanced"), + ::anno::soft_range(0, 4) + ]] +) +[[ + ::anno::display_name("Metal Knurling Silver"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Silver_Knurling.Silver_Knurling.png"), + ::anno::key_words(string[]("metal", "silver", "knurled", "knurling", "pattern", "design", "bumped")), + ::anno::contributor("Ruediger Raab"), + ::anno::author("NVIDIA vMaterials") +]] += let +{ + color metal_tint = color(0.9614253056f, 0.948983344333f, 0.918968346466f); // Silver + + // Texture setup + texture_2d normal_tex = texture_2d("./metal_knurling_norm.jpg", ::tex::gamma_linear); + texture_2d multi_heights_tex = texture_2d("./metal_knurling_multi_heights.jpg", ::tex::gamma_linear); + texture_2d diff_rough_grunge_tex = texture_2d("./metal_knurling_multi_R_diff_G_rough_B_grunge.jpg", ::tex::gamma_linear); + + // Coordinate setup + ::base::texture_coordinate_info uvw = vmat_transform( + translation: texture_translate, + rotation: texture_rotate, + scaling: texture_scale, + system: ::base::texture_coordinate_uvw, + uv_space: uv_space_index + ); + + // ---------- Diff Rough Grunge Lookup ---------- + + float3 diff_rough_grunge_lookup = float3( + ::base::file_texture( + texture: diff_rough_grunge_tex, + uvw: uvw, + mono_source: ::base::mono_average + ).tint ); + + float3 multi_height_lookup = float3( + ::base::file_texture( + texture: multi_heights_tex, + uvw: uvw, + mono_source: ::base::mono_average + ).tint ); + + float3 norm = ::base::tangent_space_normal_texture( + texture: normal_tex, + factor: bump_strength, + uvw: uvw + ); + + + float remap_rough = histogram_range( + input: diff_rough_grunge_lookup.y, + range: 1.0f, + position: 0.234f + ); + + + float roughness_mapped = remap_rough + (roughness * multi_height_lookup.y); + + float remapped_diff = histogram_range( + input: diff_rough_grunge_lookup.x, + range: 1.0f, + position: (brightness * 0.4f) + 0.4f + ); + + float diff_contribution = ::math::pow(remapped_diff - ((grooves_dirt * 0.5) * multi_height_lookup.x * diff_rough_grunge_lookup.z), 2.67f); + + bsdf ggx_smith_bumped = ::df::weighted_layer( + layer: ::df::microfacet_ggx_smith_bsdf( + roughness_u: roughness_mapped * roughness_mapped, + roughness_v: roughness_mapped * roughness_mapped, + tint: color(diff_contribution), + mode: ::df::scatter_reflect + ), + base: bsdf(), + weight: 1.0f, + normal: norm + ); + + bsdf diff_bsdf = ::df::diffuse_reflection_bsdf( + tint: color(diff_contribution) + ); + + + bsdf final_bsdf = ::df::weighted_layer( + weight: 1.0f - (diff_rough_grunge_lookup.z * multi_height_lookup.x * grooves_dirt), + layer: ::df::directional_factor( + normal_tint: metal_tint, + grazing_tint: color(1.0f), + base: ggx_smith_bumped + ), + base: diff_bsdf + ); + + + // Round Corners + float3 round_normal = enable_round_corners ? + ::state::rounded_corner_normal( + radius: roundcorner_radius * 0.001, + across_materials: across_materials + ) : ::state::normal(); +} +in material ( + + surface: material_surface( + scattering: final_bsdf + ), + geometry: material_geometry( + normal: round_normal + ) +); + + +export material Silver_Knurling_Worn(*) +[[ + ::anno::display_name("Metal Knurling - Silver Worn"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Silver_Knurling.Silver_Knurling_Worn.png"), + ::anno::key_words(string[]("metal", "silver", "knurled", "pattern", "knurling", "design", "bumped", "worn")), + ::anno::contributor("Ruediger Raab"), + ::anno::author("NVIDIA vMaterials") +]] = Silver_Knurling( + brightness: 0.4f, + roughness: 1.0f, + grooves_dirt: 1.0f, + bump_strength: 0.8f, + + enable_round_corners: false, + roundcorner_radius: 1.2f, + across_materials: false, + + texture_translate: 0.0f, + texture_rotate: 0.f, + texture_scale: 1.0f, + + uv_space_index: 0 +); + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Assets/Material/material_0474/Stainless_Steel_Brushed_Punched.mdl b/Assets/Material/material_0474/Stainless_Steel_Brushed_Punched.mdl new file mode 100644 index 0000000000000000000000000000000000000000..3c0c444c5a8e6fd38c45d93b0fdad123b117c857 --- /dev/null +++ b/Assets/Material/material_0474/Stainless_Steel_Brushed_Punched.mdl @@ -0,0 +1,1506 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. * + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + +mdl 1.6; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +const string DESCRIPTION = +"A stainless steel material with adjustable roughness and controls to add secondary effects \n" +"such as stains, smudges and mechanical damage"; + + +float4 tile_select(uniform int select = 0) +{ + switch (select) + { + case 0: return float4(0.000, 0.333, 0.666, 1.000); + case 1: return float4(0.333, 0.666, 0.666, 1.000); + case 2: return float4(0.666, 1.000, 0.666, 1.000); + + case 3: return float4(0.000, 0.333, 0.333, 0.666); + case 4: return float4(0.333, 0.666, 0.333, 0.666); + case 5: return float4(0.666, 1.000, 0.333, 0.666); + + case 6: return float4(0.000, 0.333, 0.000, 0.333); + case 7: return float4(0.333, 0.666, 0.000, 0.333); + case 8: return float4(0.666, 1.000, 0.000, 0.333); + + default: return float4(0.000, 0.333, 0.000, 0.333); + } +} + +export struct vm_coordinates +[[ + ::anno::hidden() +]] +{ + float2 uv; + float rotation; + int uv_space_index; + float4 carry; +}; + +enum vm_mono_select +[[ + ::anno::description("Modes for the creation of a gray-scale value from a color."), + ::anno::hidden() +]] +{ + mono_r = 0, + mono_g = 1, + mono_b = 2, + mono_a = 3, + mono_average = 4 +}; + +vm_coordinates vm_coord +( + float2 translation = float2(0.0f, 0.0) [[ + ::anno::display_name("Translation"), + ::anno::description("Translates the coordinates.") + ]], + float rotation = 0.0f [[ + ::anno::display_name("Rotation"), + ::anno::description("Rotates the coordinates in degrees.") + ]], + float2 scaling = float2(1.0f, 1.0f) [[ + ::anno::display_name("Scaling"), + ::anno::description("Scales the coordinates.") + ]], + uniform int uv_space = 0 [[ + ::anno::display_name("UV Space"), + ::anno::description("Chose the UV space.") + ]] +) +[[ + ::anno::display_name("vm Transform"), + ::anno::description("Generates coordinates to be used in vm_lookup functions.") +]] +{ + vm_coordinates uv; + ::base::texture_coordinate_info info = ::base::coordinate_source( ::base::texture_coordinate_uvw, uv_space); + uv.rotation = (rotation * 3.1415926535897932384626433832f) / 180.f; + uv.uv = float2(info.position.x, info.position.y); + float sine = ::math::sin(uv.rotation); + float cosine = ::math::cos(uv.rotation); + float2x2 rot = float2x2(cosine, -sine, sine, cosine); + uv.uv = rot * uv.uv; + uv.uv /= scaling; + uv.uv += translation; + return uv; +} + + +vm_coordinates vm_coord_hex( + vm_coordinates uv, + float scale = 1.0f) +{ + vm_coordinates uv_return; + float2 uv_ = float2(uv.uv.x, uv.uv.y); + + // same as from function get_hex above + float2 s = float2(1.0f, 1.7320508f); + float2 n = uv_ - float2(0.5f, 1.0f); + float4 c = ::math::floor(float4(uv_.x, uv_.y, n.x, n.y)/float4(s.x, s.y, s.x, s.y)) + 0.5f; + float2 h_1 = uv_ - float2(c.x, c.y) * s; + float2 h_2 = uv_ - (float2(c.z, c.w) + 0.5f) * s; + float4 uv_id = ::math::dot(h_1, h_1) < ::math::dot(h_2, h_2) ? float4(h_1.x, h_1.y, c.x, c.y) : float4(h_2.x, h_2.y, c.z, c.w); + + uv_return.uv = float2(uv_id.x*scale+0.5, uv_id.y*scale+0.5); + // unless we introduce random cell rotations where we need to compensate for this in the rotation + // we can just plain copy the rotation value + uv_return.rotation = uv.rotation; + return uv_return; +} + +// Offsets a set of uv coordinates in either row (u) or column (v) direction +vm_coordinates vm_coord_rowcol_offset( + vm_coordinates uv, + float offset, + bool horizontal_offset = true +) +{ + // if (horizontal_offset) + // { + // uv.uv = float2( uv.uv.x + ::math::floor(uv.uv.y) * offset, uv.uv.y); + // } + // else + // { + // uv.uv = float2(uv.uv.x, uv.uv.y + ::math::floor(uv.uv.x) * offset); + // } + + // Workaround + int index = horizontal_offset ? 0 : 1; + uv.uv[index] += ::math::floor(uv.uv[index ^ 1]) * offset; + + return uv; +} + +vm_coordinates vm_coord_grid( + vm_coordinates uv, + float scale = 1.0f +) +{ + float2x2 scal = float2x2(scale, 0., 0., scale); + uv.uv = ::math::frac(uv.uv); + uv.uv -= 0.5f; + uv.uv = scal * uv.uv; + uv.uv = uv.uv + 0.5f; + return uv; +} + +::base::texture_return vm_tex_lookup( + uniform texture_2d tex, + vm_coordinates uv = vm_coord(), + uniform vm_mono_select mono_source = mono_a, + float4 scale = float4(1.0f), + + uniform ::tex::wrap_mode wrap_u = ::tex::wrap_repeat, + uniform ::tex::wrap_mode wrap_v = ::tex::wrap_repeat, + uniform float2 crop_u = float2(0.0, 1.0), + uniform float2 crop_v = float2(0.0, 1.0) +) +{ + float mono; + float4 lookup = ::tex::lookup_float4(tex, uv.uv, wrap_u, wrap_v, crop_u, crop_v) * scale; + switch( mono_source ) { + case mono_r: mono = lookup.x; + break; + case mono_g: mono = lookup.y; + break; + case mono_b: mono = lookup.z; + break; + case mono_a: mono = lookup.w; + break; + case mono_average: mono = ::math::average(float3(lookup.x, lookup.y, lookup.z)); + break; + } + return ::base::texture_return(color(lookup.x, lookup.y, lookup.z), mono); +} + +// *** SET CUTOUT ENUM NAMES *** +export enum cutout_pattern +[[ + ::anno::description("Cutout Pattern."), + ::anno::hidden() + +]] +{ + pattern_circle = 0 + [[ anno::display_name("Circle")]], + pattern_hexagon = 1 + [[ anno::display_name("Hexagon")]], + pattern_line = 2 + [[ anno::display_name("Line") ]], + + pattern_square = 3 + [[ anno::display_name("Square")]], + pattern_rectangle = 4 + [[ anno::display_name("Rectangle")]], + pattern_cross = 5 + [[ anno::display_name("Cross")]], + + pattern_rhombus = 6 + [[ anno::display_name("Rhombus")]], + pattern_triangle = 7 + [[ anno::display_name("Triangle")]], + pattern_star = 8 + [[ anno::display_name("Star")]] +}; + +::base::texture_coordinate_info vmat_transform_post_scale( + ::base::texture_coordinate_info uvw, + float2 scale = 1.0f +) +{ + return ::base::texture_coordinate_info( + position: float3(uvw.position.x / scale.x, + uvw.position.y / scale.y, + uvw.position.z), + tangent_u: uvw.tangent_u, + tangent_v: uvw.tangent_v + ); +} + +float3 normalmap_normal( + uniform texture_2d texture, + float factor = 1.0, + ::base::texture_coordinate_info uvw = ::base::texture_coordinate_info() +) +{ + float3 lookup = (::tex::lookup_float3(texture, float2(uvw.position.x, uvw.position.y)) - float3(0.5)) * (factor * 2.0); + return ::math::normalize(uvw.tangent_u * lookup.x + uvw.tangent_v * lookup.y + state::normal() * (lookup.z + (1.0 - factor))); +} + +float overlay(float base, float layer, float weight) +{ + return base + (1.0f - base) * layer * weight; +} + +// Returns the normal n in tangent space, given n is in internal space. +float3 transform_internal_to_tangent(float3 n) +[[ + anno::hidden() +]] +{ + return + n.x* float3(state::texture_tangent_u(0).x,state::texture_tangent_v(0).x,state::normal().x)+ + n.y* float3(state::texture_tangent_u(0).y,state::texture_tangent_v(0).y,state::normal().y)+ + n.z* float3(state::texture_tangent_u(0).z,state::texture_tangent_v(0).z,state::normal().z); +} + +// Returns the normal n in internal space, given n is in tangent space. +float3 transform_tangent_to_internal(float3 n) +[[ + anno::hidden() +]] +{ + return state::texture_tangent_u(0) * n.x + + state::texture_tangent_v(0) * n.y + + state::normal() * n.z ; +} + + + +// Returns a normal by adding a detail normal to a global normal. +// If detail blending of two normal maps gives visual artifacts, check if texture_2d are loaded +// correctly with tex::gamma_linear +float3 add_detail_normal(float3 nd = state::normal(), float3 n = state::normal()) +{ + // http://blog.selfshadow.com/publications/blending-in-detail/ + float3 n_t = transform_internal_to_tangent(n); + float3 nd_t = transform_internal_to_tangent(nd); + + n_t=n_t + float3(0.,0.,1.); + nd_t = nd_t * float3(-1.,-1.,1.); + n = n_t*math::dot(n_t, nd_t)/n_t.z - nd_t; + return ::math::normalize(transform_tangent_to_internal(n)); +} + + + +float3 srgb2rgb(float3 val) +{ + return ::math::pow(::math::max(val, float3(0.0f)), 2.2); +} + + +float uint2float(int x) +{ + return float(x & 0x7FFFFFFF) + (x < 0 ? 2147483648.0 : 0.0); +} + +int lowbias32(int x) +{ + x ^= x >>> 16; + x *= 0x7feb352d; + x ^= x >>> 15; + x *= 0x846ca68b; + x ^= x >>> 16; + return x; +} + +float2 rnd22(int2 p) { + float2 ret_val = float2( + uint2float(lowbias32(p[0] + lowbias32(p[1]))) / 4294967296.f, + uint2float(lowbias32(p[0] + 32000 + lowbias32(p[1]))) / 4294967296.f + ); + return ret_val; +} + +::base::texture_coordinate_info vmat_transform( + uniform float2 translation = float2(0.0, 0.0), + uniform float rotation = 0.0, + uniform float2 scaling = float2(1.0, 1.0), + uniform ::base::texture_coordinate_system system = ::base::texture_coordinate_uvw, + uniform int uv_space = 0 +) +{ + float4x4 scale = + float4x4(1.0 /scaling.x, 0. , 0. , 0., + 0. , 1.0 /scaling.y , 0. , 0., + 0. , 0. , 1.0, 0., + translation.x , translation.y , 0.0, 1.); + + float s = ::math::sin(rotation); + float c = ::math::cos(rotation); + float4x4 rotate = + float4x4( c , -s , 0.0 , 0.0, + s , c , 0.0 , 0.0, + 0.0, 0.0 , 1.0 , 0.0, + 0. , 0.0 , 0.0 , 1.); + + return ::base::transform_coordinate(scale*rotate, ::base::coordinate_source(system, uv_space)); +} + +float2x2 invert_2x2(float2x2 M) +{ + float det = M[0][0]*M[1][1] - M[0][1]*M[1][0]; + //https://www.chilimath.com/lessons/advanced-algebra/inverse-of-a-2x2-matrix/ + return (1.0 / det) * float2x2(M[1][1], -M[0][1], -M[1][0], M[0][0]); +} + +float3 nonrepeat_lookup( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5), + float patch_size = 8.0 +) +{ + + float2 uv_in = float2(uvw.position[0], uvw.position[1]) * texture_scale; + float Z = patch_size; // patch scale inside example texture + float CON = 1.0f; + + float3 O = float3(0.f); + float2x2 M0 = float2x2(1.f,0.f, 0.5f, ::math::sqrt(3.f)/2.f); + float2x2 M = invert_2x2(M0); // transform matrix <-> tilted space + + float2 U = uv_in; + float2 V = M * uv_in; //pre-tilted hexa coordinates + int2 I = int2(::math::floor(V)); // hexa-tile id + + // The mean color needs to be determined in Photoshop then to make the + // average color work out, take the float value and calculate the apropriate + // mean value as (value^(1/2.2)) + + float3 m = average_color; + + float3 F = float3(::math::frac(V)[0], ::math::frac(V)[1], 0.f), W; + F[2] = 1.0 - F[0] - F[1]; // local hexa coordinates + + if( F[2] > 0.f ) + + O = (W[0] = F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I))) - m*float(CON)) + + (W[1] = F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0,1)))) - m*float(CON)) + + (W[2] = F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1,0)))) - m*float(CON)); + else + O = (W[0] = -F[2]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1)))) - m*float(CON)) + + (W[1] = 1.f - F[1]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(1, 0)))) - m*float(CON)) + + (W[2] = 1.f - F[0]) * (( ::tex::lookup_float3(texture, U/Z-rnd22(I+int2(0, 1)))) - m*float(CON)); + O = m + O/::math::length(W); + O = ::math::clamp( (O), 0.0, 1.0); + + return float3(O); +} + + +float histogram_range(float input, float range, float position) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(::math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + + +color endless_texture( + uniform texture_2d texture = texture_2d(), + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 10.0, + float3 average_color = float3(0.5, 0.5, 1.0), + float patch_size = 8.0, + bool gamma_correct_lookup = true +) +{ + return gamma_correct_lookup ? color(srgb2rgb( + nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )) + ) : color(nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + )); +} + +float3 endless_normal( + uniform texture_2d texture = texture_2d(), + float factor = 1.0, + bool flip_tangent_u = false, + bool flip_tangent_v = false, + ::base::texture_coordinate_info uvw = ::base::coordinate_source(), + float texture_scale = 1.0, + float3 average_color = float3(0.5, 0.5, 1.0), + float patch_size = 8.0 +) +{ + float3 transformed_tangent_u = flip_tangent_u ? uvw.tangent_u : - uvw.tangent_u; + float3 transformed_tangent_v = flip_tangent_v ? uvw.tangent_v : - uvw.tangent_v; + + if (flip_tangent_u) + transformed_tangent_u=-transformed_tangent_u; + if (flip_tangent_v) + transformed_tangent_v=-transformed_tangent_v; + + // normalized Lookup + float3 tangent_space_normal = + (nonrepeat_lookup ( + texture: texture, + uvw: uvw, + texture_scale: texture_scale, + average_color: average_color, + patch_size: patch_size + ) - 0.5) * (2.0 * factor); + + return ::math::normalize(uvw.tangent_u * tangent_space_normal.x + + uvw.tangent_v * tangent_space_normal.y + + ::state::normal()*1.0); +} + +export material Stainless_Steel_Brushed_Punched( + uniform bool infinite_tiling = false [[ + ::anno::description("Enables infinite tiling feature which removes repeating texture patterns. Note that depending on the material this feature changes the appearance of the material slightly."), + ::anno::display_name("Infinite Tiling"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.18f [[ + ::anno::description("Softens the reflections in the direction of the brushing."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float steel_anisotropy = 0.53f [[ + ::anno::description("Higher values lengthen the reflections perpendicular to the brushing direction."), + ::anno::display_name("Roughness Anisotropy"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float cloudiness = 0.5f [[ + ::anno::description("Adds a cloudy reflection to the metal material which results in a more grayish appearance."), + ::anno::display_name("Cloudiness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(3) + ]], + float brightness = .5f [[ + ::anno::description("Low values make the metal darker and add slight variation to the brightness while a high value gives it a bright uniform look."), + ::anno::display_name("Brightness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(4) + ]], + float brush_brightness_variation = 0.91f [[ + ::anno::description("Enhances the brushing effect by adding variations to the brightness. This makes the overall appearance darker."), + ::anno::display_name("Brushing Brightness Variation"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(5) + ]], + float brushing_bump_strength = 0.f [[ + ::anno::description("Adds a milled grooves on the metal."), + ::anno::display_name("Brushing Bump Strength"), + ::anno::in_group("Appearance", "Bump"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(6) + ]], + float dents_bump_strength = 0.f [[ + ::anno::description("Adds dents and bumps."), + ::anno::display_name("Dents Bump Strength"), + ::anno::in_group("Appearance", "Bump"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float dents_scale = 1.2f [[ + ::anno::description("Scales the size of the dents that are scattered across the surface."), + ::anno::display_name("Dents Scale"), + ::anno::in_group("Appearance", "Bump"), + ::anno::ui_order(8) + ]], + float smudges_1_weight = 0.f [[ + ::anno::description("Adjusts the weight of the primary smudges."), + ::anno::display_name("Smudges Weight"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(9) + ]], + float smudges_2_weight = 0.f [[ + ::anno::description("Adjusts the weight of the secondary smudges."), + ::anno::display_name("Stains Weight"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(10) + ]], + float smudges_falloff = 0.1f [[ + ::anno::description("Controls the falloff of the smudges on the surface. Low values make the smudges wide and soft while high values make them small."), + ::anno::display_name("Smudges Falloff"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(11) + ]], + float smudges_scale = 2.f [[ + ::anno::description("Scales the smudges relative to the overal scale of the material."), + ::anno::display_name("Smudges and Stains Scale"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(12) + ]], + float brightness_variation = 0.0f [[ + ::anno::description("A value of 0 makes the material reflect light in a uniform manner while higher values introduce variations to the brightness."), + ::anno::display_name("Brightness Variation"), + ::anno::in_group("Appearance", "Advanced"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(13) + ]], + float brush_gloss_variation = 0.0f [[ + ::anno::description("Adds more variation to the roughness of the brushing with a more uneven and noisy appearance."), + ::anno::display_name("Brushing Gloss Variation"), + ::anno::in_group("Appearance", "Advanced"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(14) + ]], + uniform float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(15) + ]], + uniform float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(16) + ]], + uniform float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(17) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(18) + ]], + uniform float roundcorners_radius_mm = 0.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(19) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(20) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Advanced"), + ::anno::hard_range(0, 10), + ::anno::ui_order(21) + ]]) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Template"), + ::anno::description(DESCRIPTION), + ::anno::hidden(), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "gray")) +]] + = + let { + bool tmp0 = false; + float2 texture_rescale = texture_scale * 0.33; + + material_surface tmp1(::df::custom_curve_layer(0.799999952f, 1.f, 3.0999999f, 1.f, ::df::weighted_layer(overlay(cloudiness * 0.330000013f, overlay(smudges_1_weight * ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).x, ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).y, smudges_2_weight), 1.f), ::df::microfacet_ggx_smith_bsdf(histogram_range(overlay(cloudiness * 0.330000013f, overlay(smudges_1_weight * ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).x, ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).y, smudges_2_weight), 1.f), 0.199999988f, 0.300000012f - cloudiness * 0.100000001f), histogram_range(overlay(cloudiness * 0.330000013f, overlay(smudges_1_weight * ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).x, ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).y, smudges_2_weight), 1.f), 0.199999988f, 0.300000012f - cloudiness * 0.100000001f), color(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 1.f, ::math::lerp(1.f, 0.670000017f, brush_brightness_variation)) * (histogram_range(::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).z, 1.f, 1.f - brightness_variation * 0.300000012f) * (brightness * 0.300000012f + 0.600000024f))), color(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 1.f, ::math::lerp(1.f, 0.670000017f, brush_brightness_variation)) * (histogram_range(::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).z, 1.f, 1.f - brightness_variation * 0.300000012f) * (brightness * 0.300000012f + 0.600000024f))), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(0.799999952f, ::df::microfacet_ggx_smith_bsdf(overlay(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 0.560000002f, ::math::lerp(0.0299999993f, 0.25f, roughness)), float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).x, brush_gloss_variation) * overlay(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 0.560000002f, ::math::lerp(0.0299999993f, 0.25f, roughness)), float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).x, brush_gloss_variation), overlay(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 0.189999998f, ::math::lerp(0.099999994f, 0.5f, steel_anisotropy) + ::math::lerp(0.0299999993f, 0.25f, roughness)), float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).x, brush_gloss_variation) * overlay(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 0.189999998f, ::math::lerp(0.099999994f, 0.5f, steel_anisotropy) + ::math::lerp(0.0299999993f, 0.25f, roughness)), float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).x, brush_gloss_variation), color(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 1.f, ::math::lerp(1.f, 0.670000017f, brush_brightness_variation)) * (histogram_range(::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).z, 1.f, 1.f - brightness_variation * 0.300000012f) * (brightness * 0.300000012f + 0.600000024f))), color(0.f, 0.f, 0.f), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index).tangent_u, ::df::scatter_reflect), bsdf(), add_detail_normal(infinite_tiling ? endless_normal(texture_2d("./stainless_damages_norm.jpg", ::tex::gamma_linear), dents_bump_strength, false, false, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(dents_scale)), 9.13999939f, float3(0.5f, 0.5f, 0.999000013f), 8.38000011f) : normalmap_normal(texture_2d("./stainless_damages_norm.jpg", ::tex::gamma_linear), dents_bump_strength, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(dents_scale))), infinite_tiling ? endless_normal(texture_2d("./stainless_brushed_norm.jpg", ::tex::gamma_linear), brushing_bump_strength * 0.400000006f, false, false, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.5f, 0.5f, 0.999000013f), 8.38000011f) : normalmap_normal(texture_2d("./stainless_brushed_norm.jpg", ::tex::gamma_linear), brushing_bump_strength * 0.400000006f, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index)))), add_detail_normal(infinite_tiling ? endless_normal(texture_2d("./stainless_damages_norm.jpg", ::tex::gamma_linear), dents_bump_strength, false, false, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(dents_scale)), 9.13999939f, float3(0.5f, 0.5f, 0.999000013f), 8.38000011f) : normalmap_normal(texture_2d("./stainless_damages_norm.jpg", ::tex::gamma_linear), dents_bump_strength, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(dents_scale))), infinite_tiling ? endless_normal(texture_2d("./stainless_brushed_norm.jpg", ::tex::gamma_linear), brushing_bump_strength * 0.400000006f, false, false, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.5f, 0.5f, 0.999000013f), 8.38000011f) : normalmap_normal(texture_2d("./stainless_brushed_norm.jpg", ::tex::gamma_linear), brushing_bump_strength * 0.400000006f, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index)))), ::df::tint(color(0.f, 0.f, 0.f), ::df::weighted_layer(overlay(cloudiness * 0.330000013f, overlay(smudges_1_weight * ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).x, ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).y, smudges_2_weight), 1.f), ::df::microfacet_ggx_smith_bsdf(histogram_range(overlay(cloudiness * 0.330000013f, overlay(smudges_1_weight * ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).x, ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).y, smudges_2_weight), 1.f), 0.199999988f, 0.300000012f - cloudiness * 0.100000001f), histogram_range(overlay(cloudiness * 0.330000013f, overlay(smudges_1_weight * ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).x, ::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).y, smudges_2_weight), 1.f), 0.199999988f, 0.300000012f - cloudiness * 0.100000001f), color(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 1.f, ::math::lerp(1.f, 0.670000017f, brush_brightness_variation)) * (histogram_range(::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).z, 1.f, 1.f - brightness_variation * 0.300000012f) * (brightness * 0.300000012f + 0.600000024f))), color(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 1.f, ::math::lerp(1.f, 0.670000017f, brush_brightness_variation)) * (histogram_range(::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).z, 1.f, 1.f - brightness_variation * 0.300000012f) * (brightness * 0.300000012f + 0.600000024f))), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(0.799999952f, ::df::microfacet_ggx_smith_bsdf(overlay(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 0.560000002f, ::math::lerp(0.0299999993f, 0.25f, roughness)), float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).x, brush_gloss_variation) * overlay(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 0.560000002f, ::math::lerp(0.0299999993f, 0.25f, roughness)), float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).x, brush_gloss_variation), overlay(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 0.189999998f, ::math::lerp(0.099999994f, 0.5f, steel_anisotropy) + ::math::lerp(0.0299999993f, 0.25f, roughness)), float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).x, brush_gloss_variation) * overlay(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 0.189999998f, ::math::lerp(0.099999994f, 0.5f, steel_anisotropy) + ::math::lerp(0.0299999993f, 0.25f, roughness)), float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).x, brush_gloss_variation), color(histogram_range(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.159999996f, 0.569000006f, 0.0460000001f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_multi_R_impurities_G_rough_B_dents.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint).y, 1.f, ::math::lerp(1.f, 0.670000017f, brush_brightness_variation)) * (histogram_range(::math::pow(float3(infinite_tiling ? endless_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), 9.13999939f, float3(0.0599999987f, 0.0500000007f, 0.463f), 8.38000011f, false) : ::base::file_texture(texture_2d("./stainless_brushed_smudges.jpg", ::tex::gamma_linear), color(0.f, 0.f, 0.f), color(1.f, 1.f, 1.f), ::base::mono_alpha, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(smudges_scale)), float2(0.f, 1.f), float2(0.f, 1.f), ::tex::wrap_repeat, ::tex::wrap_repeat, false, 0.f, int2(0), ::tex::wrap_repeat, 30.f).tint), smudges_falloff + 1.f).z, 1.f, 1.f - brightness_variation * 0.300000012f) * (brightness * 0.300000012f + 0.600000024f))), color(0.f, 0.f, 0.f), vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index).tangent_u, ::df::scatter_reflect), bsdf(), add_detail_normal(infinite_tiling ? endless_normal(texture_2d("./stainless_damages_norm.jpg", ::tex::gamma_linear), dents_bump_strength, false, false, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(dents_scale)), 9.13999939f, float3(0.5f, 0.5f, 0.999000013f), 8.38000011f) : normalmap_normal(texture_2d("./stainless_damages_norm.jpg", ::tex::gamma_linear), dents_bump_strength, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(dents_scale))), infinite_tiling ? endless_normal(texture_2d("./stainless_brushed_norm.jpg", ::tex::gamma_linear), brushing_bump_strength * 0.400000006f, false, false, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.5f, 0.5f, 0.999000013f), 8.38000011f) : normalmap_normal(texture_2d("./stainless_brushed_norm.jpg", ::tex::gamma_linear), brushing_bump_strength * 0.400000006f, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index)))), add_detail_normal(infinite_tiling ? endless_normal(texture_2d("./stainless_damages_norm.jpg", ::tex::gamma_linear), dents_bump_strength, false, false, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(dents_scale)), 9.13999939f, float3(0.5f, 0.5f, 0.999000013f), 8.38000011f) : normalmap_normal(texture_2d("./stainless_damages_norm.jpg", ::tex::gamma_linear), dents_bump_strength, vmat_transform_post_scale(vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), float2(dents_scale))), infinite_tiling ? endless_normal(texture_2d("./stainless_brushed_norm.jpg", ::tex::gamma_linear), brushing_bump_strength * 0.400000006f, false, false, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index), 9.13999939f, float3(0.5f, 0.5f, 0.999000013f), 8.38000011f) : normalmap_normal(texture_2d("./stainless_brushed_norm.jpg", ::tex::gamma_linear), brushing_bump_strength * 0.400000006f, vmat_transform(texture_translate, texture_rotate, texture_rescale * 0.200000003f, ::base::texture_coordinate_uvw, uv_space_index))))), ::state::normal()), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(1.f, 1.f, 1.f); + material_volume tmp4 = material_volume(scattering: vdf(), absorption_coefficient: color(0.f, 0.f, 0.f), scattering_coefficient: color(0.f, 0.f, 0.f)); + material_geometry tmp5(float3(0.f), 1.f, roundcorners_enable ? ::state::rounded_corner_normal(roundcorners_radius_mm * 0.00100000005f, roundcorners_across_materials, 1.f) : ::state::normal()); + hair_bsdf tmp6 = hair_bsdf(); + } in + material( + thin_walled: tmp0, + surface: tmp1, + backface: tmp2, + ior: tmp3, + volume: tmp4, + geometry: tmp5, + hair: tmp6); + + + + +export material Stainless_Steel_Brushed_Punched_( + // Cutout parameters + + uniform cutout_pattern shape_select = pattern_circle //select atlas tile here + [[ + ::anno::description("Select a cutout shape."), + ::anno::display_name("Cutout Shape"), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(0) + ]], + float2 punching_grid_size = float2(.5f, .5f) + [[ + ::anno::description("Scales the size of the punching grid."), + ::anno::display_name("Punching Grid Size"), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(1) + ]], + float cutout_size = .92f + [[ + ::anno::description("Scales the size of the cutout pattern independently from the base material."), + ::anno::display_name("Cutout Size"), + ::anno::hard_range(0.f, 1.2f), + ::anno::soft_range(0.f, 1.0f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(2) + ]], + float cutout_roundness = .4f + [[ + ::anno::description("At low values it makes the cutouts sharper. Higher values give the shapes a more rounded look."), + ::anno::display_name("Cutout Roundness"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(3) + ]], + float cutout_bevel_width = 0.5f + [[ + ::anno::description("Adjusts the width of the bevel transition."), + ::anno::display_name("Cutout Bevel Width"), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(4) + ]], + float cutout_bump_strength = .8f + [[ + ::anno::description("Sets the strength of the bevelled normal around the cutout."), + ::anno::display_name("Cutout Bevel Strength"), + ::anno::soft_range(0.0f, 1.0f), + ::anno::hard_range(0.0f, 2.0f), + ::anno::in_group("Appearance", "Cutout"), + ::anno::ui_order(5) + ]], +// Grid Layout parameters + bool hexagonal_grid = true + [[ + ::anno::description("When enabled, the punching will occur on a hexagonal grid, otherwise a square grid."), + ::anno::display_name("Enable Hexagonal Grid"), + ::anno::in_group("Appearance", "Cutout Layout"), + ::anno::ui_order(6) + ]], + float square_grid_offset = 0.0f + [[ + ::anno::description("Offsets each row of the grid by a certain amount."), + ::anno::display_name("Square Grid Offset"), + ::anno::in_group("Appearance", "Cutout Layout"), + ::anno::enable_if("hexagonal_grid==false"), + ::anno::ui_order(7) + ]], + bool horizontal_offset = true + [[ + ::anno::description("Choose whether to offset either in row or column direction."), + ::anno::display_name("Horizontal Offset"), + ::anno::in_group("Appearance", "Cutout Layout"), + ::anno::enable_if("hexagonal_grid==false"), + ::anno::ui_order(8) + ]], + + + +// Stainless Steel parameters + uniform bool infinite_tiling = false [[ + ::anno::description("Enables infinite tiling feature which removes repeating texture patterns. Note that depending on the material this feature changes the appearance of the material slightly."), + ::anno::display_name("Infinite Tiling"), + ::anno::in_group("Appearance"), + ::anno::ui_order(9) + ]], + float roughness = 0.18f [[ + ::anno::description("Softens the reflections in the direction of the brushing."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(10) + ]], + float steel_anisotropy = 0.53f [[ + ::anno::description("Higher values lengthen the reflections perpendicular to the brushing direction."), + ::anno::display_name("Roughness Anisotropy"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(11) + ]], + float cloudiness = 0.5f [[ + ::anno::description("Adds a cloudy reflection to the metal material which results in a more grayish appearance."), + ::anno::display_name("Cloudiness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(12) + ]], + float brightness = .5f [[ + ::anno::description("Low values make the metal darker and add slight variation to the brightness while a high value gives it a bright uniform look."), + ::anno::display_name("Brightness"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(13) + ]], + float brush_brightness_variation = 0.91f [[ + ::anno::description("Enhances the brushing effect by adding variations to the brightness. This makes the overall appearance darker."), + ::anno::display_name("Brushing Brightness Variation"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(14) + ]], + float brushing_bump_strength = 0.f [[ + ::anno::description("Adds a milled grooves on the metal."), + ::anno::display_name("Brushing Bump Strength"), + ::anno::in_group("Appearance", "Bump"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(15) + ]], + float dents_bump_strength = 0.f [[ + ::anno::description("Adds dents and bumps."), + ::anno::display_name("Dents Bump Strength"), + ::anno::in_group("Appearance", "Bump"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(16) + ]], + float dents_scale = 1.2f [[ + ::anno::description("Scales the size of the dents that are scattered across the surface."), + ::anno::display_name("Dents Scale"), + ::anno::in_group("Appearance", "Bump"), + ::anno::ui_order(17) + ]], + float smudges_1_weight = 0.f [[ + ::anno::description("Adjusts the weight of the primary smudges."), + ::anno::display_name("Smudges Weight"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(18) + ]], + float smudges_2_weight = 0.f [[ + ::anno::description("Adjusts the weight of the secondary smudges."), + ::anno::display_name("Stains Weight"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(19) + ]], + float smudges_falloff = 0.1f [[ + ::anno::description("Controls the falloff of the smudges on the surface. Low values make the smudges wide and soft while high values make them small."), + ::anno::display_name("Smudges Falloff"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(20) + ]], + float smudges_scale = 2.f [[ + ::anno::description("Scales the smudges relative to the overal scale of the material."), + ::anno::display_name("Smudges and Stains Scale"), + ::anno::in_group("Appearance", "Imperfections"), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(21) + ]], + float brightness_variation = 0.0f [[ + ::anno::description("A value of 0 makes the material reflect light in a uniform manner while higher values introduce variations to the brightness."), + ::anno::display_name("Brightness Variation"), + ::anno::in_group("Appearance", "Advanced"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(22) + ]], + float brush_gloss_variation = 0.0f [[ + ::anno::description("Adds more variation to the roughness of the brushing with a more uneven and noisy appearance."), + ::anno::display_name("Brushing Gloss Variation"), + ::anno::in_group("Appearance", "Advanced"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(23) + ]], + uniform float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(24) + ]], + uniform float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(25) + ]], + uniform float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(26) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::hard_range(0, 10), + ::anno::ui_order(27) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(28) + ]], + uniform float roundcorners_radius_mm = 0.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(29) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(30) + ]] + +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Circular Punched"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "gray")) +]] = let +{ + material base_mat = Stainless_Steel_Brushed_Punched( + infinite_tiling: infinite_tiling, + roughness: roughness, + steel_anisotropy: steel_anisotropy, + cloudiness: cloudiness, + brightness: brightness, + brush_brightness_variation: brush_brightness_variation, + brushing_bump_strength: brushing_bump_strength, + dents_bump_strength: dents_bump_strength, + dents_scale: dents_scale, + smudges_1_weight: smudges_1_weight, + smudges_2_weight: smudges_2_weight, + smudges_falloff: smudges_falloff, + smudges_scale: smudges_scale, + brightness_variation: brightness_variation, + brush_gloss_variation: brush_gloss_variation, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + uv_space_index: uv_space_index + ); + texture_2d punching_cutout = texture_2d("./atlas_02_norm_dist.png", ::tex::gamma_linear); + + // remap range of slider to avoid artifacts in the bevelling + float2 punching_scale = texture_scale * 0.01f * punching_grid_size; + float cutout_roundness_ = cutout_roundness*0.6f+0.4f; + float cutout_size_lin = (1.0f/cutout_size); + float cutout_bevel_width_ = 0.1 + cutout_bevel_width * 0.9f; + + vm_coordinates uv = vm_coord( + translation: texture_translate, + rotation: texture_rotate, + scaling: punching_scale, + uv_space: uv_space_index + ); + + vm_coordinates punching_uv = hexagonal_grid ? vm_coord_hex( + uv: uv, + scale: cutout_roundness_ * cutout_size_lin + ) : vm_coord_grid( + uv: vm_coord_rowcol_offset( + uv: uv, + offset: square_grid_offset, + horizontal_offset: horizontal_offset + ), + scale: cutout_roundness_ * cutout_size_lin + ); + // select the correct subtile from the atlas + float4 crop = tile_select(shape_select); + + ::base::texture_return lookup = vm_tex_lookup( + tex: punching_cutout, + uv: punching_uv, + mono_source: mono_a, + scale: float4(1.0f), + crop_u: float2(crop.x, crop.y), + crop_v: float2(crop.z, crop.w), + wrap_u: ::tex::wrap_clamp, + wrap_v: ::tex::wrap_clamp + ); + + float low = (1.0 - cutout_roundness_); + float high = (cutout_size_lin * (cutout_bevel_width_ * 0.2f) * cutout_roundness_) + (1.0 - cutout_roundness_); + // remap x...y to (clamped) 0...1 + float x = ::math::clamp((lookup.mono - low)/(high - low), 0.0, 1.0); + // spherical falloff + float falloff=::math::sqrt(1.0-x*x); + // masking falloff as the center of the cutout is flat + float masked_falloff=falloff<=0.0?1.0:falloff; + + // where base material is still there, use the value of the base material + float cutout= ::math::min(falloff<=0.0?0.0:1.0, base_mat.geometry.cutout_opacity); + + // bring in -.5 ... +.5 range and lerp between lookup and flat normal + float3 remap_norm = ::math::lerp(float3(lookup.tint), float3(0.5, 0.5, 1.0), masked_falloff) - float3(0.5); + float3 t_norm = ::math::normalize(remap_norm * float3(cutout_bump_strength, cutout_bump_strength, 1.0)); + + float3 rotfix_norm = float3(::math::cos(punching_uv.rotation) * t_norm.x - ::math::sin(punching_uv.rotation) * t_norm.y, + ::math::sin(punching_uv.rotation) * t_norm.x + ::math::cos(punching_uv.rotation) * t_norm.y, + t_norm.z); + + float3 normal = ::state::texture_tangent_u(punching_uv.uv_space_index) * rotfix_norm.x + + ::state::texture_tangent_v(punching_uv.uv_space_index) * rotfix_norm.y + + ::state::normal() * rotfix_norm.z; + + float3 final_normal = ::base::blend_normals( + base_normal: normal, + base_normal_weight: 1.0f, + detail_normal: base_mat.geometry.normal, + detail_normal_weight: 1.0f + ); + +} in material( + surface: material_surface( + scattering: base_mat.surface.scattering + ), + volume: base_mat.volume, + ior: base_mat.ior, + thin_walled: true, + geometry: material_geometry( + displacement: base_mat.geometry.displacement, + normal: final_normal, + cutout_opacity: cutout + ) +); + + +export material Stainless_Steel_Brushed_Punched_Small_Circular(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Small Circular Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Small_Circular.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "circular", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_circle, + punching_grid_size: float2(.6f), + cutout_size: 0.5f, + cutout_roundness: 0.4f, + cutout_bevel_width: 0.5f, + cutout_bump_strength: 0.8f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); + +export material Stainless_Steel_Brushed_Punched_Hexagonal(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Hexagonal Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Hexagonal.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "hexagon", "hexagonal", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_hexagon, + punching_grid_size: 1.5f, + cutout_size: .95f, + cutout_roundness: 0.4f, + cutout_bevel_width: 0.5f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); + + +export material Stainless_Steel_Brushed_Punched_Hexagonal_Small(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Small Hexagonal Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Hexagonal_Small.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "hexagon", "hexagonal", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_hexagon, + punching_grid_size: float2(.75f), + cutout_size: .58f, + cutout_roundness: 0.4f, + cutout_bevel_width: 0.3f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); + +// Square punch +export material Stainless_Steel_Brushed_Punched_Square(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Square Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Square.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "square", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_square, + punching_grid_size: 1.2f, + cutout_size: 0.56f, + cutout_roundness: 0.1f, + cutout_bevel_width: 0.5f, + cutout_bump_strength: 1.5f, + hexagonal_grid: false, + square_grid_offset: 0.5f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); + +// Line punch +export material Stainless_Steel_Brushed_Punched_Line(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Line Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Line.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "line", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_line, + punching_grid_size: float2(.8f), + cutout_size: 0.59f, + cutout_roundness: 0.4f, + cutout_bevel_width: 0.3f, + cutout_bump_strength: 1.5f, + hexagonal_grid: false, + square_grid_offset: 0.3333f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); + + +// Cross punch +export material Stainless_Steel_Brushed_Punched_Cross(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Cross Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Cross.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "cross", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_cross, + punching_grid_size: float2(.8f), + cutout_size: 0.59f, + cutout_roundness: 0.1f, + cutout_bevel_width: 0.44f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); + +// Rhombus punch +export material Stainless_Steel_Brushed_Punched_Rhombus(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Rhombus Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Rhombus.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "rhombus", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_rhombus, + punching_grid_size: float2(.8f), + cutout_size: 1.0f, + cutout_roundness: 0.8f, + cutout_bevel_width: 0.5f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); + + +// Triangle punch +export material Stainless_Steel_Brushed_Punched_Triangle(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Triangle Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Triangle.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "triangle", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_triangle, + punching_grid_size: float2(.8f), + cutout_size: 1.08f, + cutout_roundness: 1.0f, + cutout_bevel_width: 1.0f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); + +// Star punch +export material Stainless_Steel_Brushed_Punched_Star(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Star Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Star.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "star", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_star, + punching_grid_size: float2(.8f), + cutout_size: 0.68f, + cutout_roundness: 0.5f, + cutout_bevel_width: 0.44f, + cutout_bump_strength: 1.5f, + hexagonal_grid: true, + square_grid_offset: 0.0f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); + +// Additional fancier Presets + +// Cross punch +export material Stainless_Steel_Brushed_Punched_Cross_Special(*) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::contributor("Maik Rohland"), + ::anno::display_name("Stainless Steel Brushed - Special Cross Punch"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Stainless_Steel_Brushed_Punched.Stainless_Steel_Brushed_Punched_Cross_Special.png"), + ::anno::key_words(string[]("metal", "steel", "anisotropic", "stainless", "brushed", "design", "kitchen", "sanitary", "construction", "automotive", "architecture", "interior", "exterior", "new", "shiny", "smooth", "reflective", "plain", "punched", "punching", "cross", "gray")) +]] = Stainless_Steel_Brushed_Punched_ ( + shape_select: pattern_cross, + punching_grid_size: float2(.8f), + cutout_size: 0.67f, + cutout_roundness: 0.1f, + cutout_bevel_width: 0.4f, + cutout_bump_strength: 1.5f, + hexagonal_grid: false, + square_grid_offset: 0.0f, + horizontal_offset: true, + + infinite_tiling: true, + roughness: 0.18f, + steel_anisotropy: 0.53f, + cloudiness: 0.5f, + brightness: 0.5f, + brush_brightness_variation: 0.91f, + brushing_bump_strength: 0.0f, + dents_bump_strength: 0.0f, + dents_scale: 1.2f, + smudges_1_weight: 0.0f, //Smudges Weight + smudges_2_weight: 0.0f, //Stains Weight + smudges_falloff: 0.1f, + smudges_scale: 2.0f, + brightness_variation: 0.0f, + brush_gloss_variation: 0.0f, + texture_translate: 0.0f, + texture_rotate: 0.0f, + texture_scale: 1.0f, + uv_space_index: 0, + roundcorners_enable: false, + roundcorners_radius_mm: 0.5f, + roundcorners_across_materials: false +); \ No newline at end of file diff --git a/Assets/Material/material_0477/carbon_steel_ao.jpg b/Assets/Material/material_0477/carbon_steel_ao.jpg new file mode 100644 index 0000000000000000000000000000000000000000..84fe18a517355ad8f9c622be424e38b168fc3217 --- /dev/null +++ b/Assets/Material/material_0477/carbon_steel_ao.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:424730ed2269a77071342c2f36b5df7145d9245728565766582552c9f2935bbe +size 3192900 diff --git a/Assets/Material/material_0477/carbon_steel_multi.jpg b/Assets/Material/material_0477/carbon_steel_multi.jpg new file mode 100644 index 0000000000000000000000000000000000000000..6dd24239b27482d97eb3292812fb150b5e179dd9 --- /dev/null +++ b/Assets/Material/material_0477/carbon_steel_multi.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:73ea2fec4f10ccc4add48cab993cb5c57b197d82d210556429944ef9319092b4 +size 3527961 diff --git a/Assets/Material/material_0477/carbon_steel_norm.jpg b/Assets/Material/material_0477/carbon_steel_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..aea9aa9dc3c6599ffc0d8d99c21527a601fc8f9f --- /dev/null +++ b/Assets/Material/material_0477/carbon_steel_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a4678770024f5092e440d144f7d8f8719e1c76cde1be49829bd2efb3260c2cc +size 3387620 diff --git a/Assets/Material/material_0478/metal_galvan_multi_R_base_G_dirtmask_B_dirt.jpg b/Assets/Material/material_0478/metal_galvan_multi_R_base_G_dirtmask_B_dirt.jpg new file mode 100644 index 0000000000000000000000000000000000000000..a87c2b2baa6d18689d110d809fdc0ef3a6693dc2 --- /dev/null +++ b/Assets/Material/material_0478/metal_galvan_multi_R_base_G_dirtmask_B_dirt.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3c42f6fa4bc53551a3f9570f1ba41917879e7649fd67bd1bd7b694367ccad678 +size 2899859 diff --git a/Assets/Material/material_0478/metal_galvan_multi_R_dirt_G_urough_B_vrough.jpg b/Assets/Material/material_0478/metal_galvan_multi_R_dirt_G_urough_B_vrough.jpg new file mode 100644 index 0000000000000000000000000000000000000000..5897960a5f38417be020c0f77147879186f58678 --- /dev/null +++ b/Assets/Material/material_0478/metal_galvan_multi_R_dirt_G_urough_B_vrough.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:42f4f165fc4a624362fc389536f9ee21c5394e7886fa8232349a863ee614317e +size 3547124 diff --git a/Assets/Material/material_0478/metal_galvan_normal.jpg b/Assets/Material/material_0478/metal_galvan_normal.jpg new file mode 100644 index 0000000000000000000000000000000000000000..597d21223b1619b7f81547f704998a34adcbbaca --- /dev/null +++ b/Assets/Material/material_0478/metal_galvan_normal.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:10226261c24ea1f695828e7183e0ab13d1b12798b955de4347ffd93025100dac +size 2516459 diff --git a/Assets/Material/material_0494/atlas_02_norm_dist.png b/Assets/Material/material_0494/atlas_02_norm_dist.png new file mode 100644 index 0000000000000000000000000000000000000000..a368ebd9ef175a3e7566594df7f06c1af5f5e27e --- /dev/null +++ b/Assets/Material/material_0494/atlas_02_norm_dist.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:545d952caf139061c8f7c9474fbadd59cc2dedc5616386bbcb2ac71c88add6f0 +size 1576300 diff --git a/Assets/Material/material_0494/sheet_metal_R_rough_G_ao_B_streaks.jpg b/Assets/Material/material_0494/sheet_metal_R_rough_G_ao_B_streaks.jpg new file mode 100644 index 0000000000000000000000000000000000000000..8a919e141894a2242175b13c37dee2571da51ce0 --- /dev/null +++ b/Assets/Material/material_0494/sheet_metal_R_rough_G_ao_B_streaks.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9bcc1276b9bf79abb650315d368f57d20a4f7929ca207b4c3fa5fed8b9eb6306 +size 4451500 diff --git a/Assets/Material/material_0494/sheet_metal_multi_rough.jpg b/Assets/Material/material_0494/sheet_metal_multi_rough.jpg new file mode 100644 index 0000000000000000000000000000000000000000..029d7ad1d517779b532e07cc1c31366c01f36854 --- /dev/null +++ b/Assets/Material/material_0494/sheet_metal_multi_rough.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0e2309dba2da6ba419f804936bf213270cb62b98a589b9c38bd99ce6bcad861f +size 7088427 diff --git a/Assets/Material/material_0494/sheet_metal_norm.jpg b/Assets/Material/material_0494/sheet_metal_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..b954935687b2c9052528646b6e2e2f5136d85a70 --- /dev/null +++ b/Assets/Material/material_0494/sheet_metal_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3145f26a544857dd0163129591cb37d6c7d7934dc59aaa3611030f9f44ecd613 +size 3633863 diff --git a/Assets/Material/material_0500/metal_knurling_multi_R_diff_G_rough_B_grunge.jpg b/Assets/Material/material_0500/metal_knurling_multi_R_diff_G_rough_B_grunge.jpg new file mode 100644 index 0000000000000000000000000000000000000000..f773c9cafdd2fa71939326f23ba94520cda6be24 --- /dev/null +++ b/Assets/Material/material_0500/metal_knurling_multi_R_diff_G_rough_B_grunge.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:827f0cf47b4356493fba016b6e9ddbcc6bfab0224b99a4e6a9c6ab69e24189a9 +size 5944332 diff --git a/Assets/Material/material_0500/metal_knurling_multi_heights.jpg b/Assets/Material/material_0500/metal_knurling_multi_heights.jpg new file mode 100644 index 0000000000000000000000000000000000000000..3090c2e09a72cf7551ca2608f3c7be2a475b07c8 --- /dev/null +++ b/Assets/Material/material_0500/metal_knurling_multi_heights.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b4d7b7feb8921eed2081b4eb60a08bbce49aab76ac17f74cc564eeb7c7a4c11 +size 2076774 diff --git a/Assets/Material/material_0500/metal_knurling_norm.jpg b/Assets/Material/material_0500/metal_knurling_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9036d8679b5c63892eb665576e748b66afef3088 --- /dev/null +++ b/Assets/Material/material_0500/metal_knurling_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dc9e78477fee20785975eb0b93ae5e861e135591998a89d624ce80fd779128f2 +size 1900541 diff --git a/Assets/Material/material_0501/metal_scratched_R_diff_G_scratchvar_B_dirt.jpg b/Assets/Material/material_0501/metal_scratched_R_diff_G_scratchvar_B_dirt.jpg new file mode 100644 index 0000000000000000000000000000000000000000..1e5130fa5a243fd255a37ff6099a38a6a6e41d52 --- /dev/null +++ b/Assets/Material/material_0501/metal_scratched_R_diff_G_scratchvar_B_dirt.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:51a6eb57877fc78f9da063bc7eedfb417ccde0726015712d400dbe84ea03fa46 +size 3114776 diff --git a/Assets/Material/material_0501/metal_scratched_R_scratch1_G_scratch2_B_scratch3.jpg b/Assets/Material/material_0501/metal_scratched_R_scratch1_G_scratch2_B_scratch3.jpg new file mode 100644 index 0000000000000000000000000000000000000000..30f1a268fffa7e0b70da8c2e3a04396b75b75e0e --- /dev/null +++ b/Assets/Material/material_0501/metal_scratched_R_scratch1_G_scratch2_B_scratch3.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:22a432baddf95f05140af2f8fb47d763439f06e84648e89eddc9d9b726d59867 +size 6891717 diff --git a/Assets/Material/material_0501/metal_scratched_scratch_norm.jpg b/Assets/Material/material_0501/metal_scratched_scratch_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..b5b09ebf9955e03dfc4ab47f095f7380cd485197 --- /dev/null +++ b/Assets/Material/material_0501/metal_scratched_scratch_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fef50be8c23dabfbd7a799a3434ba6c39122d058140dd9c11cb0c3da1da5b537 +size 3254868 diff --git a/Assets/Material/material_0520/plaster_rough_diff.jpg b/Assets/Material/material_0520/plaster_rough_diff.jpg new file mode 100644 index 0000000000000000000000000000000000000000..e688fd96c60bdb16a0df83ed19242cc7f249c66d --- /dev/null +++ b/Assets/Material/material_0520/plaster_rough_diff.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:958d2cd2bc4fad0e8c353394177cc34c75eb52370696e2b8618880ea067aa843 +size 1955185 diff --git a/Assets/Material/material_0520/plaster_rough_multi_R_rough_G_ao_B_height.jpg b/Assets/Material/material_0520/plaster_rough_multi_R_rough_G_ao_B_height.jpg new file mode 100644 index 0000000000000000000000000000000000000000..60d3b017d466eff4674442f6a0619c8910dfb1e3 --- /dev/null +++ b/Assets/Material/material_0520/plaster_rough_multi_R_rough_G_ao_B_height.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5480e0bbec124e7df3aef79a3693b4aa8d0739407880df1fe36277de195549f2 +size 3541609 diff --git a/Assets/Material/material_0520/plaster_rough_norm.jpg b/Assets/Material/material_0520/plaster_rough_norm.jpg new file mode 100644 index 0000000000000000000000000000000000000000..89c9f7e74495c2d0422578e991f1505f489fc0e9 --- /dev/null +++ b/Assets/Material/material_0520/plaster_rough_norm.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3dd20c55f24ef3f9b0ca8759a44255a0ae4ac6764ee44aff6889cf924dae6c9e +size 2677077 diff --git a/Assets/Material/material_0527/Plastic_Standardized_Surface_Finish.mdl b/Assets/Material/material_0527/Plastic_Standardized_Surface_Finish.mdl new file mode 100644 index 0000000000000000000000000000000000000000..2f12b4c32ff37f22326ef642855f57855a64da3c --- /dev/null +++ b/Assets/Material/material_0527/Plastic_Standardized_Surface_Finish.mdl @@ -0,0 +1,1630 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + + +mdl 1.6; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +const string DESCRIPTION = "A plastic material with a industrial standardized surface finish."; + +float remap(float input, float low_1, float high_1, float low_2, float high_2) +{ + return low_2 + ((input - low_1) * (high_2 - low_2))/(high_1 - low_1); +} + +float histogram_scan_big(float input, float width, float position) +{ + return ::math::clamp( + remap(input, + ::math::lerp(-width, 1.0, position), + ::math::lerp(0.0, 1.0 + width, position), + 0.0, + 1.0), + 0.0, + 1.0); +} + +struct vm_coordinates{ + float2 uv; + float rotation; + int uv_space_index; + float4 carry; +}; + +export enum vm_mono_select +[[ + anno::description("Modes for the creation of a gray-scale value from a color"), + anno::hidden() +]] +{ + mono_r = 0, + mono_g = 1, + mono_b = 2, + mono_a = 3, + mono_average = 4 +}; + +vm_coordinates vm_coord +( + float2 translation = float2(0.0f, 0.0) [[ + ::anno::display_name("Translation"), + ::anno::description("Translates the coordinates") + ]], + float rotation = 0.0f [[ + ::anno::display_name("Rotation"), + ::anno::description("Rotates the coordinates in degrees") + ]], + float2 scaling = float2(1.0f, 1.0f) [[ + ::anno::display_name("Scaling"), + ::anno::description("Scales the coordinates") + ]], + uniform int uv_space = 0 [[ + ::anno::display_name("UV Space"), + ::anno::description("Chose the UV space") + ]] +) +[[ + ::anno::display_name("vm Transform"), + ::anno::description("Generates coordinates to be used in vm_lookup functions") +]] +{ + vm_coordinates uv; + ::base::texture_coordinate_info info = ::base::coordinate_source( ::base::texture_coordinate_uvw, uv_space); + uv.rotation = (rotation * 3.1415926535897932384626433832f) / 180.f; + uv.uv = float2(info.position.x, info.position.y); + float sine = ::math::sin(uv.rotation); + float cosine = ::math::cos(uv.rotation); + float2x2 rot = float2x2(cosine, -sine, sine, cosine); + uv.uv = rot * uv.uv; + uv.uv /= scaling; + uv.uv += translation; + // Translation before or after rotation? + return uv; +} + +::base::texture_return vm_tex_lookup( + uniform texture_2d tex, + vm_coordinates uv = vm_coord(), + uniform vm_mono_select mono_source = mono_a, + float4 scale = float4(1.0f)) +{ + float mono; + float4 lookup = ::tex::lookup_float4(tex, uv.uv, ::tex::wrap_repeat, ::tex::wrap_repeat) * scale; + switch( mono_source ) { + case mono_r: mono = lookup.x; + break; + case mono_g: mono = lookup.y; + break; + case mono_b: mono = lookup.z; + break; + case mono_a: mono = lookup.w; + break; + case mono_average: mono = ::math::average(float3(lookup.x, lookup.y, lookup.z)); + break; + } + return ::base::texture_return(color(lookup.x, lookup.y, lookup.z), mono); +} + +float3 vm_tex_normal_lookup( + uniform texture_2d tex, + vm_coordinates uv = vm_coord(), + float strength = 1.0f +) +{ + float rot = uv.rotation; + // Lookup and convert normal texture to -1 ... 1 range + float3 norm = (::tex::lookup_float3(tex, uv.uv, ::tex::wrap_repeat, ::tex::wrap_repeat) - float3(.5f)) * 2.0f; + norm = ::math::normalize(norm * float3(strength, strength, 1.0)); + // if any rotation happened prior to the lookup, compensate for it + norm = float3(::math::cos(rot) * norm.x - ::math::sin(rot) * norm.y, + ::math::sin(rot) * norm.x + ::math::cos(rot) * norm.y, + norm.z); + return norm.x * ::state::texture_tangent_u(uv.uv_space_index) + + norm.y * ::state::texture_tangent_v(uv.uv_space_index) + + norm.z * ::state::normal(); +} + +export material Plastic_Standardized_Surface_Finish( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.07f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 0.13f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.47f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(0.024f, 0.024f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 10.f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = true [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]], + // Material presets need to have different scalings. This parameter is required to fit all material presets + // so that the 'normal' texture_scale sits at 1.0f + float2 texture_scale_refit = 1.f [[ + ::anno::description("Adjusts the texture scale for a material."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Advanced"), + ::anno::hidden(), + ::anno::ui_order(11) + ]] + ) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish Template"), + ::anno::description("Master template material. This material should be hidden. " + "If you see this material, the integration is not hiding it correctly."), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "artificial", "finish", "decorative", "treated", "automotive", "design", "shiny", "new", "black", "dark")), + ::anno::hidden() +]] + = + let { + bool tmp0 = false; + float2 texture_rescale = texture_scale * texture_scale_refit; + float reflection_reweight = 1.0f - reflection_weight; + + material_surface tmp1(::df::custom_curve_layer(0.0399999991f, 1.f, 5.f, histogram_scan_big(vm_tex_lookup(texture_2d("./mold_01_rough.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).mono, 1.f, reflection_reweight * 0.680000007f), ::df::microfacet_ggx_smith_bsdf(roughness * 0.0700000003f, roughness * 0.0700000003f, color(1.f, 1.f, 1.f), color(0.f, 0.f, 0.f), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(1.0f, ::df::diffuse_reflection_bsdf(plastic_color, 0.f), bsdf(), vm_tex_normal_lookup(texture_2d("./mold_01_norm.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), bump_strength)), vm_tex_normal_lookup(texture_2d("./mold_01_norm.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), bump_strength)), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(2.30851698f, 2.30851698f, 2.30851698f); + material_volume tmp4 = material_volume(scattering: vdf(), absorption_coefficient: color(0.f, 0.f, 0.f), scattering_coefficient: color(0.f, 0.f, 0.f)); + material_geometry tmp5(float3(0.f), 1.f, roundcorners_enable ? ::state::rounded_corner_normal(roundcorners_radius_mm * 0.00100000005f, roundcorners_across_materials, 1.f) : ::state::normal()); + } in + material( + thin_walled: tmp0, + surface: tmp1, + backface: tmp2, + ior: tmp3, + volume: tmp4, + geometry: tmp5); + +// V12 +export material Plastic_Standardized_Surface_Finish_V12( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.2f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 0.3f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.34f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 10.f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = true [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V12"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V12.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 12", "artificial", "finish", "decorative", "treated", "automotive", "design", "shiny", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.0024f +); + +// V15 +export material Plastic_Standardized_Surface_Finish_V15( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.23f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 0.41f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.34f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 10.f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = true [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V15"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V15.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 15", "artificial", "finish", "decorative", "treated", "automotive", "design", "shiny", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.0048f +); + +// V18 +export material Plastic_Standardized_Surface_Finish_V18( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.25f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 0.83f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.34f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 10.f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = true [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V18"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V18.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 18", "artificial", "finish", "decorative", "treated", "automotive", "design", "shiny", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.00552f +); + +// V21 +export material Plastic_Standardized_Surface_Finish_V21( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.25f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 0.83f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.34f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 10.f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = true [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V21"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V21.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 21", "artificial", "finish", "decorative", "treated", "automotive", "design", "shiny", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.006f +); + +// V24 +export material Plastic_Standardized_Surface_Finish_V24( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.25f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 0.83f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.34f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 10.f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = true [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V24"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V24.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 24", "artificial", "finish", "decorative", "treated", "automotive", "design", "shiny", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.0072f +); + + +// V27 +export material Plastic_Standardized_Surface_Finish_V27( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.25f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 0.83f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.34f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 10.f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = true [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V27"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V27.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 27", "artificial", "finish", "decorative", "treated", "automotive", "design", "shiny", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.0084f +); + + +// Template for other VDI-like materials which use a different bump map +export material Plastic_Standardized_Surface_Finish_Template_V2( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic."), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.2f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 1.f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::soft_range(0.f, 1.f), + ::anno::hard_range(0.f, 2.f), + ::anno::ui_order(2) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 4.30000019f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + float reflection_weight = 0.5f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 1.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(10) + ]], + // Material presets need to have different scalings. This parameter is required to fit all material presets + // so that the 'normal' texture_scale sits at 1.0f + float2 texture_scale_refit = 0.015f [[ + ::anno::description("Adjusts the texture scale for a material."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Advanced"), + ::anno::hidden(), + ::anno::ui_order(11) + ]]) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish Template V2"), + ::anno::description("Master template material. This material should be hidden." + "If you see this material, the integration is not hiding it correctly."), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_Template_V2.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "artificial", "finish", "decorative", "treated", "automotive", "design", "rough", "bumped", "matte", "bumped", "new", "black", "dark")), + ::anno::hidden() +]] + = + let { + bool tmp0 = false; + float2 texture_rescale = texture_scale * texture_scale_refit; + + material_surface tmp1(::df::custom_curve_layer(0.0399999991f, 1.f, 5.f, histogram_scan_big(float3(vm_tex_lookup(texture_2d("./mold_45_r_rough_g_ao.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), mono_a, float4(1.f)).tint).y, 0.610000014f, ::math::lerp(0.879999995f, 0.239999995f, reflection_weight)), ::df::microfacet_ggx_smith_bsdf(roughness * 0.199999988f, roughness * 0.199999988f, color(1.f, 1.f, 1.f), color(0.f, 0.f, 0.f), ::state::texture_tangent_u(0), ::df::scatter_reflect), ::df::weighted_layer(1.f, ::df::diffuse_reflection_bsdf(plastic_color, 0.f), bsdf(), vm_tex_normal_lookup(texture_2d("./mold_45_norm.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), bump_strength)), vm_tex_normal_lookup(texture_2d("./mold_45_norm.jpg", ::tex::gamma_linear), vm_coord(texture_translate, texture_rotate, texture_rescale, uv_space_index), bump_strength)), material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + material_surface tmp2 = material_surface(scattering: bsdf(), emission: material_emission(emission: edf(), intensity: color(0.f, 0.f, 0.f), mode: intensity_radiant_exitance)); + color tmp3 = color(2.30851698f, 2.30851698f, 2.30851698f); + material_volume tmp4 = material_volume(scattering: vdf(), absorption_coefficient: color(0.f, 0.f, 0.f), scattering_coefficient: color(0.f, 0.f, 0.f)); + material_geometry tmp5(float3(0.f), 1.f, roundcorners_enable ? ::state::rounded_corner_normal(roundcorners_radius_mm * 0.00100000005f, roundcorners_across_materials, 1.f) : ::state::normal()); + + } in + material( + thin_walled: tmp0, + surface: tmp1, + backface: tmp2, + ior: tmp3, + volume: tmp4, + geometry: tmp5); + + +// V30 +export material Plastic_Standardized_Surface_Finish_V30( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.2f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 1.0f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.6f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 0.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V30"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V30.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 30", "artificial", "finish", "decorative", "treated", "automotive", "design", "matte", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish_Template_V2( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.0108f +); + +// V 33 +export material Plastic_Standardized_Surface_Finish_V33( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.2f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 1.0f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.6f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 0.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V33"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V33.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 33", "artificial", "finish", "decorative", "treated", "automotive", "design", "matte", "bumped", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish_Template_V2( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.0168f +); + + +// V 36 +export material Plastic_Standardized_Surface_Finish_V36( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.2f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 1.0f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.6f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 0.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V36"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V36.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 36", "artificial", "finish", "decorative", "treated", "automotive", "design", "matte", "bumped", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish_Template_V2( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.0204f +); + + +// V 39 +export material Plastic_Standardized_Surface_Finish_V39( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.2f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 1.0f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.6f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 0.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V39"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V39.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 39", "artificial", "finish", "decorative", "treated", "automotive", "design", "matte", "bumped", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish_Template_V2( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.024f +); + + +// V 42 +export material Plastic_Standardized_Surface_Finish_V42( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.2f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 1.0f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.6f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 0.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V42"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V42.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 42", "artificial", "finish", "decorative", "treated", "automotive", "design", "matte", "bumped", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish_Template_V2( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.0384f +); + + + +// V 45 +export material Plastic_Standardized_Surface_Finish_V45( + color plastic_color = color(0.03f, 0.03f, 0.03f) [[ + ::anno::description("Choose the color of the plastic"), + ::anno::display_name("Plastic Color"), + ::anno::in_group("Appearance"), + ::anno::ui_order(0) + ]], + float roughness = 0.2f [[ + ::anno::description("Higher roughness values lead to bigger highlights and blurrier reflections."), + ::anno::display_name("Roughness"), + ::anno::in_group("Appearance"), + ::anno::usage("roughness"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(1) + ]], + float bump_strength = 1.0f [[ + ::anno::description("Specifies the strength of the bump."), + ::anno::display_name("Bump Strength"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f), + ::anno::soft_range(0.f, 1.f), + ::anno::ui_order(2) + ]], + float reflection_weight = 0.6f [[ + ::anno::description("Amount of reflection, higher numbers provide more reflection."), + ::anno::display_name("Reflection Weight"), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f), + ::anno::ui_order(7) + ]], + float2 texture_translate = 0.f [[ + ::anno::description("Controls the position of the texture."), + ::anno::display_name("Texture Translate"), + ::anno::in_group("Transform"), + ::anno::ui_order(3) + ]], + float texture_rotate = 0.f [[ + ::anno::description("Rotates angle ofy the texture in degrees."), + ::anno::display_name("Texture Rotate"), + ::anno::in_group("Transform"), + ::anno::soft_range(0.f, 360.f), + ::anno::ui_order(4) + ]], + float2 texture_scale = 1.f [[ + ::anno::description("Larger numbers increase the size."), + ::anno::display_name("Texture Scale"), + ::anno::in_group("Transform"), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::ui_order(5) + ]], + uniform int uv_space_index = 0 [[ + ::anno::description("Uses selected UV space for material."), + ::anno::display_name("UV Space Index"), + ::anno::in_group("Transform"), + ::anno::ui_order(6) + ]], + uniform bool roundcorners_enable = false [[ + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::display_name("Enable Round Corners"), + ::anno::in_group("Round Corners"), + ::anno::ui_order(8) + ]], + uniform float roundcorners_radius_mm = 0.5f [[ + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::display_name("Round Corner Radius (mm)"), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f), + ::anno::ui_order(9) + ]], + uniform bool roundcorners_across_materials = false [[ + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::display_name("Across Materials"), + ::anno::in_group("Round Corners."), + ::anno::ui_order(10) + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::contributor("Rüdiger Raab"), + ::anno::display_name("Plastic - Industrial Surface Finish V45"), + ::anno::description(DESCRIPTION), + ::anno::copyright_notice(COPYRIGHT), + ::anno::thumbnail("./.thumbs/Plastic_Standardized_Surface_Finish.Plastic_Standardized_Surface_Finish_V45.png"), + ::anno::key_words(string[]("plastic", "industrial", "VDI", "VDI 45", "artificial", "finish", "decorative", "treated", "automotive", "design", "matte", "bumped", "new", "black", "dark")) +]] = +Plastic_Standardized_Surface_Finish_Template_V2( + plastic_color: plastic_color, + roughness: roughness, + bump_strength: bump_strength, + reflection_weight: reflection_weight, + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + roundcorners_enable: roundcorners_enable, + roundcorners_radius_mm: roundcorners_radius_mm, + roundcorners_across_materials: roundcorners_across_materials, + texture_scale_refit: 0.1032f +); \ No newline at end of file diff --git a/Assets/Material/material_0555/laminate_oak_diffuse.jpg b/Assets/Material/material_0555/laminate_oak_diffuse.jpg new file mode 100644 index 0000000000000000000000000000000000000000..c5622401917428bc7cff1881c4c3b06770c6bd33 --- /dev/null +++ b/Assets/Material/material_0555/laminate_oak_diffuse.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:90ef8ef45d7cb0186b25c35fb5653b06946ffb73bc808a4160eb1e6a53bdedfa +size 2467433 diff --git a/Assets/Material/material_0555/laminate_oak_multi_R_rough_G_aniso.jpg b/Assets/Material/material_0555/laminate_oak_multi_R_rough_G_aniso.jpg new file mode 100644 index 0000000000000000000000000000000000000000..9b29338d6c06f6122b89d26b76f942188348beaa --- /dev/null +++ b/Assets/Material/material_0555/laminate_oak_multi_R_rough_G_aniso.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e426a7ec2e3cca9d19d6703618b015896f9008f94f6baf0612cca78ae30a2a90 +size 10480809 diff --git a/Assets/Material/material_0555/laminate_oak_normal.jpg b/Assets/Material/material_0555/laminate_oak_normal.jpg new file mode 100644 index 0000000000000000000000000000000000000000..e462a3d02108c78f111273fcc26e970f555c7ee3 --- /dev/null +++ b/Assets/Material/material_0555/laminate_oak_normal.jpg @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5fadceb9068374fbab649525991a091e37ac6c02636214480b0e60addd1f6531 +size 5397470 diff --git a/Assets/Material/material_0564/Wood_Tiles_Fineline.mdl b/Assets/Material/material_0564/Wood_Tiles_Fineline.mdl new file mode 100644 index 0000000000000000000000000000000000000000..3510cf6c886dc8fda9bab3dcef07dea84920c11b --- /dev/null +++ b/Assets/Material/material_0564/Wood_Tiles_Fineline.mdl @@ -0,0 +1,2876 @@ +/****************************************************************************** + * Copyright 2024 NVIDIA Corporation. All rights reserved. + ****************************************************************************** + +Permission is hereby granted by NVIDIA Corporation ("NVIDIA"), free of charge, +to any person obtaining a copy of the sample definition code that uses our +Material Definition Language (the "MDL Materials"), to reproduce and distribute +the MDL Materials, including without limitation the rights to use, copy, merge, +publish, distribute, and sell modified and unmodified copies of the MDL +Materials, and to permit persons to whom the MDL Materials is furnished to do +so, in all cases solely for use with NVIDIA's Material Definition Language, +subject to the following further conditions: + +1. The above copyright notices, this list of conditions, and the disclaimer +that follows shall be retained in all copies of one or more of the MDL +Materials, including in any software with which the MDL Materials are bundled, +redistributed, and/or sold, and included either as stand-alone text files, +human-readable headers or in the appropriate machine-readable metadata fields +within text or binary files as long as those fields can be easily viewed by the +user, as applicable. +2. The name of NVIDIA shall not be used to promote, endorse or advertise any +Modified Version without specific prior written permission, except a) to comply + with the notice requirements otherwise contained herein; or b) to acknowledge +the contribution(s) of NVIDIA. + +THE MDL MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA CORPORATION BE LIABLE FOR +ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS. +*/ + + +mdl 1.5; + +import ::anno::*; +import ::base::*; +import ::df::*; +import ::math::*; +import ::state::*; +import ::tex::*; +import ::nvidia::core_definitions::blend_colors; +import ::nvidia::core_definitions::dimension; + + +const string COPYRIGHT = +" Copyright 2024 NVIDIA Corporation. All rights reserved.\n" +" MDL MATERIALS ARE PROVIDED PURSUANT TO AN END USER LICENSE AGREEMENT,\n" +" WHICH WAS ACCEPTED IN ORDER TO GAIN ACCESS TO THIS FILE. IN PARTICULAR,\n" +" THE MDL MATERIALS ARE PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n" +" EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF\n" +" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF\n" +" COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL NVIDIA\n" +" CORPORATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY\n" +" GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN\n" +" AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR\n" +" INABILITY TO USE THE MDL MATERIALS OR FROM OTHER DEALINGS IN THE MDL MATERIALS.\n"; + +const string DESCRIPTION = "A wooden tile material with adjustments to produce a rich variety of wooden floor styles ranging from new to worn"; + + +// ---------------------------------------------------------------------------------------------------------------------- + + +float histogram_range(float input, float range = 1.0f, float position = 0.5f) +{ + float low = ::math::clamp(1.0 - ::math::min(((1.0 - position) + range * 0.5), (1.0 - position) * 2), 0.0, 1.0); + float high = ::math::clamp(::math::min((position + range * 0.5 ), position * 2.0), 0.0, 1.0); + return ::math::lerp(low, high, input); +} + +float remap_xy_to_0_1(float input, float x, float y) +{ + return (input - x)/(y - x); +} + +float histogram_scan_big(float input, float width, float position) +{ + return ::math::clamp( + remap_xy_to_0_1(input, + ::math::lerp(-width, 1.0, position), + ::math::lerp(0.0, 1.0 + width, position)), + 0.0, + 1.0); +} + +// ********** Randomization functions -I- ********** + +int random(int seed = 0, int modulus = 65536, int multiplier = 1664525, int increment = 1013904223) +{ + return (multiplier * seed + increment) % modulus; +} + +// Returns the normal n in tangent space, given n is in internal space. +float3 transform_internal_to_tangent(float3 n) +[[ + ::anno::hidden() +]] +{ + return + n.x* float3(::state::texture_tangent_u(0).x,::state::texture_tangent_v(0).x,::state::normal().x)+ + n.y* float3(::state::texture_tangent_u(0).y,::state::texture_tangent_v(0).y,::state::normal().y)+ + n.z* float3(::state::texture_tangent_u(0).z,::state::texture_tangent_v(0).z,::state::normal().z); +} + +// Returns the normal n in internal space, given n is in tangent space. +float3 transform_tangent_to_internal(float3 n) +[[ + ::anno::hidden() +]] +{ + return ::state::texture_tangent_u(0) * n.x + + ::state::texture_tangent_v(0) * n.y + + ::state::normal() * n.z ; +} + + + +// Returns a normal by adding a detail normal to a global normal. +// If detail blending of two normal maps gives visual artifacts, check if texture_2d are loaded +// correctly with ::tex::gamma_linear +float3 add_detail_normal(float3 nd = ::state::normal(), float3 n = ::state::normal()) +{ + // http://blog.selfshadow.com/publications/blending-in-detail/ + float3 n_t = transform_internal_to_tangent(n); + float3 nd_t = transform_internal_to_tangent(nd); + + n_t=n_t + float3(0.,0.,1.); + nd_t = nd_t * float3(-1.,-1.,1.); + + n = n_t*::math::dot(n_t, nd_t)/n_t.z - nd_t; + return ::math::normalize(transform_tangent_to_internal(n)); +} + +::base::texture_coordinate_info transform_coordinate_2( + float4x4 transform + [[ ::anno::description("A transformation to be applied to the source coordinates. rotation_translation_scale() is a suggested means to compute the transformation matrix.") ]], + ::base::texture_coordinate_info coordinate = ::base::texture_coordinate_info() + [[ ::anno::description("Coordinate, typically sourced from coordinate_source or coordinate_projection.") ]] +) [[ + ::anno::description("Transform a texture coordinate by a matrix.") , + ::anno::noinline() + ]] +{ + // Version 2 + float4 r_position = transform * float4(coordinate.position.x,coordinate.position.y,coordinate.position.z,1); + + float4 u = transform[0]; + float3 ru = ::math::normalize(float3(u.x,u.y,u.z)); + float cos = ru.x; + float sin = -ru.y; + + return ::base::texture_coordinate_info( + float3(r_position.x,r_position.y,r_position.z), + ::math::normalize(cos * coordinate.tangent_u - sin * coordinate.tangent_v), + ::math::normalize(cos * coordinate.tangent_v + sin * coordinate.tangent_u)); +} + + +// Takes the standard input that every material has. It combines a couple of +// functions in one convenience function. +::base::texture_coordinate_info vmat_transform( + float2 translation = float2(0.0, 0.0), + float rotation = 0.0, // rotation in degrees + float2 scaling = float2(1.0, 1.0), + uniform ::base::texture_coordinate_system system = ::base::texture_coordinate_uvw, + uniform int uv_space = 0 +) +{ + float rotation_rad = (rotation * 3.1415926535897932384626433832f) / 180.f; + float4x4 scale = + float4x4(1.0 /scaling.x, 0. , 0. , 0., + 0. , 1.0 /scaling.y , 0. , 0., + 0. , 0. , 1.0, 0., + translation.x , translation.y , 0.0, 1.); + + float s = ::math::sin(rotation_rad); + float c = ::math::cos(rotation_rad); + float4x4 rotate = + float4x4( c , -s , 0.0 , 0.0, + s , c , 0.0 , 0.0, + 0.0, 0.0 , 1.0 , 0.0, + 0. , 0.0 , 0.0 , 1.); + + return transform_coordinate_2(scale*rotate, ::base::coordinate_source(system, uv_space)); +} + + +// Returns 4 random IDs for a given pattern +// TODO: Describe how the whole things exactly works +float4 rand_tile_id( + ::base::texture_coordinate_info uvw, + ::base::texture_return id_offset_map // map containing the ID in r channel + //and the cell offset in g channel. + ) +[[ + ::anno::noinline() +]] +{ + float4 ret_val; + int offset_x, offset_y; + + + float3 id_offset_map_2 = float3(id_offset_map.tint); + float offset_id = id_offset_map_2.y; + int rand_id = int(id_offset_map_2.x * 254.f); // the more logical value of 255 causes sometimes rendering artifacts + // with the random number generator. Setting it to 254 apparently fixes it + + // Offset of overlapping tiles stored in G-channel + // [0 - 0.25[ : ( 0/ 0) Grayscale value: 0.1 + // [0.25 - 0.5 [ : (-1/ 0) Grayscale value: 0.37 + // [0.5 - 0.75[ : (-1/-1) Grayscale value: 0.62 + // [0.75 - 1.0 [ : ( 0/-1) Grayscale value: 0.87 + + offset_x = offset_id < 0.25f ? 0 : (offset_id < .75f) ? 1 : 0; + offset_y = offset_id < 0.5 ? 0 : 1; + + int2 cell_id = int2(int(::math::floor(uvw.position.x) - offset_x), int(::math::floor(uvw.position.y) - offset_y)); + + /* // ORIGINAL + int rand_val_1 = triple32(rand_id + triple32(cell_id.x + triple32(cell_id.y))); + int rand_val_2 = triple32(rand_val_1); + int rand_val_3 = triple32(rand_val_2); + int rand_val_4 = triple32(rand_val_3); + + ret_val = float4(uint2float(rand_val_1), + uint2float(rand_val_2), + uint2float(rand_val_3), + uint2float(rand_val_4)); + + return float4(ret_val/4294967296.f); + */ + + /* Simplified Version */ + int rand_val_1 = random(rand_id + random(cell_id.x + random(cell_id.y))); + int rand_val_2 = random(rand_val_1); + int rand_val_3 = random(rand_val_2); + int rand_val_4 = random(rand_val_3); + + ret_val = float4(rand_val_1, rand_val_2, rand_val_3, rand_val_4); + + return float4(ret_val/65535.0f); +} + + +// ****************************************************************************************************** + +export material Wood_Tiles_Fineline( + color wood_color = color(0.5f) [[ + ::anno::display_name("Wood Color"), + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::in_group("Appearance") + ]], + float age_dirt = 0.0f [[ + ::anno::display_name("Age Dirt"), + ::anno::description("Adds dark dirt spots on top of the surface to create the appearance of a somewhat aged surface."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float wood_bump_strength = 0.05f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::description("Randomly darkens the tiles of the floor."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.25f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + + + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.1f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.9f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.15f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.4f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]], + +// WOOD Highlights (Not accessible to regular users) + uniform bool preview_wood_highlights = false + [[ + ::anno::display_name("Preview Wood Specular"), + ::anno::description("Enables previewing of the wood specular highlights for tweaking."), + ::anno::in_group("Advanced", "Wood Highlight") + ]], // just previews the highlights of the wood material + float isotropic_roughness = 0.5f // The average roughness value of the isotropic highlight. When roughness variation is applied, the variation will go above and below those values.") + [[ + ::anno::display_name("Isotropic Roughness"), + ::anno::description("Sets the roughness of the isotropic component of the wood reflection."), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Advanced", "Wood Highlight") + ]], + float isotropic_roughness_range = 0.844f // Adjusts the range of variation being applied to the isotropic highlight, a value of zero has no effect at all whereas 1 produces the most variation") + [[ + ::anno::display_name("Isotropic Roughness Range"), + ::anno::description("Sets the degree roughness variation around the isotropic highlight."), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Advanced", "Wood Highlight") + ]], + float isotropic_specular_brightness = 1.0f // Sets how strong the isotropic specular highlight appears + [[ + ::anno::display_name("Isotropic Highlight Brightness"), + ::anno::description("Sets the brightness of the isotropic wood highlight."), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Advanced", "Wood Highlight") + ]], + float wood_specular_level = 0.787f // Adjusts the specular level (PBR Style) + [[ + ::anno::display_name("Wood Specular Level"), + ::anno::description("Adjusts the falloff of the wood highlights."), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Advanced", "Wood Highlight") + ]], + float aniso_attenuation = 0.484f //Attenuates the the anisotropic highlight using a texture. Use the preview for exclusively previewing the wood hightligghts for properly adjusting this term" + [[ + ::anno::display_name("Anisotropic Attenuation"), + ::anno::description("Breaks up the reflection of the anisotropic highlight."), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Advanced", "Wood Highlight") + ]], + float aniso_bsdf_width = 0.553f //Controls the width of the anisotropic highlight" + [[ + ::anno::display_name("Anisotropic Width"), + ::anno::description("Adjusts the width of the anisotropic wood highlight."), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Advanced", "Wood Highlight") + ]], + float aniso_bsdf_height = 0.656f //Controls the height of the anisotropic highlight" + [[ + ::anno::display_name("Anisotropic Height"), + ::anno::description("Adjusts the height of the anisotropic highlight."), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Advanced", "Wood Highlight") + ]], + float anisotropic_isotropic_balance = 0.361f // Balances the Anisotropic vs. the isotropic wood highlight" + [[ + ::anno::display_name("Anisotropic - Isotropic Balance"), + ::anno::description("Blends between the contribution of isotropic and anisotropic highlight."), + ::anno::hard_range(0.f, 1.f), + ::anno::in_group("Advanced", "Wood Highlight") + ]], + +// TEXTURES (Not accessible to regular users) + uniform texture_2d tex_srgb_wood_color = texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb) // Diffuse + [[ + ::anno::display_name("Diffuse Wood Texture"), + ::anno::description("The diffuse wood texture used to cover the tiles (srgb)."), + ::anno::in_group("Advanced", "Textures") + ]], + uniform texture_2d tex_lin_wood_rough_detail = texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear) // Anisotropic Roughness AKA "Rough Detail" + [[ + ::anno::display_name("Anisotropic Variation Texture"), + ::anno::description("Texture to add variation to the anisotropic reflections of the wood (linear space)."), + ::anno::in_group("Advanced", "Textures") + ]], + uniform texture_2d tex_lin_wood_rough_grain = texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear) // Isotropic Roughness AKA "Rough Grain" + [[ + ::anno::display_name("Isotropic Variation Texture"), + ::anno::description("Texture to add variation to the isotropic reflections of the wood (linear space)."), + ::anno::in_group("Advanced", "Textures") + ]], + uniform texture_2d tex_lin_wood_detail_norm = texture_2d("./fineline_norm.jpg", ::tex::gamma_linear) // Wood detail Normal - Grain & Structure + [[ + ::anno::display_name("Wood Normal Texture"), + ::anno::description("Tangent Space Normal texture for defining the bumpiness of the wood."), + ::anno::in_group("Advanced", "Textures") + ]], + uniform texture_2d tex_lin_tiles_id_offset_rotation = texture_2d("./brickbond_R_id_G_offs_B_rotation.png", ::tex::gamma_linear) // Tiles ID, Offset & Rotation + [[ + ::anno::display_name("Tiles ID - Offset - Rotation Texture"), + ::anno::description("Texture that holds information about the wood tiles needed to create the wood tiles effect. R - Tiles ID, G - Tiles offset, B - Tiles Rotation (linear space)."), + ::anno::in_group("Advanced", "Textures") + ]], + uniform texture_2d tex_lin_tiles_edgewear_gaps_gapsrough= texture_2d("./brickbond_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear) // Edgewear, Gaps(AO), Gaps Roughnesss + [[ + ::anno::display_name("Edgewear - Gaps - Gap Rough"), + ::anno::description("Texture that holds maps for the edgewear roughness, the tile gaps and the gaps roughness (linear space)."), + ::anno::in_group("Advanced", "Textures") + ]], + uniform texture_2d tex_lin_tiles_normal = texture_2d("./brickbond_norm.png", ::tex::gamma_linear) // Tiles Normal (Grout and Bend) + [[ + ::anno::display_name("Tiles Normal Texture"), + ::anno::description("Texture that holds the normal map for the tiles (linear space)."), + ::anno::in_group("Advanced", "Textures") + ]], + uniform texture_2d tex_lin_tiles_rough_dents_spots = texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear) // Tiles Roughness, Dents and Spots + [[ + ::anno::display_name("Tiles Rough - Dents - Spots"), + ::anno::description("Texture that contains maps for the tiles roughness, dents and spots which is a roughness effect applied to the wood coating layer (linear space)."), + ::anno::in_group("Advanced", "Textures") + ]], + uniform texture_2d tex_lin_tiles_orange_peel = texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) // Tiles orange Peel + [[ + ::anno::display_name("Tiles Orange Peel"), + ::anno::description("Tangent Space Normal texture for the orange peel which is applied to the coating of the tiles."), + ::anno::in_group("Advanced", "Textures") + ]] + +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Brick Bond Master"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "master", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline.png"), + ::anno::copyright_notice(COPYRIGHT) + //::anno::hidden() +]] + = + let { +/* + texture_2d tex_srgb_wood_color = texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb); // Diffuse + texture_2d tex_lin_wood_rough_detail = texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear); // Anisotropic Roughness AKA "Rough Detail" + texture_2d tex_lin_wood_rough_grain = texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear); // Isotropic Roughness AKA "Rough Grain" + texture_2d tex_lin_wood_detail_norm = texture_2d("./fineline_norm.jpg", ::tex::gamma_linear); // Wood detail Normal - Grain & Structure + texture_2d tex_lin_tiles_id_offset_rotation = texture_2d("./brickbond_R_id_G_offs_B_rotation.png", ::tex::gamma_linear); // Tiles ID, Offset & Rotation + texture_2d tex_lin_tiles_edgewear_gaps_gapsrough= texture_2d("./brickbond_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear); // Edgewear, Gaps(AO), Gaps Roughnesss + texture_2d tex_lin_tiles_normal = texture_2d("./brickbond_norm.png", ::tex::gamma_linear); // Tiles Normal (Grout and Bend) + texture_2d tex_lin_tiles_rough_dents_spots = texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear); // Tiles Roughness, Dents and Spots + texture_2d tex_lin_tiles_orange_peel = texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear); // Tiles orange Peel +*/ +/* + // Wood Highlight tweaks + bool preview_wood_highlights = false; // just previews the highlights of the wood material + float wood_specular_level = 1.f; // Adjusts the specular level (PBR Style) + float isotropic_specular_brightness = 1.0f; // Sets how strong the isotropic specular highlight appears + float aniso_attenuation = 0.5f; //Attenuates the the anisotropic highlight using a texture. Use the preview for exclusively previewing the wood hightligghts for properly adjusting this term" + float anisotropic_isotropic_balance = 0.467f; // Balances the Anisotropic vs. the isotropic wood highlight" + float isotropic_roughness_range = 0.66f; // Adjusts the range of variation being applied to the isotropic highlight, a value of zero has no effect at all whereas 1 produces the most variation") + float isotropic_roughness = 0.34f; // The average roughness value of the isotropic highlight. When roughness variation is applied, the variation will go above and below those values."), + + float aniso_bsdf_width = 0.36f; //Controls the width of the anisotropic highlight" + float aniso_bsdf_height = 0.50f; //Controls the height of the anisotropic highlight"), +*/ + + // Prepare the UV coordinates for regular texture lookups + ::base::texture_coordinate_info base_uvw = vmat_transform( + translation:texture_translate, + rotation: texture_rotate, + scaling: texture_scale, + system: ::base::texture_coordinate_uvw, + uv_space: uv_space_index + ); + + + // Random tile transform + // R: tile_id + // G: tile_offset + // B: tile_rotation + + ::base::texture_return rand_id_offset_lookup = ::base::file_texture( + texture: tex_lin_tiles_id_offset_rotation, + uvw: base_uvw, + mono_source: ::base::mono_alpha + ); + + + float4 rand_vals = rand_tile_id( + uvw: base_uvw, + id_offset_map: rand_id_offset_lookup + ); + + float2 rand_translation = float2(rand_vals.x, rand_vals.y); + float rand_rotation = (float3(rand_id_offset_lookup.tint).z + (rand_vals.z - 0.5) * wood_random_rotation) * 360; + float2 rand_scale = float2(wood_scale/(1.0 - wood_scale_variation * 0.5 * rand_vals.x)) * texture_scale; + +// *** TILE UV *** - The randomized UV lookup for the tiles + ::base::texture_coordinate_info tile_uvw = vmat_transform( + translation:rand_translation, + rotation: rand_rotation, + scaling: rand_scale, + system: ::base::texture_coordinate_uvw, + uv_space: uv_space_index + ); + + + // Tiling Lookups and compositing + // R: Edgewear + // G: Gaps + // B: Gaps Damage Roughness + float3 egdewear_gaps_gapsrough_lookup = float3( ::base::file_texture( + texture: tex_lin_tiles_edgewear_gaps_gapsrough, + uvw: base_uvw, + mono_source: ::base::mono_alpha + ).tint); + + // R: Coat Base Roughness (Footsteps, Grain, Wipe) + // G: Dents (Dirt/Ao) + // B: Spots (Liquid-alike) + float3 rough_dents_spots_lookup = float3( ::base::file_texture( + texture: tex_lin_tiles_rough_dents_spots, + uvw: base_uvw, + mono_source: ::base::mono_alpha + ).tint); + + float dirt_and_spots_amount_remap = dirt_and_spots_amount * 0.5; + + float coat_roughness = egdewear_gaps_gapsrough_lookup.x * edgewear_roughness_amount + // edgewear + egdewear_gaps_gapsrough_lookup.z * dirt_and_spots_amount_remap + // Gaps Damage + histogram_range(rough_dents_spots_lookup.x, base_roughness_range, tiles_base_roughness) + // base roughness + rough_dents_spots_lookup.z * dirt_and_spots_amount + // Spots (rough) + (1.0 - rough_dents_spots_lookup.y) * dirt_and_spots_amount; // Dents + + float coat_roughness_squared = coat_roughness*coat_roughness; // roughness squared + + bsdf coating_bsdf = ::df::microfacet_ggx_smith_bsdf( + roughness_u: coat_roughness_squared, + roughness_v: coat_roughness_squared, + tint: color(1.0f), + mode: ::df::scatter_reflect + ); + +// ******** NORMALS ******** + + // Tiles normal + float3 tiles_normal = ::base::tangent_space_normal_texture( + texture: tex_lin_tiles_normal, + factor: tiles_bump_strength, + uvw: base_uvw + ); + + float3 wood_detail_normal = ::base::tangent_space_normal_texture( + texture: tex_lin_wood_detail_norm, + factor: wood_bump_strength, + uvw: tile_uvw + ); + + float3 orange_peel_normal = ::base::tangent_space_normal_texture( + texture: tex_lin_tiles_orange_peel, + factor: tiles_orange_peel_bump_factor * 0.1f, + uvw: base_uvw + ); + + // Randomized Tiles normals - This needs to be probably rotated with the normal of the uv-tiles + float slope_amount = 0.07 * tiles_random_slope_orientation; + float3 slope = ::math::normalize( + ::state::texture_tangent_u(uv_space_index) * (rand_vals.y - 0.5) * slope_amount + + ::state::texture_tangent_v(uv_space_index) * (rand_vals.z - 0.5) * slope_amount + + ::state::normal() * ((1.0f - slope_amount) + 1.0f) + ); + + float3 tiles_slope_normal = add_detail_normal( + n: slope, + nd: tiles_normal + ); + + float3 tiles_slope_detail_normal = add_detail_normal( + n: tiles_slope_normal, + nd: wood_detail_normal + ); + + float3 normal_final = add_detail_normal( + n: tiles_slope_detail_normal, + nd: orange_peel_normal + ); + +// ******** Anisotropic Highlight ******** + // Lookup for anisotropic brightness variation + ::base::texture_coordinate_info aniso_brightnessvar_lookup_uvw = vmat_transform( + translation: texture_translate, + rotation: texture_rotate, + scaling: texture_scale * 0.6, + system: ::base::texture_coordinate_uvw + ); + + ::base::texture_return aniso_brightnessvar_lookup = ::base::file_texture( + texture: tex_lin_wood_rough_detail, + uvw: aniso_brightnessvar_lookup_uvw, + mono_source: ::base::mono_average + ); + + float aniso_brightnessvar = histogram_scan_big( + input: aniso_brightnessvar_lookup.mono, + width: 0.911, + position: aniso_attenuation + ); + + ::base::texture_return aniso_mod_lookup = ::base::file_texture( + texture: tex_lin_wood_rough_detail, + uvw: tile_uvw, + mono_source: ::base::mono_average + ); + + float aniso_detail_u = histogram_range(aniso_mod_lookup.mono, 1.0, aniso_bsdf_width); + float aniso_detail_v = histogram_range(aniso_mod_lookup.mono, 1.0, aniso_bsdf_height); + + bsdf wood_highlight_aniso = ::df::weighted_layer( + layer: ::df::microfacet_ggx_smith_bsdf( + roughness_u: aniso_detail_u * aniso_detail_u, + roughness_v: aniso_detail_v * aniso_detail_v, + tint: color(aniso_brightnessvar), + tangent_u: tile_uvw.tangent_u, + mode: ::df::scatter_reflect + ), + weight: 1.0f, + normal: tiles_slope_normal + ); + +// ******** Isotropic Highlight ******** + ::base::texture_return iso_mod_lookup = ::base::file_texture( + texture: tex_lin_wood_rough_grain, + uvw: tile_uvw, + mono_source: ::base::mono_average + ); + + float iso_mod = histogram_range( + input: iso_mod_lookup.mono, + range: isotropic_roughness_range, + position: isotropic_roughness + ); + + float iso_mod_squared = iso_mod * iso_mod; + + bsdf wood_highlight_isotropic = ::df::microfacet_ggx_smith_bsdf( + roughness_u: iso_mod_squared, + roughness_v: iso_mod_squared, + tint: color(isotropic_specular_brightness), + mode: ::df::scatter_reflect + ); + +// ******** Comping Anisotropic and Isotropic Highlight ******** + + bsdf wood_highlight_isotropic_bumped = ::df::weighted_layer( + layer: wood_highlight_isotropic, + base: wood_highlight_aniso, + weight: anisotropic_isotropic_balance, + normal: tiles_slope_detail_normal + ); + + +// ******** Diffuse Comping ******** + + float floor_brightness_remap = ::math::lerp( + a: 0.3f, + b: 1.0f, + l: floor_brightness); + + color diffuse_attenuation = ::math::lerp( + a: gaps_brightness, + b: floor_brightness_remap, + l: egdewear_gaps_gapsrough_lookup.y); + + ::base::texture_return diffuse_lookup = ::base::file_texture( + texture: tex_srgb_wood_color, + uvw: tile_uvw, + mono_source: ::base::mono_alpha, + color_scale: diffuse_attenuation + ); + + float rand_tile_brightness = ::math::lerp( + a: ::math::lerp(a: 1.0f, // range of maximum wood brightness variation + b: 0.73, /*max rand wood darkening */ + l: wood_brightness_variation), + b: 1.0f, + l: rand_vals.z // random value + ); + + // adding the darkening of the dents texture channel + float rand_tile_brightness_dents = rand_tile_brightness * ::math::lerp(1.0f, rough_dents_spots_lookup.y, age_dirt); + + + ::base::texture_return tiles_rand_brightness = ::nvidia::core_definitions::blend_colors( + color_1: diffuse_lookup.tint, + color_2: color(::math::pow( a: rand_tile_brightness_dents, b: 2.2)), // do gamma compensation + mode: ::base::color_layer_multiply, + weight: 1.0f + ); + + ::base::texture_return tiles_rand_brightness_tint = ::nvidia::core_definitions::blend_colors( + color_1: tiles_rand_brightness.tint, + color_2: wood_color, + mode: ::base::color_layer_overlay, + weight: .95f + ); + + bsdf diffuse = ::df::weighted_layer( + layer: ::df::diffuse_reflection_bsdf( + tint: tiles_rand_brightness_tint.tint + ), + normal: tiles_slope_detail_normal, + weight: 1.0 + ); + +// Diffuse + Highlights BSDF + + bsdf diffuse_and_highlights_bsdf = ::df::custom_curve_layer( + normal_reflectivity: wood_specular_level * 0.08, + grazing_reflectivity: 1.0f, + weight: aniso_brightnessvar , + layer: wood_highlight_isotropic_bumped, + base: diffuse + ); + +// DEBUG + bsdf debug_diffuse_and_highlights_bsdf = ::df::custom_curve_layer( + normal_reflectivity: wood_specular_level * 0.08, + grazing_reflectivity: 1.0f, + weight: aniso_brightnessvar , + layer: wood_highlight_isotropic_bumped + ); + +// Coating Layer + // separate controls for the reflectivity of the gaps and the general reflectivity of the coat + // Note that "gaps_brightness" also controls the diffuse texture (saving an additional parameter here) + float coating_weight = ::math::lerp( + a: gaps_brightness, + b: coating_reflectivity, + l: egdewear_gaps_gapsrough_lookup.y + ); + + // apply the coating layer + bsdf coated_wood_tiles_bsdf = ::df::custom_curve_layer( + normal_reflectivity: 0.03, //may as well be made adjustable (0.08 * specular_level) + grazing_reflectivity: 1.0f, + layer: coating_bsdf, + weight: coating_weight, + base: diffuse_and_highlights_bsdf, + normal: normal_final + ); + + +// ******** Round Corners ******** + float3 round_normal = round_corners ? + ::state::rounded_corner_normal( + radius: roundcorner_radius_mm * 0.001, // is in mm + across_materials: across_materials + ) : ::state::normal(); + +} in material( + surface: material_surface( + scattering: preview_wood_highlights ? debug_diffuse_and_highlights_bsdf : coated_wood_tiles_bsdf + ), + geometry: material_geometry( + normal: round_normal + ) +); + + +// ****************************************************************************************************** +// 01 + +export material Wood_Tiles_Fineline_Brickbond( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Brick Bond"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "brick bond", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Brickbond.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./brickbond_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./brickbond_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./brickbond_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); + + +// ****************************************************************************************************** +// 02 + +export material Wood_Tiles_Fineline_Chantilly( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Chantilly"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "chantilly", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Chantilly.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./chantilly_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./chantilly_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./chantilly_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); + +// ****************************************************************************************************** +// 03 + +export material Wood_Tiles_Fineline_Chevron( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Chevron"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "chevron", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Chevron.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./chevron_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./chevron_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./chevron_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); + + +// ****************************************************************************************************** +// 04 + +export material Wood_Tiles_Fineline_Cubes( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Cubes"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "cubes", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Cubes.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./cubes_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./cubes_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./cubes_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); + + +// ****************************************************************************************************** +// 05 + +export material Wood_Tiles_Fineline_Diagonal( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Diagonal"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "diagonal", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Diagonal.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./diagonal_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./diagonal_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./diagonal_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); + + +// ****************************************************************************************************** +// 06 + +export material Wood_Tiles_Fineline_Herringbone( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Herringbone"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "herringbone", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Herringbone.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./herringbone_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./herringbone_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./herringbone_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); + + +// ****************************************************************************************************** +// 07 + +export material Wood_Tiles_Fineline_Mosaic( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Mosaic"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "mosaic", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Mosaic.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./mosaic_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./mosaic_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./mosaic_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); + +// ****************************************************************************************************** +// 08 + +export material Wood_Tiles_Fineline_Stackbond( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Stack Bond"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "stack bond", "stack", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Stackbond.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./stackbond_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./stackbond_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./stackbond_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); + + +// ****************************************************************************************************** +// 09 + +export material Wood_Tiles_Fineline_Versailles( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Versailles"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "versailles", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Versailles.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./versailles_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./versailles_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./versailles_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); + + +// ****************************************************************************************************** +// 10 + +export material Wood_Tiles_Fineline_Woodstrip( + color wood_color = color(0.5f) [[ + ::anno::description("Applies an overlay color to tint the wood. The color is used using the 'overlay' mode as known " + "from paint programs. A gray value of 0.5 has no effect, brighter values brighten it while darker colors will have a darkening effect."), + ::anno::display_name("Wood Color"), + ::anno::in_group("Appearance") + ]], + uniform float wood_bump_strength = 0.1f // Determines the degree of bumpiness"), + [[ + ::anno::display_name("Wood Bump Strength"), + ::anno::description("Adjusts the strength of the wood bump map."), + ::anno::in_group("Appearance"), + ::anno::hard_range(0.f, 2.f) + ]], + float floor_brightness = 0.5f [[ + ::anno::description("Adjusts the general brightness of the wood."), + ::anno::display_name("Floor Brightness"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_brightness_variation = 0.5f [[ + ::anno::display_name("Wood Brightness Variation"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float wood_random_rotation = 0.015f [[ + ::anno::display_name("Wood Random Rotation"), + ::anno::description("Adds a random rotation around the main wood tile alignment direction."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + float2 wood_scale = 0.33f [[ + ::anno::description("Sets the size of the wood relative to the tiles pattern. Larger numbers increase the size of the wood texture within the tiles."), + ::anno::display_name("Wood Scale"), + ::anno::in_group("Tiles") + ]], + float wood_scale_variation = 0.f [[ + ::anno::description("Adds random variation to size of the wood in each tile."), + ::anno::display_name("Wood Scale Variation"), + ::anno::in_group("Tiles"), + ::anno::soft_range(0.f, 2.f) + ]], + uniform float tiles_bump_strength = 0.4f [[ + ::anno::description("Determines the degree of bumpiness of the tiles texture (grooves and bent tiles)."), + ::anno::display_name("Tiles Bump Strength"), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float tiles_random_slope_orientation = 0.05f [[ + ::anno::display_name("Tiles Random Slope Orientation"), + ::anno::description("Makes tiles individual tiles to appear tilted in random directions. Good for old floors and to take away too perfect appearing tiled floors."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float gaps_brightness = 0.3f [[ + ::anno::display_name("Gaps Brightness"), + ::anno::description("Adjusts the brightness and roughness of the gaps between the tiles."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + uniform float tiles_orange_peel_bump_factor = 0.0f [[ + ::anno::display_name("Coating Unevenness"), + ::anno::description("Applies an unevenness to the clear coat layer akin to orange peel."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + float coating_reflectivity = 1.f [[ + ::anno::display_name("Coating Reflectivity"), + ::anno::description("The overall reflectivity of the clearcoat layer. Note that other parameters will show no effect when the clearcoat reflectivity is 0."), + ::anno::in_group("Tiles"), + ::anno::hard_range(0.f, 1.f) + ]], + + + float tiles_base_roughness = 0.04f [[ + ::anno::description("Adjusts the roughness of the coating. Higher value leading to blurrier and softer reflections."), + ::anno::display_name("Coating Roughness"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float base_roughness_range = 0.6f [[ + ::anno::description("Applies roughness variation to the coating, introducing signs of wear such as footprints and smudges."), + ::anno::display_name("Coating Roughness Variation"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float dirt_and_spots_amount = 0.0f [[ + ::anno::description("Adds random dirt and spots on top of the surface which adds variation to the clearcoat roughness."), + ::anno::display_name("Dirt and Spots"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + float edgewear_roughness_amount = 0.0f [[ + ::anno::description("Adds edgewear around the tile borders which results in a more worn and rough look of the clearcoat."), + ::anno::display_name("Edgewear Roughness Amount"), + ::anno::in_group("Tiles", "Coating"), + ::anno::hard_range(0.f, 1.f) + ]], + + //----------------------------------------------- + + float2 texture_translate = 0.f [[ + ::anno::display_name("Texture Translate"), + ::anno::description("Controls the position of the texture."), + ::anno::in_group("Transform") + ]], + float texture_rotate = 0.f [[ + ::anno::display_name("Texture Rotate"), + ::anno::description("Rotates angle of the texture in degrees."), + ::anno::in_group("Transform") + ]], + float2 texture_scale = 1.0f [[ + ::anno::display_name("Texture Scale"), + ::anno::description("Larger numbers increase the size."), + ::nvidia::core_definitions::dimension(float2(1.0f, 1.0f)), + ::anno::in_group("Transform") + ]], + uniform int uv_space_index = 0 [[ + ::anno::display_name("UV Space Index"), + ::anno::description("Uses selected UV space for material."), + ::anno::in_group("Transform") + ]], + uniform bool round_corners = false [[ + ::anno::display_name("Round Corners"), + ::anno::description("Enables the round corner effect. Comes at a slight performance cost as additional raytracing calls are required to evaluate the round corner effect."), + ::anno::in_group("Round Corners") + ]], + uniform float roundcorner_radius_mm = 1.5f [[ + ::anno::display_name("Radius (mm)"), + ::anno::description("Radius of the rounded corners in millimeters."), + ::anno::in_group("Round Corners"), + ::anno::soft_range(0.f, 10.f) + ]], + uniform bool across_materials = false [[ + ::anno::display_name("Across Materials"), + ::anno::description("Applies the round corner effect across different materials when enabled."), + ::anno::in_group("Round Corners") + ]] +) +[[ + ::anno::author("NVIDIA vMaterials"), + ::anno::display_name("Wood Tiles Fineline - Wood Strip"), + ::anno::description(DESCRIPTION), + // reflective, varnished, bumped, matte, natural, stained, exterior, new, aged, decayed, abstract, modern, classic + ::anno::key_words(string[]("wood", "tiles", "tiled", "pattern", "decorative", "multimaterial", "organic", "natural", "coated", "infinite tiling", "architecture", "strip", "interior")), + ::anno::thumbnail("./.thumbs/Wood_Tiles_Fineline.Wood_Tiles_Fineline_Woodstrip.png"), + ::anno::copyright_notice(COPYRIGHT) +]] = Wood_Tiles_Fineline( + wood_color: wood_color, + wood_bump_strength: wood_bump_strength, + floor_brightness: floor_brightness, + wood_brightness_variation: wood_brightness_variation, + wood_random_rotation: wood_random_rotation, + wood_scale: wood_scale, + wood_scale_variation: wood_scale_variation, + + tiles_bump_strength: tiles_bump_strength, + tiles_random_slope_orientation: tiles_random_slope_orientation, + gaps_brightness: gaps_brightness, + tiles_orange_peel_bump_factor: tiles_orange_peel_bump_factor, + coating_reflectivity: coating_reflectivity, + tiles_base_roughness: tiles_base_roughness, + base_roughness_range: base_roughness_range, + dirt_and_spots_amount: dirt_and_spots_amount, + edgewear_roughness_amount: edgewear_roughness_amount, + + texture_translate: texture_translate, + texture_rotate: texture_rotate, + texture_scale: texture_scale, + uv_space_index: uv_space_index, + + round_corners: round_corners, + roundcorner_radius_mm: roundcorner_radius_mm, + across_materials: across_materials, + + preview_wood_highlights: false, + isotropic_roughness: 0.5f, + isotropic_roughness_range: 0.844f, + isotropic_specular_brightness: 1.0f, + wood_specular_level: 0.787f, + aniso_attenuation: 0.484f, + aniso_bsdf_width: 0.533f, + aniso_bsdf_height: 0.656f, + anisotropic_isotropic_balance: 0.361f, + + tex_srgb_wood_color: texture_2d("./fineline_diff.jpg", ::tex::gamma_srgb), + tex_lin_wood_rough_detail: texture_2d("./fineline_rough_detail.jpg", ::tex::gamma_linear), + tex_lin_wood_rough_grain: texture_2d("./fineline_rough_grain.jpg", ::tex::gamma_linear), + tex_lin_wood_detail_norm: texture_2d("./fineline_norm.jpg", ::tex::gamma_linear), + tex_lin_tiles_id_offset_rotation: texture_2d("./woodstrip_R_id_G_offs_B_rotation.png", ::tex::gamma_linear), + tex_lin_tiles_edgewear_gaps_gapsrough: texture_2d("./woodstrip_R_edgewear_G_gaps_B_gaps_rough.jpg", ::tex::gamma_linear), + tex_lin_tiles_normal: texture_2d("./woodstrip_norm.png", ::tex::gamma_linear), + tex_lin_tiles_rough_dents_spots: texture_2d("./tiles_wood_R_rough_G_dents_B_spots.jpg", ::tex::gamma_linear), + tex_lin_tiles_orange_peel: texture_2d("./tiles_wood_orangepeel_norm.jpg", ::tex::gamma_linear) + +); \ No newline at end of file