Opened 14 months ago

Last modified 14 months ago

#8870 new defect

AVIO_FLAG_DIRECT does not work

Reported by: str Owned by:
Priority: normal Component: avformat
Version: git-master Keywords:
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug:
I want to reduce buffering overhead when using avio_open2/av_write_frame API.
How to reproduce:

avio_open2(formatContext->pb, "test.avi", AVIO_FLAG_WRITE | AVIO_FLAG_DIRECT, 0, 0);
av_write_frame(formatContext, avPacket); //return -5 if avpack.size > 262144
I found that is due to line 241 in file.c where this value is set. In line 425 in file avio.c is this value compared to input size and fails if size > 262144. Is there any way to workaround this?
ffmpeg version
built on 4.3.1

Change History (2)

comment:1 by str, 14 months ago

Component: undeterminedavformat
Summary: How to use AVIO_FLAG_DIRECTAVIO_FLAG_DIRECT does not work
Version: git-master4.2

comment:2 by str, 14 months ago

Version: 4.2git-master
Note: See TracTickets for help on using tickets.