In case of time-out to generate a frame, leave the last
frame on-screen, instead of going black until catching up. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38672 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -745,6 +745,14 @@ VideoProducer::_FrameGeneratorThread()
|
|||||||
err = fSupplier->FillBuffer(playlistFrame,
|
err = fSupplier->FillBuffer(playlistFrame,
|
||||||
buffer->Data(), fConnectedFormat, forceSendingBuffer,
|
buffer->Data(), fConnectedFormat, forceSendingBuffer,
|
||||||
wasCached);
|
wasCached);
|
||||||
|
if (err == B_TIMED_OUT) {
|
||||||
|
// Don't send the buffer if there was insufficient
|
||||||
|
// time for rendering, this will leave the last
|
||||||
|
// valid frame on screen until we catch up, instead
|
||||||
|
// of going black.
|
||||||
|
wasCached = true;
|
||||||
|
err = B_OK;
|
||||||
|
}
|
||||||
// clean the buffer if something went wrong
|
// clean the buffer if something went wrong
|
||||||
if (err != B_OK) {
|
if (err != B_OK) {
|
||||||
// TODO: should use "back value" according
|
// TODO: should use "back value" according
|
||||||
|
|||||||
Reference in New Issue
Block a user