I've used the sample project (Screen Recording Example) and have tried changing the format of the GameRecorder object from Auto to MPEG-4 H264 on both the latest versions of Chrome and Firefox and both give the error of
'MediaRecorder': Failed to initialize native MediaRecorder the type provided (video/mp4) is not supported.
Doesn't make much sense because it's an option to select. Has anyone seen this work? Am I missing something?
Chrome supports MP4 and so does the newest Firefox.
The video encode formats depend on the browser, and you can see which are supported in the About dialog of Construct. Note browsers support different encode formats to decode formats - for example Chrome can decode MP4 but only supports encoding WebM. The default "Auto" option is a good default as it will use a format that works, and if you manually change it to an option that is not supported it will not work. You can also try recording a WebM video and use external video tools to transcode it to MP4.
Alright but what browsers DO support encoding to MP4?
So Chrome, Edge, and Firefox do not.
I tried with Safari and no luck either.
Develop games in your browser. Powerful, performant & highly capable.
I thought Safari did support it.
Either way, you can record a WebM video and convert it afterwards with a tool like ffmpeg or some of the free online services that can do video conversion.