US 11,989,858 B2
Systems and methods of determining margins of an image for content insertion to form a composite image
Michael Sollami, Cambridge, MA (US); and Jessica Lundin, Bellevue, WA (US)
Assigned to Salesforce, Inc., San Francisco, CA (US)
Filed by Salesforce, Inc., San Francisco, CA (US)
Filed on Sep. 30, 2022, as Appl. No. 17/957,545.
Prior Publication US 2024/0112304 A1, Apr. 4, 2024
Int. Cl. G06T 5/50 (2006.01); G06T 7/13 (2017.01); G06V 10/46 (2022.01)
CPC G06T 5/50 (2013.01) [G06T 7/13 (2017.01); G06V 10/462 (2022.01); G06T 2207/20024 (2013.01); G06T 2207/20221 (2013.01)] 16 Claims
OG exemplary drawing
 
1. A method comprising:
removing, at a server, any alpha channel from an image, and downsampling the image with the removed alpha channel;
determining, at the server, a first upper bound of a x-direction frame margin of the downsampled image and a second upper bound for a y-direction frame margin of the downsampled image;
determining, at the server, saliency, edge detection, and gradient filters of the downsampled image, and generating a weighted grayscale image;
determining, at the server, a total value for each row and column of the weighted grayscale image, from a first side of the weighted grayscale image to the x-direction frame margin and from a second side of the weighted grayscale image to the y-direction frame margin;
applying, at the server, outlier filtering to the determined total values for each row and column of the weighted grayscale image, and determining a peak of pairwise ratios of consecutive values for left and right sides of the weighted grayscale image by setting a maximum value to be an x-margin, and determining a peak of pairwise ratios of consecutive values for top and bottom sides of the weighted grayscale image by setting a maximum value to be a y-margin; and
applying, at the server, content to the image based on the determined x-margin and y-margin values to form a composite image.