After Effects: How to do line animation on a moving camera
After more research I found the solution myself:

I created a null track layer from the camera tracker data, then a new shape layer. The shape layer then needs to be a 3D-layer and then linked to the null track layer. Once that was in place I was able to draw the path I needed and then animate it.