Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #44884
| Date | 2013-05-07 08:10 -0400 |
|---|---|
| From | Dave Angel <davea@davea.name> |
| Subject | Re: use python to split a video file into a set of parts |
| References | <b42ca928-ec8d-4388-adc6-df48b246e275@googlegroups.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.1405.1367928940.3114.python-list@python.org> (permalink) |
On 05/07/2013 07:15 AM, iMath wrote: > I use the following python code to split a FLV video file into a set of parts ,when finished ,only the first part video can be played ,the other parts are corrupted.I wonder why and Is there some correct ways to split video files > There are two parts to answering the question. First, did it accurately chunk the file into separate pieces. That should be trivial to test -- simply concatenate them back together (eg. using copy /b) and make sure you get exactly the original. (using md5sum, for example) I think you will. And second, why the arbitrary pieces don't play in some unspecified video player. That one's more interesting, but hasn't anything to do with Python. I'm curious why you would expect that it would play. It won't have any of the header information, and the compressed data will be missing its context information. To split apart a binary file into useful pieces requires a lot of knowledge about the file format. -- DaveA
Back to comp.lang.python | Previous | Next — Previous in thread | Find similar | Unroll thread
use python to split a video file into a set of parts iMath <redstone-cold@163.com> - 2013-05-07 04:15 -0700 Re: use python to split a video file into a set of parts Chris Angelico <rosuav@gmail.com> - 2013-05-07 22:00 +1000 Re: use python to split a video file into a set of parts Dave Angel <davea@davea.name> - 2013-05-07 08:10 -0400
csiph-web