예제 #1
0
bool
StreamingSound::moreData()
{
    if (decodingCompleted()) return false;

    decodeNextBlock();
    return true;
}
예제 #2
0
bool
EmbedSoundInst::moreData()
{
    if (decodingCompleted() || reachedCustomEnd()) {

        if (loopCount) {
            // negative count is documented to mean loop forever.
            if (loopCount > 0) --loopCount;
            restart();
            return true;
        }
        // Nothing more to do.
        return false;
    }

    // It's not clear if this happens for Embedded sounds, but it
    // would permit incremental decoding.
    decodeNextBlock();
    return true;
}