- Timestamp:
- Jun 14, 2013 12:15:06 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/src-client/VideoRec.cpp
r46549 r46553 49 49 VIDREC_COPYING = 2, 50 50 /* signal that we are terminating */ 51 VIDREC_TERMINATING = 251 VIDREC_TERMINATING = 3 52 52 }; 53 53 static uint32_t g_enmState = VIDREC_UNINITIALIZED; … … 394 394 { 395 395 PVIDEORECSTREAM pStrm = &pCtx->Strm[uScreen]; 396 if (ASMAtomicReadBool(&pStrm->fRgbFilled)) 396 if ( pStrm->fEnabled 397 && ASMAtomicReadBool(&pStrm->fRgbFilled)) 397 398 { 398 399 rc = videoRecRGBToYUV(pStrm); … … 590 591 bool VideoRecIsEnabled(PVIDEORECCONTEXT pCtx) 591 592 { 592 if (!pCtx) 593 return false; 594 595 return pCtx->fEnabled; 593 uint32_t enmState = ASMAtomicReadU32(&g_enmState); 594 return ( enmState == VIDREC_IDLE 595 || enmState == VIDREC_COPYING); 596 596 } 597 597 … … 720 720 721 721 PVIDEORECSTREAM pStrm = &pCtx->Strm[uScreen]; 722 722 if (!pStrm->fEnabled) 723 { 724 rc = VINF_TRY_AGAIN; /* not (yet) enabled */ 725 break; 726 } 723 727 if (u64TimeStamp < pStrm->u64LastTimeStamp + pStrm->uDelay) 724 728 { … … 726 730 break; 727 731 } 728 729 732 if (ASMAtomicReadBool(&pStrm->fRgbFilled)) 730 733 {
Note:
See TracChangeset
for help on using the changeset viewer.