About camera option

Discussion in 'iOS Programming' started by iphonejudy, Jun 26, 2009.

  1. iphonejudy macrumors 6502

    iphonejudy

    Joined:
    Sep 12, 2008
    #1
    I used the below code.It displays No camera.

    What i need to do ?


    i
    Code:
    f ( (![UIImagePickerController isSourceTypeAvailable:UIImagePickerControllerSourceTypeCamera])
    
    {
    
        NSLog(@"No camera");
    
    }
    
     
  2. robbieduncan Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #2
    Do you have a camera on the device? Are you running in the simulator?
     
  3. iphonejudy thread starter macrumors 6502

    iphonejudy

    Joined:
    Sep 12, 2008
    #3
    I am running in the simulator
     
  4. robbieduncan Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #4
    Well that's your answer: the simulator does not have a camera so that is as expected. If you want to test camera functions you need to test on a device.
     
  5. iphonejudy thread starter macrumors 6502

    iphonejudy

    Joined:
    Sep 12, 2008
    #5
    Can' t we check in Simulator 3.0 also ?
     
  6. robbieduncan Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #6
    Read the release notes and see. I'm not about to do it for you. I know for a fact that there is no camera support in the Simulator in earlier versions.
     
  7. iphonejudy thread starter macrumors 6502

    iphonejudy

    Joined:
    Sep 12, 2008
    #7
    thanks
     

Share This Page