Skip to content
Snippets Groups Projects
Commit 8aa6d899 authored by Michael Niedermayer's avatar Michael Niedermayer
Browse files

cafdec: fix seeking with adpcm


Fixes Ticket1906

Signed-off-by: default avatarMichael Niedermayer <michaelni@gmx.at>
parent 16ef48c3
No related branches found
No related tags found
No related merge requests found
......@@ -401,7 +401,7 @@ static int read_seek(AVFormatContext *s, int stream_index,
if (caf->frames_per_packet > 0 && caf->bytes_per_packet > 0) {
/* calculate new byte position based on target frame position */
pos = caf->bytes_per_packet * timestamp / caf->frames_per_packet;
pos = caf->bytes_per_packet * (timestamp / caf->frames_per_packet);
if (caf->data_size > 0)
pos = FFMIN(pos, caf->data_size);
packet_cnt = pos / caf->bytes_per_packet;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment