Automatic creation of text-on-path graphic along complex paths
AssigneeAdobe Inc.
InventorsTarun Gehlaut, Siddharth Bhasin
Life of this patent
Estimating the term…
Abstract
A text-on-path graphic is automatically created from entered text and a drawn shape having a complex path. Shape boundary curves are identified from the shape. A set of overlapping boundary curves is determined from the shape boundary curves. The set of overlapping boundary curves is combined into a combined curve. The combined curve and the shape boundary curves outside the set are assigned to segments of the complex path. A cost for each ordered path through the segments is determined, where the cost of each ordered path is based on a distance to a next segment and a length of the next segment. The text-on-path graphic is then created from the text and the ordered path having the lowest cost.
Claims19
A computer-implemented method for generating a text-on-path graphic, comprising:
- receiving text from a user to appear along a compound path of an image;
- locating shape boundary curves from shapes within the image;
- determining a set of overlapping boundary curves from the shape boundary curves;
- combining the set of overlapping boundary curves into a combined curve;
- assigning the combined curve and the shape boundary curves outside the set to N segments of the compound path, where N is at least 2;
- determining N factorial distinct ordered paths through the segments, where each ordered path is a directed graph including the segments as nodes connected via edges having a direction;
- for each of the ordered paths,
- for each of the edges of the corresponding ordered path,
- determining an edge cost of the corresponding edge based on a distance to a next segment and a length of the next segment,
- summing the edge costs to generate a path cost;
- generating a text-on-path graphic from the text and flowing the text along the segments according to an order of the segments in the ordered path having the lowest path cost.
A computing system for generating a text-on-path graphic, the system comprising:
- a computer comprising a memory storing an application and a processor configured to execute the application,
- wherein the application includes a user interface for combining an image graphic with a textual graphic to form the text-on-path graphic,
- wherein the combining determines N segments from shapes within the image graphic, determines N factorial distinct ordered paths through the segments, selects an optimal one of the ordered paths from lengths of the segments and distances between source and destination pairs of the segments, generates flowed text by flowing text of the textual graphic along the segments ordered according to the selected ordered path, and generates the text-on-path graphic by replacing the shapes with the flowed text,
- where each ordered path is a directed graph including the segments as nodes connected via edges having a direction and N is at least 2,
- wherein the optimal one of the ordered paths has a lowest path cost among a plurality of path costs and determining of the path costs comprises:
- for each of the ordered paths,
- for each of the edges of the corresponding ordered path,
- determining an edge cost of the corresponding edge based on a distance to
- a next segment and a length of the next segment;
- and
- summing the edge costs to generate a corresponding one of the path costs.
A non-transitory computer readable medium for generating a text-on-path graphic comprises instructions that, when executed by at least one processor, cause a computing device to:
- for each of a plurality of shape boundary curves of an input image, determining whether the corresponding shape boundary curve is open or closed;
- adding each of the shape boundary curves determined to be open, to an array as a corresponding segment;
- for each of the shape boundary curves determined to be closed, determining whether the corresponding shape boundary curve is part of at least one group of shape boundary curves that intersect one another;
- adding each of the shape boundary curves determined to be closed and not part of the at least one group, to the array;
- for each group present, combining the shape boundary curves of the group into a single combined segment and adding the single combined segment to the array to form N segments, where N is at least 2;
- determining N factorial distinct ordered paths through the segments of the array, where each ordered path is a directed graph including the segments as nodes connected via edges having a direction and N is at least 2;
- and
- flowing text along the segments according to an order of the ordered path with a lowest path cost among a plurality of path costs and determining of the path costs comprises:
- for each of the ordered paths,
- for each of the edges of the corresponding ordered path,
- determining an edge cost of the corresponding edge based on a distance to a next segment and a length of the next segment;
- and
- summing the edge costs to generate a corresponding one of the path costs.
Dependencies are inferred from the claim text.