user34917: Quick summary of what I want to create with AE:
I have a drone shot and I want to add a realistic planet in the sky/horizon by using 3d Camera Tracker in After Effects.
What I want:
While flying past a wind turbine I want to create depth by showing the turbine in front of the planet in the horizon to create some kind of realistic depth.
The Problem:
Currently the planet in the horizon is in the foreground and covers the wind turbine and its moving rotos etc.
What I tried so far:
I know I have to use the masking tool but I am not sure about the order of the procedures of how to get to my results. I've created a mask and tried subtracting but this didn't go as expected. I also readjusted the mask shape and keyframed the mask path for the relevant frames where the turbine should be in the foreground. But this didn't go out as expeted.
Can someone please guide me through the the procedure to get to my final result?
I attached an image which shows the end result I want to achieve in my video:

Thank you

user34930: You need to add a copy of your video (so you have two layers, only the bottom one needs the planet on it). Rotoscope the top layer - when you create your mask the only thing you will see is the bit of video inside the mask, the blade in this case and it will sit above the planet because it is the top layer. If you use more than one mask you will need to set it/them to "Add".
You'll have to add 3d Camera Tracker only to the bottom video where the planet is. Also be aware that you only need to mask the areas that go over the planet when they go over the planet.

user4426: If the blades are rotating, and the camera is moving, you need to create a good foreground layer with anything the planet is supposed to be obscured by.
So from the image it looks like it will be obscured by the spinning rotors.
You need to find a good way to make a layer containing only the rotors.
You could make a mask and move it frame by frame, but if you have more than a few frames this method will take a long time.
You could try using a key - isolating your foreground based on hue (colour), brightness or saturation (how much colour is present).  The blades look like the whitest thing in the image, so this might work, but probably won't give you the result you're looking for...
Or you could rotoscope the blades.  This will take a while, but will probably give the best result. The new rotoscope v2 in the latest versions of After Effects is really amazing, and combined with some careful feathering / motion blur settings will probably work perfectly.  It will still take a while though.
To get the planet in the right position in the sky, you need to make a camera track of the scene, then place the planet as a 3D layer at the right distance and scale.

34917: <p>Quick summary of what I want to create with AE:
I have a drone shot and I want to add a realistic planet in the sky/horizon by using 3d Camera Tracker in After Effects.</p>
<p>What I want:
While flying past a wind turbine I want to create depth by showing the turbine in front of the planet in the horizon to create some kind of realistic depth.</p>
<p>The Problem:
Currently the planet in the horizon is in the foreground and covers the wind turbine and its moving rotos etc.</p>
<p>What I tried so far:
I know I have to use the masking tool but I am not sure about the order of the procedures of how to get to my results. I've created a mask and tried subtracting but this didn't go as expected. I also readjusted the mask shape and keyframed the mask path for the relevant frames where the turbine should be in the foreground. But this didn't go out as expeted.</p>
<p>Can someone please guide me through the the procedure to get to my final result?</p>
<p>I attached an image which shows the end result I want to achieve in my video:
<a href="https://i.stack.imgur.com/JNHKX.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/JNHKX.jpg" alt="One clearly can see that the rotors and the wind turbine are in the foreground and therfore creating some kind of realistic depth" /></a></p>
<p>Thank you</p>
 34930: <p>You need to add a copy of your video (so you have two layers, only the bottom one needs the planet on it). Rotoscope the top layer - when you create your mask the only thing you will see is the bit of video inside the mask, the blade in this case and it will sit above the planet because it is the top layer. If you use more than one mask you will need to set it/them to &quot;Add&quot;.</p>
<p>You'll have to add 3d Camera Tracker only to the bottom video where the planet is. Also be aware that you only need to mask the areas that go over the planet when they go over the planet.</p>
 4426: <p>If the blades are rotating, and the camera is moving, you need to create a good foreground layer with anything the planet is supposed to be obscured by.</p>
<p>So from the image it looks like it will be obscured by the spinning rotors.</p>
<p>You need to find a good way to make a layer containing only the rotors.</p>
<p>You could make a mask and move it frame by frame, but if you have more than a few frames this method will take a long time.</p>
<p>You could try using a key - isolating your foreground based on hue (colour), brightness or saturation (how much colour is present).  The blades look like the whitest thing in the image, so this might work, but probably won't give you the result you're looking for...</p>
<p>Or you could rotoscope the blades.  This will take a while, but will probably give the best result. <a href="https://www.youtube.com/watch?v=1nYs9RjxiFk" rel="nofollow noreferrer">The new rotoscope v2 in the latest versions of After Effects</a> is really amazing, and combined with some careful feathering / motion blur settings will probably work perfectly.  It will still take a while though.</p>
<p>To get the planet in the right position in the sky, you need to <a href="https://www.schoolofmotion.com/blog/how-to-use-camera-tracker-after-effects" rel="nofollow noreferrer">make a camera track of the scene</a>, then place the planet as a 3D layer at the right distance and scale.</p>
