Questions tagged [iphone-4]

The iPhone 4 is the fourth version of the iPhone released by Apple, Inc. Use this tag for questions specific to this platform. Don't confuse with the iPhone 4S.

The iPhone 4 is the fourth version of the iPhone released by Apple, Inc. Use this tag for questions specific to this platform. Don't confuse with the iPhone 4S.

Resource

303 questions
154
votes
12 answers

Xcode: Could not locate device support files

As I am trying to run my application from a newly updated Xcode 8 to my iPhone 4 which is running iOS 7.1.2, it throws the below error, And, this is my Xcode version, How can I fix this problem?
Praveenkumar
  • 24,084
  • 23
  • 95
  • 173
31
votes
4 answers

Compensating compass lag with the gyroscope on iPhone 4

I've been experimenting with the compass and gyroscope on iPhone 4 and would like some help with an issue I'm having. I want to compensate for the slowness of the compass by using data from the gyroscope. Using CMMotionManager and its CMDeviceMotion…
donkim
  • 13,119
  • 3
  • 42
  • 47
28
votes
3 answers

iPhone 4 Camera Specifications - Field of View / Vertical-Horizontal Angle

Does someone know the field of view values for the new iPhone4 camera? I'm doing some AR app's, and I want to know the horizontal and vertical angle of the rear camera. Thanks!
mguellsegarra
  • 465
  • 1
  • 5
  • 11
24
votes
6 answers

Reading the iPhone's Ambient Light sensor

I notice on my iPhone, after a few seconds of being in direct sun light, the screen will adjust to become brighter, dimmer etc. I was wondering if there was a way to interact with this sensor? I have an application which is used outside. When you…
George Johnston
  • 31,652
  • 27
  • 127
  • 172
23
votes
11 answers

Detect retina screen/iPhone 4 in iPhone SDK

In my application I am downloading some images from the web (from my server to be precise), in order to save some bandwith and especially memory on the phone, I provide them in two resolutions: 480x320 for the "old" iPhone series and in 960x640 for…
Robin
  • 8,197
  • 11
  • 45
  • 74
20
votes
5 answers

iPhone 4 Retina "apple-touch-startup-image" for Web-apps

This has been asked multiple times here, but without a solid and understandable answer. This is a web-app, not a native-app. I'm using: to display the startup image. It loads fine…
20
votes
2 answers

Need to access the default camera shutter sound used by the iPhone

Right now when a user presses a button I play a custom camera shutter sound. However, if possible, I would much rather just use the camera shutter sound that plays by default whenever you take a photo using your iPhone. Is there a way that I can…
user3344977
  • 3,584
  • 4
  • 32
  • 88
19
votes
2 answers

How use CGImageCreateWithImageInRect for iPhone 4 (HD)?

I use the following code to getting images from the sprite. And it works fine everywhere except the iPhone 4 (HD version). - (UIImage *)croppedImage:(CGRect)rect { CGImageRef image = CGImageCreateWithImageInRect([self CGImage], rect); …
Victor
  • 3,497
  • 3
  • 39
  • 51
18
votes
5 answers

Enabling the photo library button on the UIImagePickerController

Does anyone know how to enable the photo album button on the UIImagePickerController when its in the camera mode? Like how the camera app on on the iphone can toggle between image and video taking and also has the button to view the photo library?
MBU
  • 4,998
  • 12
  • 59
  • 98
15
votes
3 answers

iPhone 4 iOS5 Core Plot and ARC error:"The current deployment target does not support weak references"

I've converted my project to iOS 5 and enabled ARC. Now I need to integrate core plot with the project. When I try to instantiate a sample controller included with the Core Plot, I get about 20 errors as follows: The current deployment target does…
Alex Stone
  • 46,408
  • 55
  • 231
  • 407
15
votes
2 answers

What is the best way for supporting both screen resolution of iPhone4 and iPhone5 ? - Auto layout in only iOS6

Have anyone figured out how to support both screen resolution iPhone4 and iPhone 5 ? In iOS6 we have support of Autolayout. Can that be used for iPhone4-iPhone5 screen i.e. 320x480 and 320x568. If we use auto layout feature for that we will have to…
Janak Nirmal
  • 22,706
  • 18
  • 63
  • 99
12
votes
7 answers

Location services don't stop when application is terminated

I'm currently developing an iPhone application which needs location services for various use including AR. I test everything on simulator and on my iPhone 3GS and everything went well. I recently tested on iPhone4 and on iPad2 and the location…
Jaffa
  • 12,442
  • 4
  • 49
  • 101
11
votes
3 answers

CGContextDrawImage in Retina draws image pixelated?

I need to draw images into a CALayer because I need to perform various effects, animations and filters on it. When I do simple drawing into the CGContext no matter what I do it always gets drawn pixelated... What's the right way to draw onto a…
shein
  • 1,834
  • 15
  • 23
11
votes
2 answers

Images for retina display iphone

I have an working application which i have tested in my ipod touch. Everything works pretty fine. My tabbar icons and splash screen images are in a separate folder in my Resources folder Resources->images Now, I know for iPhone4 i need to use 2x…
Neelesh
  • 3,673
  • 8
  • 47
  • 78
10
votes
4 answers

How do I test the equality of two CLLocations

I'm having a problem with isEqual: The code: if (currentAnchor isEqual:currentBusiness.getCllLocation)) { do a; } else { do b; } currentanchor and currentbusiness.getCllocation are locations But if they are the…
user4951
  • 32,206
  • 53
  • 172
  • 282
1
2 3
20 21