"MEncoder svn r34540 (Ubuntu), built with gcc-4.6 (C) 2000-2012 MPlayer Team
Exiting... (No output file specified, please see the -o option.)"
This command calls mencoder on a file named "mf://*.png -o movie.avi
-ovc x264". Do you have a file named like that?
Rémy.
sent from my droid
On Aug 29, 2013 6:18 PM, "bdentremont" <bdent...@gmail.com> wrote:
>
> I'm trying to combine some plots in PNG into a movie on Ubuntu. I would like this to happen automatically after running my Go program. If I run from the bash shell,
>
> cd /tmp/2013-08-29_16.54.51.432786
> mencoder "mf://*.png" -o movie.avi -ovc x264
>
> I get what I want. However, when I attempt to call the shell command in Go, I get the following error:
>
> "MEncoder svn r34540 (Ubuntu), built with gcc-4.6 (C) 2000-2012 MPlayer Team
>
> Exiting... (No output file specified, please see the -o option.)"
>
>
> Both the commented "ls" commands in the following code work properly and the output verifies that I'm in the right directory. Can someone point me in the direction of what I'm missing?
>
> package main
>
> import (
> "fmt"
> "os/exec"
> )
>
> func main() {
> cmd := exec.Command(`mencoder`, `mf://*.png -o movie.avi -ovc x264`)
This should read:
cmd := exec.Command(`mencoder`, `mf://*.png', '-o', 'movie.avi', 'x264`)
With double quotes all along.
-s
> //cmd := exec.Command(`ls`, `-la`)
> //cmd := exec.Command(`ls`, `-l`, `-a`)
> cmd.Dir = "/tmp/2013-08-29_16.54.51.432786"
> out, _ := cmd.CombinedOutput()
> fmt.Println(string(out))
> }
>
> --
> You received this message because you are subscribed to the Google Groups "golang-nuts" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
MEncoder svn r34540 (Ubuntu), built with gcc-4.6 (C) 2000-2012 MPlayer Team
Exiting... (No output file specified, please see the -o option.)--
--
MEncoder svn r34540 (Ubuntu), built with gcc-4.6 (C) 2000-2012 MPlayer Team
No stream found to handle url "mf://*.png"
Cannot open file/device.
Exiting...
panic: exit status 1
goroutine 1 [running]:
main.main()
/home/brian/go/src/bdentremont/tmp/main.go:15 +0x186
goroutine 2 [syscall]:
created by runtime.main
/build/buildd/golang-1/src/pkg/runtime/proc.c:221
Error: process exited with code 2.