Hi Justin
Been playing around with QProcess but only got it to send start/finished
signals.
trying subprocess now.
here is what i have. But i can't append the stdout from the process.
It exports everything ok. just no feedback.
----code-----------
def export(self):
self.proc=subprocess.Popen("avconv -i %s -b %s -s %s %s"
%(self.inputFile,self.bitRatesList[self.bitRate.currentIndex()],
self.sizeList[self.sizeSel.currentIndex()],self.outputFile),shell=True,stdout=subprocess.PIPE)
for i in range (2000):
output=self.proc.stdout.readline()
self.log.append(output)
---code------
cheers all
Ricardo Viana
On 03/06/2013 06:07 PM, Justin Israel wrote:
Does the avconv output give you textual progress? If so, you would
need to be reading from the subprocess or QProcess as it runs, parsing
the progress value and setting that value on your progress meter.
QProcess will emit signals as new output is ready from the command,
whereas a subprocess would require that you keep checking it, either
with a qtimer until its done, or a for loop where you make sure to be
periodically calling QApplication.processEvents() to keep the event
loop flowing.
On Mar 7, 2013 5:22 AM, "Ricardo Viana" <[email protected]
<mailto:[email protected]>> wrote:
Hi Fellas!
i'm trying to build my own video converter gui on a Linux. Using
Pyqt4.
I'm using avconv command line converter.
I have setup all parameters and it is working fine.
The thing is i would like to have some kind of progress feedback.
Does anyone know how to retrieve the command line feedback so
i can hook it to some kind of expression to drive the QProgressBar?
thank you very much
--
////////////////////////////////////
Ricardo Viana
VFX Generalist
--
You received this message because you are subscribed to the Google
Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it,
send an email to [email protected]
<mailto:python_inside_maya%[email protected]>.
To post to this group, send email to
[email protected]
<mailto:[email protected]>.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google
Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.
--
////////////////////////////////////
Ricardo Viana
VFX Generalist
--
You received this message because you are subscribed to the Google Groups "Python
Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.