I am writting an application on the iPhone which makes heavy use of OpenAL. I have loaded some sounds looping, and everything is fine, until I use alGetSourcef to obtain the current time offset of a sound:
The problem is that the value returned is rounded to the nearest value! I only get results like 1.000000, 2.000000, 3.000000!
Can anyone help me on this?
Code:
- (float)timeOffset
{
ALfloat tOffset;
alGetSourcef(source, AL_SEC_OFFSET, &tOffset);
//NSLog(@"%f", tOffset);
return tOffset;
}
The problem is that the value returned is rounded to the nearest value! I only get results like 1.000000, 2.000000, 3.000000!
Can anyone help me on this?