QTMovie help

deliciousMammal

Registered
So, I am attempting to process every frame of a movie using QTMovie and have a loop that looks like this:

Code:
while (QTTimeCompare([myMovie currentTime], [myMovie duration]) != NSOrderedSame)
{
	// I do some stuff with some things	
	
	[myMovie stepForward];
}

And it works just fine, but when it reaches around the last frame it gives me a bad access warning. I'm guessing that since -duration gives me the time at the end of the movie and -currentTime on the last frame would give me -duration - the_length_of_a_frame I am continuing my loop too long.

But I can't find a way to check that I have done every frame.

If anyone has any ideas, I'd love the help. Thanks!
 
Back
Top