iphone

Possible to layer different Videos with alpha Channels?

Hi, like i said, i want to know if it´s possible to layer different videos with alpha channels? So for example i have 3 videos playing layered. Then i want to change on runtime the second layer. Does that work on the iPad? I´ve no idea. I´ve only read that you can display a video in a single view since the iOS 3.2 Version, but playin...

How to make cocos2d sprite scale up and down (for a pulsating effect) every second?

I want to have a sprite scale up and down once every second to make it seem like it is bulging and pulsating. How can I do this? ...

iPhone: Is it possible to have an 'info'-button in all views in my app?

Hi, As mentioned in the title, how do I implement such a functionality? I am using the code below, (in my viewDidLoad), to get the button on my Navigation Controller of my main view. UIButton* infoButton = [UIButton buttonWithType:UIButtonTypeInfoLight]; [infoButton addTarget:self action:@selector(viewWillAppear:) forControlEvents:UI...

"Terminating app due to uncaught exception 'NSInvalidArgumentException'" error with stringByTrimmingCharactersInSet on iPhone.

I am reading JSON data back from a server, and I am trying to parse a particular string that contains an HTML URL. The data is in an NSString called current_weatherIconUrl2. The console output from Xcode is below: 2010-07-06 17:17:46.628 WhatToDo[13437:20b] Current Condition: URL2: ( "http://www.worldweatheronline.com/images/wsymb...

App crashes on invoking CGPDFContentStreamWithPage

Hi all, I am trying to parse a PDF and extract catalogue from it. For this purpose I am using following code: - CGPDFPageRef page = CGPDFDocumentGetPage(document, currentPage); //1 myContentStream = CGPDFContentStreamCreateWithPage (page); //2 myScanner = CGPDFScannerCreate (myContentStream, table, NULL); //3 CGPDFScannerSca...

pedometer application

I try to calculate a miles per hours. For this I write a code like this mint=sec/60; hour=mint/60; mph=miles/hour; nsstring *speed=[nsstring stringwithformat:@"%5.2f",mph]; [mph settext: speed]; I get a miles from this code miles = (steps *steplength)/1500; NSString *distance =[NSString stringWithFormat:@"%5.3f",TotalDistance]; [Mi...

How to tell if view has appeared via popping or not?

Using a UINavigationViewController, how do I find out how a view has appeared? The view has either appeared in a straightforward manner, as the first view in the UINavigationController stack. Or it has appeared because a second view has been popped and the first view has revealed itself again. How do you find out which of these happened...

Push Notification not coming on device from server through APNS to device

What are the reasons,that push notification is not coming on my device when my app is not running ...

iPhone paint app (glPaint based). Blending with white background.

Hi, I'm developing painting app. I've tried to do it with CoreGraphics/Quartz 2D and drawing curves algorithm is pretty slow. So we've decided to switch to the OpenGL ES. I've never had any OpenGL experience, so I found glPaint example from apple and started play with it. I've changed erase method do make white background. How I stuck...

iPhone application development using PhoneGap

Hi All of You, I am interested to develop iPhone applications Using PhoneGap. PhoneGap is an Open-source development tool,by Nitobi team using HTML,CSS and JS. The main use of PhoneGap is for making webApps to look like a native iPhone applications. As i googled, i found the below one, to start the application. http://building-iphone-...

What silly noob mistake am I making here?

I have a method: - (CGPoint) calculateVectorBetweenThisPoint:(CGPoint)firstPoint andThisPoint:(CGPoint)secondPoint { float xDif = firstPoint.x - secondPoint.x; float yDif = firstPoint.y - secondPoint.y; return CGPointMake(xDif, yDif); } And I try to invoke it as follows: - (float) angleBetweenThisPoint:(CGPoint)firstPoin...

iPhone HTTP Request Security

hey I don't know much about these type of things so please excuse the NOOBness I am sending a HTTP Request to a server and I want the server to know that the request is authentic, so I have a p12 with a certificate and key (pre-made by the server) bundled with my application that I extract and use as a credential when I send my request...

iOS4 - fast context switching

Hi All, When application enters in background running state, how much dirty memory usages is good to go. In apple video it's mentioned that the dirty memory should be reduced as much as we can. But in my App, I am using navigation controller to push and pop views. After moving from about 20 different pages, the dirty memory usages reac...

Cannot load alternating urls with UIWebview

I have one view holding a list of videos(buttons which can be clicked, each hold a url) which currently bring up a new view which holds the UIWebview, the only problem is I cant pass the url to the webview depending on which button was clicked. At the moment I just get an empty UIWebview. How can the url string be passed to the webvi...

How to get indexPath from one class to another

I have an app where my primary view is a tableview. where each cell loads another view containing certain data. Now, each cell is different so the data in the view loaded by each cell should be different. For that I need the indexPath. I've created a class for the TableView and another class for a simple UIView. How do I forward the inde...

Prevent duplicates when importing RSS feed to Core Data

Trying to import a RSS feed into Core Data. Once they are imported, when trying to update the feed again afterwards, how do I most efficiently prevent duplicates. Right now it checks every item against the datastore during the parsing, which is not very efficient. I looked into the Top Songs sample from Apple. It uses a least recently u...

UISearch bar for pickerView

Hi all Can any one please help me as to how to use a search bar for a picker view. What i want to do is i have a view which when clicked gives me a pickerview. the picker view has a search bar on top of it. when anything is entered in the search bar the picker view should rotate and align to the word matching in the array and all the con...

UIView drag event

I have an slide show application. There is a UIView on main screen, I want when someone slide his fingers horizontally it moves to next screen. What this event is called? (slide fingers horizontally/vertically) How can i detect this event? Want to call a method xyz on this event ...

UITextField resign first responder iOS4

Hi Everybody! I have a simple piece of code that works on every system except iOS4. It's about resigning first responder for a UITextField. The text field is all wired up, and here's the code for the delegate: - (BOOL)textFieldShouldReturn:(UITextField *)textField{ [opis resignFirstResponder]; return YES; } I've tried it almo...

Get to the view controller that pushed the visible view controller

I have an app that has a UINavigationController that pushes a UITabBarController into view. This UITabBarController has four tabs, one of which shows a custom UIViewController, an instance of EventInformationViewController. A button in this custom view controller in turn pushes another custom view controller EventRatingAddViewController ...