# "Invalid image format!" is printed when call processFrame

**URL:** <https://forum.deepar.ai/t/invalid-image-format-is-printed-when-call-processframe/332>\
**Category:** SDK\
**Tags:** effect-help\
**Created:** [June 8, 2023, 1:32am UTC](https://forum.deepar.ai/t/invalid-image-format-is-printed-when-call-processframe/332 "2023-06-08T01:32:09Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![user5](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.deepar.ai/user5/32/487_2.png) [@user5](https://forum.deepar.ai/u/user5)\
**Post date:** [June 8, 2023, 1:32am UTC](https://forum.deepar.ai/t/invalid-image-format-is-printed-when-call-processframe/332/1 "2023-06-08T01:32:09Z")

</div>

[iOS]  
If CVPixelBufferRef obtained from webrtc is passed to processFrame, “Invalid image format!” is output to the console and is not processed.

below is my sample codes. anybody help me plz.  
thank you

1. intializing

below is CVPixelBufferRef information , not support 420v?

\<CVPixelBuffer 0x283778dc0 width=640 height=480 pixelFormat=420v iosurface=0x28027c170 planes=2 poolName=CoreVideo\>

\<Plane 0 width=640 height=480 bytesPerRow=640\>

\<Plane 1 width=320 height=240 bytesPerRow=640\>

\<attributes={

```
PixelFormatDescription = {

    BitsPerComponent = 8;

    ComponentRange = VideoRange;

    ContainsAlpha = 0;

    ContainsGrayscale = 0;

    ContainsRGB = 0;

    ContainsYCbCr = 1;

    FillExtendedPixelsCallback = {length = 24, bytes = 0x0000000000000000e8a0c4be010000000000000000000000};

    IOSurfaceCoreAnimationCompatibility = 1;

    IOSurfaceOpenGLESFBOCompatibility = 1;

    IOSurfaceOpenGLESTextureCompatibility = 1;

    OpenGLESCompatibility = 1;

    PixelFormat = 875704438;

    Planes = (

                    {

            BitsPerBlock = 8;

            BlackBlock = {length = 1, bytes = 0x10};

        },

                    {

            BitsPerBlock = 16;

            BlackBlock = {length = 2, bytes = 0x8080};

            HorizontalSubsampling = 2;

            VerticalSubsampling = 2;

        }

    );

};

```

} propagatedAttachments={

```
CVImageBufferColorPrimaries = "ITU_R_709_2";

CVImageBufferTransferFunction = "ITU_R_709_2";

CVImageBufferYCbCrMatrix = "ITU_R_601_4";

MetadataDictionary = {

    ExposureTime = "0.033331";

    LuxLevel = 325;

    NormalizedSNR = "21.63113965390955";

    SNR = "31.59735072970156";

    SensorID = 1300;

};

```

} nonPropagatedAttachments={

}\>

---

<div class="post-metadata">

**Author:** ![user5](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.deepar.ai/user5/32/487_2.png) [@user5](https://forum.deepar.ai/u/user5)\
**Post date:** [June 8, 2023, 2:49am UTC](https://forum.deepar.ai/t/invalid-image-format-is-printed-when-call-processframe/332/2 "2023-06-08T02:49:51Z")

</div>

change pixel format BGRA, and then normally processed.

I want to know supported pixel format. let me know plz  
@jelena @Zak

---

<div class="post-metadata">

**Author:** ![jelena](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.deepar.ai/jelena/32/14_2.png) [@jelena](https://forum.deepar.ai/u/jelena)\
**Post date:** [June 9, 2023, 11:24am UTC](https://forum.deepar.ai/t/invalid-image-format-is-printed-when-call-processframe/332/3 "2023-06-09T11:24:33Z")

</div>

Hi, the iOS SDK doesn’t support 420v as an output format. Here’s a list  
[https://s3.eu-west-1.amazonaws.com/sdk.developer.deepar.ai/doc/ios/\_deep\_a\_r\_8h.html#aeb712c6c6c0a8af0dfd79f451ecb9277](https://s3.eu-west-1.amazonaws.com/sdk.developer.deepar.ai/doc/ios/_deep_a_r_8h.html#aeb712c6c6c0a8af0dfd79f451ecb9277)

---

<div class="post-metadata">

**Author:** ![rafaelnobrekz](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.deepar.ai/rafaelnobrekz/32/542_2.png) [@rafaelnobrekz](https://forum.deepar.ai/u/rafaelnobrekz)\
**Post date:** [July 20, 2023, 3:52pm UTC](https://forum.deepar.ai/t/invalid-image-format-is-printed-when-call-processframe/332/4 "2023-07-20T15:52:49Z")

</div>

@jelena what are the supported pixel buffer input formats for `processFrame` and `enqueueCameraFrame` SDK methods? I’m getting invalid pixel format for 420f capture straight from the camera (I would hope the enqueueCameraFrame would work with that?)

---

<div class="post-metadata">

**Author:** ![rafaelnobrekz](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.deepar.ai/rafaelnobrekz/32/542_2.png) [@rafaelnobrekz](https://forum.deepar.ai/u/rafaelnobrekz)\
**Post date:** [July 20, 2023, 3:56pm UTC](https://forum.deepar.ai/t/invalid-image-format-is-printed-when-call-processframe/332/5 "2023-07-20T15:56:21Z")

</div>

I would expect the SDK to return a proper error on the onError delegate callback with accurate details ie what was the supported expected formats and the provided format. Having only a print statement is not enough
