I'm trying to make a mask out of some footage i have.
Basically, i have a footage with many trees and i'm trying to make a day to night effect, i already have the color correction i like, but between the leaves you can see the clear sky.
I did a precomp with the footage, modify the curves to get a b&w result and ad a tin to it so the sky can be dark blue, almost black, but when i use that precomp as a track matte there's still a clear border around the leaves.
Do anyone have any idea how can i fix this? or how can i do this efect?
Depends on your screen calibration how this looks, but perhaps more in this direction. The key is to darker the highlight end with curves so that while the sky remains the lightest, even it is mid blue or below. If the sky is the only source of light, it will look quite natural. It is possible to add some lighting to the shadow areas with shadows/hilites adjustment to compensate if they go too dark. But shadows do go very dark at night and unless you have artificial lighting, this is quite realistic.