Skip to content

autovideoconvert2: select one or multiple elements to convert

  1. This plugin make single or multiple elements to perform conversion and add only the selected element not all the elements like autovideoconvert. And we may have some plugins with hardware video conversion, for some formats, a single plugin may not support and often need to combine multiple plugins to complete. This plugin can also combine those plugins automatically to achieve the required function.

  2. If the caps change, The plugin may change the selected element and remove the current one if the current one no longer matches the caps.

  3. The general workflow is as follows. Firstly, it will pick an element that matches the caps on both sides whose rank is greater than the composite rank level. And record the element if it only match one cap(sink caps or src caps) to the corresponding lists(first_factories or last_factories). Secondly, if none of the those elements match the caps whose rank is higher than composite rank, it will then try to pick and combine two elements (first element and last element) from the previous elements (first_factories or last_factories) which have been tried before according to the rank and check whether they match and add them. Lastly, if none of the composite elements match the caps, it will try to pick the remain elements whose rank are equal to or less than composite rank. If single element can perform conversion, this single element is the first element in the diagram and there is no last element. The first element src pad connects #internal_sinkpad directly.

 * +---------------------------------------------------------------------------+
 * | autoselect                                                                |
 * |                   +---------------+   +---------------+                   |
 * |                   | first element |   | last element  |                   |
 * | internal_srcpad-sink             src-sink            src-internal_sinkpad |
 * |                   +---------------+   +---------------+                   |
 * sink-+                                                                   +-src
 * +---------------------------------------------------------------------------+
Edited by elliot chen

Merge request reports