Audio/video stream recording forums
|
Attention Visitor: |
You may have to register or log in before you can post:
|
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
trying to download a ts packet using command lineI would like to capture a TS packet using a command line method so that I can automate downloading the entire stream.
Here's an example packet from nbcolympics.com. It is a 5-second transport stream packet. http://r2---dfw06s22.c.youtube.com/v...es&file=seg.ts I can open this link in VLC player and it will play or let me save it to disk. I can also open it in a web browser and save it to disk. I cannot figure out any way to do it using command line. I tried to do it with VLC's command line options but it says it cannot be opened. Can anyone give me an example command line string, using any program, to do this? Last edited by wer783 : 08-22-2012 at 10:25 PM. |
#2
|
|||
|
|||
Re: trying to download a ts packet using command lineI've found no easy way to do this yet, but I haven't had a lot of time to put into it. As for getting all the 5-second file segments, a really easy way to do it is with Streaming Video Recorder (apowersoft), but it can't join the files. I've explained this challenge to their support and they say they're working on it and it will be in the next version.
VLC can play the entire folder of these crystal clear files, but there's a short pause at the end of each segment before the following one plays. Perhaps VLC has a way of exporting the playing of this sequential playlist to a file(?). |
#3
|
|||
|
|||
Re: trying to download a ts packet using command lineQuote:
|
#4
|
|||
|
|||
Re: trying to download a ts packet using command lineThanks for the information on Streaming Video Recorder. I tried it out and was able to get it to give me a bunch of pieces. The only problem is that it just grabs what is currently playing and so there's not any way to automate the process. So it's not any better than using ffmpeg to capture the stream by reading the m3u8 playlist file described in the big nbcolympics.com thread. But I like that program because I have been using GetFlv for a long time and thought it was the only game in town. It looks like this program will do similar things.
By the way, anyone reading this who just wants an easy way to capture videos from nbcolympics.com should see this thread: http://stream-recorder.com/forum/cap...om-t13287.html It's explained very well there and is easy to do. The only reason I'm trying to directly download each 5-second segment is that the connections will usually timeout before I can download an entire video. It usually takes a lot of tries to get the full video. Some of the longer ones, like the ones that are 7 hours long, I've been uanble to get. I've tried to use wget and VLC command line and they don't work, but it's really easy to download these segments if you just paste the link in VLC player or a web browser. But this would take forever and wouldn't be practical. deadmund seemed to have figured out how to download individual packets this with VLC player from a script, but has still not come back to explain. It seems like there should be some way to do this, given that it's so easy to do with a GUI. |
#5
|
|||
|
|||
Re: trying to download a ts packet using command lineQuote:
|
#6
|
|||
|
|||
Re: trying to download a ts packet using command lineQuote:
BTW, if I use ffmpeg to capture the file, is there a simple way to record a 4 hour video in 30 minute segments? |
#7
|
|||
|
|||
Re: trying to download a ts packet using command lineQuote:
•Start Firefox •Open web console (CTRL-SHIFT-K) •Optional - Unselect CSS, JS, & Logging on the menu bar •Type in "m3u8" in the filter on top right •Start the video you want to see •Click the gear icon on bottom right of video and select the quality you want (typically 1080) and you'll see a new m3u8 file appear •Use this URL for the "-i" option of ffmpeg The m3u8 file is a playlist that contains all those small files. Next, what you do is run this command, where URL is the m3u8 playlist file and output.ts is the name of the output video file: ffmpeg.exe -i URL -c copy output.ts |
#8
|
|||
|
|||
Re: trying to download a ts packet using command lineQuote:
|
#9
|
|||
|
|||
Re: trying to download a ts packet using command lineQuote:
If anyone has any ideas how to download each segment individually, I would still like to know how to do it. I have an idea which I haven't tried yet. Use a download manager. I haven't used one in a long time, not since I was using dial-up. I remember being able to use a pretty advanced download list with GetRight, so maybe it would work. The reason I want to get the segments individually is that you have the most options when you get the raw data. Since it's trivial to cat ts files together (just use a binary file combiner), there's no disadvantage to doing it this way, and if you have raw data you can fix problems. For example, in one stream on nbcolympics.com, there's some bad data that would easily be fixable but causes ffmpeg to make the audio go out of sync. I can fix this in the raw data files I've downloaded of that stream. And I'm not really doing this just to get the Olympics. I all ready have everything I really wanted from the Olympics. I assume I will be able to use what I find out in the future for other things. |
#10
|
|||
|
|||
Re: trying to download a ts packet using command lineQuote:
Just registered to say: Wow, that worked for me. I had to learn a bit about m3u syntax first in order to know exactly what to truncate in the modified m3u8 file, but after that it was smooth sailing. Saved the modified m3u8 to my hard drive and opened it in ffmpeg which started saving it right away. I'd previously used -ss and ffmpeg would go through the entire playlist before saving what I wanted, and by that time the link expired. Editing m3u8 is the way to go with really long videos. Thanks again! |
Tags: download |
Thread Tools | |
Display Modes | |
|
|