aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/eacmv.c
diff options
context:
space:
mode:
authorJose Da Silva <digital@joescat.com>2021-01-18 21:43:13 -0800
committerPaul B Mahol <onemda@gmail.com>2021-01-28 15:50:37 +0100
commitc31a7d07f6f22a94b7f44dcb73c025b2d78cfc66 (patch)
treec0dd61d6c43f255ba84494084988de88e15a222b /libavcodec/eacmv.c
parentcb70e1921aeda4df11ad77ee550e7bdcdca2b834 (diff)
downloadffmpeg-c31a7d07f6f22a94b7f44dcb73c025b2d78cfc66.tar.gz
avcodec/xbmenc: Allow for making UW images
I've run into some bugs where I was downloading a bunch of data and began seeing weird hiccups. For example, javascript promises to allow you to push some very long lines of data, but the hiccups I saw was with data larger than 2k in length (windows) pushed out of a child process stdout piped into the stdin of the calling parent program. Soo much for smooth promises, this was broken and would run into similar problems on a linux PC with 32k line limits. The solution was to break the data into smaller chunks than 2k - and then these data hiccups disappeared (windows PC). It would be expected to be similar for linux PCs (32k I think) and other OSes with different sizes. If the ANSI required minimum needs to be 509 chars or larger (assuming 509+<CR>+<LF>+<0>=512), then 509 was chosen as the shortest worst-case scenario) in this patch. Most small pictures will go output looking pretty much the same data out until you get to about 84bytes (672 pixels wide), where lines out begin to be split. For example a UW 4K will exceed a 2k readln and a UW 10K picture approaches an 8k readln The purpose for this patch is to ensure that data remains below the readline limits (of 509 chars), so that programs (like javascript) can push data in large chunks without breaking into hiccups because the data length is too long to be pushed cleanly in one go. Subject: [PATCH 3/3] avcodec/xbmenc: Allow for making UW images Worst-case ANSI must allow for 509 chars, while Windows allows for 2048 and Linux for 32K line length. This allows an OS with a small readline access limitation to fetch very wide images (created from ffmpeg).
Diffstat (limited to 'libavcodec/eacmv.c')
0 files changed, 0 insertions, 0 deletions