Luma matte works inaccurate

Hi everyone. I tried to learn how to use luma matte and created a test project using a color and alpha video.

{
    "timeline": {
        "background": "#000000",
        "tracks": [
            {
                "clips": [
                    {
                        "asset": {
                            "type": "luma",
                            "src": "https://scfuntest.s3.amazonaws.com/alpha.mp4"
                        },
                        "position": "center",
                        "start": 0,
                        "fit": "crop",
                        "length": 15
                    },
                    {
                        "asset": {
                            "type": "video",
                            "src": "https://scfuntest.s3.amazonaws.com/color.mp4"
                        },
                        "position": "center",
                        "start": 0,
                        "fit": "crop",
                        "length": 15
                    }
                ]
            }
        ]
    },
    "output": {
        "format": "mp4",
        "size": {
            "width": 1080,
            "height": 1920
        },
        "quality": "high",
        "scaleTo": "mobile"
    }
}

I checked that frames of alpha and color video match perfectly, but in result video I see them unsynchronised.

Is there any way to make frames of both videos aligned?

Hi,
I had a quick look. I can see your source footage files are recorded at 30 frames per second (fps). The timeline default is however 25 fps. You can adjust the fps setting to match the source footage and then timing will be correct.

If you update your output JSON to look like this:

    "output": {
        "format": "mp4",
        "size": {
            "width": 1080,
            "height": 1920
        },
        "quality": "high",
        "scaleTo": "mobile",
        "fps": 30
    }

Then run the render again, it should show in time.

You need to invert your luma masks black and white to make the background transparent though.

1 Like