Skip to main content

Posts

Showing posts with the label ios4

Edge Detection of Image in iPhone Using Image Magick

I want to convert RGB image into Below Image. I am using ImageMagick Library . I want help to know that by which functions i can convert in Original Image into Image-2. Here is below two images. I would like to use Only ImageMagick Library. I would like to do Image Processing simillar to this Link in Objective C.

Compile PHP with GD for iPhone OS 4.1

The Goal: have a working version of PHP with the GD library working on an iPod Touch 4th Gen. The Status: PHP is working on the iPod (lighttpd + PHP 5.2.8 + sqlite3) without GD. When trying to compile PHP on the iPod I get this error: http://pastebin.com/kUmgq70G The Proposed Solution: Can anyone point me in the direction of how to compile PHP with GD and then package it up nicely as a .deb file for everyone else to use? The best situation I believe is to compile the latest version of PHP with the GD library included and enabled. Second best would be to settle for compiling GD as a module and then installing that into the currently working PHP that is available from Cydia. However to compile GD you would have to do this with the SAME source that was used to create the php_5.2.8-3_iphoneos-arm.deb available from Cydia - I think it would be easier and safer for everyone in the future to just compile a fresh PHP with GD already enabled and then pack it up as a .deb Here

Create text Stroke for UILabel iphone

I was wondering how can I create text stroke for UILabel in iOS4 ? I need some suggestion . I want something like this : EDITED : UIFont *font = [UIFont fontWithName:@"Arial" size:222]; CGPoint point = CGPointMake(0,0); CGContextRef context = UIGraphicsGetCurrentContext(); CGContextSetRGBFillColor(context, 1.0, 1.0, 1.0, 0.7); CGContextSetRGBStrokeColor(context, 2, 2, 2, 1.0); CGContextSetTextDrawingMode(context, kCGTextFillStroke); CGContextSaveGState(context); // I change it to my outlet [label.text drawAtPoint:point withFont:font]; CGContextRestoreGState(context); Source: Tips4all

NSDateFormatter"s init method is deprecated?

Per http://developer.apple.com/iphone/library/documentation/Cocoa/Reference/Foundation/Classes/NSDateFormatter_Class/Reference/Reference.html The init method of NSDateFormatter is "Available in iPhone OS 2.0 through iPhone OS 3.2", and therefore not in 4.0. Now, it certainly works, but this seems odd. Is this is a mistake or is there some other way to create a NSDateFormatter ?

Exit application in iOS 4.0

Before iOS4.0 clicking the home button on iPhone exits the application, and Apple had in their guide that programmatically exiting the application was not accepted. now everything changed in iOS4.0, clicking the home button puts your app in a suspended mode (multitasking).. and I think there should be a clear way for the user to exit the app, like an exit button. is it now OK with apple? and how can it be done?

Play local notification default sound when displaying UIAlertView?

I'm writing a reminders app for iPhone that displays reminders using local notifications. If a reminder goes off while the application is running, the local notification isn't displayed. Instead, the didReceiveLocalNotification method is called in my app delegate, and I mimic the local notification dialog by displaying a UIAlertView with the reminder text. When local notifications are displayed outside of the app, the device vibrates and the sound specified by UILocalNotificationDefaultSoundName is played. Again, I'd like to mimic this in the app when displaying the UIAlertView . I can vibrate the device by calling AudioServicesPlaySystemSound(kSystemSoundID_Vibrate) , but I can't figure out how to play the local notification default sound. There's no equivalent SystemSoundID constant, and I'm not sure what the path would be. tl;dr I'd like to play the local notification default sound when displaying a UIAlertView. Any ideas?

iPhone iOS 4.0 Camera FigCreateCGImageFromJPEG returned -1

Since I updated to 4.0, when I take a photo with my App using UIImagePickerController I get the following error output: * ERROR: FigCreateCGImageFromJPEG returned -1. Input (null) was 711733 bytes. I still get the image returned and can continue as normal, but does any body know what and why I get this error. I also get the following warnings that could be related: Using two-stage rotation animation. To use the smoother single-stage animation, this >application must remove two-stage method implementations. Using two-stage rotation animation is not supported when rotating more than one view >controller or view controllers not the window delegate Any information would be of great help. Thanks in advance.

While sending SMS, application is crashing

I want to send sms using below code in iPhone 4, but the application is crashing due to this code only. if ([MFMessageComposeViewController canSendText]) { MFMessageComposeViewController *smsComposerController = [[[MFMessageComposeViewController alloc] init] autorelease]; [smsComposerController setBody:@"First SMS"]; smsComposerController.recipients = [NSArray arrayWithObjects:@"9886333333",@"9980444444",nil]; smsComposerController.messageComposeDelegate = self; [smsComposerController release]; } I am new for SMS sending , so can any one help me what I am doing wrong?

post and delete method for ios devices

Adding a playlist to youtube account POST /feeds/api/playlists/PLAYLIST_ID HTTP/1.1 Host: gdata.youtube.com Content-Type: application/atom+xml Content-Length: CONTENT_LENGTH Authorization: AuthSub token="AUTHORIZATION_TOKEN" GData-Version: 2 X-GData-Key: key=DEVELOPER_KEY <?xml version="1.0" encoding="UTF-8"?> <entry xmlns="http://www.w3.org/2005/Atom" xmlns:yt="http://gdata.youtube.com/schemas/2007"> <id>VIDEO_ID</id> <yt:position>1</yt:position> </entry> delete playlist of youtube account DELETE /feeds/api/users/USERNAME/playlists/PLAYLIST_ID HTTP/1.1 Host: gdata.youtube.com Content-Type: application/atom+xml Authorization: AuthSub token="AUTHORIZATION_TOKEN" GData-Version: 2 X-GData-Key: key=DEVELOPER_KEY HOW DO I SEND THIS BOTH METHOD TO YOUTUBE SERVER IN IOS AND GET RESULT. ihave all require data (e.g. token and allthat) but idont know how to send this post and delete method

DETECT Speaking Language- iPhone

I can covert the speech that a user spokes to text using Open ears (see http://www.politepix.com/openears/yourapp ). But How i could detect the language which the user speaks is English, french, chinese etc... Is there any method to understand in which language the user speaks? How can i check this.? Any help would be appreciated. Thanks Can I play any thing with this - (NSError *) generateLanguageModelFromArray:(NSArray *)languageModelArray withFilesNamed:(NSString *)fileName;

warning: UUID mismatch detected with the loaded library

i have been getting this since updated to 5.0.1 warning: UUID mismatch detected with the loaded library - on disk is: /Users/alfredjunco/Library/Developer/Xcode/iOS DeviceSupport/5.0.1 (9A405)/Symbols/System/Library/Frameworks/CoreLocation.framework/CoreLocation i also got this one but i don't know if it matters unable to load symbol file: warning: Unable to read symbols for /Library/MobileSubstrate/MobileSubstrate.dylib (file not found). warning: No copy of MobileSubstrate.dylib found locally, reading from memory on remote device. This may slow down the debug session.

Can i sell ticket in an iphone app without IAP

I'm building a app for an online service that sell tickets on their website. We want to allow people to buy ticket from the iphone but we can't use in app purchase as it cost too much. So my question is, can we have a button on the Event detail view "View Tickets", then when clicked do on of the follow preferably the 1: Open a webview from the app that display the mobile optimized website. Open safari on the event detail screen. Thanks.