Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

crash when the the viewcontroller of PanoramaGL dismissModalViewController #18

Open
GoogleCodeExporter opened this issue Jul 2, 2015 · 6 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. I make a project refer to the PanoramaGL demo and use its pic reource
2. I touch the screen and move on it.but when the viewcontroller of PanoramaGL 
dismissModalViewControllerAnimated ,then the project crash because its delegate 
is delloced
3. how to resolve the problem

What is the expected output? What do you see instead?
-[_DViewController respondsToSelector:]: message sent to deallocated instance 
0x78bc550

What version of the product are you using? On what operating system?
the last version,

Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 24 Oct 2012 at 1:46

@GoogleCodeExporter
Copy link
Author

when i do not set its delegate.the viewdidload,do nothing and press a button to 
dismissModalViewControllerAnimated.and it crash

Original comment by [email protected] on 24 Oct 2012 at 2:09

@GoogleCodeExporter
Copy link
Author

I am having the same issue. Is there any resolution?

Original comment by [email protected] on 12 Nov 2012 at 6:15

@GoogleCodeExporter
Copy link
Author

I am having the same issue. Is there any resolution?
 *** -[PanoViewController respondsToSelector:]: message sent to deallocated instance 0x8ab80e0
(lldb) 


Original comment by [email protected] on 25 Jan 2013 at 5:45

@GoogleCodeExporter
Copy link
Author

I notice that in device debug mode, it is call dealloc method, so its not make 
crash in debug mode.
when i run app directly after installed, it will make crashed on PLViewBase.m
-(void)drawViewInternally
{
    if(scene && !isValidForFov && !isSensorialRotationRunning)
    {
        PLCamera *camera = scene.currentCamera;
        [camera rotateWithStartPoint:startPoint endPoint:endPoint];

        // COMMENTED BELOW LINE BECAUSE OF CRASH,,,,, WHEN DISMISS VIEW CONTROLLER......
        // UNCOMMENT BELOW IF BEHAVE ANY UNCONSISTANCY....
        ///*
         if(delegate && [delegate respondsToSelector:@selector(view:didRotateCamera:rotation:)])
         [delegate view:self didRotateCamera:camera rotation:[camera getAbsoluteRotation]];
        // */
        ////END,,,,,

    }
    if(renderer)
        [renderer render];
}


Any solution for this ?

Original comment by [email protected] on 25 Jan 2013 at 9:42

@GoogleCodeExporter
Copy link
Author

Hay, I solve issue.
need to force dealloc all live instance of PLView, before close.

This issue came because of it will not called dealloc method automatically, 
because of retain count is not reach to 0, due to any reason.

so, method dealloc does not called at dismiss view controller.


below is solution,


- (IBAction)btnCloseTouched:(id)sender {

    // force close/release PLViews objects....
    [(PLView *)self.view forceStop];
    [self.navigationController popViewControllerAnimated:NO];
}


in PLViewBase.m


-(void) forceStop
{   [self stopAnimation];
    [self reset];
    [self deactiveAccelerometer];
    if(isValidForTransitionString)
        [isValidForTransitionString release];
    if(currentTransition)
    {
        [currentTransition stop];
        [currentTransition release];
    }
    if(renderer)
    {
        [renderer stop];
        [renderer release];
    }
    if(scene)
        [scene release];

}

-(void)dealloc 
{
    [super dealloc];
}

hope this help.

Original comment by [email protected] on 25 Jan 2013 at 11:43

@GoogleCodeExporter
Copy link
Author

Hi��hardikda
     Thank you any way. The project I  develop has finished for a long time.I deprecated this framework because it has many other issues,eg:touch not smoothly and use much memory .Instead,I use panoramagl of HTML5  which effect is much better.but the software is paied.
     My English is just so so,hope you understand what I write��HaHa��






At 2013-01-25 19:43:18,[email protected] wrote:

Original comment by [email protected] on 13 Mar 2013 at 10:20

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant