On Sat, Dec 7, 2013 at 1:54 AM, iMath <redstone-c...@163.com> wrote:
>     fp=tempfile.NamedTemporaryFile(delete=False)
>     fp.write(("file '"+fileName1+"'\n").encode('utf-8'))
>     fp.write(("file '"+fileName2+"'\n").encode('utf-8'))
>
>
>     subprocess.call(['ffmpeg', '-f', 'concat','-i',fp.name, '-c',  'copy', 
> fileName])
>     fp.close()

You need to close the file before getting the other process to use it.
Otherwise, it may not be able to open the file at all, and even if it
can, you might find that not all the data has been written.

But congrats! You have successfully found the points I was directing
you to. Yes, I was hinting that you need NamedTemporaryFile, the .name
attribute, and delete=False. Good job!

ChrisA
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to