Skip to content

Commit

Permalink
Add Depth output to Normal Map node
Browse files Browse the repository at this point in the history
  • Loading branch information
myaaaaaaaaa committed Nov 6, 2024
1 parent 5dbd41d commit daea7c1
Showing 1 changed file with 65 additions and 5 deletions.
70 changes: 65 additions & 5 deletions addons/material_maker/nodes/normal_map2.mmg
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,24 @@
"from_port": 0,
"to": "switch",
"to_port": 0
},
{
"from": "math",
"from_port": 0,
"to": "gen_outputs",
"to_port": 1
},
{
"from": "gen_inputs",
"from_port": 0,
"to": "math_2",
"to_port": 1
},
{
"from": "math_2",
"from_port": 0,
"to": "math",
"to_port": 0
}
],
"label": "Normal Map",
Expand Down Expand Up @@ -96,6 +114,10 @@
{
"node": "edge_detect_1",
"widget": "amount"
},
{
"node": "math",
"widget": "default_in2"
}
],
"longdesc": "The strength of the normal map filter",
Expand Down Expand Up @@ -137,8 +159,8 @@
{
"name": "gen_outputs",
"node_position": {
"x": -458.663818359375,
"y": 73.04736328125
"x": -414.663818,
"y": 77.047363
},
"parameters": {

Expand All @@ -148,8 +170,14 @@
"group_size": 0,
"longdesc": "Shows the generated normal map",
"name": "Normal",
"shortdesc": "Output",
"shortdesc": "Normal",
"type": "rgb"
},
{
"longdesc": "The corresponding depth map ready to be connected to the material",
"name": "Depth",
"shortdesc": "Depth",
"type": "f"
}
],
"seed": -6314,
Expand All @@ -158,8 +186,8 @@
{
"name": "gen_inputs",
"node_position": {
"x": -1147.91015625,
"y": 77.9473648071289
"x": -1119.910156,
"y": 81.047363
},
"parameters": {

Expand Down Expand Up @@ -336,6 +364,38 @@
},
"seed_int": 0,
"type": "ensure_greyscale"
},
{
"name": "math",
"node_position": {
"x": -581.165161,
"y": 334.908386
},
"parameters": {
"clamp": false,
"default_in1": 0,
"default_in2": 1,
"op": 2
},
"seed": 0,
"seed_locked": false,
"type": "math"
},
{
"name": "math_2",
"node_position": {
"x": -808.220703,
"y": 334.130615
},
"parameters": {
"clamp": false,
"default_in1": 1,
"default_in2": 1,
"op": 1
},
"seed": 0,
"seed_locked": false,
"type": "math"
}
],
"parameters": {
Expand Down

0 comments on commit daea7c1

Please sign in to comment.