How can I animate a sequence of 10 Images in iPhone OS?
I have 10 small images that have to be shown quickly one after another in order to make an animation effect. Is there an easy way to do that, or must I implement an routine by myself? ...
I have 10 small images that have to be shown quickly one after another in order to make an animation effect. Is there an easy way to do that, or must I implement an routine by myself? ...
Is there any problem applying multiple transforms to a UIView and it's corresponding CALayer? Specifically, can you "mix and match" CATransform3Ds with CGAffineTransforms without running into issues? Also are there any problems with setting some transforms directly while animating another transform change simultaneously? Are there any...
I have a problem in my application. Any help will be greatly appreciated. Basically it is from view A to view B, and then come back from view B. In the view A, it has dynamic data loaded in from the database, and display on the table view. In this page, it also has the edit button, not on the navigation bar. When user tabs the edit b...
I'm trying to mock a UITabBarController in my app's tests. I have a category method on that class defined elsewhere in another file that gets imported along with ocmock in my test class. what i'm trying to so is this: - (void) setUp { id mockTabController = [OCMockObject mockForClass:[UITabBarController class]]; [[[mockTabCont...
When you drag a finger across the iPhone touchscreen, it generates touchesMoved events at a nice, regular 60Hz. However, the transition from the initial touchesBegan event to the first touchesMoved is less obvious: sometimes the device waits a while. What's it waiting for? Larger time/distance deltas? More touches to lump into the eve...
Hi all, I'm writing an application that uses your finger to draw simple diagrams. I have it working for the most part but now I'm trying to optimize its performance. When the user swipes their finger fast, I can't capture enough touch events to draw a smooth path. Here's my current approach: 1) I subclassed a UIView and added a porop...
Hello, I been trying this in my code and it doesn´t work: NSArray *paths = [aUITableView indexPathsForVisibleRows]; An empty NSArray is returned. But if I do this in the previous line it works fine....is this a framework bug? NSArray *cells = [aUITableView visibleCells]; NSArray *paths = [aUITableView indexPathsForVisibleRows]; The...
I currently have 1 UIView where I do custom drawing. I want to overlay that view with another view which has a few controls (label, button, etc). This overlayed view will be transparent so you can see the drawing view. 2 Questions: 1) Should I make the drawing view a sibling or child of the overlay view? 2) If its a child, do touch eve...
I'm not sure, but maybe there's a way to determine the finger pressure on the iPhone screen? I know it has no pressure sensors, but it could be somehow calculated from the touch "footprint", if it was accessible in some way. ...
I give it 0 and 400 and it returns me sometimes values above 400. That doesn't make sense. - (float)randomValueBetween:(float)low andValue:(float)high { return (((float) arc4random() / RAND_MAX) * (high - low)) + low; } that's actually a snippet I found on the net. Maybe someone can see the bug in there? ...
I have this code to mask an image. Basically, I only work with PNG images. So I have a 300x400 PNG image with 24bits of color (PNG-24). I am not sure if it also has an alpha channel. But there's no transparency in it. Then, there is the image mask which is PNG-8bit without alpha channel. It is just black, grayscale and white. I create...
I have a UIView that I am trying to render into a UIImage using [CALayer renderInContext:]. However, I find that the resultant image is flipped vertically. I kind of expect this due to the different coordinate systems. However, I then try and flip the context back to normal with an affine transform - but it doesn't have any effect: CGAf...
Currently I have an user interface that makes incredible heavy use of core animation. I wonder if it is worth to spent another 2 months for learning openGL ES? Does that really improve drawing performance for 2D surfaces? I have no 3D objects, but highly animated 2D stuff. Sometimes with 3D distortions, a lot of rotations and scaling. I...
Some methods of my class need to know how many times the class has been loaded. Do I need a Singleton for this, or are there other ways to do this? Are there static variables that I can attach to the class and then just increment them every time a viewDidLoad? When the application starts, that value is resetted (=0). I'm not such a big ...
I need a kind of "screenshot" from everything that's displayed in an UIView. Maybe there's a way to just access the image data that the renderer generated to display the contents on screen? ...
Apple says: removeFromSuperview Unlinks the receiver from its superview and its window, and removes it from the responder chain. (void)removeFromSuperview Never invoke this method while displaying. So, when I want to get rid of a view, I was used to just kick it off from it's superview. Why should I never in...
I have an UIImage and want to shift it's saturation about +10%. Are there standard methods or functions that can be used for this? ...
I create a context from an UIImage, and then I draw into it with CGContextDrawImage(bitmapContext, CGRectMake(0, 0, originalImage.size.width, originalImage.size.height), oImageRef); the image appears upside-down due to the flipped coordinate system in quartz. How can I fix that? ...
I didn't notice much performance lost by doing this. So I wonder if it doesn't hurt when I re-use the same UIImage multiple times at the same time inside multiple UIImageViews? ...
Hello, I use ABUnknownPersonViewController to display a contact view. I try to set an image with: NSData *dataRef = UIImagePNGRepresentation([UIImage imageNamed:@"contact3.png"]); ABPersonSetImageData(newPersonViewController.displayedPerson, (CFDataRef)dataRef, nil); It doesn't work and I don't know why. Any ideas? ...