vf_hwupload/hwmap: Support setting a fixed pool size
authorMark Thompson <sw@jkqxz.net>
Sat, 5 Aug 2017 21:10:46 +0000 (22:10 +0100)
committerMark Thompson <sw@jkqxz.net>
Sun, 11 Feb 2018 22:11:10 +0000 (22:11 +0000)
commitc6bc18bc121ea66df715123c59f7ef9542c0914a
treea6b4d6aeba3df36b5cf627f343efbe0c86f73eb8
parente4cdef00263dc8b3c8de9d34ceacd00dc68979c0
vf_hwupload/hwmap: Support setting a fixed pool size

These filters do not directly know whether the API they are using will
support dynamic frame pools, so this is somewhat tricky.  If the user
sets extra_hw_frames, we assume that they are aware of the problem and
set a fixed size based on that.  If not, most cases use dynamic sizing
just like they did previously.  The hardware-reverse-mapping case for
hwmap previously had a large fixed size (64) here, primarily as a hack
for QSV use - this is removed and extra_hw_frames will need to be set
for QSV to work since it requires fixed-size pools (as the other cases
do, and which didn't work before).
libavfilter/vf_hwmap.c
libavfilter/vf_hwupload.c