vc_auto not working for every video in library
Hello,
I have multiple videos that have been uploaded to my media library, and i'm fairly certain they have been uploaded the same way - using the reactjs uploadWidget. The problem I have is when playing them back with the videoCodec set to auto.
This clip:
https://res.cloudinary.com/thatwaspro/video/upload/v1607342470/V5wjGuKYqK28RIG4cpmc.mp4
will not play when using vc_auto in the URL:
https://res.cloudinary.com/thatwaspro/video/upload/vc_auto/V5wjGuKYqK28RIG4cpmc.mp4
However, this clip:
https://res.cloudinary.com/thatwaspro/video/upload/v1602559029/sAjty5oOzz04t18DNKmF.mp4
works fine when using vc_auto in the URL:
https://res.cloudinary.com/thatwaspro/video/upload/vc_auto/sAjty5oOzz04t18DNKmF.mp4
My understanding is that I should be using vc_auto for an overall better experience for end users, and from the tests I've run it seems to load a lot faster using this method. Why is this not working for every video in my library?
-
Hi Matthew,
In general, in order to help debug Cloudinary URLs, the response for failed requests includes a header called `X-Cld-Error` which provides more information on why the request was not successful. If you inspect the X-Cld-Error response to this example URL you'll see the following: "X-Cld-Error: Video is too large to process synchronously, please use an eager transformation with eager_async=true to resolve"
Cloudinary sets an 'online' video transformation limit of 40MB for Free plans and 100 MB for paid plans. This is not a limit on the size of videos you can upload into your account but is the maximum size of a video which can be transformed synchronously/on-the-fly.
For videos larger than this limit you must request that the derived versions are created before they're requested, which we call 'eagerly', and that the processing takes place in the background ('asynchronously'). When using asynchronous eager transformations you can manipulate videos as large as your account's maximum video file size limit.
Part of the reason that this limit exists is that transforming/transcoding large videos can take significantly longer than smaller videos and there can be a long delay before the first request for the video receives a response, and requests may time out before it finishes processing. if your application needs to know when the derived video is ready, you can use the 'eager_notification_url' parameter and we'll send a request to your server when the requested transformations have completed, and you can use this to update your system state and start using the newly transformed/derived video.
Eager transformations can be requested for new videos in the upload API call or configured in an upload preset, including an upload preset that is used when you upload to Media Library.
You can read more about eager transformations here: https://cloudinary.com/documentation/transformations_on_upload#eager_transformations
For existing videos, you can request eager transformations via the explicit API method: https://cloudinary.com/documentation/image_upload_api_reference#explicit_method
Once the video is transformed eagerly/asynchronously it will be available via the URL as normal.
Please let us know if this works for you.
Best,
Michal
0 -
Thanks for the detailed response!
0 -
You are welcome. Let us know if you have any further questions.
0 -
Hey, I have a related question now. I want to add an overlay image to all uploaded videos, and I also want to use the eager transformation as discussed previously. However, since adding the overlay transformation, I now get this message:
Here are the transformations I have listed in my upload preset. To my understanding, it should apply the overlay transformation before storing the media, and then it should eagerly create the auto video codec transformations afterwards? I have successfuly added the watermark image by just inserting the transformation into the url using '.../video/upload/l_watermark,w_300,g_north_east/...' so I'm pretty sure the overlay parameters are correct.
0 -
Hi,
In order to set the incoming transformation to be async, you will need to set the Async to True on the upload control. Here is a screenshot:
Hope that helps,
0
Post is closed for comments.
Comments
5 comments