-[<CALayer: 0x5584190> display]: Ignoring bogus layer size (255211754908294243945860531626574872576.000000, 340282346638528859811704183484516925440.000000)
Can any one please tell me what's this warning about? The app is crashing on some devices showing this.
Any suggestion would be greatly helpful.
I believe this is caused because the layer is too large and I expect this will cause issues buffering to an image for drawing.
I had this problem with a large UIView with relatively simple graphics and solved it by using a CATiledLayer
To do this, include the following in your UIView subclass to enable tiling:
+ (Class)layerClass {
return [CATiledLayer class];
}
I just encountered this error in a view controller that was being presented in a popover. The "ignoring bogus layer size" error was occurring when the popover was presented, and as a result a text field within the view controller did not render its text.
In my case, moving a textField.becomeFirstResponder()
call from viewWillAppear
to viewDidAppear
resolved the issue.
I spent a bit of time trying to find the answer to a similar question, I was getting:
[<CALayer: 0x37d540> display]: Ignoring bogus layer size (nan, nan)
but only on a device, not on the simulator.
My problem was due to the fact that I was loading images out of the applicationCacheDirectory
and it turns out the files had a mix of upper and lower cases in my project director. But in the Cache directory on device, they were all changed to lower case. Hope this helps someone in the future.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With