Fix for seeking bugs
parent
b1ad4b00ae
commit
01a0259c44
|
@ -73,7 +73,9 @@
|
||||||
|
|
||||||
- (void)seek:(double)time
|
- (void)seek:(double)time
|
||||||
{
|
{
|
||||||
|
NSLog(@"SEEKING IN BUFFERCHIAN");
|
||||||
[inputNode seek:time];
|
[inputNode seek:time];
|
||||||
|
|
||||||
[inputNode resetBuffer];
|
[inputNode resetBuffer];
|
||||||
[converterNode resetBuffer];
|
[converterNode resetBuffer];
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,6 +47,7 @@
|
||||||
{
|
{
|
||||||
if (shouldSeek == YES)
|
if (shouldSeek == YES)
|
||||||
{
|
{
|
||||||
|
NSLog(@"Actually seeking");
|
||||||
[soundFile seekToTime:seekTime];
|
[soundFile seekToTime:seekTime];
|
||||||
shouldSeek = NO;
|
shouldSeek = NO;
|
||||||
}
|
}
|
||||||
|
@ -68,6 +69,7 @@
|
||||||
|
|
||||||
- (void)seek:(double)time
|
- (void)seek:(double)time
|
||||||
{
|
{
|
||||||
|
NSLog(@"SEEKING WEEE");
|
||||||
seekTime = time;
|
seekTime = time;
|
||||||
shouldSeek = YES;
|
shouldSeek = YES;
|
||||||
}
|
}
|
||||||
|
|
|
@ -43,7 +43,9 @@
|
||||||
if (availOutput == 0)
|
if (availOutput == 0)
|
||||||
{
|
{
|
||||||
[writeLock unlock];
|
[writeLock unlock];
|
||||||
|
NSLog(@"WAITING %i", shouldContinue);
|
||||||
[semaphore wait];
|
[semaphore wait];
|
||||||
|
NSLog(@"NOT WAITING: %i", shouldContinue);
|
||||||
[writeLock lock];
|
[writeLock lock];
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -153,6 +155,7 @@
|
||||||
|
|
||||||
- (void)resetBuffer
|
- (void)resetBuffer
|
||||||
{
|
{
|
||||||
|
[semaphore signal];
|
||||||
[readLock lock];
|
[readLock lock];
|
||||||
[writeLock lock];
|
[writeLock lock];
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue