Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* This field is internal to libavformat and access from outside is not allowed.
*/
int seek_count;
+
+ /**
+ * writeout statistic
+ * This field is internal to libavformat and access from outside is not allowed.
+ */
+ int writeout_count;
} AVIOContext;
/* unbuffered I/O */
s->error = ret;
}
}
+ s->writeout_count ++;
s->pos += len;
}
avio_flush(s);
h = s->opaque;
av_freep(&s->buffer);
- if (!s->write_flag)
+ if (s->write_flag)
+ av_log(s, AV_LOG_DEBUG, "Statistics: %d seeks, %d writeouts\n", s->seek_count, s->writeout_count);
+ else
av_log(s, AV_LOG_DEBUG, "Statistics: %"PRId64" bytes read, %d seeks\n", s->bytes_read, s->seek_count);
av_free(s);
return ffurl_close(h);