Video recording. ERROR:ENGINE: Unable to start recording (-2) (DEF-3825)

Why video recording can do not work? I’ve got error:

ERROR:ENGINE: Unable to start recording (-2)

But it works on empty new project.
Any ideas?

my guess is that you’re sending start_record to system on your Windows desktop and in your debug Windows build and getting this error in the console?

Is this on Windows/Linux/macOS?
In your project, do you use an app manifest?

I’m sending message:

msg.post("@system:", "start_record", { file_name = "test_rec.ivf" } )

I tried Win/Mac. Debug build and run from editor. I have custom render script. Is it related?
Any ideas what “-2” means?

-2 means an invalid parameter sent to the recording code. It could be the file_name being nil or the codec or container being wrong (we don’t allow you to specify these) BUT it can also be caused by width or height in game.project being 0 (unlikely) or not being a multiple of 8 (likely). Could you please check that the width and height specified in game.project is a multiple of 8?

Yes, this is not documented, which is bad. I’ll make sure that it gets documented!

4 Likes

Created DEF-3825. (We will also print a warning in the console).

3 Likes

Now it works!
Width in game.project was not a multiple of 8.

Thanx!

3 Likes

This was documented in 1.2.149 and it will now also print a console warning.

1 Like