- Posts: 582
- Joined: Sun May 11, 2014 10:03 am
Text1.Output.OriginalWidth
Text1.Output.OriginalHeight
Those expressions would go in the Width and Height fields in the Format tab. Set Output Size to Custom to expose them.
- Code: Select all
{
Tools = ordered() {
Text1 = TextPlus {
Inputs = {
Width = Input { Value = 800, },
Height = Input { Value = 600, },
["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
Font = Input { Value = "Open Sans", },
StyledText = Input { Value = "This is TEXT", },
Style = Input { Value = "Bold", },
ManualFontKerningPlacement = Input {
Value = StyledText {
Array = {
},
Value = ""
},
},
},
ViewInfo = OperatorInfo { Pos = { 354, 85 } },
},
Polygon1 = PolylineMask {
DrawMode = "ClickAppend",
DrawMode2 = "InsertAndModify",
CtrlWZoom = false,
Inputs = {
OutputSize = Input { Value = FuID { "Custom" }, },
MaskWidth = Input {
Value = 1920,
Expression = "Text1.Output.OriginalWidth",
},
MaskHeight = Input {
Value = 1080,
Expression = "Text1.Output.OriginalHeight",
},
PixelAspect = Input { Value = { 1, 1 }, },
ClippingMode = Input { Value = FuID { "None" }, },
Polyline = Input {
SourceOp = "Polygon1Polyline",
Source = "Value",
},
Polyline2 = Input {
Value = Polyline {
},
Disabled = true,
},
},
ViewInfo = OperatorInfo { Pos = { 352, 132 } },
},
Polygon1Polyline = BezierSpline {
SplineColor = { Red = 173, Green = 255, Blue = 47 },
NameSet = true,
KeyFrames = {
[0] = { 0, Flags = { Linear = true, LockedY = true }, Value = Polyline {
} }
}
}
}
}
If you want to get the bounding box of the text inside the Text+, that's a little more involved. This thread has what you need:
viewtopic.php?f=22&t=72710&p=405140