Skip to content

Offset error #7

Open
Open
@NickSuglobov

Description

@NickSuglobov

Hi!
I found that you are adding offset twice in your code. The sample is working because offset is 0 for current audio format. Not working with aac.
In class TDAudioStreamer, line 68
memcpy((char *)(self.audioQueueBuffer->mAudioData + self.fillPosition), (const char *)(data + packetDescription.mStartOffset), packetDescription.mDataByteSize);
and line 46:
memcpy((char *)(self.audioQueueBuffer->mAudioData + self.fillPosition), (const char *)(data + offset), length);

This offset is already added in class TDAudioFileStream, line 85
[self.delegate audioFileStream:self didReceiveData:(const void *)(packets + packetOffset) length:packetSize packetDescription:(AudioStreamPacketDescription)packetDescriptions[i]];

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions