> On 26 Jun 2016, at 4:58 PM, Sandor Szatmari
> wrote:
>
> You can either asynchronously monitor the task's output with notifications,
> or I have read about a new API, but never used it,
> -setReadabilityHandler:^(NSFileHandle* file)
>
> Sandor
>
Thanks!
I was able to set a readability
Graham,
> On Jun 26, 2016, at 01:29, Graham Cox wrote:
>
>
>> On 26 Jun 2016, at 3:22 PM, dangerwillrobinsondan...@gmail.com wrote:
>>
>> If it helps, you can think of it as an object oriented wrapped around C
>> system calls that keeps track of PID and all the other bits like stdout and
>>
Graham,
> On Jun 25, 2016, at 23:37, Graham Cox wrote:
>
> HI all,
>
> I am using NSTask to wrap ffmpeg, the video conversion utility.
>
> I am able to invoke ffmpeg alright, but it’s unclear how the argument list
> should be passed through NSTask. I tried making my various arguments into one
> On 26 Jun 2016, at 3:22 PM, dangerwillrobinsondan...@gmail.com wrote:
>
> If it helps, you can think of it as an object oriented wrapped around C
> system calls that keeps track of PID and all the other bits like stdout and
> so on.
> That helps to grok why the args is and array and the too
If it helps, you can think of it as an object oriented wrapped around C system
calls that keeps track of PID and all the other bits like stdout and so on.
That helps to grok why the args is and array and the tool is separate.
Sent from my iPhone
> On Jun 26, 2016, at 1:37 PM, Graham Cox wrot
Ah thanks Marco, Andy… this makes a lot more sense and works fine.
—Graham
> On 26 Jun 2016, at 2:30 PM, Marco S Hyman wrote:
> I believe arguments is an array of arguments, not an array containing a
> string that matches a command line.
>
> Then your arguments array should contain five item
>
> NSString* argString = [NSString stringWithFormat:@"-i \"%@\" -c copy
> %@", [url absoluteString], [self.outputFileURL absoluteString]];
>
> self.ffMPEGTask = [NSTask launchedTaskWithLaunchPath:execPath
> arguments:@[argString]];
I believe arguments is an array of argument
Don't glom the arguments together. Pass each as a separate array
element: "-i", the URL string, "-c", "copy", the output string.
And you don't need to quote the arguments, just pass them as is.
I hope that makes sense -- I'd make it more code-like if I were at my
desk rather than on my phone.
HI all,
I am using NSTask to wrap ffmpeg, the video conversion utility.
I am able to invoke ffmpeg alright, but it’s unclear how the argument list
should be passed through NSTask. I tried making my various arguments into one
big string, but ffmeg doesn’t parse it, instead writing an error.
Her