Newbie questions

Virso <[email protected]> Fri, 12 Dec 2003 10:24:33 -0300
Newsgroups gmane.comp.multimedia.avifile.general
Message-ID <[email protected]>
Hi,

I'm a new user of Avifile and i have some questions to do.

First at all, i saw that i cannot do something like this:

stream->StartStreaming();
while(!stream->Eof()) {
    CImage* image = stream->GetFrame(true);
    // ... processing image	      
}

1) Why? Is it alway needed to wait the time between two frames to read the
next one?


And, my second question is:

2) If I want to read a specific frame, what can I do? 
   I thinked about the code below:

  //(Read the frame from time 10 sec)
  videoStream->SeekTime(10.0);
  framepos_t num_frame = videoStream->GetPos();
  framepos_t inicio; 
  for(inicio; = videoStream->SeekToPrevKeyFrame(); inicio < num_frame; inicio++)
{
    videoStream->ReadFrame();
    // Wait?
  }

  Is there another way? How can I use ReadDirect?

Thank you and sorry for the English,

Wilson 



------------------------------------------
Use o melhor sistema de busca da Internet
Radar UOL - http://www.radaruol.com.br