Notes on a particularly perplexing ffmpeg problem.
This commit is contained in:
parent
970e63e19b
commit
5b6ea201fe
1 changed files with 13 additions and 0 deletions
13
pyav_by8
Normal file
13
pyav_by8
Normal file
|
@ -0,0 +1,13 @@
|
|||
try to create an image with a custom buffer, format rbga
|
||||
image is 278x57
|
||||
got 63384 bytes, need 63840 bytes
|
||||
63384=278*57*4, checks out. why 63840?
|
||||
factor 63384=2*2*2*3*19*139
|
||||
factor 63840=2*2*2*2*2*3*5*7*19
|
||||
factor 278=2*139
|
||||
factor 57=3*19
|
||||
factor 4=2*2
|
||||
63840 doesn't have 139 as a factor... if we divide by the other two we get 2*2*2*5*7=280
|
||||
is it padding an extra pixel on each side? no, reducing video frame width to 276 still demands 63840 bytes.
|
||||
does stretching image to 280 work? yes! so it has to be a multiple of 5... or 10, or 20. and larger than the requested dimension.
|
||||
after some further fiddling, it's 8.
|
Loading…
Add table
Add a link
Reference in a new issue