• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Adding an image to a project
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Adding an image to a project


  • Subject: Adding an image to a project
  • From: Vincenzo Morgante <email@hidden>
  • Date: Wed, 14 Jul 2010 11:12:10 +0000 (GMT)

Hi, I'm a newbie and I should use an image and show it, so I should put this image into the resources directory within my XCode project. How can I load the file containing this image? I should use this file in order to create an IplImage object (see OpenCV), but the image is not found.
If I specify the complete path, for example "Users/myName/Desktop/image.png", the image is loaded without any problems, but if I want to load it from resources directory, it doesn't work because the image is not found.

IplImage *image = cvLoadImage("Users/myName/Desktop/image.png", ...);
The above code works because the path is full, I would include the image into the executable.

How could I resolve the problem?

Thanks a lot!

Vincenzo





_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Adding an image to a project
      • From: Sam <email@hidden>
    • Re: Adding an image to a project
      • From: Graham Cox <email@hidden>
  • Prev by Date: iPhone, Bindings, and KVO
  • Next by Date: Re: Adding an image to a project
  • Previous by thread: iPhone, Bindings, and KVO
  • Next by thread: Re: Adding an image to a project
  • Index(es):
    • Date
    • Thread