PathGeometry is a class in the System.Windows.Media namespace. It represents a complex shape that may be composed of lines, arcs, points, polygons, etc. PathGeometry has several useful methods that can help in detecting overlap of shapes and overlapping areas. Also, it has methods for handling various operations necessary when working with odd shapes.
Questions tagged [pathgeometry]
126 questions
14
votes
7 answers
Get path geometry from image
If i have a logo, let's say done as a jpg or even a png. Any suggestion for how I can use that to define a path geometry? It would be really good if any suggestions could be provided for how i can do it in blend.
Thanks

Irwin
- 12,551
- 11
- 67
- 97
11
votes
1 answer
MatrixAnimationUsingPath animate on surroundings (outline) of path
i have a path data that i coppy it from syncfusion program.
i have a path with that data in my page and want to animate my object exact on path way (in mid of path line) but the problem is the object move on outline (surroundings ) of path .
here is…

Mamad RN
- 690
- 9
- 33
10
votes
1 answer
Combining multiple paths with different fills while still able to stretch uniformly
I'm trying to create a re-sizable drawing from a group of paths I've generated from Adobe Illustrator, but can't figure out how to make it re-sizable and maintain the fills. The original path data is:

user1017144
- 103
- 1
- 1
- 5
8
votes
2 answers
Path stroke algorithm (convert to triangles/quads) or other suggestions
Does anyone know a good algorithm for converting a vector path into a stroked path that is composed of triangle/quad faces? Ideally with round line joins.
Basically I am trying to draw a thick path that whose colour is based upon a value that varies…

Pete
- 4,784
- 26
- 33
8
votes
2 answers
Convert path to geometric shape
Hey everyone I have tried to sum up and come with the basic question and my idea which does not work so far :S
Basicly my question is:
The user adds elements together, and I want to create a new element based on these figures, such that a new path…

JTIM
- 2,774
- 1
- 34
- 74
7
votes
3 answers
WPF PathGeometry update is _SLOW_
In a WPF UI I have nodes connected by bezier paths, like so:
It might be... atomic http://nv3wrg.blu.livefilestore.com/y1pIGBd33lCC6lF-9H0MqgnL40BdNEoEemZDENzgpEI1IL2j4B-qb3qS3WlxMSys28IjqNngR7mdfvQBnPzerf4cFJQj9VqHBh4/acurve.png?psid=1
When the…

Robert Fraser
- 10,649
- 8
- 69
- 93
6
votes
1 answer
Cutting holes in PathGeometry
I have a PathGeometry defining some path like this one:
original path http://devblog.ailon.org/devblog/_stuff/wpfpathgeoquestion/original.gif
This is a simplified example. In reality it can have segments of any type (Line, Arc, Bezier).
Now I need…

Alan Mendelevich
- 3,591
- 4
- 32
- 50
6
votes
3 answers
Finding widest empty straight path through a set of point
I'm creating a simple game and come up with this problem while designing AI for my game:
Given a set of N points inside a rectangle in the Cartesian coordinate, i need to find the widest straight path through this rectangle. The path must be empty…

Chan Le
- 2,184
- 3
- 23
- 33
6
votes
3 answers
Algorithm to split self-intersected Path2D into several not self-intersected paths?
I need to get rid of self-intersections in a shape. Shape is constructed from an array of points, so all segments of that shape are lines. (only lines, no curves and arcs)
Previously, I tried to create Path2D from that points, construct an Area from…

Rogach
- 26,050
- 21
- 93
- 172
6
votes
1 answer
WP7 PathGeometry error
I'm having a strange error with a simple PathGeometry object and I can't seem to figure it out. I would appreciate it if someone could explain to me why this doesn't work.
Here is an example of a working Path, which draws a small triangle:

justin.m.chase
- 13,061
- 8
- 52
- 100
6
votes
2 answers
Is it possible to animate a PolyLineSegment in Silverlight, i.e. the PointCollection?
I'm clipping a Canvas I have with a diamond-shaped PolyLineSegment in a PathGeometry. I'm trying to animate the PointCollection of it though, and cannot seem to resolve the TargetProperty. This is the only other reference all of Google found that is…

Stan
- 746
- 1
- 17
- 35
6
votes
3 answers
Splitting a WPF PathGeometry into "tiles"
I have a rather large PathGeometry (over 100,000 points and stroked but not filled) to display for the user, but only a small portion of the path will be visible at any one time. To clarify, the path itself is not predetermined but will be created…

FTLPhysicsGuy
- 1,035
- 1
- 11
- 23
6
votes
1 answer
Geometry drawing in WPF
I'm kinda new to all this geometry part, but I can see it gives me the ability to draw basically whatever I want. I can't find a good manual that teaches how to create whatever image I have in my head. I really hoped to find some kinda painter that…

user1531186
- 323
- 1
- 7
- 20
6
votes
1 answer
WPF - Path/Geometry help - Strange shape
Anyone know a good way to create this object from Xaml? It also has to work at .5 Opacity when layered on top of other controls.
It also has to be resizable via Horizontal or Vertical Alignment.
I'm having some difficulty. The closest I get is…

jonathanpeppers
- 26,115
- 21
- 99
- 182
6
votes
1 answer
Is there a more efficient way to detect polygon overlap/intersection than PathGeometry.FillContainsWithDetail()?
I have a method that is gobbling up 25% of my cpu time. I call this method about 27,000 times per second. (Yup, lots of calls since it's updating frequently). I am wondering if anybody knows a faster way to detect if 2 polygons overlap. …

Curtis
- 5,794
- 8
- 50
- 77