Extending DX11 GPU for programmable vector graphics
US-9330495-B2 · May 3, 2016 · US
US9619853B2 · US · B2
| Field | Value |
|---|---|
| Publication number | US-9619853-B2 |
| Application number | US-201313787363-A |
| Country | US |
| Kind code | B2 |
| Filing date | Mar 6, 2013 |
| Priority date | Aug 9, 2012 |
| Publication date | Apr 11, 2017 |
| Grant date | Apr 11, 2017 |
A practical reading order for non-experts. Skip the full description unless you need deep technical detail.
What the patent document calls the invention.
A short plain-language summary of the technical disclosure.
Who owns or filed the patent and who is credited as inventor.
Filing, priority, publication, and grant dates set the timeline.
The legal scope of protection — read this for what is actually claimed.
Technology tags used to group this patent with similar filings.
Prior art links and similar publications in this corpus.
Official abstract text for this publication.
This disclosure is directed to techniques for performing GPU-accelerated path rendering. A GPU is described that is configured to receive data indicative of a path segment of a path to be rendered, tessellate the path segment into a plurality of primitives, and render at least one of a fill area and a stroke area for the path segment based on the plurality of primitives. The techniques of this disclosure may be used to improve the performance of path rendering operations, to reduce memory bandwidth requirements needed to perform path rendering operations, and/or to reduce the memory footprint needed to perform path rendering operations.
Opening claim text (preview).
What is claimed is: 1. A method comprising: receiving, with a graphics processing unit (GPU), data indicative of a first path segment of a first path to be rendered and a second path segment of a second path to be rendered, the first path segment and the second path segment comprising respective two-dimensional vector graphics paths; tessellating, with the GPU, the first path segment into a first plurality of primitives and the second path segment into a second plurality of primitives; rendering, with the GPU, a fill area for the first path segment based on the first plurality of primitives, wherein the first plurality of primitives comprises a first plurality of line segments, and wherein rendering the fill area comprises: generating, with the GPU, a first plurality of triangle primitives based on the first plurality of line segments, each of the first plurality of triangle primitives being generated based on a respective one of the first plurality of line segments; rendering, with the GPU, each of the first plurality of triangle primitives into a common stencil buffer such that the common stencil buffer stores data indicative of which pixels are inside of the fill area for the first path segment; and rendering, with the GPU, one or more first primitives that encompass the pixels that are inside of the fill area based on the data stored in the common stencil buffer and a fill color to generate a rasterized version of the fill area for the first path segment; and rendering, with the GPU, a stroke area for the second path segment based on the second plurality of primitives comprises a second plurality of line segments, and wherein rendering the stroke area comprises: fattening, with a geometry shader of the GPU, the second plurality of line segments by shifting endpoints of the second plurality of line segments in positive and negative normal directions; generating, with the geometry shader of the GPU, a triangulation of the stroke area creating a second plurality of triangle primitives; and rendering, with the GPU, the second plurality of triangle primitives, wherein rendering comprises correcting overlapping portions of rendered second plurality of triangle primitives using a depth test, and the depth test configured to use data stored in the common stencil buffer without allocating a separate depth buffer. 2. The method of claim 1 , wherein tessellating the first path segment comprises tessellating the first path segment using a fixed-function tessellation engine of the GPU and a domain shader program executing on a shader unit of the GPU, and wherein generating the first plurality of triangle primitives comprises generating the first plurality of triangle primitives using a geometry shader program executing on a shader unit of the GPU. 3. The method of claim 2 , wherein generating the first plurality of triangle primitives comprises generating the first plurality of triangle primitives such that each of the first plurality of triangle primitives has a common vertex and two vertices that correspond to endpoints of a respective one of the first plurality of line segments. 4. The method of claim 3 , wherein rendering each of the first plurality of triangle primitives into the common stencil buffer comprises: for each of the first plurality of triangle primitives, inverting one or more values in the stencil buffer that correspond to the respective triangle primitive. 5. The method of claim 3 , wherein rendering each of the first plurality of triangle primitives into the common stencil buffer comprises: for each of the first plurality of triangle primitives, incrementing one or more values in the common stencil buffer that correspond to the respective triangle primitive if a vertex order for the respective triangle primitive is oriented in a clockwise direction; and for each of the first plurality of triangle primitives, decrementing one or more values in the common stencil buffer that correspond to the respective triangle primitive if the vertex order for the respective triangle primitive is oriented in a counter-clockwise direction. 6. The method of claim 1 , wherein rendering the stroke area comprises: for each of the second plurality of line segments, generating, with the GPU, one or more second primitives that spatially correspond to a stroke area for a respective line segment of the second plurality of line segments; and for each of the second plurality of line segments, rendering, with the GPU, the one or more primitives for the respective line segment of the second plurality of line segments based on a stroke color to generate a rasterized version of the stroke area for the second path segment. 7. The method of claim 6 , further comprising: tessellating the second path segment using a fixed-function tessellation engine of the GPU and a domain shader program executing on a shader unit of the GPU, wherein generating the second one or more primitives comprises generating the one or more second primitives using a geometry shader program executing on a shader unit of the GPU. 8. The method of claim 6 , wherein fattening the second plurality of line segments comprises: generating a plurality of normal vectors for the respective line segment, each of the normal vectors being indicative of a direction that is perpendicular to a tangent of the path segment at a respective one of a plurality of points along the path segment, each of the plurality of points along the path segment corresponding to a respective one of the endpoints of the respective line segment; determining corner points of a stroke area for the respective line segment based on the plurality of normal vectors and a stroke width; and generating the one or more primitives that spatially correspond to the stroke area for the respective line segment based on the corner points of the stroke area. 9. The method of claim 1 , wherein tessellating the first path segment into the first plurality of primitives and the second path segment into a second plurality of primitives comprises determining a center of an ellipse of the first path segment or the second path segment when the first path segment or the second path segment comprises an elliptic arc. 10. The method of claim 1 , wherein rendering the stroke area for the second path segment further comprises: generating, by the geometry shader with the GPU, a join or an endcap on an end of the second path segment. 11. A device comprising: a memory; a graphics processing unit (GPU) configured to receive data from the memory indicative of a first path segment of a first path to be rendered and a second path segment of a second path to be rendered, the first path segment and the second path segment comprising respective two-dimensional vector graphics paths, tessellate the first path segment into a first plurality of primitives and the second path segment into a second plurality of primitives, render a fill area for the first path segment based on the first plurality of primitives, wherein the first plurality of primitives comprises a first plurality of line segments, and wherein the GPU is further configured to: generate a plurality of first triangle primitives based on the first plurality of line segments, each of the first plurality of triangle primitives being generated based on a respective one of the first plurality of line segments; render each of the first plurality of triangle primitives into a common stencil buffer such that the common stencil buffer stores data indicative of which pixels are inside of the fill area for the first path segment; render one or more first primitives that encompass the pixels that are inside of the fill area based on the data store
Related publications grouped by family.
Answers are generated from the same data shown on this page.