-
- if( video->state == CLVIDEO_FIRSTFRAME )
- destframe = 0;
- else
- destframe = (int)((realtime - video->starttime) * video->framerate);
- if( destframe < 0 )
- destframe = 0;
- if( video->framenum < destframe ) {
- do {
- video->framenum++;
- if( dpvsimpledecode_video( video->stream, video->imagedata, cl_videormask,
- cl_videogmask, cl_videobmask, cl_videobytesperpixel,
- cl_videobytesperpixel * video->cpif.width )
- ) { // finished?
- CL_RestartVideo( video );
- if( video->state == CLVIDEO_PLAY )
- video->state = CLVIDEO_FIRSTFRAME;
- return;
- }
- } while( video->framenum < destframe );
- R_MarkDirtyTexture( video->cpif.tex );
- }
-}
-
-void CL_Video_Frame( void ) // update all videos
-{