Converting uploaded videos to .flv and having them added to my website - ffmpeg

I plan to open a smaller and more specialised Youtube like site where users can upload their videos in a variety of formats and it will be converted to .FLV, and then posted on the website.
Most of the code I can handle myself, but I wanted to get some feedback on the uploading and converting stage of this. I'm planning to have the converting done on a separate server, independent of the one hosting the site. How would I go about converting the videos?
I checked out ffmpeg, would this be the best option to use? I want the videos in both high and low quality so it would be preferable to choose the bitrate.
Thanks.

Yes, ffmpeg would be the best option. It's simplest and most versatile.

Take a look at videopress.com - the video sharing service for wordpress.com. The entire solution is open source and uses ffmpeg to transcode video into multiple formats for embedding in websites.
You can access the code at http://code.trac.wordpress.org/
You should be able to either use this out of the box or customise if for your particular project.

You might also find something like Panda (http://pandastream.com) useful. It's an open source video encoding service.

Related

Stream a website to a mp4 (rendering html to a mp4)

I am trying to composite a website (which contains JavaScript and as a result is updating regularly) with a video feed. My goal is to do it on virtual hosted Linux server (my plan is to use Ubuntu, but I am flexible) - I am not interested in solutions utilizing OBS or the like as my solution would be headless.
The problem I am facing is how to output the website to a video stream from a command line.
The site I want to capture is https://vscore.ch/home and I would like to render it in a way that I can feed it to ffmpeg where I can composite it with the live game video that is being delivered via RTMP.
You may want to use this puppeteer plugin and stream those screenshots, or parse them into a video and stream that.

Application that Streams Videos from Local Cache - in Browser?

I've built a webapp to host low-res proxies of our teams video files. The webapp is primarily for tagging and searching video. Additionally, I'd like to be able to play a random playlist of clips on TVs around the office. I've implemented this by "Casting Tab" to a Chromecast, and it works fine.
However, now I'm running up against the bandwidth limitations of my host. Latency and everything is fine, but to run a single TV's 2.5Mbps stream 8hrs a day for 23 days a month comes to about 207 GB/month, 20% of my alotted 1TB monthly transfer.
How can i build something that will "cache" these clips client-side, so that it doesnt re-download them unnecessarily? There are about 1000 clips. I'd prefer to keep it connected to my webapp via browser or some API endpoint so the RAND() stream of clips is constantly updated as people add to it.
Note: I asked a related question yesterday, and it seemed to fix my specific issue, but it doesn't seem to have worked at scale, so I'm broadening the approach a bit. Browser Caching of images and videos served via php query strings
Shaka Player has built-in support for offline playback, along with a pretty good API for listing offline assets, and removing them again.
This would require that you have your videos in MPEG-DASH format. Luckily Google also has a tool available for that. Shaka Packager can take your mp4's and package them for MPEG-DASH, provided the MP4's follow some simple requirements.
You could probably build something yourself using similar mechanisms to the Shaka Player, but it seems much easier to use Shaka for doing it.

Cut MP3 file and set it as ringtone

I want to develop an WP7 application to cut/split an MP3 file from marked position. I tried looking for some API to split but no luck. I really appreciate if anybody can guide me on below points.
Is there any control available for WP7 to play and mark the MP3 file for splitting.
Is there any API to cut the selected portion in MP3 file.
Thanks
I am now aware of the Windows Phone lib for that, but...
Perhaps you could do it on a server because there are great MP3 C# libs available
Mp3Sharp
If you could get the mp3 to/from the server, it would be great. To play it on the device, use advice from another StackOverflow question. Enable selecting part of the song, send the info to the server which will then return you the cut mp3 file.
Sounds good to me, at least in theory. (you didn't post any code, so I guess we're just theorizing ;)

Real-time audio record/playback from a Ruby web app

I am wondering if anyone has success with audio record (from microphone on the users browser) and playback from a web based app (Ruby/RoR)?
What I have found so far - I could write a flex/flash app which will record the audio and then have a server side like Red5 or so to receive and convert. This sounds more involved and I also saw different types of hosting issues etc people are having - so I am thinking there may be better/easier solutions out there!! I looked at html5/web-kit too but seems to only works on chrome and is limited to text fields etc.
In my app, i want to record users voice, save it on a aws/s3 as mp3 or similar file format and play it back to user within the app based on users input/choice. While flash based solution is workable for now, non-flash based solution will be preferred as it will support more devices (you know devices I am referring)..
The only options for web based record are Flash, Silverlight or Java. None of these will work on an iPhone or iPad - You will need a native app for that.
You don't need to use Red5 for Flash recording - you can record direct to memory, optionally encode (or zip), and then upload the the data. You might be better doing mp3 encoding server-side using ffmpeg or SoX before moving the file to s3.
There is a way using HTML5 and a server. Just record a video.
Convert the video to audio, then use the audio as you wish.
This implementation takes audio from a video and runs
ffmpeg to extract the audio:
http://goo.gl/A0bya
This is in PHP, but it should not be too
hard to create a Ruby version. Easy peasy.

Hosting recommendations for technical screencasts

I am asking this question on SO because a similar question was asked here and migrated to SuperUser, but the answers it got there were more about screen sharing than hosting screencasts. I'm hoping that some of you have faced (and solved) this issue before...
My team is putting together a bunch of technical screencasts, and we are currently hosting them ourselves. We would much prefer to host them externally, to take advantage of a bigger pipe, geographically distributed data centers, and better uptime.
The screencasts are typically less than 10 minutes.
Is there a programmer-centric screencast hosting solution? Would you recommend YouTube? Vimeo? Something else?
Since Jon's answer two years ago, there have been a few additions to the screencast market:
Screencast.com, by TechSmith. The makers of Snagit, Camtasia, and Jing have a place where you can host your Screencasts at any resolution. It's not as straightforward as Screenr, but it provides you many options to upload your videos. You can upload by file or directly from Snagit 11, Jing (Free), or Camtasia.
YouTube and Vimeo (Pro) continue to be good options if you're looking for a hosting platform and they now both support a large range of HD formats as well as supporting HTML5. The drawback (or benefit?) is that your video is going to be converted to their playback resolution(s) rather than your source resolution. Snagit 11 will even upload directly to YouTube now.
Screencast.com seems like a good option if your main concern is recording screencasts on the fly and getting them uploaded quickly.
YouTube and Vimeo are probably better choices if you want your videos to be visible to the widest possible audience.
While Vimeo is more of a professional site, YouTube offers HTML5 / H.264 video playback support for all videos, so they'll play on iPhone. Vimeo currently doesn't support that on user videos, and is planning on adding it as a pro feature in the future.
If you are really concerned about 1-to-1 pixel resolution in your screencast, Vimeo Pro is not the best choice. My files had an exact 1920 to 1080 resolution and I exported them from Screenflow in "lossless". It appeared very crisp on the Mac in Quicktime Player, but after uploading to Vimeo Pro, turning HD "on", I could not read the details.
Vimeo is quick, but they have a compression good for movie scenes, but bad for small computer screen fonts. I am trying screencast.com since they leave the file "as is".
Personally, I prefer to see videos on something like Vimeo rather than YouTube or a similar site. Vimeo has a certain air of professionalism about it while still be convenient and user-friendly. Also, you can put embedded videos on your support pages if you wish or simply link to the videos in FAQs or forums. It makes it very convenient. Again though, this is just MHO.
A popular modern option is Wistia. They are more expensive than say Vimeo, but they have excellent tools for collecting emails and for analyzing how well your videos are doing. Basically they are hosting combined with video marketing.
I decided to go with them for my indie-hacker screencasts site.

Resources