iphone

How do I process iPhone camera data and overlay a 3-D object on it?

I am trying to develop an Augmented Reality iPhone application in which I will place a 3D object in front of a live camera feed. I need to zoom in and zoom out the object as the user moves backward/forward, and rotate the 3D model as the user walks around. Is there a way to do this on the iPhone ? ...

Is this a memory leak?

Hi all, I have the following 2 code snippets. Assume I have a Parent class and in Parent.h class I have @property (retain) NSMutableArray *childrens; and I have synthesize it in the .m file correctly. assume in Parent.m file -(void) dealloc { [childrens release]; [super dealloc]; } In another class I declare like this. 1. P...

MPMoviePlayerController re-orientation portrait to landscape and back to portrait (iOS 4.1)

Since iOS 3.2 the MPMoviePlayerController class allows to embed a movie in the view hierarchy. Now I'm facing this issue: I create my portrait view by placing an instance of MPMoviePlayerController. When the user touch the "fullscreen" button this view enters in fullscreen mode but the view remains in portrait. When the user rotates the...

UISplitViewController Vs Custom Made Views...

Hi everyone, I have an app in the iPhone that is something like that is a Home Screen when you click a button and you go into a Navigation Controller with Master Detail table views. I want to transfer the app to iPad and was looking at UISplitView controller and find out that must be in the main window and the first thing displayed whe...

Can't use button after using the Shake method.

Hi, I have a trouble with my app. I'm using the shake function, so that, when I shake the device, I change from one view to another.What happens is that when I change the view, I can't resign the FirstResponder from the shake function and I can't use the button that appears in the following view. I can't do anything Anybody can help me ...

How to add TabBar in Navigation bar app

My first two view are Navigatinbased table view controllers. The third view is a tab bar with tabs based on selected row. My problem is I am using TabBar based app so for first two view I have used presentModelView, but when user select a row I should open Tabbar view with same transaction(animation) as we have in navigation controller,...

Core Data with pre populated sqlite3 file

I'm working on an iPhone app that uses NSURLConnection to down load files and then convert those files into sqlite3 tables. I would like to use core data to store these tables and to create all the applicable objects. So, do I have to build the models of the data in XCode with the graphical tool representing all the table names and colum...

How to hide control before MPMoviePlayerController movie is played?

Assume iOS 3.2 or later. What is the proper sequence of command to play a move with the controls initially hidden. When the movie is playing, the user has the option to tag on screen and show controls. Thanks! My (control not hidden) code: - (void)playMovie { NSURL *url = [NSURL fileURLWithPath:[[NSBundle mainBundle] pathForResour...

Where should i be using removeFromSuperview in relation to adding views to a table?

Hi guys, I have a little table that works pretty well. But I was told to remove my subviews at some stage incase the call to drawn the table happens again for whatever reason. I was told it can be handled using removeFromSuperview. Where and how should i handle this? I need to use tags to identify the cells or views? Here is my code t...

iPhone "multistep" animations?

tl;dr: How do I combine multiple UIView block-based animations into a single conceptual unit such that UIViewAnimationOptionBeginFromCurrentState works as expected? I'm attempting to implement multi-step animations for re-orienting the screen on an iPhone. I've enabled orientation notifications and am using animatewithDuration: to exe...

CGContextDrawPDFPage memory leak

I have used CGContextDrawPDFPage two times in my project. One is for displaying the PDF and the other is for making the thumb image of the PDF. I am using the PDF to image code from http://github.com/0xced/pdfrasterize/blob/master/CGPDFAdditions.c I am calling the PDF to image method like this in my code NSURL *url = [NSURL fileURLW...

Load image asynchronously from file

I have an relatively image in local storage, I want to show it to the user without disturbing UI thread. I'm currently using [[UIImage alloc] initWithContentsOfFile:path]; to load image. Any suggestions/help please.... ...

Zooming multiple subviews in an UIScrollView

How would I go about zooming multiple subviews of an UIScrollView simultaneously? I have a UIScrollView inside another UIScrollView (with paging enabled) and inside the inner scrollview I have four UIImageViews. I would like for the zoom to persist when I scroll to the next page, thus displaying the next image. Relevant code follows: -...

Is the a way to turn off the UITableView delegates temporarily?

I have a UITableView with the usual table view delegates. The problem is that the table is built from core data .. so when my refresh method runs it refills the core data entities. I think this means that the data for the table is unstable, and hence it crashes on a line like this (in 'cellForRowAtIndexPath'): cell.textLabel.text = [obj...

UIButton modify image of UIImageView

Hi guys, I'm developing an iPhone app, and I need a little help. I created a button and I want when I click on to change an image's imageView by the button's one. the image and button : CGRect slot1Rect = CGRectMake(70, 90, 80, 110); UIImageView *slot1 = [[UIImageView alloc] initWithFrame:slot1Rect]; [slot1 setImage:[UIImage im...

iPhone - Save and download user comments to and from the internet

I have a photogallery in my app that I want users to be able to comment on, adding funny captions, and I want users to be able to click Thumbs Up or Thumbs Down. What is the best way to store and load the comments and thumbsup/down information? I'm a bit of a noob to the iOs and am assuming I would have my own website hosting a mysql d...

using glTexSubImage2D in opengl es 1.1

I am sending an opengl 3D scene across an IP link to my iPhone app built using SDK 4.1. I render the 3D scene first using FBO, read it with glReadPixels and send it to the iphone app. If I convert the pixel data received by the app to UIImage, I see it is displayed correctly. But when I use the same data in glTexSubImage2D using opengl e...

iphone app system clock & sleep independent tick count

Is there any way to maintain a tick count in your iphone app which is : (1) independent of system clock (2) is not impacted by device sleep ( unlike CACurrentMediaTime(),UpTime() etc.) ...

iphone simulator and "DONE" keyboard button for UITextField

Hello, I have problem probably the same like this guy: When clicking on text field, after entering data, "done" button doesn't work?? Is it iphone simulator issue? Please tell me how to get the "done" button work with Interface Builder only. Solution: After googling for 50min I finally understood my problem. And now in plain english...

How to create animation like water fall on wall and then spread out drops on wall ?

I need to create animation that images of water come out from bottom of view and then at middle of view at fall like water fall on wall or on ground and drops spread out here and there using core animation. I tried to use transformation & scaling with CABasicAnimation but failed to create that type of animation. how to do that ? ...