collab-project / videojs-record

video.js plugin for recording audio/video/image files
https://collab-project.github.io/videojs-record
MIT License
1.38k stars 312 forks source link

Output blob size is 0 on IPhone - Chrome when recording a Video #646

Open aruljayaraj opened 2 years ago

aruljayaraj commented 2 years ago

Description

I would like to record video on Chrome using iPhone 13, the output blob for video has no data. Output video blob is 0 MB.

Steps to reproduce

Pls, open this below link in the iPhone chrome browser.

https://codesandbox.io/s/zhde4?file=/src/App.js:978-987

  1. Click on the Video Icon to record, if it asks permission give that.
  2. Start recording
  3. Stop recording. You will see the "Media could not be loaded, either because the server or network failed or because the format is not supported"
  4. You can see the results with 0 bytes on the console.

Results

Refer to the screenshot for the error

WhatsApp Image 2022-04-14 at 4 58 19 PM

Expected

    `{stream: Blob,
      lastModified: 1649934483285,
      lastModifiedDate: Thu Apr 14 2022 16:38:03 GMT+0530 (India Standard Time),
      name: "1649934483285.mkv",
      size: 263257,
      type: "video/x-matroska;codecs=avc1",
      arrayBuffer: ƒ arrayBuffer() {},
      slice: ƒ slice() {},
      stream: ƒ stream() {},
      text: ƒ text() {},
    <constructor>: "Blob"}`

Actual

It's working on iPhone Safari. Mac Chrome and Firefox also working fine.

versions

IPhone 13 - 15.4 Chrome - 100.0.4896.77

videojs

videojs-record - 4.5.0

browsers

iPhone Chrome

OSes

IOS

faizanumer commented 2 years ago

Any update on this? I'm having the same issue.

aruljayaraj commented 2 years ago

@faizanumer No update yet.

pork1977 commented 2 years ago

Not that I have much to add to this, I just wanted to say that I've also been struggling with this recently. Like @aruljayaraj aruljayaraj says, it only seems to be Chrome iOS affected, Safari works beautifully and I'm always seeing a 0 bytes file generated. The "finishRecord" event triggers and I'm not seeing any errors. Currently using v4.5.0 of videojs record (and latest on the main videojs). When you start to record, you can see the camera start up and it records fine. When you stop it recording, nothing displays in teh recorder because of the completed file can't be generated. Does anyone have any clues on why it might be happening? Where in the code it's failing? is it somethign to do with the way the code is trying to generate the file or perhaps to do with RecordRTC?

Pastorsin commented 1 year ago

Hi, any update on this? I have the same problem

omarcs commented 1 year ago

Any update on this? I have the exact same problem, I have tested with several codecs and plugins, but result is always 0 bytes in video blob

mamerbloovo commented 4 months ago

Any update on this?

AoutoCooper commented 3 months ago

any update on this? same on audio record

thijstriemstra commented 3 months ago

it's bizarre to me people keep adding this "any update on this" when there's clearly no update. please stop, ty.

AoutoCooper commented 3 months ago

it's bizarre to me people keep adding this "any update on this" when there's clearly no update. please stop, ty.

is there any update on this?