Camera view doesn't work on iPhone, works on another

I made an iPhone app with a camera view as its main function. It processes camera images via OpenGL so I can change frames. When I test my app it works fine (I have an iPhone 4s Ios 5.1 in the Netherlands), but when I upload it to the AppStore to test it, it denies. They say the camera view is not working and they only get a black screen. I really don't know what to do because it works great for me. I am unable to reproduce the error.

Does anyone have the same problem as me? Or someone who knows what to do?


source to share

2 answers

I didn't include the framework, it wasn't necessary on the iphone 4s, it was on the iphone 4 ...



You don't say if you are using OpenGL ES 2.0 for this, but if you do, they may have tested your app on an iPhone 3G that lacks 2.0 support. You can filter out these unsupported devices by adding a key opengles-2

to yours UIRequiredDeviceCapabilities

in your Info.plist.

The second possibility is that you are trying to display a camera image that exceeds the tester's maximum OpenGL ES texture size. You can check this size , but on devices older than iPad 2, this maximum texture size is 2048x2048. On iPad 2, the new iPad Retina, and iPhone 4S, this texture size is 4096x4096. The iPhone 4 can capture images larger than 2048 pixels, which might explain why your camera view works on your iPhone 4S but shows a black image on older hardware.

In addition, there is also the remote possibility of using an OpenGL ES extension that does not exist on this older hardware, but I don't think any of the latest additions in the A5 chips would be useful for image processing. I think newer hardware also supports more textures, attributes and changes, but I would need to check that.

This is why I always try to test on the oldest hardware that has the minimum capabilities I need in my applications, because there are subtle variations in how different device GPUs handle things.



All Articles