Archived from the Transloadit support forum. Originally posted on January 7, 2011; details may be outdated, see our docs for current behavior. Original thread
Love the service and I can’t wait to ramp this up for our new web app.
But a critical obstacle I’m facing right now is that I can’t seem to get a video to play after I’ve uploaded it to s3 using transloadit. I’ve tried with and without the video encode robot, to no avail. The file uploads great (in terms of speed) but the resulting file looks like this when I try to play it in a browser
I figured out that the issue is likely that I uploaded a video files with mov extension but were actually inside an mp4 wrapper. The files were created with screen flow and wrapped in mp4 so they would stream faster. Seems that Transloadit was adding a mime header of mp4. I changed the template to force an mov QuickTime header and it worked. This solution is not ideal for our production site… So I am wondering if there is a way this could be fixed, either on your side or using templates. thanks.
When I do a test, it uploads and plays in the flowplayer player, but going to the url directly in a browser doesn’t permit the file to play in the browser.
In the results of the assembly is
[ext] => mov
[size] => 4332285
[mime] => video/mp4
So you see the ext and the mime don’t match. Transloadit correctly sees that the video is wrapped inside an mp4 “container” for fast playing, but for some reason setting this mime in the headers prevents the video from playing through the browser (s3 url directly).
When I upload using basic s3 tools (s3 hub, cyberduck, etc) there are no such issues.
While we plan on playing these videos through a player off our server, it still seems like it might be a bug.
Well, technically “mp4” uses the same container format as “mov”, but is more specific about certain aspects (such as putting the meta information in the beginning of the file to allow streaming).
However, it seems that Firefox is essentially clueless about “video/mp4”, so it pretends to be unable to play the file. This is foremost a bug / missing feature in Firefox, but of course we need to work around it.
So I think what we can try to do, is to teach the storage robots that to use the “mov” mimetype, even if the file is technically “mp4”. This should work across all browsers.
Yes, I think that would work. When we manually force quicktime/mov in the mime using a special template, it works. It still streams like an mp4 by not waiting for the entire video to download before play begins.
More info. The following works:
Uploading mp4 extension to s3 using other tools, it plays in Firefox
Uploading mov extension with mp4 wrapper, it plays in Firefox
Uploading mov extension with no mp4 wrapper, it plays in Firefox
I have no idea why Screenflow doesn’t change the extension of mp4 wrapped mov’s to .mp4
If we weren’t using Transloadit to build a video serving platform that the public uses, I would just change our workflow or use a custom template. But we don’t want to face the same question from a client that is expecting the videos to play from a browser “normally”
Thanks.
PS - I decide to use Live Headers extension for Firefox to see what’s being sent when I hit a .mov video file that has the mp4 wrapper for fast streaming. Here’s the header info: