Log in or register to post comments

Pixel Format issue when initalizing CameraDevice

January 20, 2014 - 6:31pm #1

Hello! I'm having trouble running the provided sample apps on devices running iOS 7. I've tried it on an iPad Air, iPhone 5s and iPhone 4s. Each time, I get the following error:

On line 404 of SampleApplicationSession.mm, in QCAR::CameraDevice::getInstance().init(camera), under a call stack of 7 unnamed functions within the Vuforia SDK, there is a call to [AVCaptureVideoDataOutput setVideoSettings] that's throwing this exception:

'*** -[AVCaptureVideoDataOutput setVideoSettings:] - b32a (1647522401) is not a supported pixel format type.  See AVCaptureOutput.h for a list of supported formats.  Available pixel format types on this platform are (420v, 420f, BGRA).'

Is anyone else seeing this error when try to initialize a CameraDevice on iOS 7? I've seen the sample applications work on iOS 6 at work, but I don't have an iOS 6 device to test with at home.

Thanks,

Mike

Pixel Format issue when initalizing CameraDevice

October 2, 2015 - 9:30am #5

I´m having the same problem, the code words well on iPhone but on iPad the same code doesn´t work, the project is kinda old its still using xib, and the werid thing is that the same code works well on a fresh proyect, and works well on Vuforia Samples, I´m going crazy trying to figurate out what settings is causing the error.

 

if someone have the fix I would be nice if its shared.

Please help me. 

 

 -[AVCaptureVideoDataOutput setVideoSettings:] - b32a (1647522401) is not a supported pixel format type.  See AVCaptureOutput.h for a list of supported formats.  Available pixel format types on this platform are (
    420v,
    420f,
    BGRA
).
 
Info:
VuforiaSamples-5-0-5
iPad 2 iOS 7.0.3
iPad 3 iOS 8.3

Pixel Format issue when initalizing CameraDevice

January 22, 2014 - 6:38am #4

Thanks for the update here.

I checked with the development team and there is nothing untoward here.

 

N

Pixel Format issue when initalizing CameraDevice

January 21, 2014 - 2:15pm #3

Agh, no wonder I was having trouble finding others with the same problem. I was seeing that error as a result of a a special breakpoint+script I had set up which caught exceptions at the throw site and printed out the error. When I turned that off, everything worked as expected.

For what it's worth, I figured this out by swizzling AVCaptureVideoDataOutput's setVideoSettings method, and in doing so I discovered that Vuforia sets that property 17 times in a row, unnecessarily since the only acceptable key is the pixel format key and there are only three acceptable values for that key. In fact, each time Vuforia passes an unsupported pixel format the OS throws an exception which is handled by Vuforia before it tries again. Here are the values that Vuforia tries to set as the videoSettings property (note the warning from the OS about the fact that Vuforia is passing in unsupported keys!):

2014-01-21 12:26:00.142 Vuforia[376:4707] VIDEO SETTINGS: {

   PixelFormatType = 875704438;

}
2014-01-21 12:26:01.718 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 1647522401;
}
2014-01-21 12:26:04.675 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 1110783541;
}
2014-01-21 12:26:06.665 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 24;
}
2014-01-21 12:26:08.890 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 24;
}
2014-01-21 12:26:10.784 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 1380401729;
}
2014-01-21 12:26:11.852 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 1380401729;
}
2014-01-21 12:26:12.831 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 32;
}
2014-01-21 12:26:13.742 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 32;
}
2014-01-21 12:26:14.901 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 1111970369;
}
2014-01-21 12:26:16.397 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 1111970369;
}
2014-01-21 12:26:17.624 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 875704438;
}
2014-01-21 12:26:18.533 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 2033463856;
}
2014-01-21 12:26:19.468 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 892679473;
}
2014-01-21 12:26:20.309 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 842285639;
}
2014-01-21 12:26:21.086 Vuforia[376:4707] VIDEO SETTINGS: {
    PixelFormatType = 842285639;
}
2014-01-21 12:26:21.728 Vuforia[376:4707] VIDEO SETTINGS: {
    AVVideoScalingModeKey = AVVideoScalingModeFit;
    Height = 1080;
    PixelFormatType = 875704438;
    Width = 1920;
}
2014-01-21 12:26:21.731 Vuforia[376:4707] *** -[AVCaptureVideoDataOutput setVideoSettings:] - videoSettings dictionary contains one or more unsupported (ignored) keys: (
    Width,
    AVVideoScalingModeKey,
    Height
)

Pixel Format issue when initalizing CameraDevice

January 21, 2014 - 4:01am #2

I do not know why you are seeing this error.

The samples have been through a range of extensive testing, covering different versions of iOS and different devices.  If this was a common error then it would have shown up by now.  Also I just tested the Vuforia samples application on an iPad Mini Retina and it ran withou issue.

Is there anything else you can think of as to why your setup could be different?

Exactly what are the steps to reproduce and which sample app is it?

 

N

Log in or register to post comments