Error "Error creating full framebuffer" using Google sdk maps for ios

Finding this problem only gave me messages that related to opengl items that I don't know about.

On my storyboard, I have 1 view in which I place a slightly smaller UIView object to act as a container for my map. This works great, not much code. I installed the UIView class GMSMapView . I CTRL - drag it to create an output on the corresponding viewController. After that, I create a GMSCameraPosition in a specific place. I set self.mapView , which is the output, for [GMSMapView mapWithFrame:CGRectZero camera:camera]; camera indicated at camera position i.

It seems that this works, the application starts without errors, and the map is displayed in the UIView that I created, but the camera position is not where I pointed. And I know that the position is valid because if I use self.view instead of self.mapView , the map is displayed on the whole screen in the correct position.

In the log I get the error Failed to make complete framebuffer object 8cd6 , and, as I already said, the messages regarding this did not make any sense to me, and I do not know what the problem is.

Help will be appreciated!

+7
source share
5 answers

There was a friend who helped me, thanks for the answer, but these answers are not the way I ultimately decided.

The code we use is:

 CLLocationDegrees lat = 59.34702; CLLocationDegrees lon = 18.04053; GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:lat longitude:lon zoom:10]; [self.mapView setCamera:camera]; 

We do not play with this frame at all, because it seems that the view automatically sets the map to a position not specified by me, using the size that it has in the storyboard. Therefore, we needed to add a camera, as in this example. It saved me from this error that I spoke of.

If someone has a better answer that can explain this more efficiently, it will be fine. But this works, just ctrl drag the View with the class set to GMSMapView as the output and add the code I wrote.

0
source

I wonder if this could be because you are initializing the map CGRectZero frame. I think that using CGRectZero intended to be used when the view is the root view of the view controller, i.e. it will be resized to full screen size. You may need to set the size, for example:

 [GMSMapView mapWithFrame:CGRectMake(0, 0, 300, 300) camera:camera]; 
+11
source

For me this leads to the fact that the map works / loads the correct coordinates, but still throws an 8cd6 error. Setup: Xcode 4.6.1 iOS 6.1 using storyboard

I have a view inside the main view / viewcontroller.

Make sure that the UIView (under the view, which should be a map) under the attribute tab β†’ class = GMSMapView, and is attached to the mapView property below

YourViewController.h:

 #import <UIKit/UIKit.h> #import <GoogleMaps/GoogleMaps.h> @interface YourViewController : UIViewController //other @properties @property (strong, nonatomic) IBOutlet GMSMapView *mapView;//linked to storyboard @end 

YourViewController.m:

 #import "YourViewController.h" #import <GoogleMaps/GoogleMaps.h> @interface YourViewController() @end /*.. ..other setup code ..*/ -(void)viewDidLoad{ [super viewDidLoad]; GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:-33.8683 longitude:151.2086 zoom:10]; self.mapView.camera = camera; } 

the 8cd6 error is related to the frame / borders (obviously). Something is not being called (or is being set?) If you try initWithFrame. The view loading hangs, and then by default the place is set under London. I did not edit setMapView for this solution, I just skipped setting the borders and let the storyboard take care of that.

Still hope someone finds a fix that clears the 8cd6 error though.

+2
source

I also came across this problem. My solution is not very elegant, but it works. Firstly, @sythnesize your exit to viewController.m (@synthesize mapView = _mapView;). Then write a custom setter:

 - (void)setMapView:(GMSMapView *)mapView { if (!mapView) { mapView = [[GMSMapView alloc] initWithFrame:CGRectZero]; } _mapView = mapView; } 

This will still give you the error you saw, but then in viewDidLoad mode (or somewhere else that will be called after loading the view) set the camera:

 self.mapView.camera = [GMSCameraPosition cameraWithLatitude:3 longitude:27 zoom:13]; 

Within a second of a second, the map will be incorrect, but I do not think that it is visible to the user.

0
source

This error appeared to me when I subclassed GMSMapView. I basically declared all the methods "did *" / "will *" and I found that an error occurred between willMoveToWindow and didMoveToWindow. Debugging willMoveToWindow I found that the frame was (0,0,0,0). I basically added this and the error went away.

 - (void)willMoveToWindow:(UIWindow *)newWindow { self.bounds = self.superview.bounds ; [super willMoveToWindow:newWindow] ; } 
0
source

All Articles