8thwall/web

Remove MediaRecorder endCard

jimib opened this issue · 1 comments

jimib commented

I'm using the following configuration for the MediaRecorder:

XR8.MediaRecorder.configure({
    maxDurationMs: 5000,
    maxDimension : 1024,
    enableEndCard : false
 });

The settings for maxDurationMs and maxDimension are working, but the end card on the video is still being applied.

jimib commented

Figured it out. It's because I was using the XRExtras MediaPreview which has a default configuration setup included:

const currentConfig = {
enableEndCard: true,
footerImageUrl: 'https://cdn.8thwall.com/web/img/almostthere/v2/poweredby-horiz-white-2.svg',
}

I had to call to configure and overwrite the default options on the XRExtras as every time that called updateConfig it would override my existing options. This worked:

XR8.MediaRecorder.configure({
    maxDurationMs: 5000,
    maxDimension : 1024,
    enableEndCard : false
 });
XRExtras.MediaRecorder.configure({enableEndCard:false});
XRExtras.MediaRecorder.initMediaPreview();

I'm not going to close this as I feel that either the documentation needs updating, or the defaults in the XTExtras need updating to match those in the docs.