git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/kdesupport/taglib@615877
283d02a7-25f6-0310-bc7c-
ecb5cbfe19da
{
static const int blockSize[] = { 0, 384, 1152, 1152 };
- double timePerFrame = blockSize[firstHeader.layer()];
- timePerFrame = firstHeader.sampleRate() > 0 ? timePerFrame / firstHeader.sampleRate() : 0;
+ double timePerFrame = blockSize[firstHeader.layer()] / firstHeader.sampleRate();
d->length = int(timePerFrame * d->xingHeader->totalFrames());
d->bitrate = d->length > 0 ? d->xingHeader->totalSize() * 8 / d->length / 1000 : 0;
}