Animation nodes for geometry line art?
FreeStyle Edge Mark

Animation Nodes have a node Splines From Edges that takes a list of edges and vertices an returns splines that represents those edges. All we have to do is filter the edges by whether they are marked as freestyle or not. The blender API provide access to this data through the edge.use_freestyle_mark where it returns True if the edge is marked as a freestyle and False otherwise. To generate a boolean list of this property, we can use such list comprehension:

[e.use_freestyle_mark for e in object.data.edges]


Animation Nodes have a node Mask List which returns a filtered version of the input list if for each element its corresponding element in the input boolean List is True. So we can use the Mask List node to filter our edges based on the boolean list we generated before using such a node tree:



Edge Crease

The same workflow can be used, however, the boolean list used in filtering will change to be based on an angle threshold. Let us define the angle of the edge as the angle between the normals of the two faces the edge is part of, that, of course, fails for boundary edge that is part of only a single polygon. The problem reduces to finding the indices of the two polygons that each edge is part of. The internal structure of meshes in Blender stores loops which are vertices of polygons, something that you may remember from our study in this answer. A loop also corresponds to an edge that is part of the polygon as well as share the vertex that the loop represents in the polygon, you can study this from the Design Document of the Bmesh structure. So, loops can be used to identify which edges are in each polygon, but we want the inverse of that, we want a function that takes the edge and returns the polygons, this is something that we can solve by using a simple look up table. We can get the indices of the loops through polygon.loop_indices and we can get the index of the loop edge through loop.edge_index, you can study those form the API.The implementation is nested and not direct, so take your time to understand it.

We crate a list of n empty lists where n is the number of edges in the mesh, this can be done by the list comprehension [[] for _ in range(n)]. We will append the index of the polygon to those lists indicating that the polygon is composed of that edge. We will create two loops, the first loop iterates over the polygons and gets the indices of the loops it contains through polygon.loop_indices, that loop in turn hands the indices to another loop which gets the small initially empty list at each of the loop indices and append the polygon index to it, set the new list to the generic list and reassign the generic list. Notice that the polygon index is the loop (iterator) index of the upper loop. Also notice that to get the list after we appended it, we have to enable Output option for the input list:



Now that we have computed the look up table, we can loop over it, get the polygons, compute the angle between them using the dot product or the axis quaternion, if the angle is smaller than a threshold, append True and false otherwise, note that we have to check of the edge is a boundary or not as well. the implementation is simple, if the list contains two elements (It is not boundary) AND if the dot product between the two polygon normals at the two list indices is less than cosine some angle, return True and false otherwise:



Which if we used in filtering the edges, yields:



Blend file for study and practice:



Layering Filters

Layering filters is as easy as combing the boolean lists using what ever logic you want to use, for instance, if I want to use the edge mark OR the Crease, we can add the two boolean lists (Addition is OR in boolean algebra):



Sky is the limit when it comes to Animation Nodes.

External Contour

As for External Contour, a screen space processing might be your best option. For instance, construct a signed distance field in screen space and them march a spline starting from a known edges point, or use marching squares algorithm to polygonize it, project point on the surface and convert it into a spline. I don't have enough time to research the topic further, so i will leave it to you.