修訂 | 866920582d62d53ab9c79de8db1ffc7a4332d737 (tree) |
---|---|
時間 | 2024-12-10 05:41:59 |
作者 | sebastian_bugiu |
Commiter | sebastian_bugiu |
Added SMAA + Dynamic Cubemaps.
@@ -1,3 +1,23 @@ | ||
1 | +compositor_node SkyboxSMAA_RenderingNode | |
2 | +{ | |
3 | + //in 0 rt0 | |
4 | + texture rt1 target_width target_height PF_R8G8B8A8 | |
5 | + | |
6 | + //Play nice with Multi-GPU setups. See Postprocessing sample. | |
7 | + target rt1 | |
8 | + { | |
9 | + pass clear | |
10 | + { | |
11 | + colour_value 0 1 0 1 | |
12 | + buffers colour | |
13 | + discard_only true | |
14 | + } | |
15 | + } | |
16 | + | |
17 | + //out 0 rt0 | |
18 | + out 0 rt1 | |
19 | +} | |
20 | + | |
1 | 21 | compositor_node DefaultFinalComposition |
2 | 22 | { |
3 | 23 | in 0 rtN |
@@ -526,11 +546,11 @@ | ||
526 | 546 | |
527 | 547 | compositor_node DynamicCubemapRenderingSkyboxNode0 |
528 | 548 | { |
529 | - //texture rt0 target_width target_height PF_R8G8B8 | |
530 | - in 0 rt_renderwindow | |
531 | - in 1 demo_dynamic_cubemap | |
549 | + texture rt0 target_width target_height PF_R8G8B8 | |
550 | + //in 0 rt_renderwindow | |
551 | + in 0 demo_dynamic_cubemap | |
532 | 552 | |
533 | - target rt_renderwindow | |
553 | + target rt0 | |
534 | 554 | { |
535 | 555 | pass clear |
536 | 556 | { |
@@ -565,16 +585,16 @@ | ||
565 | 585 | rq_first 2 |
566 | 586 | } |
567 | 587 | } |
568 | -// out 0 rt0 | |
588 | + out 0 rt0 | |
569 | 589 | } |
570 | 590 | |
571 | 591 | compositor_node DynamicCubemapRenderingSkyboxNode1 |
572 | 592 | { |
573 | - //texture rt0 target_width target_height PF_R8G8B8 | |
574 | - in 0 rt_renderwindow | |
575 | - in 1 demo_dynamic_cubemap | |
593 | + texture rt0 target_width target_height PF_R8G8B8 | |
594 | + //in 0 rt_renderwindow | |
595 | + in 0 demo_dynamic_cubemap | |
576 | 596 | |
577 | - target rt_renderwindow | |
597 | + target rt0 | |
578 | 598 | { |
579 | 599 | pass clear |
580 | 600 | { |
@@ -609,16 +629,16 @@ | ||
609 | 629 | rq_first 2 |
610 | 630 | } |
611 | 631 | } |
612 | -// out 0 rt0 | |
632 | + out 0 rt0 | |
613 | 633 | } |
614 | 634 | |
615 | 635 | compositor_node DynamicCubemapRenderingSkyboxNode2 |
616 | 636 | { |
617 | - //texture rt0 target_width target_height PF_R8G8B8 | |
618 | - in 0 rt_renderwindow | |
619 | - in 1 demo_dynamic_cubemap | |
637 | + texture rt0 target_width target_height PF_R8G8B8 | |
638 | + //in 0 rt_renderwindow | |
639 | + in 0 demo_dynamic_cubemap | |
620 | 640 | |
621 | - target rt_renderwindow | |
641 | + target rt0 | |
622 | 642 | { |
623 | 643 | pass clear |
624 | 644 | { |
@@ -653,16 +673,16 @@ | ||
653 | 673 | rq_first 2 |
654 | 674 | } |
655 | 675 | } |
656 | -// out 0 rt0 | |
676 | + out 0 rt0 | |
657 | 677 | } |
658 | 678 | |
659 | 679 | compositor_node DynamicCubemapRenderingSkyboxNode3 |
660 | 680 | { |
661 | - //texture rt0 target_width target_height PF_R8G8B8 | |
662 | - in 0 rt_renderwindow | |
663 | - in 1 demo_dynamic_cubemap | |
681 | + texture rt0 target_width target_height PF_R8G8B8 | |
682 | + //in 0 rt_renderwindow | |
683 | + in 0 demo_dynamic_cubemap | |
664 | 684 | |
665 | - target rt_renderwindow | |
685 | + target rt0 | |
666 | 686 | { |
667 | 687 | pass clear |
668 | 688 | { |
@@ -697,16 +717,16 @@ | ||
697 | 717 | rq_first 2 |
698 | 718 | } |
699 | 719 | } |
700 | -// out 0 rt0 | |
720 | + out 0 rt0 | |
701 | 721 | } |
702 | 722 | |
703 | 723 | compositor_node DynamicCubemapRenderingSkyboxNode4 |
704 | 724 | { |
705 | - //texture rt0 target_width target_height PF_R8G8B8 | |
706 | - in 0 rt_renderwindow | |
707 | - in 1 demo_dynamic_cubemap | |
725 | + texture rt0 target_width target_height PF_R8G8B8 | |
726 | + //in 0 rt_renderwindow | |
727 | + in 0 demo_dynamic_cubemap | |
708 | 728 | |
709 | - target rt_renderwindow | |
729 | + target rt0 | |
710 | 730 | { |
711 | 731 | pass clear |
712 | 732 | { |
@@ -741,16 +761,16 @@ | ||
741 | 761 | rq_first 2 |
742 | 762 | } |
743 | 763 | } |
744 | -// out 0 rt0 | |
764 | + out 0 rt0 | |
745 | 765 | } |
746 | 766 | |
747 | 767 | compositor_node DynamicCubemapRenderingSkyboxNode5 |
748 | 768 | { |
749 | - //texture rt0 target_width target_height PF_R8G8B8 | |
750 | - in 0 rt_renderwindow | |
751 | - in 1 demo_dynamic_cubemap | |
769 | + texture rt0 target_width target_height PF_R8G8B8 | |
770 | + //in 0 rt_renderwindow | |
771 | + in 0 demo_dynamic_cubemap | |
752 | 772 | |
753 | - target rt_renderwindow | |
773 | + target rt0 | |
754 | 774 | { |
755 | 775 | pass clear |
756 | 776 | { |
@@ -785,16 +805,16 @@ | ||
785 | 805 | rq_first 2 |
786 | 806 | } |
787 | 807 | } |
788 | -// out 0 rt0 | |
808 | + out 0 rt0 | |
789 | 809 | } |
790 | 810 | |
791 | 811 | compositor_node DynamicCubemapRenderingSkyboxNode6 |
792 | 812 | { |
793 | - //texture rt0 target_width target_height PF_R8G8B8 | |
794 | - in 0 rt_renderwindow | |
795 | - in 1 demo_dynamic_cubemap | |
813 | + texture rt0 target_width target_height PF_R8G8B8 | |
814 | + //in 0 rt_renderwindow | |
815 | + in 0 demo_dynamic_cubemap | |
796 | 816 | |
797 | - target rt_renderwindow | |
817 | + target rt0 | |
798 | 818 | { |
799 | 819 | pass clear |
800 | 820 | { |
@@ -829,16 +849,16 @@ | ||
829 | 849 | rq_first 2 |
830 | 850 | } |
831 | 851 | } |
832 | -// out 0 rt0 | |
852 | + out 0 rt0 | |
833 | 853 | } |
834 | 854 | |
835 | 855 | compositor_node DynamicCubemapRenderingSkyboxNode7 |
836 | 856 | { |
837 | - //texture rt0 target_width target_height PF_R8G8B8 | |
838 | - in 0 rt_renderwindow | |
839 | - in 1 demo_dynamic_cubemap | |
857 | + texture rt0 target_width target_height PF_R8G8B8 | |
858 | + //in 0 rt_renderwindow | |
859 | + in 0 demo_dynamic_cubemap | |
840 | 860 | |
841 | - target rt_renderwindow | |
861 | + target rt0 | |
842 | 862 | { |
843 | 863 | pass clear |
844 | 864 | { |
@@ -873,16 +893,16 @@ | ||
873 | 893 | rq_first 2 |
874 | 894 | } |
875 | 895 | } |
876 | -// out 0 rt0 | |
896 | + out 0 rt0 | |
877 | 897 | } |
878 | 898 | |
879 | 899 | compositor_node DynamicCubemapRenderingSkyboxNode8 |
880 | 900 | { |
881 | - //texture rt0 target_width target_height PF_R8G8B8 | |
882 | - in 0 rt_renderwindow | |
883 | - in 1 demo_dynamic_cubemap | |
901 | + texture rt0 target_width target_height PF_R8G8B8 | |
902 | + //in 0 rt_renderwindow | |
903 | + in 0 demo_dynamic_cubemap | |
884 | 904 | |
885 | - target rt_renderwindow | |
905 | + target rt0 | |
886 | 906 | { |
887 | 907 | pass clear |
888 | 908 | { |
@@ -917,7 +937,7 @@ | ||
917 | 937 | rq_first 2 |
918 | 938 | } |
919 | 939 | } |
920 | -// out 0 rt0 | |
940 | + out 0 rt0 | |
921 | 941 | } |
922 | 942 | |
923 | 943 | compositor_node SkyboxNode0 |
@@ -1282,115 +1302,117 @@ | ||
1282 | 1302 | |
1283 | 1303 | workspace SkyboxWorkspace0 |
1284 | 1304 | { |
1285 | -// connect SkyboxNode0 0 DefaultFinalComposition 0 | |
1286 | -// connect_output DefaultFinalComposition 1 | |
1287 | -// connect_output SkyboxNode0 0 | |
1305 | + //Cubemap on channel #1 | |
1306 | + connect_external 1 DynamicCubemapRenderingSkyboxNode0 0 | |
1307 | + | |
1308 | + connect DynamicCubemapRenderingSkyboxNode0 0 SmaaNode 0 | |
1309 | + connect SkyboxSMAA_RenderingNode 0 SmaaNode 1 | |
1288 | 1310 | |
1311 | + connect SmaaNode 0 DefaultFinalComposition 0 | |
1289 | 1312 | //Render Window on channel #0 |
1290 | - connect_external 0 DynamicCubemapRenderingSkyboxNode0 0 | |
1291 | - //Cubemap on channel #1 | |
1292 | - connect_external 1 DynamicCubemapRenderingSkyboxNode0 1 | |
1293 | -// connect DynamicCubemapRenderingSkyboxNode0 0 DefaultFinalComposition 0 | |
1294 | -// connect_output DefaultFinalComposition 1 | |
1313 | + connect_external 0 DefaultFinalComposition 1 | |
1295 | 1314 | } |
1296 | 1315 | |
1297 | 1316 | workspace SkyboxWorkspace1 |
1298 | 1317 | { |
1299 | -// connect SkyboxNode1 0 DefaultFinalComposition 0 | |
1300 | -// connect_output DefaultFinalComposition 1 | |
1318 | + //Cubemap on channel #1 | |
1319 | + connect_external 1 DynamicCubemapRenderingSkyboxNode1 0 | |
1320 | + | |
1321 | + connect DynamicCubemapRenderingSkyboxNode1 0 SmaaNode 0 | |
1322 | + connect SkyboxSMAA_RenderingNode 0 SmaaNode 1 | |
1301 | 1323 | |
1324 | + connect SmaaNode 0 DefaultFinalComposition 0 | |
1302 | 1325 | //Render Window on channel #0 |
1303 | - connect_external 0 DynamicCubemapRenderingSkyboxNode1 0 | |
1304 | - //Cubemap on channel #1 | |
1305 | - connect_external 1 DynamicCubemapRenderingSkyboxNode1 1 | |
1306 | -// connect DynamicCubemapRenderingSkyboxNode1 0 DefaultFinalComposition 0 | |
1307 | -// connect_output DefaultFinalComposition 1 | |
1326 | + connect_external 0 DefaultFinalComposition 1 | |
1308 | 1327 | } |
1309 | 1328 | |
1310 | 1329 | workspace SkyboxWorkspace2 |
1311 | 1330 | { |
1312 | - //Render Window on channel #0 | |
1313 | - connect_external 0 DynamicCubemapRenderingSkyboxNode2 0 | |
1314 | 1331 | //Cubemap on channel #1 |
1315 | - connect_external 1 DynamicCubemapRenderingSkyboxNode2 1 | |
1316 | -// connect DynamicCubemapRenderingSkyboxNode2 0 DefaultFinalComposition 0 | |
1317 | -// connect_output DefaultFinalComposition 1 | |
1332 | + connect_external 1 DynamicCubemapRenderingSkyboxNode2 0 | |
1333 | + | |
1334 | + connect DynamicCubemapRenderingSkyboxNode2 0 SmaaNode 0 | |
1335 | + connect SkyboxSMAA_RenderingNode 0 SmaaNode 1 | |
1336 | + | |
1337 | + connect SmaaNode 0 DefaultFinalComposition 0 | |
1338 | + //Render Window on channel #0 | |
1339 | + connect_external 0 DefaultFinalComposition 1 | |
1318 | 1340 | } |
1319 | 1341 | |
1320 | 1342 | workspace SkyboxWorkspace3 |
1321 | 1343 | { |
1322 | -// connect SkyboxNode3 0 DefaultFinalComposition 0 | |
1323 | -// connect_output DefaultFinalComposition 1 | |
1344 | + //Cubemap on channel #1 | |
1345 | + connect_external 1 DynamicCubemapRenderingSkyboxNode3 0 | |
1346 | + | |
1347 | + connect DynamicCubemapRenderingSkyboxNode3 0 SmaaNode 0 | |
1348 | + connect SkyboxSMAA_RenderingNode 0 SmaaNode 1 | |
1324 | 1349 | |
1350 | + connect SmaaNode 0 DefaultFinalComposition 0 | |
1325 | 1351 | //Render Window on channel #0 |
1326 | - connect_external 0 DynamicCubemapRenderingSkyboxNode3 0 | |
1327 | - //Cubemap on channel #1 | |
1328 | - connect_external 1 DynamicCubemapRenderingSkyboxNode3 1 | |
1329 | -// connect DynamicCubemapRenderingSkyboxNode3 0 DefaultFinalComposition 0 | |
1330 | -// connect_output DefaultFinalComposition 1 | |
1352 | + connect_external 0 DefaultFinalComposition 1 | |
1331 | 1353 | } |
1332 | 1354 | |
1333 | 1355 | workspace SkyboxWorkspace4 |
1334 | 1356 | { |
1335 | -// connect SkyboxNode4 0 DefaultFinalComposition 0 | |
1336 | -// connect_output DefaultFinalComposition 1 | |
1357 | + //Cubemap on channel #1 | |
1358 | + connect_external 1 DynamicCubemapRenderingSkyboxNode4 0 | |
1359 | + | |
1360 | + connect DynamicCubemapRenderingSkyboxNode4 0 SmaaNode 0 | |
1361 | + connect SkyboxSMAA_RenderingNode 0 SmaaNode 1 | |
1337 | 1362 | |
1363 | + connect SmaaNode 0 DefaultFinalComposition 0 | |
1338 | 1364 | //Render Window on channel #0 |
1339 | - connect_external 0 DynamicCubemapRenderingSkyboxNode4 0 | |
1340 | - //Cubemap on channel #1 | |
1341 | - connect_external 1 DynamicCubemapRenderingSkyboxNode4 1 | |
1342 | -// connect DynamicCubemapRenderingSkyboxNode4 0 DefaultFinalComposition 0 | |
1343 | -// connect_output DefaultFinalComposition 1 | |
1365 | + connect_external 0 DefaultFinalComposition 1 | |
1344 | 1366 | } |
1345 | 1367 | |
1346 | 1368 | workspace SkyboxWorkspace5 |
1347 | 1369 | { |
1348 | -// connect SkyboxNode5 0 DefaultFinalComposition 0 | |
1349 | -// connect_output DefaultFinalComposition 1 | |
1370 | + //Cubemap on channel #1 | |
1371 | + connect_external 1 DynamicCubemapRenderingSkyboxNode5 0 | |
1372 | + | |
1373 | + connect DynamicCubemapRenderingSkyboxNode5 0 SmaaNode 0 | |
1374 | + connect SkyboxSMAA_RenderingNode 0 SmaaNode 1 | |
1350 | 1375 | |
1376 | + connect SmaaNode 0 DefaultFinalComposition 0 | |
1351 | 1377 | //Render Window on channel #0 |
1352 | - connect_external 0 DynamicCubemapRenderingSkyboxNode5 0 | |
1353 | - //Cubemap on channel #1 | |
1354 | - connect_external 1 DynamicCubemapRenderingSkyboxNode5 1 | |
1355 | -// connect DynamicCubemapRenderingSkyboxNode5 0 DefaultFinalComposition 0 | |
1356 | -// connect_output DefaultFinalComposition 1 | |
1378 | + connect_external 0 DefaultFinalComposition 1 | |
1357 | 1379 | } |
1358 | 1380 | |
1359 | 1381 | workspace SkyboxWorkspace6 |
1360 | 1382 | { |
1361 | -// connect SkyboxNode6 0 DefaultFinalComposition 0 | |
1362 | -// connect_output DefaultFinalComposition 1 | |
1383 | + //Cubemap on channel #1 | |
1384 | + connect_external 1 DynamicCubemapRenderingSkyboxNode6 0 | |
1385 | + | |
1386 | + connect DynamicCubemapRenderingSkyboxNode6 0 SmaaNode 0 | |
1387 | + connect SkyboxSMAA_RenderingNode 0 SmaaNode 1 | |
1363 | 1388 | |
1389 | + connect SmaaNode 0 DefaultFinalComposition 0 | |
1364 | 1390 | //Render Window on channel #0 |
1365 | - connect_external 0 DynamicCubemapRenderingSkyboxNode6 0 | |
1366 | - //Cubemap on channel #1 | |
1367 | - connect_external 1 DynamicCubemapRenderingSkyboxNode6 1 | |
1368 | -// connect DynamicCubemapRenderingSkyboxNode6 0 DefaultFinalComposition 0 | |
1369 | -// connect_output DefaultFinalComposition 1 | |
1391 | + connect_external 0 DefaultFinalComposition 1 | |
1370 | 1392 | } |
1371 | 1393 | |
1372 | 1394 | workspace SkyboxWorkspace7 |
1373 | 1395 | { |
1374 | -// connect SkyboxNode7 0 DefaultFinalComposition 0 | |
1375 | -// connect_output DefaultFinalComposition 1 | |
1396 | + //Cubemap on channel #1 | |
1397 | + connect_external 1 DynamicCubemapRenderingSkyboxNode7 0 | |
1398 | + | |
1399 | + connect DynamicCubemapRenderingSkyboxNode7 0 SmaaNode 0 | |
1400 | + connect SkyboxSMAA_RenderingNode 0 SmaaNode 1 | |
1376 | 1401 | |
1402 | + connect SmaaNode 0 DefaultFinalComposition 0 | |
1377 | 1403 | //Render Window on channel #0 |
1378 | - connect_external 0 DynamicCubemapRenderingSkyboxNode7 0 | |
1379 | - //Cubemap on channel #1 | |
1380 | - connect_external 1 DynamicCubemapRenderingSkyboxNode7 1 | |
1381 | -// connect DynamicCubemapRenderingSkyboxNode7 0 DefaultFinalComposition 0 | |
1382 | -// connect_output DefaultFinalComposition 1 | |
1404 | + connect_external 0 DefaultFinalComposition 1 | |
1383 | 1405 | } |
1384 | 1406 | |
1385 | 1407 | workspace SkyboxWorkspace8 |
1386 | 1408 | { |
1387 | -// connect SkyboxNode8 0 DefaultFinalComposition 0 | |
1388 | -// connect_output DefaultFinalComposition 1 | |
1409 | + //Cubemap on channel #1 | |
1410 | + connect_external 1 DynamicCubemapRenderingSkyboxNode8 0 | |
1411 | + | |
1412 | + connect DynamicCubemapRenderingSkyboxNode8 0 SmaaNode 0 | |
1413 | + connect SkyboxSMAA_RenderingNode 0 SmaaNode 1 | |
1389 | 1414 | |
1415 | + connect SmaaNode 0 DefaultFinalComposition 0 | |
1390 | 1416 | //Render Window on channel #0 |
1391 | - connect_external 0 DynamicCubemapRenderingSkyboxNode8 0 | |
1392 | - //Cubemap on channel #1 | |
1393 | - connect_external 1 DynamicCubemapRenderingSkyboxNode8 1 | |
1394 | -// connect DynamicCubemapRenderingSkyboxNode8 0 DefaultFinalComposition 0 | |
1395 | -// connect_output DefaultFinalComposition 1 | |
1417 | + connect_external 0 DefaultFinalComposition 1 | |
1396 | 1418 | } |
@@ -8,6 +8,11 @@ | ||
8 | 8 | FileSystem=/2.0/scripts/materials/Common/GLSLES |
9 | 9 | FileSystem=/2.0/scripts/materials/Common/HLSL |
10 | 10 | FileSystem=/2.0/scripts/materials/Common/Metal |
11 | +FileSystem=/2.0/scripts/materials/Tutorial_SMAA | |
12 | +FileSystem=/2.0/scripts/materials/Tutorial_SMAA/GLSL | |
13 | +FileSystem=/2.0/scripts/materials/Tutorial_SMAA/HLSL | |
14 | +FileSystem=/2.0/scripts/materials/Tutorial_SMAA/Metal | |
15 | +FileSystem=/2.0/scripts/materials/Tutorial_SMAA/TutorialCompositorScript | |
11 | 16 | FileSystem=/2.0/scripts/Compositors |
12 | 17 | #FileSystem=/materials/programs/GLSL |
13 | 18 | #FileSystem=/materials/textures |