On 10/10/14 22:44, Rémi Denis-Courmont wrote:
@@ -3014,6 +3014,18 @@ typedef struct AVHWAccel {
       * AVCodecInternal.hwaccel_priv_data.
       */
      int priv_data_size;
+
+    /**
+     * Directly decode the avpacket, it is called instead of the normal
+     * AVCodec callback.
+     */
+    int (*decode)(AVCodecContext *, void *outdata, int *outdata_size,
+                  AVPacket *avpkt);
+    /**
+     * Flush the decoder, it is called instead of the normal AVCodec
+     * callback.
+     */
+    void (*flush)(AVCodecContext *);

Based on the VDPAU series review, I have to believe that adding new visible
but internal members to AVHWAccel is not allowed.

I consider AVHWAccel the same as AVCodec, from outside should be always accessed by reference.

Are the codec profile and resolution known at that point? I would not think so.

A bitstream hwaccel does that internally.

If not, that will never going to work smoothly, unless the back-end supported
all profiles and all resolutions. In particular, that will prevent software
fallback.

I'd rather rework the software fallback on a second time and I'd rather add an option to make it an explicit error instead of always automagic.

lu

_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to