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 |
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.
|