[FFmpeg-trac] #1760(avcodec:new): Don't use VDA on Snow Leopard/ppc
FFmpeg
trac at avcodec.org
Sat Sep 22 20:41:51 CEST 2012
#1760: Don't use VDA on Snow Leopard/ppc
-------------------------------------+-----------------------------------
Reporter: jeremyhu | Owner:
Type: defect | Status: new
Priority: normal | Component: avcodec
Version: unspecified | Resolution:
Keywords: vda | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-------------------------------------+-----------------------------------
Changes (by jeremyhu):
* keywords: => vda
* component: undetermined => avcodec
Comment:
It doesn't seem right to disable VDA across all slices just because it's
not available on ppc, so I would suggest updating with a patch like:
{{{
diff --git a/libavcodec/allcodecs.c b/libavcodec/allcodecs.c
index 8806c6a..b15b784 100644
--- a/libavcodec/allcodecs.c
+++ b/libavcodec/allcodecs.c
@@ -58,7 +58,9 @@ void avcodec_register_all(void)
REGISTER_HWACCEL (H263_VAAPI, h263_vaapi);
REGISTER_HWACCEL (H264_DXVA2, h264_dxva2);
REGISTER_HWACCEL (H264_VAAPI, h264_vaapi);
+#ifndef __ppc__
REGISTER_HWACCEL (H264_VDA, h264_vda);
+#endif
REGISTER_HWACCEL (MPEG1_VDPAU, mpeg1_vdpau);
REGISTER_HWACCEL (MPEG2_DXVA2, mpeg2_dxva2);
REGISTER_HWACCEL (MPEG2_VAAPI, mpeg2_vaapi);
@@ -135,7 +137,9 @@ void avcodec_register_all(void)
REGISTER_ENCDEC (H263P, h263p);
REGISTER_DECODER (H264, h264);
REGISTER_DECODER (H264_CRYSTALHD, h264_crystalhd);
+#ifndef __ppc__
REGISTER_DECODER (H264_VDA, h264_vda);
+#endif
REGISTER_DECODER (H264_VDPAU, h264_vdpau);
REGISTER_ENCDEC (HUFFYUV, huffyuv);
REGISTER_DECODER (IDCIN, idcin);
diff --git a/libavcodec/vda_h264.c b/libavcodec/vda_h264.c
index 4b8c754..fe620bc 100644
--- a/libavcodec/vda_h264.c
+++ b/libavcodec/vda_h264.c
@@ -20,6 +20,9 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301 USA
*/
+/* https://ffmpeg.org/trac/ffmpeg/ticket/1760 */
+#ifndef __ppc__
+
#include <CoreFoundation/CFDictionary.h>
#include <CoreFoundation/CFNumber.h>
#include <CoreFoundation/CFData.h>
@@ -380,3 +383,5 @@ AVHWAccel ff_h264_vda_hwaccel = {
.decode_slice = decode_slice,
.end_frame = end_frame,
};
+
+#endif /* !ppc */
diff --git a/libavcodec/vda_h264_dec.c b/libavcodec/vda_h264_dec.c
index 36453c5..09115a7 100644
--- a/libavcodec/vda_h264_dec.c
+++ b/libavcodec/vda_h264_dec.c
@@ -24,6 +24,9 @@
* @author Xidorn Quan <quanxunzhen at gmail.com>
*/
+/* https://ffmpeg.org/trac/ffmpeg/ticket/1760 */
+#ifndef __ppc__
+
#include <string.h>
#include <CoreFoundation/CoreFoundation.h>
@@ -256,3 +259,5 @@ AVCodec ff_h264_vda_decoder = {
.flush = vdadec_flush,
.long_name = NULL_IF_CONFIG_SMALL("H.264 (VDA acceleration)"),
};
+
+#endif /* !ppc */
}}}
This caused the darwin/ppc fate builds to start failing when I updated
them from Leopard to Snow Leopard:
http://fate.ffmpeg.org/history.cgi?slot=ppc-darwin-gcc-4.2.1
--
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/1760#comment:1>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list