Revision a2704c97 libavformat/dxa.c

View differences:

libavformat/dxa.c
95 95
        uint32_t size, fsize;
96 96
        c->has_sound = 1;
97 97
        size = avio_rb32(pb);
98
        c->vidpos = url_ftell(pb) + size;
98
        c->vidpos = avio_tell(pb) + size;
99 99
        avio_seek(pb, 16, SEEK_CUR);
100 100
        fsize = avio_rl32(pb);
101 101

  
......
104 104
            return -1;
105 105
        ff_get_wav_header(pb, ast->codec, fsize);
106 106
        // find 'data' chunk
107
        while(url_ftell(pb) < c->vidpos && !url_feof(pb)){
107
        while(avio_tell(pb) < c->vidpos && !url_feof(pb)){
108 108
            tag = avio_rl32(pb);
109 109
            fsize = avio_rl32(pb);
110 110
            if(tag == MKTAG('d', 'a', 't', 'a')) break;
......
114 114
        if(ast->codec->block_align)
115 115
            c->bpc = ((c->bpc + ast->codec->block_align - 1) / ast->codec->block_align) * ast->codec->block_align;
116 116
        c->bytes_left = fsize;
117
        c->wavpos = url_ftell(pb);
117
        c->wavpos = avio_tell(pb);
118 118
        avio_seek(pb, c->vidpos, SEEK_SET);
119 119
    }
120 120

  
......
133 133
        st->codec->height >>= 1;
134 134
    }
135 135
    c->readvid = !c->has_sound;
136
    c->vidpos  = url_ftell(pb);
136
    c->vidpos  = avio_tell(pb);
137 137
    s->start_time = 0;
138 138
    s->duration = (int64_t)c->frames * AV_TIME_BASE * num / den;
139 139
    av_log(s, AV_LOG_DEBUG, "%d frame(s)\n",c->frames);
......
158 158
        if(ret != size)
159 159
            return AVERROR(EIO);
160 160
        c->bytes_left -= size;
161
        c->wavpos = url_ftell(s->pb);
161
        c->wavpos = avio_tell(s->pb);
162 162
        return 0;
163 163
    }
164 164
    avio_seek(s->pb, c->vidpos, SEEK_SET);
......
172 172
            if(pal_size) memcpy(pkt->data, pal, pal_size);
173 173
            memcpy(pkt->data + pal_size, buf, 4);
174 174
            c->frames--;
175
            c->vidpos = url_ftell(s->pb);
175
            c->vidpos = avio_tell(s->pb);
176 176
            c->readvid = 0;
177 177
            return 0;
178 178
        case MKTAG('C', 'M', 'A', 'P'):
......
198 198
            if(pal_size) memcpy(pkt->data, pal, pal_size);
199 199
            pkt->stream_index = 0;
200 200
            c->frames--;
201
            c->vidpos = url_ftell(s->pb);
201
            c->vidpos = avio_tell(s->pb);
202 202
            c->readvid = 0;
203 203
            return 0;
204 204
        default:

Also available in: Unified diff