Hey guys at Stackoverflow!
I need your help within my code. I wrote a little application which blurs the camera in real time.
For this I used the GPUImage framework from Brad Larson (Thanks to Brad Larson)!
Now I want to remove the blur from the camera with an animation. This animation should have a duration of 2 seconds. So I've set up my code to remove the filter from my camera like this:
-(IBAction)BtnPressed:(id)sender {
[UIView animateWithDuration: 2
animations:^{
[(GPUImageTiltShiftFilter *)filter setBlurSize:0.0];
}];
}
As far as I know the code should work. However, I run the application and push the button, but the filter was not removed within two seconds.
It was removed in less than one second, which means that the code above doesn't work.
I tried to put some code to change the alpha
with an animation, like this:
-(IBAction)BtnPressed:(id)sender {
[UIView animateWithDuration: 2
animations:^{
fstBtn.alpha = 0.0;
}];
}
This code worked very well with a duration of two seconds. I can't see a solution for this. I really would appreciate your help.
Thanks in advance,
Noah