- Posts: 22
- Joined: Sun Apr 30, 2017 10:46 am
Hey Dan - I don't know of such an easy way as in Nuke, but a workaround you can apply is by using a Simple Expression to size the ImagePlane3D depending on the z-distance. See example below (play around with the Z-offset in the Transform3D, and see how it automatically resizes the plane to the right size). I set this up by initially placing the Imageplane at a certain distance, then changed the scale to fit it perfectly (by using the perspective view on the merge3D). I then used the resulting scale value (1.66) in an expression to automatically link it.
Downside is of course that when you change the camera's angle of view/focal length etc it would stop working (you'd need to adjust the expression). Having said that, it should be relatively straightforward to incorporate the focal length in the simple expression too.
Oh, and btw, this one also assumes that the camera remains at position 0,0,0
- Code: Select all
{
Tools = ordered() {
FastNoise1 = FastNoise {
Inputs = {
Width = Input { Value = 1920, },
Height = Input { Value = 1080, },
["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
},
ViewInfo = OperatorInfo { Pos = { 55, 16.5 } },
},
ImagePlane3D1 = ImagePlane3D {
Inputs = {
["SurfacePlaneInputs.ObjectID.ObjectID"] = Input { Value = 1, },
MaterialInput = Input {
SourceOp = "FastNoise1",
Source = "Output",
},
["MtlStdInputs.MaterialID"] = Input { Value = 1, },
},
ViewInfo = OperatorInfo { Pos = { 165, 16.5 } },
},
Transform3D1 = Transform3D {
CtrlWZoom = false,
Inputs = {
SceneInput = Input {
SourceOp = "ImagePlane3D1",
Source = "Output",
},
["Transform3DOp.Translate.Z"] = Input { Value = -2.14, },
["Transform3DOp.Scale.X"] = Input {
Value = 1.28915662650602,
Expression = "-Transform3DOp.Translate.Z/1.66",
},
},
ViewInfo = OperatorInfo { Pos = { 275, 16.5 } },
},
Merge3D1 = Merge3D {
Inputs = {
SceneInput1 = Input {
SourceOp = "Transform3D1",
Source = "Output",
},
SceneInput2 = Input {
SourceOp = "Camera3D1",
Source = "Output",
},
},
ViewInfo = OperatorInfo { Pos = { 440, 16.5 } },
},
Camera3D1 = Camera3D {
Inputs = {
AoV = Input { Value = 19.2642683071402, },
["Stereo.Mode"] = Input { Value = FuID { "Mono" }, },
FilmGate = Input { Value = FuID { "BMD_URSA_4K_16x9" }, },
ApertureW = Input { Value = 0.831496062992126, },
ApertureH = Input { Value = 0.467716535433071, },
["SurfacePlaneInputs.ObjectID.ObjectID"] = Input { Value = 2, },
["MtlStdInputs.MaterialID"] = Input { Value = 2, },
},
ViewInfo = OperatorInfo { Pos = { 440, 247.5 } },
}
}
}