[FFmpeg-devel] [PATCH] AVFoundation: Add -pixel_format option

sfan5 sfan5 at live.de
Sun May 11 17:42:48 CEST 2014


Am 11.05.2014 17:21, schrieb Thilo Borgmann:
> Am 11.05.14 12:34, schrieb sfan5:
>> On 11.05.2014 11:43, Lukasz Marek wrote:
>>> On 11.05.2014 11:13, sfan5 wrote:
>>>> +static const struct AVFPixelFormatSpec avf_pixel_formats[] = {
>>>> +    { AV_PIX_FMT_MONOBLACK, kCVPixelFormatType_1Monochrome },
>>>> +    { AV_PIX_FMT_GRAY8, kCVPixelFormatType_8Indexed },
>>>> +    { AV_PIX_FMT_RGB555BE, kCVPixelFormatType_16BE555 },
>>>> +    { AV_PIX_FMT_RGB555LE, kCVPixelFormatType_16LE555 },
>>>> +    { AV_PIX_FMT_RGB565BE, kCVPixelFormatType_16BE565 },
>>>> +    { AV_PIX_FMT_RGB565LE, kCVPixelFormatType_16LE565 },
>>>> +    { AV_PIX_FMT_RGB0, kCVPixelFormatType_24RGB },
>>>> +    { AV_PIX_FMT_BGR0, kCVPixelFormatType_24BGR },
>>>> +    { AV_PIX_FMT_ARGB, kCVPixelFormatType_32ARGB },
>>>> +    { AV_PIX_FMT_BGRA, kCVPixelFormatType_32BGRA },
>>>> +    { AV_PIX_FMT_ABGR, kCVPixelFormatType_32ABGR },
>>>> +    { AV_PIX_FMT_RGBA, kCVPixelFormatType_32RGBA },
>>>> +    { AV_PIX_FMT_BGR48BE, kCVPixelFormatType_48RGB },
>>>> +    { AV_PIX_FMT_UYVY422, kCVPixelFormatType_422YpCbCr8 },
>>>> +    { AV_PIX_FMT_YUVA444P, kCVPixelFormatType_4444YpCbCrA8R },
>>>> +    { AV_PIX_FMT_YUVA444P16LE, kCVPixelFormatType_4444AYpCbCr16 },
>>>> +    { AV_PIX_FMT_YUV444P, kCVPixelFormatType_444YpCbCr8 },
>>>> +    { AV_PIX_FMT_YUV422P16, kCVPixelFormatType_422YpCbCr16 },
>>>> +    { AV_PIX_FMT_YUV422P10, kCVPixelFormatType_422YpCbCr10 },
>>>> +    { AV_PIX_FMT_YUV444P10, kCVPixelFormatType_444YpCbCr10 },
>>>> +    { AV_PIX_FMT_YUV420P, kCVPixelFormatType_420YpCbCr8Planar },
>>>> +    { AV_PIX_FMT_NV12, kCVPixelFormatType_420YpCbCr8BiPlanarVideoRange },
>>>> +    { AV_PIX_FMT_YUYV422, kCVPixelFormatType_422YpCbCr8_yuvs },
>>>> +    { AV_PIX_FMT_GRAY8, kCVPixelFormatType_OneComponent8 },
>>>> +    { AV_PIX_FMT_NONE, 0 }
>>>> +};
> Please align these vertically.
>
>>> No more comments from me.
>> (new patch attached)
> With this patch there is no valid default pixel format selected (at least on OSX):
>
> nue066:FFmpeg Thilo$ ./ffplay -f avfoundation ""
> ffplay version N-62999-g24734ea Copyright (c) 2003-2014 the FFmpeg developers
>    built on May 11 2014 16:58:37 with Apple LLVM version 5.1 (clang-503.0.40)
> (based on LLVM 3.4svn)
>    configuration: --disable-decoder=hevc --disable-decoder=h264
>    libavutil      52. 81.100 / 52. 81.100
>    libavcodec     55. 60.103 / 55. 60.103
>    libavformat    55. 37.102 / 55. 37.102
>    libavdevice    55. 13.101 / 55. 13.101
>    libavfilter     4.  5.100 /  4.  5.100
>    libswscale      2.  6.100 /  2.  6.100
>    libswresample   0. 18.100 /  0. 18.100
> [avfoundation @ 0x7fc1d9823800] Selected pixel format is not supported by
> AVFoundation
> : Input/output error
>
>
> It should not be mandantory to explicitly select the pixel format.
>
> -Thilo
>
(new patch attached)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-AVFoundation-Add-pixel_format-option.patch
Type: text/x-patch
Size: 5827 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140511/1af5ebeb/attachment.bin>


More information about the ffmpeg-devel mailing list