[Live-devel] Non Blocking doGetNextFrame
d_osthei at ece.concordia.ca
Thu Mar 30 13:25:37 PST 2006
In a current school project I am using FFMPEG and LIVE to stream an
MPEG-4 stream. As each component is connected with Buffers, the
doGetNextFrame retrieves the next frame to send from there. If no frame
exists NULL is returned.
If within the doGetNextFrame function there is a loop such that it
waits for a non null value (Polling the buffer), everything streams
okay with high CPU loads. What I would like to do is make this a non
Blocking piece of code as is suggested by the comments in FramedSource.
If i check if the received data is null and only call deliverFrame() if
it is not null, I do not get a stream being sent.
I beleive i have to reschedule the call to doGetNextFrame however can't
seem to find the one line of code similar to that at the end of
nextTask() = envir().taskScheduler().scheduleDelayedTask(0,
It would be a great help if anyone could suggest the correct method of
doing this. Thanks.
Computer Engineering Undergraduate Student,
More information about the live-devel