• 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
Re: Storing images in subfolder of apps resource?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Storing images in subfolder of apps resource?


  • Subject: Re: Storing images in subfolder of apps resource?
  • From: "M. Uli Kusterer" <email@hidden>
  • Date: Mon, 14 Feb 2005 09:04:52 +0100

At 16:50 Uhr -0800 13.02.2005, Scott Andrew wrote:
I have a bunch of images that I want to organize in app as subfolders.. Can
I do this with XCODE? I would like to do the following:

Application\Resources\Asprite
                    Frame1.png
                    Frame2.png
                    Frame3.png

Aplication\Resources\Bsprite
                    Frame1.png
                    Frame2.png

Read the docs. Have you even looked at the NSBundle methods? There's a method to get the path of a folder inside "Resources" in there!


At 17:16 Uhr -0800 13.02.2005, Scott Andrew wrote:
Can ithen use..

[[NSBundle mainBundle] pathForResource:@"Resources/Asprite/Frame1"
ofType:@"png"]];

To get the path name?

Well, sure. If you had tried it you'd have known that. Though I'm not sure whether you really want what you wrote above, because this would get you the path of:


/path/to/MyApp.app/Contents/Resources/Resources/Asprite/Frame1.png

And personally I could do with one less "Resources" in there ;-)
--
Cheers,
M. Uli Kusterer
------------------------------------------------------------
       "The Witnesses of TeachText are everywhere..."
                   http://www.zathras.de
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Re: Storing images in subfolder of apps resource? (From: Scott Andrew <email@hidden>)

  • Prev by Date: Re: UDP SOCKETS!!
  • Next by Date: A intractable socket bind problem.
  • Previous by thread: Re: Storing images in subfolder of apps resource?
  • Next by thread: Re: Storing images in subfolder of apps resource?
  • Index(es):
    • Date
    • Thread