In light of the Coronavirus crisis, please help make sure nothing stands in the way of social distancing in the VFX industry.

This petition asks the MPAA to act accordingly:


Sign the petition on Change.org

Be safe, everyone.

How do I add borders in Fusion?

User avatar
morrisondoll
Posts: 16
Joined: Mon Oct 14, 2019 12:25 pm
Answers: 1
Real name: Israel Trejo

How do I add borders in Fusion?

#1

Post by morrisondoll » Wed Mar 25, 2020 4:03 pm

Hi!

I am trying to add borders in an element in a composition and color it.
I don't know if it is possible using Fusion to do this

The result that I am searching is like this:
Original
Screen Shot 2020-03-25 at 5.00.47 PM.png
Expected Result
Screen Shot 2020-03-25 at 12.51.32 PM.png

I appreciate your help and collaboration.

Thanks!! :D :D
by Midgardsormr » Wed Mar 25, 2020 4:38 pm
There are a couple ways. Probably the simplest is to use the Filter tool in Sobel mode and convert it into a mask. Here's an example:

Code: Select all

{
	Tools = ordered() {
		Wand1 = WandMask {
			Inputs = {
				Filter = Input { Value = FuID { "Fast Gaussian" }, },
				MaskWidth = Input { Value = 1920, },
				MaskHeight = Input { Value = 1080, },
				PixelAspect = Input { Value = { 1, 1 }, },
				ClippingMode = Input { Value = FuID { "None" }, },
				Source = Input {
					SourceOp = "Loader1",
					Source = "Output",
				},
				SelectionPoint = Input { Value = { 0.808093994778068, 0.731678486997636 }, },
				Range = Input { Value = 0.646, },
			},
			ViewInfo = OperatorInfo { Pos = { 275, 148.5 } },
		},
		Filter1 = Filter {
			Inputs = {
				FilterType = Input { Value = 3, },
				Input = Input {
					SourceOp = "MatteControl1",
					Source = "Output",
				},
			},
			ViewInfo = OperatorInfo { Pos = { 440, 115.5 } },
		},
		MatteControl1 = MatteControl {
			Inputs = {
				Filter = Input { Value = FuID { "Fast Gaussian" }, },
				["Garbage.Matte"] = Input {
					SourceOp = "Wand1",
					Source = "Mask",
				},
				Background = Input {
					SourceOp = "Loader1",
					Source = "Output",
				},
			},
			ViewInfo = OperatorInfo { Pos = { 275, 181.5 } },
		},
		ErodeDilate1 = ErodeDilate {
			CtrlWZoom = false,
			Inputs = {
				Filter = Input { Value = 3, },
				XAmount = Input { Value = 0.0067, },
				Input = Input {
					SourceOp = "Filter1",
					Source = "Output",
				},
			},
			ViewInfo = OperatorInfo { Pos = { 550, 115.5 } },
		},
		Merge1 = Merge {
			Inputs = {
				Background = Input {
					SourceOp = "Background1",
					Source = "Output",
				},
				Foreground = Input {
					SourceOp = "MatteControl1",
					Source = "Output",
				},
				PerformDepthMerge = Input { Value = 0, },
			},
			ViewInfo = OperatorInfo { Pos = { 550, 181.5 } },
		},
		Background1 = Background {
			Inputs = {
				Width = Input { Value = 383, },
				Height = Input { Value = 423, },
				["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
				TopLeftRed = Input { Value = 0.164624, },
				TopLeftGreen = Input { Value = 1, },
				TopLeftBlue = Input { Value = 0.042, },
				EffectMask = Input {
					SourceOp = "ErodeDilate1",
					Source = "Output",
				}
			},
			ViewInfo = OperatorInfo { Pos = { 550, 148.5 } },
		},
		Merge2 = Merge {
			Inputs = {
				Background = Input {
					SourceOp = "Loader1",
					Source = "Output",
				},
				Foreground = Input {
					SourceOp = "Merge1",
					Source = "Output",
				},
				PerformDepthMerge = Input { Value = 0, },
			},
			ViewInfo = OperatorInfo { Pos = { 550, 214.5 } },
		},
		Loader1 = Loader {
			Clips = {
				Clip {
					ID = "Clip1",
					Filename = "C:\\Users\\Bryan\\Desktop\\Screen Shot 2020-03-25 at 5.00.47 PM.png",
					FormatID = "PNGFormat",
					StartFrame = -1,
					LengthSetManually = true,
					TrimIn = 0,
					TrimOut = 0,
					ExtendFirst = 0,
					ExtendLast = 0,
					Loop = 0,
					AspectMode = 0,
					Depth = 0,
					TimeCode = 0,
					GlobalStart = 0,
					GlobalEnd = 0
				}
			},
			Inputs = {
				["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
				["Clip1.PNGFormat.PostMultiply"] = Input { Value = 1, },
			},
			ViewInfo = OperatorInfo { Pos = { 110, 214.5 } },
		}
	}
}
You can control the thickness of the outline with the Erode/Dilate tool. The Wand and MatteControl wouldn't be necessary if your graphic has an alpha channel to start with.
Go to full post
You do not have the required permissions to view the files attached to this post.

User avatar
Midgardsormr
Fusionator
Posts: 1591
Joined: Wed Nov 26, 2014 8:04 pm
Answers: 11
Location: Los Angeles, CA, USA
Been thanked: 51 times
Contact:

Re: How do I add borders in Fusion?

#2

Post by Midgardsormr » Wed Mar 25, 2020 4:38 pm

There are a couple ways. Probably the simplest is to use the Filter tool in Sobel mode and convert it into a mask. Here's an example:

Code: Select all

{
	Tools = ordered() {
		Wand1 = WandMask {
			Inputs = {
				Filter = Input { Value = FuID { "Fast Gaussian" }, },
				MaskWidth = Input { Value = 1920, },
				MaskHeight = Input { Value = 1080, },
				PixelAspect = Input { Value = { 1, 1 }, },
				ClippingMode = Input { Value = FuID { "None" }, },
				Source = Input {
					SourceOp = "Loader1",
					Source = "Output",
				},
				SelectionPoint = Input { Value = { 0.808093994778068, 0.731678486997636 }, },
				Range = Input { Value = 0.646, },
			},
			ViewInfo = OperatorInfo { Pos = { 275, 148.5 } },
		},
		Filter1 = Filter {
			Inputs = {
				FilterType = Input { Value = 3, },
				Input = Input {
					SourceOp = "MatteControl1",
					Source = "Output",
				},
			},
			ViewInfo = OperatorInfo { Pos = { 440, 115.5 } },
		},
		MatteControl1 = MatteControl {
			Inputs = {
				Filter = Input { Value = FuID { "Fast Gaussian" }, },
				["Garbage.Matte"] = Input {
					SourceOp = "Wand1",
					Source = "Mask",
				},
				Background = Input {
					SourceOp = "Loader1",
					Source = "Output",
				},
			},
			ViewInfo = OperatorInfo { Pos = { 275, 181.5 } },
		},
		ErodeDilate1 = ErodeDilate {
			CtrlWZoom = false,
			Inputs = {
				Filter = Input { Value = 3, },
				XAmount = Input { Value = 0.0067, },
				Input = Input {
					SourceOp = "Filter1",
					Source = "Output",
				},
			},
			ViewInfo = OperatorInfo { Pos = { 550, 115.5 } },
		},
		Merge1 = Merge {
			Inputs = {
				Background = Input {
					SourceOp = "Background1",
					Source = "Output",
				},
				Foreground = Input {
					SourceOp = "MatteControl1",
					Source = "Output",
				},
				PerformDepthMerge = Input { Value = 0, },
			},
			ViewInfo = OperatorInfo { Pos = { 550, 181.5 } },
		},
		Background1 = Background {
			Inputs = {
				Width = Input { Value = 383, },
				Height = Input { Value = 423, },
				["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
				TopLeftRed = Input { Value = 0.164624, },
				TopLeftGreen = Input { Value = 1, },
				TopLeftBlue = Input { Value = 0.042, },
				EffectMask = Input {
					SourceOp = "ErodeDilate1",
					Source = "Output",
				}
			},
			ViewInfo = OperatorInfo { Pos = { 550, 148.5 } },
		},
		Merge2 = Merge {
			Inputs = {
				Background = Input {
					SourceOp = "Loader1",
					Source = "Output",
				},
				Foreground = Input {
					SourceOp = "Merge1",
					Source = "Output",
				},
				PerformDepthMerge = Input { Value = 0, },
			},
			ViewInfo = OperatorInfo { Pos = { 550, 214.5 } },
		},
		Loader1 = Loader {
			Clips = {
				Clip {
					ID = "Clip1",
					Filename = "C:\\Users\\Bryan\\Desktop\\Screen Shot 2020-03-25 at 5.00.47 PM.png",
					FormatID = "PNGFormat",
					StartFrame = -1,
					LengthSetManually = true,
					TrimIn = 0,
					TrimOut = 0,
					ExtendFirst = 0,
					ExtendLast = 0,
					Loop = 0,
					AspectMode = 0,
					Depth = 0,
					TimeCode = 0,
					GlobalStart = 0,
					GlobalEnd = 0
				}
			},
			Inputs = {
				["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
				["Clip1.PNGFormat.PostMultiply"] = Input { Value = 1, },
			},
			ViewInfo = OperatorInfo { Pos = { 110, 214.5 } },
		}
	}
}
You can control the thickness of the outline with the Erode/Dilate tool. The Wand and MatteControl wouldn't be necessary if your graphic has an alpha channel to start with.

User avatar
morrisondoll
Posts: 16
Joined: Mon Oct 14, 2019 12:25 pm
Answers: 1
Real name: Israel Trejo

Re: How do I add borders in Fusion?

#3

Post by morrisondoll » Thu Mar 26, 2020 10:50 am

I will test the example, thanks!!!!

Added in 8 minutes 43 seconds:
Great!!! The filter with sobel and mask is the perfect thing!!! Thank you very much!!!!!