Баш скрипт:
date=$(date '+%Y-%m-%d_%H:%M:%S.mp4')
ffmpeg -video_size 1130x800 -framerate 25 -f x11grab -i :0.0+570,180 -f alsa -ac 2 -i hw:0 -g 100 /mnt/storage/$date
Пытаюсь сделать то же самое из qt:
QString strSize = lblWidth->text() + "x" + lblHeight->text();
QString strPos = "-i :0.0+" + lblLeft->text() + "," + lblTop->text();
QDateTime t = QDateTime::currentDateTime();
QString s = t.toString("yyyy.MM.dd-HH.mm.ss")+".mp4";
QStringList arguments;
arguments << "-video_size" << strSize << "-framerate" << "25" << "-f" << "x11grab" ;
arguments << strPos << "-f" << "alsa" << "-ac" << "2" << "-i" << "hw:0" << "-g" << "100" << "/mnt/storage/rec_" + s;
recProcess = new QProcess(this);
recProcess->setProcessChannelMode(QProcess::MergedChannels);
connect(recProcess, SIGNAL(started()), this, SLOT(processStarted()));
connect(recProcess, SIGNAL (readyReadStandardOutput()), this, SLOT(readProcessOutput()));
recProcess->start( "ffmpeg", arguments );
При попытке начать запись в выхлопе ffmpeg получаю ошибку:
Unrecognized option 'i :0.0+225,145'.
Error splitting the argument list: Option not found
Почему из баша опция определяется нормально, из qt выдает ошибку?